Skip to content

Conversation

@adilhafeez
Copy link
Contributor

@adilhafeez adilhafeez commented Nov 12, 2024

After this change we can generate custom spans showing total time taken by upstream llm

image



with open(envoy_log_path, "r") as f:
while True:
Copy link
Contributor

Choose a reason for hiding this comment

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

I think best to check if the log file exists to begin with, if not that means tracing was off - then no need to run this for loop.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

it must exist - if it doesnt we should fail/crash

I also make sure to create this file in Dockerfile see here -https://github.com/katanemo/arch/pull/262/files#diff-8e3a6a6de1bde2a67bc1791e073f4724332070eac7b751f83122f8929eb87f1fR9

attributes: vec![],
});

trace_data.add_span(Span {
Copy link
Contributor

Choose a reason for hiding this comment

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

I think this should be an even in the total_time span. We shouldn't represent TTFT as a separate span because there is technically no new service work. https://opentelemetry.io/docs/concepts/signals/traces/#span-events

Copy link
Contributor Author

Choose a reason for hiding this comment

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

using event now

@adilhafeez adilhafeez merged commit 30647fd into main Nov 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants