Astra-Ares README

The project's README from github.com/miuuyy/Astra-Ares. As one markdown file: README.md.

[!IMPORTANT] Experimental reference implementation. Astra-Ares has a straightforward setup, but runs a separate, patched version of Codex CLI. It is primarily a reference for bringing adaptive reasoning effort into your own agent systems; it is still an early preview for everyday development.

Most of my projects focus on ready-to-download, user-friendly apps: Persona Voice adds custom voices to AI assistants, and Codex ChatGPT Web brings ChatGPT Web models into Codex. Astra-Ares is a more technical project intended for experimentation and integration.

Astra-Ares — Adaptive Reasoning Effort Selection. Let the task set the thinking depth.

Adaptive Reasoning Effort Selection for GPT-6 Astra, Sol and Luna while your Codex task runs.

Get started · How it works · Configuration · Troubleshooting

Astra-Ares is the first tool to let Jev adapt GPT-6's reasoning effort while a Codex task runs. The goal is to reduce token usage by matching reasoning depth to the next step. Jev reads bounded task context, chooses how much your selected model should think next, and decides how many generations that effort should last. Codex applies the choice while work continues.

This is possible because GPT-6 models can change reasoning effort without invalidating the original prompt prefix used for caching. Ares uses that native mechanism, keeping the same model, conversation, and direct OpenAI connection. How GPT-6 preserves the prefix →

Get started

You install a separate, patched Codex CLI. Setup downloads a pinned Codex version, applies the included patch, and builds it automatically. You do not edit Codex yourself. Your existing codex command and Codex desktop app stay as they are.

You need Node.js 22+, npm, Git, curl, tar, a native C/C++ build toolchain, and Rust via rustup. Allow about 10 GB free for the first build and several minutes to compile. The build installs upstream's pinned Rust toolchain. On macOS, install the Xcode Command Line Tools if needed: xcode-select --install.

Platform Status
macOS · Apple Silicon Built and tested locally
macOS Intel / Linux Build paths provided; not yet acceptance-tested
Windows Not supported by this Unix-socket integration

1. Install from source

Clone the repository:

git clone https://github.com/miuuyy/Astra-Ares.git
cd Astra-Ares
npm ci
npm run setup
npm link

npm link makes astra-ares and ares available in your terminal. This preview is distributed as source; there is no published npm package or prebuilt Ares download yet. See installation details for build reuse, updates, and running without a global link.

2. Add your Jev key

Create an OpenRouter API key with funded credits, then run:

ares configure

Paste the key into the hidden prompt. OpenRouter is the default for new installs. The key is saved in your private user configuration, outside the repository.

Your selected model uses your existing Codex login with access to that model, separately from the Jev key. If needed, sign in with astra-ares login. Other Jev providers and environment variables →

3. Start Codex

astra-ares

The normal Codex terminal opens. In /model, select Astra Ares, Sol Ares, or Luna Ares. Each entry keeps its underlying model fixed while Jev chooses the reasoning effort. Entries appear when the corresponding model is available in your Codex catalog. New Ares profiles select Astra Ares by default.

Confirmed effort changes appear directly in the transcript. Example display:

Jev  LOW → HIGH  ✓ APPLIED
     Step 3 · next 2 generation(s) · 321 ms

APPLIED means Codex confirmed the settings for the next generation. The notification is emitted after native application, not when Jev merely suggests a value.

Everyday use

astra-ares -C /path/to/project   # work in a repository
astra-ares resume --last        # continue your last Ares session
ares configure                 # replace the Jev key
ares doctor                    # check installation and configuration locally
ares doctor --probe            # make one small, billable Jev request

Codex still owns the terminal UI, tools, approvals, cancellation, and history. Choose ordinary Astra or another model in /model to work without Jev routing. Ares uses a separate Codex profile; resuming refers to that profile's sessions.

How it works

Your task + public progress + recent tool results
                       │
                       ▼
               Jev chooses effort
             and 1 / 2 / 5 / 10 steps
                       │
                       ▼
           Codex applies native settings
                       │
                       ▼
      Selected model generates → tools run
                       │
              repeat when due

A step is one model generation, which may produce several tool calls. The decision happens before the next generation, after available tool results enter the conversation. Jev judges the reasoning needed next, in the context of the user's goal. Reading a file does not automatically imply low effort: interpreting what was found may be the difficult part.

Jev also selects how long to keep its choice. If it selects ten generations, Ares asks at step 1 and again at step 11. Steps 2–10 use the accepted choice with no extra Jev requests. New user input, a tool failure, a model switch, or a manual effort change ends the current lease and triggers a fresh decision at the next eligible checkpoint. A failure asks Jev to reassess; it does not force a hardcoded escalation.

What Jev sees

Context Limit
Original/current task and retained previous user requests Preserved in the evaluator context
Public progress, plans, and published reasoning summaries Preserved; private/encrypted reasoning is excluded
Recent tool calls and paired results Last 6 calls
Combined result text for each call 1,000 local tokens, with explicit head/tail truncation
Complete evaluator request 28,000 local-token guard; oversized requests stop explicitly

These limits apply to Jev's view. Your selected model keeps its native conversation. The local tokenizer is a budget estimate, not Jev's exact tokenizer. This bounded task context is sent to your selected Jev provider; configuration and logs explain what is stored.

