(id: str)
| 163 | @staticmethod |
| 164 | @extension.extensible |
| 165 | def remove(id: str): |
| 166 | with AgentContext._contexts_lock: |
| 167 | context = AgentContext._contexts.pop(id, None) |
| 168 | if context and context.task: |
| 169 | context.task.kill() |
| 170 | return context |
| 171 | |
| 172 | def get_data(self, key: str, recursive: bool = True): |
| 173 | # recursive is not used now, prepared for context hierarchy |