@@ -33,7 +33,7 @@ def start_session(self, session_id: str, agent_info: Dict[str, Any], workflow_sp
3333 self ._workflow_spans [session_id ] = workflow_span
3434 if agent_span :
3535 self ._agent_spans [session_id ] = agent_span
36-
36+
3737 # Initialize conversation counter
3838 self ._conversation_counters [session_id ] = 0
3939
@@ -48,7 +48,7 @@ def end_conversation(self, session_id: str) -> None:
4848 with self ._lock :
4949 if session_id in self ._conversation_spans :
5050 del self ._conversation_spans [session_id ]
51-
51+
5252 def has_active_conversation (self , session_id : str ) -> bool :
5353 """Check if there's an active conversation for this session."""
5454 with self ._lock :
@@ -88,25 +88,25 @@ def get_workflow_phase(self, session_id: str) -> str:
8888 """Detect current workflow phase based on state."""
8989 with self ._lock :
9090 session = self ._sessions .get (session_id , {})
91-
92- if session .get (' tools_executed' , []):
91+
92+ if session .get (" tools_executed" , []):
9393 return "executing"
94- elif session .get (' step_count' , 0 ) > 0 :
94+ elif session .get (" step_count" , 0 ) > 0 :
9595 return "executing"
9696 else :
9797 return "planning"
98-
98+
9999 def get_workflow_span (self , session_id : str ):
100100 """Get the active workflow span for a session."""
101101 with self ._lock :
102102 return self ._workflow_spans .get (session_id )
103-
103+
104104 def get_agent_span (self , session_id : str ):
105105 """Get the active agent span for a session."""
106106 with self ._lock :
107107 return self ._agent_spans .get (session_id )
108-
108+
109109 def get_conversation_span (self , session_id : str ):
110110 """Get the active conversation span for a session."""
111111 with self ._lock :
112- return self ._conversation_spans .get (session_id )
112+ return self ._conversation_spans .get (session_id )
0 commit comments