(config: DictConfig,
key: str,
default_user_id: str | None = None)
| 17 | |
| 18 | |
| 19 | def get_memory_meta_safe(config: DictConfig, |
| 20 | key: str, |
| 21 | default_user_id: str | None = None): |
| 22 | if not hasattr(config, key): |
| 23 | return None, None, None, None |
| 24 | trigger_config = getattr(config, key, OmegaConf.create({})) |
| 25 | user_id = getattr(trigger_config, 'user_id', default_user_id) |
| 26 | agent_id = getattr(trigger_config, 'agent_id', None) |
| 27 | run_id = getattr(trigger_config, 'run_id', None) |
| 28 | memory_type = getattr(trigger_config, 'memory_type', None) |
| 29 | return user_id, agent_id, run_id, memory_type |
no outgoing calls
no test coverage detected