Track conversational flow turn usage in telemetry (#6324)
Some checks failed
CodeQL Advanced / Analyze (actions) (push) Has been cancelled
CodeQL Advanced / Analyze (python) (push) Has been cancelled
Vulnerability Scan / pip-audit (push) Has been cancelled
Build uv cache / build-cache (3.10) (push) Has been cancelled
Build uv cache / build-cache (3.11) (push) Has been cancelled
Build uv cache / build-cache (3.12) (push) Has been cancelled
Build uv cache / build-cache (3.13) (push) Has been cancelled

* Track conversational flow turn usage in telemetry

* adjusted name to flow:conversation_turn

* only mark on turn completed event

* ensure tui also emits these events
This commit is contained in:
Lorenze Jay
2026-06-25 11:02:07 -07:00
committed by GitHub
parent 654abcb40d
commit 9b31226494
8 changed files with 286 additions and 12 deletions

View File

@@ -65,8 +65,12 @@ def _load_conversational_flow_from_kickoff_script() -> Any | None:
def _run_conversational_flow_tui(flow: Any) -> Any:
from crewai.events.event_listener import EventListener
from crewai_cli.crew_run_tui import CrewRunApp
EventListener() # ensures we get events from the TUI
app = CrewRunApp(
crew_name=getattr(flow, "name", None) or type(flow).__name__,
conversational=True,