Skip to content

feat: stamp gateway attribution metadata#4

Merged
haasonsaas merged 1 commit intomainfrom
harden/shim-attribution-20260503
May 3, 2026
Merged

feat: stamp gateway attribution metadata#4
haasonsaas merged 1 commit intomainfrom
harden/shim-attribution-20260503

Conversation

@haasonsaas
Copy link
Copy Markdown
Contributor

Summary

  • add team, workload, session, and evidence attribution headers to the OpenAI shim
  • pass the new attribution options through sync and async Python clients and the TypeScript client
  • keep org/principal/trace behavior backward compatible

Tests

  • npm test
  • npm run typecheck
  • .venv/bin/python -m pytest tests

@cursor
Copy link
Copy Markdown

cursor Bot commented May 3, 2026

PR Summary

Low Risk
Low risk: adds optional request headers and plumbs new constructor options/env vars through the OpenAI shims without changing existing org/principal/trace behavior.

Overview
Adds support for stamping additional gateway attribution metadata (team, workload, session, evidence) as X-EvalOps-* headers in both the Python and TypeScript OpenAI shims.

Plumbs the new options through OpenAI/AsyncOpenAI (Python) and EvalOpsOpenAI (TS), resolving values from explicit options or EVALOPS_* env vars, and updates unit tests to assert the new headers.

Reviewed by Cursor Bugbot for commit c0cd85d. Bugbot is set up for automated code reviews on this repo. Configure here.

@haasonsaas haasonsaas merged commit 2f5ab54 into main May 3, 2026
5 checks passed
@haasonsaas haasonsaas deleted the harden/shim-attribution-20260503 branch May 3, 2026 05:15
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.

1 participant