Get current context ID, defaulting to 0 if not set.
(self)
| 135 | ) |
| 136 | |
| 137 | def _get_context_id(self) -> int: |
| 138 | """Get current context ID, defaulting to 0 if not set.""" |
| 139 | return self._context_id if self._context_id is not None else 0 |
| 140 | |
| 141 | def _build_memory_config(self, context_id: int) -> Any: |
| 142 | """Build memory configuration based on text_mem_type. |