Skip to content

[rollout-trace] Add x-codex-inference-call-id header to inference calls.#22311

Merged
cassirer-openai merged 2 commits into
mainfrom
cassirer/05-12/add-tracer-header-to-inference-requests
May 12, 2026
Merged

[rollout-trace] Add x-codex-inference-call-id header to inference calls.#22311
cassirer-openai merged 2 commits into
mainfrom
cassirer/05-12/add-tracer-header-to-inference-requests

Conversation

@cassirer-openai
Copy link
Copy Markdown
Contributor

This allows us to attach call logs to inference requests in traces.

This allows us to attach call logs to inference requests in traces.
@cassirer-openai cassirer-openai requested a review from a team as a code owner May 12, 2026 11:31
@cassirer-openai
Copy link
Copy Markdown
Contributor Author

@codex review

Copy link
Copy Markdown
Contributor

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 4203f62651

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread codex-rs/core/src/client.rs
Copy link
Copy Markdown
Collaborator

@jif-oai jif-oai left a comment

Choose a reason for hiding this comment

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

I'll let you take care of ws

fn next_inference_call_id() -> InferenceCallId {
let ordinal = NEXT_INFERENCE_ATTEMPT.fetch_add(1, Ordering::Relaxed);
format!("inference:{ordinal}")
Uuid::new_v4().to_string()
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

FYI uuid can sometimes panic on some unusual OS that does not support getrandom at kernel level. I don't expect this to happen for any of our application but good to keep in mind if we go in some funky training setup

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Thanks. Let's assume it isn't an issue until we run into it.

@cassirer-openai cassirer-openai merged commit cb55b76 into main May 12, 2026
27 checks passed
@cassirer-openai cassirer-openai deleted the cassirer/05-12/add-tracer-header-to-inference-requests branch May 12, 2026 12:55
@github-actions github-actions Bot locked and limited conversation to collaborators May 12, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants