Uh oh!
There was an error while loading. Please reload this page.
fix(ai-openrouter): exclude unsupported 'prediction' param from generated model options - #1135
Conversation
…ated model options The OpenRouter model-metadata sync (#1048) started emitting 'prediction' in the generated per-model option Picks, but @openrouter/sdk's ChatRequest does not declare that field (its outbound schema would strip it at runtime), so packages/ai-openrouter no longer compiled and main CI went red. Add 'prediction' to the generator's excludedParams set (same rationale as the existing entries) and strip it from the generated model-meta. Also update the stale GROK_CHAT_MODELS test expectation that the same sync commit broke by adding grok-4.5 / grok-4.6.
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
💤 Files with no reviewable changes (1)
Included review availability: Your plan includes up to 8 reviews per rolling hour; 7 remain after this review. 📝 WalkthroughWalkthroughThe PR excludes ChangesOpenRouter prediction compatibility
Grok model coverage
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk:⚪ Minimal · up to The change removes an unsupported OpenRouter option from generated metadata and updates the affected model-list expectation; no actionable merge-blocking risk remains after normal checks and review. Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 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 |
View your CI Pipeline Execution ↗ for commit 50d1be0
☁️ Nx Cloud last updated this comment at |
@tanstack/ai@tanstack/ai-acp@tanstack/ai-angular@tanstack/ai-anthropic@tanstack/ai-bedrock@tanstack/ai-byteplus@tanstack/ai-claude-code@tanstack/ai-client@tanstack/ai-code-mode@tanstack/ai-code-mode-snippets@tanstack/ai-codex@tanstack/ai-cohere@tanstack/ai-devtools-core@tanstack/ai-durable-stream@tanstack/ai-elevenlabs@tanstack/ai-event-client@tanstack/ai-fal@tanstack/ai-gemini@tanstack/ai-grok@tanstack/ai-grok-build@tanstack/ai-groq@tanstack/ai-isolate-cloudflare@tanstack/ai-isolate-daytona@tanstack/ai-isolate-node@tanstack/ai-isolate-quickjs@tanstack/ai-isolate-quickjs-bun@tanstack/ai-mcp@tanstack/ai-memory@tanstack/ai-mistral@tanstack/ai-ollama@tanstack/ai-openai@tanstack/ai-opencode@tanstack/ai-openrouter@tanstack/ai-perplexity@tanstack/ai-persistence@tanstack/ai-preact@tanstack/ai-react@tanstack/ai-react-ui@tanstack/ai-sandbox@tanstack/ai-sandbox-cloudflare@tanstack/ai-sandbox-daytona@tanstack/ai-sandbox-docker@tanstack/ai-sandbox-local-process@tanstack/ai-sandbox-sprites@tanstack/ai-sandbox-vercel@tanstack/ai-solid@tanstack/ai-solid-ui@tanstack/ai-svelte@tanstack/ai-utils@tanstack/ai-vercel-gateway@tanstack/ai-vue@tanstack/ai-vue-ui@tanstack/openai-base@tanstack/preact-ai-devtools@tanstack/react-ai-devtools@tanstack/solid-ai-devtoolscommit: |
🎯 Changes
Main CI went red after the OpenRouter model-metadata sync (#1048):
predictionas a supported parameter, so the generator emittedPick<OpenRouterBaseOptions, ... | 'prediction'>for 9 models — but@openrouter/sdk@0.13.20'sChatRequestdoes not declare that field (its outbound schema would strip it at runtime), sopackages/ai-openrouterno longer compiled (TS2344 inmodel-meta.ts, dts generation fails, which cascades into every example/e2e typecheck).grok-4.5/grok-4.6toGROK_CHAT_MODELSwithout updating the ai-grok unit test that pins the list, sotest:libwas red too.Fix:
predictionto the sync script'sexcludedParamsset (same rationale as the existing entries: the SDK strips undeclared keys, so exposing it would silently no-op user input) and strip it from the generatedmodel-meta.ts.GROK_CHAT_MODELStest expectation.✅ Checklist
pnpm run test:pr(targeted:@tanstack/ai-openrouterbuild/test:lib/test:types and@tanstack/ai-groktest:lib are green; the full suite was red on main because of this very breakage).🚀 Release Impact
Summary by CodeRabbit
Bug Fixes
New Features