2 Commits
Author SHA1 Message Date
Alex cf9a5e9cb8 Fall back to model_id for the logged model
Agents store their model only in model_id, so neither log_activity nor
agent_log_context bound a model key. start_agent_span already reads it.
2026-09-24 13:47:46 +01:00
Alex 9df90ab9df Bind the log context for tool continuations
gen_continuation is not wrapped by @log_activity, so the llm_* log lines
from a resumed turn carried no user, agent, conversation or endpoint. Every
OpenAI-compatible /v1 client-tool round landed anonymous in the logs.

Add agent_log_context, which binds the same keys log_activity binds while
keeping any enclosing activity_id, and wrap gen_continuation in it. Both
now derive the keys from one helper.
2026-09-24 13:26:49 +01:00