Commit graph

17 commits

Author SHA1 Message Date
decolua
8f81363675 Enhance token refresh functionality across multiple executors
- Updated refreshCredentials methods in various executors (Antigravity, Base, Default, Github, Kiro) to accept optional proxyOptions for improved proxy handling.
- Modified token refresh logic to utilize proxy-aware fetch for better network management.
- Enhanced usage retrieval functions to support proxy options, ensuring seamless integration with proxy configurations.
- Updated ModelSelectModal and ProviderInfoCard components to incorporate kind filtering for improved user experience in model selection.
- Added validation for API keys in the provider validation route, including support for webSearch/webFetch providers.
2026-04-28 17:28:57 +07:00
Manuel B.
58a821d687
fix: granular reasoning_effort handling for Claude models (#791)
- github.js: split thinking vs reasoning_effort stripping
  - thinking (Claude-native format) still stripped for all Claude on Copilot
  - reasoning_effort now passed through for Opus 4.6 and Sonnet 4.6
  - still stripped for Haiku 4.5 and Opus 4.7 (rejected upstream)
  - reasoning_effort "none" stripped for all models (not all support it)
- openai-to-claude.js: map reasoning_effort → thinking.budget_tokens
  for direct Anthropic backend (none→skip, low→4096, medium→8192,
  high→16384, xhigh→32768)

Previously reasoning_effort was stripped for ALL Claude models,
meaning Opus 4.6 via Copilot never received thinking configuration.

AI-generated commit by Claude Opus 4.6 (Anthropic)
2026-04-28 09:49:27 +07:00
omar-nahhas
95841f9a48 fix(github): preserve reasoning_effort for non-Claude models (#713)
The previous blanket strip in GithubExecutor.transformRequest removed
`thinking` AND `reasoning_effort` for every GitHub-routed model to avoid
Claude-on-Copilot 400s from OpenClaw. That regressed GPT-5 family support
(gh/gpt-5-mini honors reasoning_effort: low/medium/high).

Make supportsThinking(model) model-aware — return false only for Claude
models, so the strip fires only where the upstream actually rejects these
fields.

Benchmarks on /v1/chat/completions via GitHub Copilot:
  effort=(none) → 64 reasoning_tokens, ~2.0s
  effort=low    → 0  reasoning_tokens, ~1.55s
  effort=medium → 64 reasoning_tokens, ~1.9s
  effort=high   → 128 reasoning_tokens, ~2.2s

Made-with: Cursor
2026-04-22 10:23:31 +07:00
anuragg-saxenaa
afe09f3f14 fix(github): strip thinking/reasoning_effort for Copilot chat completions (closes #623)
GitHub Copilot /chat/completions endpoint does not support the thinking
or reasoning_effort fields. OpenClaw sends thinking: { type: "enabled" }
for Claude models which causes a 400 Bad Request.

Added supportsThinking() and strip both fields in transformRequest before
sending to the upstream endpoint.

Co-authored-by: anuragg-saxenaa <anuragg.saxenaa@gmail.com>
Made-with: Cursor
2026-04-17 12:54:50 +07:00
Anurag Saxena
554bbfceed
fix: strip temperature parameter for gpt-5.4 model (closes #536) (#612) 2026-04-17 12:02:53 +07:00
decolua
ed17a8ffac Feat : Tailscale 2026-04-11 11:36:33 +07:00
Anurag Saxena
38eabae2e7
fix: retry /responses endpoint when GitHub returns model not supported (closes #470) (#488) 2026-04-04 08:50:38 +07:00
Manuel B.
cd1e06b641
fix: add missing clientId to github provider config for OAuth token refresh (#442)
The github provider in open-sse/config/providers.js was missing clientId,
causing refreshGitHubToken() to send client_id=undefined on 401 retry.
Also guard against undefined clientSecret in both refresh implementations.

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-30 12:24:31 +07:00
decolua
adae2605bf Feat : Auto restart after crash 2026-03-14 09:37:29 +07:00
Nick Roth
754a24d52a fix: SSE data: [DONE] sentinel + response_format for Claude via GitHub
- Guard data: [DONE] in github.js TransformStream with stream === true
- Inject response_format as system prompt for Claude models via GitHub executor

Note: stream.js guards skipped, createSSEStream is only called for true streaming paths.

Cherry-picked and adapted from PR #286 by @rothnic
https://github.com/decolua/9router/pull/286

Made-with: Cursor
2026-03-13 10:13:02 +07:00
decolua
b0c6b61398 Refactor config 2026-03-12 16:20:46 +07:00
decolua
880f4eca91 feat(proxy): add proxy pool and per-connection binding + strictProxy support
- Centralize proxy management with reusable proxy pools
- Per-connection proxy binding with legacy fallback
- Add strictProxy option: fail hard instead of silently falling back to direct
- Resolve alicode-intl conflict: keep alicode-intl support + proxy support

Made-with: Cursor
2026-03-09 15:46:06 +07:00
Cengizhan
f763d4ffed
fix: resolve GitHub Copilot 400 error for Claude models in Cursor IDE (#220)
- github.js: add sanitizeMessages() to convert unsupported content types
  (tool_use, tool_result, thinking) to plain text before sending to
  GitHub /chat/completions endpoint
- openai-responses.js: skip pushing message blocks with empty content
  (e.g. assistant messages that only contain tool_calls)
- providerModels.js: revert targetFormat changes (not needed with sanitize fix)

Fixes: https://github.com/decolua/9router/issues/219
2026-03-01 15:38:14 +07:00
Quan
07717bad60 feat: cherry-pick PR #183 — multi-provider support, PWA, dynamic models, UI improvements
Cherry-picked from decolua/9router PR #183.
Note: open-sse changes included but need further review due to extensive modifications.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-25 11:40:50 +07:00
Bexultan
69131295db
fix(github): Implement dynamic fallback for Codex models requiring /responses endpoint (#127)
* fix(github): add dynamic fallback to /responses for Codex models

* Refactor GithubExecutor: use config for URL detection
2026-02-15 07:40:55 +07:00
decolua
32aefe5a76 feat(executors): Improved UI components for displaying provider limits and usage statistics in the dashboard. 2026-02-05 18:38:50 +07:00
decolua
f46ff42cb3 refactor: streamline provider interactions and enhance error handling 2026-01-11 21:45:01 +07:00