Repository navigation
Commit e25b758
fix(observability): map Claude Code user_prompt -> input.value so Langfuse Input isn't null (#59)
Claude Code emits the prompt as the span attribute 'user_prompt' (on
claude_code.interaction), but Langfuse reads observation Input from the OpenInference
'input.value' convention -> the Input field showed null while the prompt sat only in the
raw-attributes panel. Add an OTTL transform mapping user_prompt -> input.value.
Assistant OUTPUT text is NOT emitted on the trace signal (Claude Code sends it via the
logs signal, which Langfuse trace ingestion does not consume) -> output shows
tokens/cost/finish_reason only; documented inline.
Token usage + cost already work (the gen_ai.usage.* transform on main); the recent
'all null' was the stack being down after reboot (4 containers were removed and did not
auto-recreate) - brought back up, restart: unless-stopped carries them across reboots.
Verified: fresh trace -> observation usage {input:10,output:59,cache...} cost $0.109;
claude_code.interaction Input = the prompt text.
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>1 parent f1fb278 commit e25b758
1 file changed
Lines changed: 6 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
28 | 34 | | |
29 | 35 | | |
30 | 36 | | |
| |||
0 commit comments