[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-82738":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":9,"language":10,"languages":9,"totalLinesOfCode":9,"stars":11,"forks":12,"watchers":13,"openIssues":14,"contributorsCount":15,"subscribersCount":15,"size":15,"stars1d":16,"stars7d":17,"stars30d":18,"stars90d":15,"forks30d":15,"starsTrendScore":19,"compositeScore":20,"rankGlobal":9,"rankLanguage":9,"license":21,"archived":22,"fork":22,"defaultBranch":23,"hasWiki":24,"hasPages":22,"topics":25,"createdAt":9,"pushedAt":9,"updatedAt":26,"readmeContent":27,"aiSummary":28,"trendingCount":15,"starSnapshotCount":15,"syncStatus":14,"lastSyncTime":29,"discoverSource":30},82738,"UltraCode-Shim","OnlyTerp\u002FUltraCode-Shim","OnlyTerp","Give Claude Code's ultracode mode to ANY model you already pay for. A tiny local proxy + one config.json. Point your AI at AGENTS.md and it sets itself up.",null,"Python",323,26,3,2,0,6,62,192,33,86.29,"MIT License",false,"main",true,[],"2026-06-12 04:01:38","\u003Cp align=\"center\">\n  \u003Cimg src=\"assets\u002Fbrand\u002Fhero.png\" alt=\"UltraCode-Shim — run Claude Code's UltraCode mode on any model you already pay for\" width=\"100%\">\n\u003C\u002Fp>\n\n\u003Cp align=\"center\">\n  \u003Ca href=\"https:\u002F\u002Fgithub.com\u002FOnlyTerp\u002FUltraCode-Shim\u002Factions\u002Fworkflows\u002Fci.yml\">\u003Cimg src=\"https:\u002F\u002Fgithub.com\u002FOnlyTerp\u002FUltraCode-Shim\u002Factions\u002Fworkflows\u002Fci.yml\u002Fbadge.svg\" alt=\"CI\">\u003C\u002Fa>\n  \u003Ca href=\"LICENSE\">\u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FLicense-MIT-8b5cf6.svg\" alt=\"License: MIT\">\u003C\u002Fa>\n  \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fpython-3.8%2B-6366f1\" alt=\"Python 3.8+\">\n  \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fdeps-stdlib%20only-a855f7\" alt=\"deps: stdlib only\">\n  \u003Cimg src=\"https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fplatforms-Windows%20%C2%B7%20macOS%20%C2%B7%20Linux-c026d3\" alt=\"platforms\">\n\u003C\u002Fp>\n\nUse Claude Code's **UltraCode** mode (xhigh effort + the Workflow\u002Fdeep-reasoning\nharness) with **any model you already pay for** — pick it live from the `\u002Fmodel`\nmenu.\n\nOne icon. Open Claude Code, type `\u002Fmodel`, and choose any backend you've set up —\nall running with the full UltraCode harness. Your normal Claude Code install is\nleft untouched.\n\nThe example config ships ready-to-use entries for **GPT‑5.5 (Codex login)**,\n**MiniMax‑M3**, **MiMo v2.5 Pro**, **DeepSeek V4 Pro\u002FFlash**, **Step Flash**,\n**Ollama Cloud**, **OpenCode Go**, **OpenRouter**, and **local models** — keep\nthe ones you have a plan for, delete the rest. (Cursor's Composer needs the\n`cursor-agent` CLI and isn't HTTP-based — see\n[docs\u002FADD_A_MODEL.md](docs\u002FADD_A_MODEL.md).)\n\n\u003Cp align=\"center\">\n  \u003Cimg src=\"assets\u002Fbrand\u002Ffeatures.png\" alt=\"One icon, every model · stdlib-only proxy · tools translated both ways · your Claude stays untouched\" width=\"100%\">\n\u003C\u002Fp>\n\n## How it works\n\n\u003Cp align=\"center\">\n  \u003Cimg src=\"assets\u002Fbrand\u002Farchitecture.png\" alt=\"Claude Code's \u002Fmodel menu points at a loopback proxy that adds the UltraCode envelope and routes each pick to the backend you already pay for\" width=\"100%\">\n\u003C\u002Fp>\n\n> **How is this possible?** At the API level, \"UltraCode\" is just\n> `effort=xhigh` + adaptive thinking + a big `max_tokens` + one system reminder —\n> there is no secret model. The proxy adds that envelope to every request, so any\n> backend gets the UltraCode treatment. Full breakdown (with the reverse‑engineering\n> evidence) in [docs\u002FHOW_IT_WORKS.md](docs\u002FHOW_IT_WORKS.md).\n\n## Orchestrator + Worker: two models, one workflow 🪄\n\nClaude Code's `\u002Fmodel` menu is single-slot — and its **dynamic-workflow** engine\nquietly issues most of its background\u002Fsub-agent traffic as the *stock* model\n(`claude-opus-4-8`) no matter what you pick. So the dozens of parallel workers\nthat do the bulk of a workflow don't follow your selection (and can bill a model\nyou didn't choose).\n\nThis proxy turns that single slot into **two**. The launcher opens a two-column\nselector before Claude Code starts: choose an **orchestrator** (the main\ninteractive loop) on the left and a **worker** (every Workflow\u002FTask sub-agent) on\nthe right. The same choices are also available later in `\u002Fmodel`: for every model\nyou configure, the proxy auto-adds a `Worker → \u003Cmodel>` entry.\n\n- Pick **one** model (or choose `Same as orchestrator` in the selector) → it runs\n  **everything**, orchestrator *and* every parallel worker. One pick, your model\n  end-to-end.\n- Pick an orchestrator **plus** a worker model → the smart model plans while a\n  cheaper\u002Ffaster model fans out the parallel work.\n\nHow it routes: the proxy classifies each request by a structural signal (the main\nloop carries interactive-only tools like `AskUserQuestion`; sub-agents never do),\nthen sends the orchestrator tier to your orchestrator model and every worker to\nyour worker model. The workflow's stock-model background calls are remapped to\nyour picks too — so **\"use MiniMax\" really means MiniMax everywhere**, not Opus\nbehind the scenes. Toggle off with `UC_ORCH_WORKER=0`. Workers run fully in\nparallel (threaded proxy, no artificial concurrency cap).\n\n## Built for long, dynamic workflows ✨\n\nUltraCode shines on *long, autonomous* runs — deep reasoning, multi-step\nWorkflows, multi-agent fan-out. The catch with any \"route to a third-party\nbackend\" shim is that those backends occasionally hiccup, and on a 40-minute\nagent run a single unhandled hiccup can wedge the whole session. **We hardened\nthe proxy against the three failure modes we actually hit in production**, so it\nkeeps going instead of stalling:\n\n- **🔁 Empty turns auto-retry.** A backend that returns a turn with no text and no\n  tool call (a transient blip, or a budget-exhausted reasoning turn at high\n  effort) is transparently re-issued. It buffers only until the first real token,\n  so a normal turn adds **zero latency** and output is never duplicated — and it\n  never retries after real output or a fatal error.\n- **⏱️ A stalled stream can't freeze the run.** If a GPT‑5.5\u002Fcodex stream opens and\n  then goes silent mid-turn, a bounded idle timeout turns the stall into a quick\n  retry instead of a ~10-minute hang — so one stuck sub-agent no longer freezes an\n  entire multi-agent \u002F dynamic-workflow run.\n- **🛠️ Rejecting a tool call just works.** Declining (or skipping) a tool mid-run no\n  longer 400s strict backends like DeepSeek — the proxy repairs the tool-call\n  sequence and synthesizes a stub reply for anything you didn't answer, including\n  partial parallel calls. ([#3](https:\u002F\u002Fgithub.com\u002FOnlyTerp\u002FUltraCode-Shim\u002Fissues\u002F3))\n- **💬 No \"dead air\" while a model thinks.** Reasoning models (MiniMax‑M3, etc.)\n  can think for seconds before the first answer token. The proxy keeps the\n  connection live during that phase, so a workflow step looks busy instead of\n  frozen — without leaking the chain-of-thought into the answer.\n\nAll of these are tunable via env vars and locked down by the offline self-test in\nCI. Details and knobs: [docs\u002FHOW_IT_WORKS.md → Reliability](docs\u002FHOW_IT_WORKS.md#6-reliability--surviving-long-and-dynamic-workflows).\n\n## Demo\n\nThere's a ready-to-run scenario in [`examples\u002Fdemo\u002F`](examples\u002Fdemo\u002F) — a buggy\nlittle Game of Life. Launch UltraCode there, pick any model, enable auto mode,\nand paste [the prompt](examples\u002Fdemo\u002FPROMPT.md): it fixes the bug, adds an\nanimated color renderer + starting patterns, and runs its own self-test, ending\non a glider crawling across the screen.\n\n\u003C!-- Recording goes here. Drop a clip at assets\u002Fdemo\u002Fdemo.gif and uncomment: -->\n\u003C!-- ![UltraCode-Shim demo](assets\u002Fdemo\u002Fdemo.gif) -->\n\nVerified live against real backends: **GPT‑5.5** (Codex login) and **Cursor\nComposer**, plus an offline self-test that runs in CI on Linux\u002FWindows ×\nPython 3.8\u002F3.12.\n\n## What you need\n\n- **Claude Code CLI** with UltraCode access (`npm i -g @anthropic-ai\u002Fclaude-code`).\n- **Python 3.8+** (standard library only — there is nothing to `pip install`).\n- **At least one backend credential**, e.g. an API key (MiMo \u002F OpenRouter \u002F OpenAI \u002F\n  a local server) and\u002For a `codex login` for GPT‑5.5. You only set up the ones you have.\n\nTested on **Windows 11** (no WSL needed). macOS\u002FLinux\u002FWSL work too via `bin\u002Fultracode`.\n\n## Quick start\n\n\u003Cp align=\"center\">\n  \u003Cimg src=\"assets\u002Fbrand\u002Fquickstart.png\" alt=\"Three steps: get the code and run the doctor, copy config.example.json and pick your models, then launch and type \u002Fmodel\" width=\"100%\">\n\u003C\u002Fp>\n\n### Windows\n\n```powershell\ngit clone https:\u002F\u002Fgithub.com\u002FOnlyTerp\u002FUltraCode-Shim.git\ncd UltraCode-Shim\n\n# 1. Sanity-check your machine and config (safe to run anytime)\npython scripts\\doctor.py\n\n# 2. Tell it which models you want (see \"Configure your models\" below)\n#    Copy config.example.json to config.json, keep the models you have,\n#    and put your keys in it (config.json is gitignored).\ncopy config.example.json config.json\n\n# 3. Create Desktop icons (one for UltraCode, one for normal Claude Code)\n.\\windows\\Install-DesktopIcons.ps1\n\n# 4. Double-click \"UltraCode (All Models)\" — pick orchestrator + worker in the selector.\n#    You can still type \u002Fmodel later to change either tier.\n```\n\n### macOS \u002F Linux \u002F WSL\n\nRun `python3 scripts\u002Fdoctor.py` then `.\u002Fbin\u002Fultracode`. The launcher starts the\nproxy, opens the two-column orchestrator\u002Fworker selector, then launches Claude\nCode. Set `UC_SELECTOR=0` to skip the selector and use `\u002Fmodel` only.\n(The launchers copy `config.example.json` → `config.json` for you on first run if\nyou skip step 2.)\n\n## Configure your models\n\nEverything is in one file: **`config.json`** (copied from `config.example.json`).\nIt has two sections you edit:\n\n- **`models`** — what shows up in the `\u002Fmodel` menu. Every `id` **must start with\n  `claude` or `anthropic`** (Claude Code filters the rest out).\n- **`routes`** — where each of those ids actually goes. The route key must match\n  the model `id`.\n\nExample — MiMo and an OpenRouter model:\n\n```jsonc\n{\n  \"models\": [\n    { \"id\": \"claude-mimo\",       \"display_name\": \"MiMo v2.5 Pro\" },\n    { \"id\": \"claude-openrouter\", \"display_name\": \"Llama 3.3 70B (OpenRouter)\" }\n  ],\n  \"routes\": {\n    \"claude-mimo\": {\n      \"type\": \"openai_compat\",\n      \"upstream\": \"https:\u002F\u002Ftoken-plan-sgp.xiaomimimo.com\u002Fv1\",\n      \"model\": \"mimo-v2.5-pro\",\n      \"auth\": \"Bearer ${MIMO_API_KEY}\"\n    },\n    \"claude-openrouter\": {\n      \"type\": \"openai_compat\",\n      \"upstream\": \"https:\u002F\u002Fopenrouter.ai\u002Fapi\u002Fv1\",\n      \"model\": \"meta-llama\u002Fllama-3.3-70b-instruct\",\n      \"auth\": \"Bearer ${OPENROUTER_API_KEY}\"\n    }\n  }\n}\n```\n\nPut your key right in `config.json` (it's gitignored) or use `${ENV_VAR}` and\nexport it — or drop keys into a gitignored `ultracode.env` the launchers load.\n\nRoute types:\n\n| `type`          | Use for                                            | Needs |\n|-----------------|----------------------------------------------------|-------|\n| *(omit)*        | Real Claude or any Anthropic-compatible endpoint   | nothing, or `auth`\u002F`upstream` |\n| `openai_compat` | MiMo, DeepSeek, OpenRouter, OpenAI, Ollama, local llama.cpp — anything that speaks OpenAI Chat Completions (tools included) | an API key |\n| `codex_oauth`   | GPT‑5.5 via a ChatGPT\u002FCodex login (no API key)     | `codex login` once |\n| `cursor_agent`  | Cursor Composer (experimental)                     | `cursor-agent login` |\n\n> **Reasoning models (MiniMax‑M3, etc.):** an `openai_compat` route can carry a\n> `\"body\": { ... }` dict of extra params merged into every request. **MiniMax‑M3**\n> needs `\"body\": { \"reasoning_split\": true }` so its `\u003Cthink>` chain‑of‑thought is\n> returned separately instead of leaking into the visible answer — the shipped\n> example already sets this. See [docs\u002FADD_A_MODEL.md](docs\u002FADD_A_MODEL.md#minimax-m3).\n\nFull walkthrough: [docs\u002FADD_A_MODEL.md](docs\u002FADD_A_MODEL.md).\n\n## Is my normal Claude Code safe?\n\nYes. The UltraCode launcher only sets environment variables **for the launched\nprocess** and uses a session-scoped `--settings` file. It never edits your global\nClaude config or credentials. The installer also gives you a **\"Claude Code (Normal)\"**\nicon, so you can always start the plain version. Remove everything with\n`windows\\Uninstall.ps1`.\n\n## Telling your AI assistant to set this up\n\nThis repo is built so you can hand it to an assistant. Point it at\n[AGENTS.md](AGENTS.md) — that's a step-by-step runbook (install → configure →\ntest → troubleshoot) written for an AI to follow.\n\n## Docs\n\n| Doc | What |\n|-----|------|\n| [AGENTS.md](AGENTS.md) | Runbook for an AI assistant to install\u002Fconfigure\u002Ftest |\n| [docs\u002FSETUP.md](docs\u002FSETUP.md) | Human setup guide (Windows + macOS\u002FLinux) |\n| [docs\u002FHOW_IT_WORKS.md](docs\u002FHOW_IT_WORKS.md) | The mechanism + reverse-engineering evidence |\n| [docs\u002FADD_A_MODEL.md](docs\u002FADD_A_MODEL.md) | Add any backend to the `\u002Fmodel` menu |\n| [docs\u002FTROUBLESHOOTING.md](docs\u002FTROUBLESHOOTING.md) | Symptom → cause → fix |\n\n## License\n\nMIT — see [LICENSE](LICENSE). This is an unofficial, community project; it is not\naffiliated with Anthropic, OpenAI, or any model provider. You are responsible for\ncomplying with the terms of whatever accounts you route through it.\n","UltraCode-Shim 项目允许用户将 Claude Code 的 UltraCode 模式应用于任何已付费的模型。通过一个小型本地代理和配置文件，用户可以轻松地在多个模型之间切换并启用 UltraCode 功能。该项目使用 Python 编写，仅依赖标准库，支持 Windows、macOS 和 Linux 平台。其核心功能包括通过 `\u002Fmodel` 菜单选择不同的后端模型，并自动应用 UltraCode 的高努力模式和深度推理工具。适用于需要增强现有 AI 模型性能的开发者或企业，特别是那些希望在不改变原 Claude Code 安装的情况下，利用 UltraCode 特性的场景。","2026-06-11 04:09:05","CREATED_QUERY"]