Skip to content

feat: token counts, TTFT, ITL, worker IDs on span - #7816

Closed
nnshah1 wants to merge 1 commit into
nnshah1/DIS-1643-pr2-lifecycle-loggingfrom
nnshah1/DIS-1643-pr3-metrics-capture
Closed

feat: token counts, TTFT, ITL, worker IDs on span#7816
nnshah1 wants to merge 1 commit into
nnshah1/DIS-1643-pr2-lifecycle-loggingfrom
nnshah1/DIS-1643-pr3-metrics-capture

Conversation

@nnshah1

@nnshah1 nnshah1 commented Apr 2, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Record input_tokens, output_tokens, ttft_ms, avg_itl_ms, prefill_worker_id, decode_worker_id on the enclosing tracing span via ResponseMetricCollector::Drop
  • These fields appear in JSONL logs alongside request lifecycle events
  • Single file change to metrics.rs

Test plan

  • cargo check --workspace passes
  • CI checks pass

Part 3 of 4 for DIS-1643: Consistent Error Tracing
Depends on #7815

🤖 Generated with Claude Code


Open with Devin

@nnshah1
nnshah1 requested a review from a team April 2, 2026 15:44
@github-actions github-actions Bot added the feat label Apr 2, 2026
@github-actions github-actions Bot added the frontend `python -m dynamo.frontend` and `dynamo-run in=http|text|grpc` label Apr 2, 2026
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr2-lifecycle-logging branch from 2564a0d to 26a7f55 Compare April 2, 2026 16:41
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr3-metrics-capture branch from 2f3ed0a to fca4c36 Compare April 2, 2026 16:41
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr2-lifecycle-logging branch from 26a7f55 to 9c449c6 Compare April 2, 2026 16:48
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr3-metrics-capture branch from fca4c36 to 62a203a Compare April 2, 2026 16:48
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr2-lifecycle-logging branch from 9c449c6 to 5a81d75 Compare April 2, 2026 17:09
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr3-metrics-capture branch from 62a203a to 6f37eb1 Compare April 2, 2026 17:09
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr2-lifecycle-logging branch from 5a81d75 to 613f3bd Compare April 2, 2026 17:17
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr3-metrics-capture branch from 6f37eb1 to 2eef2a8 Compare April 2, 2026 17:17
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr2-lifecycle-logging branch from 613f3bd to ea87d0a Compare April 2, 2026 17:20
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr3-metrics-capture branch from 2eef2a8 to 1b49ccf Compare April 2, 2026 17:20
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr3-metrics-capture branch from 1b49ccf to 40374d3 Compare April 2, 2026 17:26
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr2-lifecycle-logging branch from ea87d0a to 26e51f1 Compare April 2, 2026 17:26
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr2-lifecycle-logging branch from 26e51f1 to de44836 Compare April 2, 2026 17:35
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr3-metrics-capture branch from 40374d3 to a9ddded Compare April 2, 2026 17:35
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr2-lifecycle-logging branch from de44836 to c5695ff Compare April 2, 2026 19:12
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr3-metrics-capture branch from a9ddded to 5c3d4f7 Compare April 2, 2026 19:12
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr2-lifecycle-logging branch from c5695ff to f8b283d Compare April 2, 2026 19:50
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr3-metrics-capture branch from 5c3d4f7 to d6edb5c Compare April 2, 2026 19:50
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr2-lifecycle-logging branch 2 times, most recently from 215ab79 to fb3a884 Compare April 2, 2026 20:17
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr3-metrics-capture branch from d6edb5c to 6d3769b Compare April 2, 2026 20:17
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr2-lifecycle-logging branch from fb3a884 to 5657e03 Compare April 2, 2026 20:36
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr3-metrics-capture branch from 6d3769b to 402c4bc Compare April 2, 2026 20:36
Record input_tokens, output_tokens, ttft_ms, avg_itl_ms,
prefill_worker_id, decode_worker_id on the enclosing tracing span via
ResponseMetricCollector::Drop so they appear in JSONL logs alongside
request lifecycle events.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr3-metrics-capture branch from 402c4bc to d5757c1 Compare April 2, 2026 20:59
@nnshah1
nnshah1 force-pushed the nnshah1/DIS-1643-pr2-lifecycle-logging branch from 5657e03 to 92676d5 Compare April 2, 2026 20:59

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 3 additional findings.

Open in Devin Review

@nnshah1

nnshah1 commented Apr 2, 2026

Copy link
Copy Markdown
Contributor Author

Superseded by combined PR #7840

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feat frontend `python -m dynamo.frontend` and `dynamo-run in=http|text|grpc` size/M

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant