Skip to content

feat(providers): Grok/xAI provider, Responses compat, and reasoning.effort mapping#252

Open
24baigei wants to merge 4 commits into
Stack-Cairn:mainfrom
24baigei:feat/xai-responses-compat
Open

feat(providers): Grok/xAI provider, Responses compat, and reasoning.effort mapping#252
24baigei wants to merge 4 commits into
Stack-Cairn:mainfrom
24baigei:feat/xai-responses-compat

Conversation

@24baigei

@24baigei 24baigei commented Jul 23, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Add direct api.x.ai Responses compatibility for Codex/OpenAI-compatible providers, plus a first-class Grok (xai) provider type in desktop GUI and WebUI.
  • Force openai-responses for xAI (formal xai type or direct api.x.ai base URL), strip OpenAI-only request fields, keep/map UI thinking levels to reasoning.effort (minimal?low, etc.), and request include for encrypted reasoning + hosted search sources.
  • Parse xAI hosted search lifecycle (x_search_call, x_keyword_search / x_semantic_search, response.x_search_call.*).
  • Import CC-Switch grokbuild providers into LiveAgent xai, use the official Grok/xAI brand icon, and extend model list fetch / native search / gateway provider typing.

Test plan

  • Unit tests: xai-responses-payload, model-factory-xai, hosted-search-events, native-web-search, settings normalization
  • Rust unit tests: ccs_imports_grokbuild_* / ccs_maps_grokbuild_app_type_to_xai
  • pnpm exec tsc --noEmit (agent-gui)
  • Windows Tauri release binary builds (liveagent.exe)
  • agent-dev debug jsonl: UI minimal ? payload reasoning.effort: "low"
  • Manual: Grok tab ? API key ? grok-4.5, switch low/medium/high and confirm behavior / debug payload
  • Manual: Settings ? import from CC-Switch shows grokbuild rows under Grok
  • Manual: non-xAI OpenAI relays still use completions when configured that way

24baigei added 2 commits July 24, 2026 03:20
Force openai-responses when Base URL is api.x.ai, strip OpenAI-only
payload fields, request encrypted reasoning and search sources via
include, and surface x_search / custom_tool_call hosted search events.
…ng effort

Introduce ProviderId xai with Settings/WebUI tabs, official brand icon, and
fixed openai-responses routing. Keep and map UI thinking levels to
reasoning.effort for api.x.ai, import grokbuild providers from CC-Switch,
and extend model fetch, native search, and tests for the new provider type.
@24baigei
24baigei force-pushed the feat/xai-responses-compat branch from a1b2de0 to 905b5a8 Compare July 23, 2026 19:20
@24baigei 24baigei changed the title feat(providers): add xAI Responses API compatibility for direct api.x.ai feat(providers): Grok/xAI provider, Responses compat, and reasoning.effort mapping Jul 23, 2026
24baigei added 2 commits July 24, 2026 03:29
Fix lint failures in GUI and Gateway WebUI CI caused by unformatted
sources (line endings / style) introduced with the xai provider work.
…xpectations

Grok/xAI first-class provider defaults add xai: high; update WebUI settings
tests to match GUI normalization expectations.
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