fix(responses): strip unsupported hosted web_search on Xiaomi MiMo destinations - #5944
codingbooo wants to merge 1 commit into
Conversation
|
✅ Deterministic PR hygiene checks passed. |
✅ READY
Review readiness checklist
✅ 4/4 boxes ticked. This pull request is already Ready for Review. |
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository: lidge-jun/opencodex/.coderabbit.yaml Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (4)
Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 7 remain after this review. 📝 WalkthroughWalkthroughThe hosted-tool policy now removes ChangesMiMo hosted search compatibility
Priority: ➖ Normal Estimated code review effort: 2 (Simple) | ~10 minutes Change: Bug fix · Severity of issue fixed: Medium Merge Risk: ⚪ Minimal · up to The MiMo destination rule strips unsupported hosted search declarations while preserving function tools. No merge-blocking issue is identified. Security Architecture ReviewSecurity architecture risk: 🔵 Low · up to The change removes unsupported hosted search tools for Xiaomi destinations without adding a tool capability or expanding privileges. Risk remains low, with some uncertainty around custom destination routing. Retained concerns Security review detailsSecurity Blast Radius
Trust Boundaries and Controls
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
리뷰 · 우선순위 74 / 80Codex가 Xiaomi MiMo로 글을 보내면, 검색을 안 하는 문장에도 이 PR은 요청 주소의 호스트가 바탕은 라인 - 라인 - 메인테이너의 판단이 필요한 지점 이슈를 연 사람은 웹 검색이 동작하기를 원했습니다. 이 PR은 검색을 실행하지 않습니다. 거절나던 선언을 지워서 글 답이 나오게 합니다. 선택이 그 검색뿐이면 호스트를 어디까지 볼지도 정해 주세요. 이슈에 적힌 주소는 너의 추천 선언을 지우는 쪽으로 두세요. 닫을 중복 PR은 없습니다. 문서의 MiMo 문장은 이 댓글은 grok-bot이 작성했습니다 |
) Six focused fixes from the assigned bug batch remain as separate attributed commits. | PR | Change | Author | | --- | --- | --- | | #5969 | Preserve Meta Muse tool-choice semantics and reject unsupported selectors before dispatch. | shawnkim | | #5944 | Remove unsupported hosted web-search declarations for Xiaomi MiMo destinations. | codingbo | | #5938 | Restart the Windows service child after unexpected exits, including exit 0, while reserving the intentional stay-out code. | codingbo | | #5935 | Reject Claude message-thread state on translated routes so the client resends full history. | kaladinhonor | | #5939 | Rewrite standalone `\\0` escapes in Meta tool-schema patterns to equivalent `\\x00`. | boblob6969 | | #5951 | Preserve Kiro-reported credits across stream attempts and in the usage ledger. | codingbo | A separate integration commit keeps upstream-controlled Kiro event-type text out of opt-in debug logs. The Kiro stream retains the previously landed bounded HTTP-error text when combined with credit metering. Left out: #5977. Independent security review found that its local read capability authenticates the request but not the HTTP response. A substituted listener could return a shape-valid forged `protected` verdict. A correct server proof bound to the nonce, endpoint, and body is outside this batch. Both its source commit and status-validation follow-up were reverted in new commits; its test and layout entries are gone. The source PR remains open. Co-authored-by: shawnkim <shawnkim@markncompany.co.kr> Co-authored-by: codingbo <cnsdbo@163.com> Co-authored-by: kaladinhonor <266145786+kaladinhonor@users.noreply.github.com> Co-authored-by: boblob6969 <boblob6969@icloud.com>
Summary
Fixes #5501 by stripping unsupported hosted
web_searchandweb_search_previewtool declarations when routing OpenAI-compatible Responses requests to Xiaomi MiMo destinations (xiaomimimo.comand its subdomains, e.g.api.xiaomimimo.comandtoken-plan-cn.xiaomimimo.com).Changes
UNSUPPORTED_HOSTED_TOOLSinsrc/responses/hosted-tool-policy.tsthat matchesxiaomimimo.comhosts (parsed vianew URL(baseUrl).hostname), denyingweb_searchandweb_search_preview.tests/responses/responses-hosted-tool-declaration.test.tscovering stripping, selector reconciliation, negative controls, and hostname parsing edge cases.providers.mdandchat-compat.mdexplaining automatic hosted tool stripping for MiMo hosts.Verification
bun run typecheck: clean 0 errors.bun test tests/responses/responses-hosted-tool-declaration.test.ts: 34 pass, 0 fail.Checklist
Review readiness checklist
This PR stays in draft until every box below is ticked. Tick all four boxes once the requirements are met:
Required local validation passed; commands, results, and any full-suite exception are documented.
I pushed my PR to a recent dev commit (at most 10 behind; a maintainer may still ask for the exact tip before merge).
I resolved all correct Codex and CodeRabbit findings.
My PR is ready for review.
Summary by CodeRabbit
web_searchorweb_search_previewtools. Function tools remain available, and matching works across the provider’s domain and subdomains.