Repository navigation
Conversation
Merge sent extra_body values, capture optional retrieval and reported costs, and preserve content masking with legacy core. Pin the recipe to published 0.1.11 for correct attribution and test both SDK bounds. Co-Authored-By: Claude Code <[email protected]>
Co-Authored-By: Claude Code <[email protected]>
Keep unrelated Chat Completions recipe capture contracts unchanged. Co-Authored-By: Claude Code <[email protected]>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
Keep Perplexity on the existing OpenAI Responses integration; do not add or retire a provider package.
extra_bodyover the normal body, honorOmit, and exclude headers/query options. This captures Perplexity'seffortand preserves overrides without mutating the SDK options.search_resultsitems toretrieval.documentson the existing LLM span, without synthetic retrieval spans. Capture reported numericusage.costvalues and supplied currency; omit missing, malformed, negative and non-finite costs.hide_inputson that older core as well. Keep token/cost attributes available when content is hidden.traceAI-openai==0.1.11, require providerperplexityat the documented host, and replace the README's QA diary with a working customer guide. The README explicitly describes the published pin, not the unreleased extensions.Why
Perplexity officially supports
/v1/responsesas the OpenAI-compatible alias for/v1/agent, and documentsextra_bodyeffort,search_results, andusage.cost:https://docs.perplexity.ai/docs/agent-api/openai-compatibility
The former recipe pin 0.1.10 labels the provider as OpenAI. Version 0.1.11 is already on PyPI; provider attribution alone needs no new release:
https://pypi.org/project/traceAI-openai/0.1.11/
The independent extension regression was reproduced on base
d6a9966dd4d5d5fb344f7f5ab11b7483c2c2a6bc: the initial 18-case regression suite had 8 failures and 10 passes on both openai 1.69.0 and 3.42.0. The transmitted body containedeffort, while invocation attributes did not; structured costs/retrieval were absent.Verification
All local tests ran under a macOS sandbox denying outbound network except loopback, using synthetic credentials and payloads. No model/vendor API calls.
git diff --checkpasses.Scope and release ordering
Existing
OpenAIInstrumentorentry points and returned SDK objects remain unchanged. The newextra_bodycapture contract is limited to Responses; Chat Completions parameter capture is unchanged. Targeted Doubleword, OrcaRouter and PrismML compatibility tests passed on both SDK versions (5 cases per version). This does not add nativeperplexitySDK/Search/Embeddings coverage, background polling, or new provider packages. No version or changelog bump; release-please owns the shared package release.PR #364 adds a recipe traffic header and does not solve these issues; this PR leaves its
src/app.pywork alone. Other provider-attribution/audio PRs remain separate.No docs-site PR is opened against an unreleased capability. A corrected extension guide is held for after the shared package release; the repository README runs against published packages now.
E2E coverage
not applicable (no e2e/ harness) · flows hit: n/a · marker: n/a · verdict: not applicable
🤖 Generated with Claude Code