MCPcopy Create free account
hub / github.com/AQ-MedAI/MedMemoryBench / query

Method query

methods/mirix_agent.py:686–703  ·  view source on GitHub ↗

Query the agent with memory-augmented response. If use_native_query is True, uses MIRIX's native send_message() which automatically retrieves relevant memories and generates response. Otherwise, falls back to manual retrieval + external LLM call.

(
        self,
        question: str,
        system_message: Optional[str] = None,
        **kwargs
    )

Source from the content-addressed store, hash-verified

684 return []
685
686 def query(
687 self,
688 question: str,
689 system_message: Optional[str] = None,
690 **kwargs
691 ) -> AgentResponse:
692 """Query the agent with memory-augmented response.
693
694 If use_native_query is True, uses MIRIX's native send_message() which
695 automatically retrieves relevant memories and generates response.
696 Otherwise, falls back to manual retrieval + external LLM call.
697 """
698 start_time = time.time()
699
700 if self.use_native_query:
701 return self._query_native(question, system_message, start_time)
702 else:
703 return self._query_manual(question, system_message, start_time)
704
705 def _query_native(
706 self,

Callers

nothing calls this directly

Calls 2

_query_nativeMethod · 0.95
_query_manualMethod · 0.95

Tested by

no test coverage detected