feat: record sampling parameters in telemetry (port 20 to 21 fields)

Each of the three emitter entry points has a pinned meaning: only the
attempt path has an effective source, so only it merges extra_body.
This commit is contained in:
2026-07-31 21:30:45 -04:00
parent b6e4cc3f3b
commit 4516761dbe
6 changed files with 141 additions and 16 deletions
@@ -41,6 +41,7 @@ _EXPECTED_COLUMNS = [
"created_at",
"cached_prompt_tokens",
"model_reported",
"sampling",
]
# run 级前缀: 同库并存的其他运行(迁移批跑/另一开发机)互不可见
@@ -104,6 +105,7 @@ async def _record_minimal(
"cost": None,
"cached_prompt_tokens": None,
"model_reported": None,
"sampling": None,
}
fields.update(overrides)
await recorder.record_llm_call(**fields)