MCPcopy
hub / github.com/Fosowl/agenticSeek / __init__

Method __init__

sources/interaction.py:23–50  ·  view source on GitHub ↗
(self, agents,
                 tts_enabled: bool = True,
                 stt_enabled: bool = True,
                 recover_last_session: bool = False,
                 langs: List[str] = ["en", "zh"]
                )

Source from the content-addressed store, hash-verified

21 Interaction is a class that handles the interaction between the user and the agents.
22 """
23 def __init__(self, agents,
24 tts_enabled: bool = True,
25 stt_enabled: bool = True,
26 recover_last_session: bool = False,
27 langs: List[str] = ["en", "zh"]
28 ):
29 self.is_active = True
30 self.current_agent = None
31 self.last_query = None
32 self.last_answer = None
33 self.last_reasoning = None
34 self.agents = agents
35 self.tts_enabled = tts_enabled
36 self.stt_enabled = stt_enabled
37 self.recover_last_session = recover_last_session
38 self.router = AgentRouter(self.agents, supported_language=langs)
39 self.ai_name = self.find_ai_name()
40 self.speech = None
41 self.stt = None
42 self.is_generating = False
43 self.languages = langs
44 if tts_enabled and not self.in_docker():
45 self.initialize_tts()
46 if stt_enabled and not self.in_docker():
47 self.initialize_stt()
48 if recover_last_session:
49 self.load_last_session()
50 self.emit_status()
51
52 def get_spoken_language(self) -> str:
53 """Get the primary TTS language."""

Callers

nothing calls this directly

Calls 7

find_ai_nameMethod · 0.95
in_dockerMethod · 0.95
initialize_ttsMethod · 0.95
initialize_sttMethod · 0.95
load_last_sessionMethod · 0.95
emit_statusMethod · 0.95
AgentRouterClass · 0.90

Tested by

no test coverage detected