Native effort changes

These GPT-6 models support configuration_update between generations. Codex retains the original request-level effort and prompt prefix, and records the new effort in conversation history. That allows effort changes while preserving the prefix for prompt-cache reuse. Normal cache eligibility and retention rules still apply.

The bridge stays outside the selected model's network path: Codex talks directly to OpenAI. A new decision adds a Jev round trip and local checkpoint processing; an active lease needs only the local checkpoint. Native fixture tests verify settings application and prefix preservation. Workload cache hit rates and savings against fixed effort have not yet been measured. Architecture →

If something fails

Run ares doctor, then ares doctor --probe to check the provider. Logs live in ~/.local/share/astra-ares/runs/<run>/decisions.jsonl by default.

429 means a rate or capacity rejection; it does not by itself mean the context is too large. Transient HTTP errors receive at most three attempts against the same provider within a 30-second deadline. Exhausted errors stop the current turn visibly. Ares never silently switches providers, substitutes another model, or invents an effort choice. Troubleshooting →

Development

npm ci
npm test
# Native integration fixtures also need Bun and the patched binary:
JEV_TEST_BINARY="$HOME/.local/share/astra-ares/bin/codex" npm run test:native

The patch and upstream source checksums are pinned in patches/upstream.json. The architecture explains the native checkpoint, leases, and acknowledgements.

Local fixture tests require no API keys.


Installation & removal · Configuration · Validation · MIT license

Independent software, unaffiliated with OpenAI, TypeSafe, OpenRouter, or Vercel. The bridge is MIT-licensed; the patched Codex source is Apache-2.0. See third-party notices.

Astra-Ares (miuuyy/Astra-Ares)

Searching Database…

这是做什么用的?Astra-Ares 是一个实验性工具,让 Jev(AI 评估器)在 Codex 任务运行期间动态调整 GPT-6 的推理力度,为每一步匹配相应的思考深度,以减少 token 消耗。
它会替换我现有的 Codex 环境,还是和它并行使用?是并行使用:setup 会安装一个单独打过补丁的 Codex CLI,你现有的 codex 命令和 Codex 桌面应用都不受影响。Ares 在自己独立的 Codex profile 中工作,终端界面、工具、审批和历史记录仍然由 Codex 本身掌管。
构建之前我的电脑需要装哪些东西?需要 Node.js 22+、npm、Git、curl、tar、本地 C/C++ 编译工具链,以及通过 rustup 安装的 Rust。首次构建请预留约 10 GB 可用磁盘空间和几分钟时间;在 macOS 上可能需要安装 Xcode Command Line Tools(xcode-select --install)。
它能用于日常写代码,还是仍处于实验阶段?它明确是一个实验性的参考实现,主要用作在你自己的 agent 系统中引入自适应推理力度的参考——对日常开发来说仍处于早期预览阶段,不是成熟的产品。
我的电脑能跑吗——Windows、Linux、Mac 都行?目前只有苹果芯片(Apple Silicon)的 macOS 经过构建和测试。Intel 版 macOS 和 Linux 有构建方案,但尚未经过验收测试;由于该集成依赖 Unix 套接字,Windows 不受支持。
Jev 到底能看到我任务的哪些内容?只有有限的一部分:任务本身、公开的进度信息,以及你最近 6 次工具调用及其结果(每次结果最多截取 1000 个本地 token,整体上限为 28000 token)——私有的加密推理内容不包含在内。这部分数据会发送给你的 Jev 服务商,而模型连接仍然是 Codex 直连 OpenAI 的路径。
许可证方面有什么要注意的吗?许可证是分开的:Astra-Ares 桥接部分采用 MIT 许可证,而它所构建的打过补丁的 Codex 源码采用 Apache-2.0。该项目也是独立的,与 OpenAI、TypeSafe、OpenRouter 或 Vercel 均无关联。
模型怎么能在任务中途更改推理力度而不破坏缓存?GPT-6 系列模型支持在两次生成之间更新配置:Codex 会保留原始请求级别的推理力度和提示词前缀,因此提示词缓存可以继续复用,新的力度只是记录在对话历史中。
Jev 是不是每一步之前都要重新选择推理力度?不是——它还会选择一个租约长度。如果它选了十次生成,那它会在第 1 步做决定,再在第 11 步重新决定,中间不会发起任何 Jev 请求。新的用户输入、工具执行失败、切换模型或手动更改力度都会提前终止租约。
我可以让它对接哪些模型?在 Codex 的 /model 菜单里选择 Astra Ares、Sol Ares 或 Luna Ares——每个选项都会锁定其对应的底层 GPT-6 模型,而推理力度由 Jev 来决定。只有当相应模型在你的 Codex 目录中可用时,这些选项才会出现;选择普通模型则以不经过 Jev 路由的方式运行 Codex。
那它到底省不省 token?目前还不清楚——README 中说明,针对实际工作负载的缓存命中率以及相比固定推理力度的节省效果尚未测量。请把它当作一个值得观察的实验,而不是保证能降低成本的工具。
Creator
miuuyy
Size
0.8 MB
Stars
309
Updated
CommitOct 07
Age
28d
Commits · 90 Days