Repository navigation
Conversation
Generated-by: OpenAI Codex
A consumer that stops the adapter mid-stream (the reasoning-mismatch throw, a user stop) leaves the SDK without a finish chunk, so teardown rejects every result promise. usage and finishReason were already consumed, but response was only read on the completed continuation path — its rejection could surface as an unhandled rejection after the turn unwound, scheduler-timing owned (observed post-test on Windows, where Node makes it a crash). Sink it unconditionally in the teardown finally, and pin the property with an unhandledRejection trap in the mismatch test so every event loop proves the path leaves none behind.
Route Qwen3.8 Max Token Plan sessions to provider-executed Responses web search, and extend the pinned open-responses adapter with the published web_search request and web_search_call stream shapes. Generated-by: OpenAI Codex
Map search, open_page, and find_in_page into the canonical provider-executed WebSearch output instead of collapsing every hosted action to search. Generated-by: OpenAI Codex
Enable provider-executed WebSearch for first-party DeepSeek V4 Responses models now that the shared Open Responses adapter preserves all observed search actions. Generated-by: OpenAI Codex
|
This pull request has had no new commits for 30 days and has been marked stale. It will be closed in 7 days unless a new commit is pushed. Comments do not reset this timer: only a new commit does. If the pull request is intentionally long-lived, a maintainer can apply the |
me2seeks
left a comment
There was a problem hiding this comment.
Automated review notice: This comment was posted by an automated review agent operated by me2seeks make. It is not an independent human review and does not replace one.
Summary
Restores DeepSeek native WebSearch: flips the DeepSeek adapter from implemented: false (with its old "SDK serializes function tools only, so a native search tool would be silently filtered" comment) to implemented: true, and also adds the alibaba-token-plan cases with the qwen3.8-max gating. Registry, llm-connections, model-metadata, the capability doc, and the backend/adapter/native-web-search tests move in step.
Findings
- [P2] Overlaps #3685 (
feat(runtime): add Qwen3.8-Max native WebSearch, also open, same author): both add the identicalalibaba-token-plan-cn/alibaba-token-plancases with theqwen3.8-maxgate inmodel-web-search.ts. Whichever lands second will conflict on those hunks — land the DeepSeek restore and the Qwen gating as one change (here) or sequence them explicitly, but not both independently. - [P2] The
implemented: false→trueflip retires a comment claiming the SDK would silently filter a native search tool from the request. The PR is a draft with no CI run ("no checks reported") — the native-web-search and responses-wire tests that prove the tool actually reaches the provider (not filtered) must run green before this assumption is trusted; the flip without a green wire test would silently restore the original silent-filter bug.
Verdict
needs-changes — plausible restore, but reconcile with #3685 and prove in CI that the hosted search tool actually reaches the wire.
|
This pull request has been closed because it received no new commits during the 7-day grace period. This is not a judgement on the merit of the change; it only keeps the review queue aligned with work that is actively in flight. The branch and review history are preserved. Push a new commit and reopen the pull request whenever the work is ready to continue. |
Summary
Restores first-party DeepSeek V4 model-native WebSearch after #2972 deliberately disabled it on the
@ai-sdk/open-responsesadapter boundary.deepseek-v4-flashanddeepseek-v4-pro) and explicitopenai-chatoverride veto;Fixes #3689
Dependencies
This is a stacked Draft PR on #3685, which adds the common Open Responses request/stream transport and preserves
search,open_page, andfind_in_page. #3685 is itself stacked on the Alibaba Token Plan Responses foundation in #3255.The branch currently includes those preceding commits and should be rebased after #3255 and #3685 merge. The DeepSeek-only commit is
0099fe751.Live verification
A normal routed smoke passed on exact DeepSeek head
0099fe751using the first-partyDEEPSEEK_API_KEYfrom the ignored local/Users/moonold/.envfile. The credential was read only in process and was never printed, placed in command arguments, persisted, or attached.Execution path:
Observed:
providerExecuted: true;search,openPage, andfindInPagewith URL/pattern fields;stop;Verification
npm run format:checknpm run lintnpm run check:asf-headersReplay boundary
@ai-sdk/open-responsesstill cannot safely round-trip a provider-executed call/result pair embedded in assistant history. Maka retains the durable search episode and grounded answer, but omits the provider-owned pair from the next request rather than emitting a dangling function output. This is the same explicit fail-closed boundary established by #2972 and is not widened here.AI use
OpenAI Codex assisted with implementation, protocol analysis, automated tests, live verification, and PR drafting. The human contributor reviewed the scope and remains responsible for the contribution. The commit carries a
Generated-by: OpenAI Codextrailer.Checklist
Does this PR entail a change in behavior?