Codexa

io.github.mirnoorata由 GitHub 帳號 mirnoorata 發布v0.20.1更新於 Oct 24, 2026

Codex-native codebase intelligence context compiler and query-only MCP server.

已驗證STDIO僅桌面知識與記憶開發者工具

概覽

AI 產生的概覽

Codexa 為 Git 儲存庫建立本機程式碼地圖,讓 AI 程式助理能搜尋程式碼、追蹤相依與測試、規劃變更並評估影響。

可以做什麼
  • 搜尋與解說程式碼:找出檔案、函式與精確文字比對,並檢視檔案及其關聯關係
  • 影響與測試分析:查看變更可能波及的程式碼與測試,並針對目前編輯提供測試建議
  • 規劃與複核變更:儲存變更計畫,比對實際編輯與計畫,標出超出範圍的修改
  • 產出證據報告:輸出彙整計畫、驗證證據與待補缺口的證明卡,以及針對已提交分支與拉取請求的變更回執
  • 透過精簡的預設工具集提供能力查詢與安裝診斷,也可切換為完整工具集
適用情境
適合變更涉及多個檔案、目標位置或影響範圍不明確的情況,也適合在提交前儲存計畫並複核編輯。範圍明確的小修改通常只需直接檢視程式碼並執行專案自帶的測試。
執行需求
以本機 stdio 程序執行 npm 套件,需要 Node.js 22 或更新版本、npm、Git,以及一個用來建立索引的本機 Git 儲存庫。核心功能不需要 API 金鑰、託管帳號或資料庫。選用的向量化與重排服務預設關閉。可用一個選用環境變數調整結構化結果的位元組上限。
安裝前請注意
初始化指令會將設定與說明檔案寫入儲存庫,包括助理設定、鉤子、AGENTS.md 或 CLAUDE.md 中的區塊,以及選用的 GitHub Actions 工作流程;產生的索引與快取目錄應加入 gitignore。工具會更新 Codexa 自身的產生狀態,但不會修改原始碼檔案或執行指令;回報的檢查只是聲明而非實際執行。選用的 AutoVerify 會執行本機檢查,且並非沙箱。選用的 OpenAI 或 TypeSafe 功能會將原始碼文字與查詢傳送給這些服務。

安裝

在 SourceWeft 中

  1. 開啟 儀表板中的 Codexa,將其新增到工作區。
  2. 為需要使用其工具的對話啟用該服務。

Desktop only,透過 STDIO。 STDIO 服務會啟動本機處理程序,因此需要 SourceWeft 桌面主機。

其他 MCP 客戶端

參照 儲存庫 中的啟動說明。

README

Codexa

[Check] [npm]

Understand the code. See what a change could affect. Check the evidence.

Codexa helps developers and AI coding assistants work on a repository with more context and fewer guesses. It builds a local map of your code, connects files to their dependencies and tests, and produces readable reports about proposed and completed changes.

Think of it as a map and a change checklist for your project. The person—or coding assistant—still drives. Codexa points out the bridge you might want to check before taking the truck across it.

Use it from a terminal, with Codex, Claude Code, or another compatible coding assistant, or in GitHub Actions to help review pull requests. The core needs no API key, hosted account, or database. Codexa is free and MIT-licensed; your AI assistant and any optional hosted services have their own requirements and costs.

Get started · Connect an assistant · Everyday use · GitHub reviews · Troubleshooting · Full reference

Maintainer expectations: Codexa is a focused project maintained by one person in spare time. Expect replies in days to weeks. Please discuss larger changes before opening a PR; see Contributing.

What does it actually do?

Your questionWhat Codexa gives you
“Where does this behavior live?”Relevant files, functions, and exact text matches, with related code when useful.
“What might break if we change this?”A map of connected code and tests that may be affected.
“What should we test?”Suggested checks tied to the changed files and known relationships.
“Did the work stay within the plan?”A comparison between a saved plan and the actual edits, including unexpected changes.
“What evidence supports this handoff?”A proof card: a summary of the plan, verification evidence, and remaining gaps.
“What is this pull request changing?”A change receipt: a report covering committed changes, possible impact, and review guidance.

For example, changing a login timeout can affect more than one number. Codexa can help locate the setting, identify code that uses it, suggest related tests, and flag edits outside the agreed scope. Its findings depend on what it can read and connect in your repository; it cannot predict every runtime behavior.

Codexa supplies context and checks. Your editor or assistant makes the edits, and your project's tests establish whether the behavior works. A green-looking report is useful evidence, not a force field.

Quick start

You need Node.js 22 or newer, npm (included with Node.js), Git, and a local Git repository—the project folder you want to inspect. You do not need to clone Codexa itself or install an AI assistant to use the terminal commands.

1. Install

Run these commands in a terminal:

bash
node --versiongit --versionnpm install -g @mirnoorata/codexacodexa --version

2. Try it on your project

Replace /path/to/project with your repository's actual folder path. Quote the path if it contains spaces. In the examples below, . means “this folder.”

bash
cd /path/to/projectcodexa index .codexa repo-map .

index reads the repository and creates the local map. repo-map shows the ranked files and modules. This terminal-only path needs no assistant setup.

Ask a question relevant to your project:

bash
codexa search . --query "login timeout"

This is an example query, not a built-in demo: results depend on your code. For ongoing use, follow the generated-files guidance and choose your assistant setup below.

No global install? Prefix commands with npx -y @mirnoorata/codexa, for example npx -y @mirnoorata/codexa index /path/to/project. npm may download the package; the default indexing itself runs locally.

Connect your coding assistant

Codexa uses MCP (Model Context Protocol), the connection that lets an AI assistant ask external tools for information. The assistant runs the model; Codexa provides repository context. Install and sign in to your chosen assistant separately.

Codex

From your project folder:

bash
codexa init . --agents-mdcodexa session-start .

This creates the index, adds the Codexa server to .codex/config.toml, installs Codex startup/edit hooks, and adds a small managed workflow block to AGENTS.md. Omit --agents-md if you want to manage your own agent instructions. If a Codexa plugin already supplies your MCP connection, avoid registering a second server for the same repository.

Open or reload that same project in Codex and trust it when prompted. Project-scoped MCP configuration is loaded only for trusted projects. In Codex CLI, /mcp shows active connections; see the official MCP setup guide.

A successful session-start check confirms observable setup and index state; it cannot prove that an already-running assistant has loaded the server.

Windows: use codexa init . --agents-md --no-hooks for native Windows MCP-only setup. The generated shell hooks require a POSIX environment such as WSL. macOS and Linux can use the standard command above.

Claude Code

For the simplest connection:

bash
codexa init . --claude --claude-md --no-hookscodexa session-start .

This also writes the server entry to .mcp.json and workflow guidance to CLAUDE.md. Restart Claude Code in that repository and approve the project MCP server if prompted. --no-hooks disables Codexa's Codex hooks; this setup gives Claude tools and instructions, without Claude hooks or slash commands.

Want automatic startup guidance, a review hook, and commands such as /codexa-plan and /codexa-review? Use the bundled Claude Code plugin. Choose either the plugin or the .mcp.json connection above to avoid duplicate servers.

Other MCP clients

Configure a local command server in your client's MCP settings:

json
{  "mcpServers": {    "codexa": {      "command": "codexa",      "args": ["serve", "/path/to/project", "--auto-refresh"]    }  }}

Replace the path and adapt the outer configuration format to your client. The client must be able to find codexa and access the repository. It launches the server; serve is not an interactive chat command.

Fresh installs expose three tools: search, change_plan, and capabilities. That small menu is intentional: capabilities provides access to the remaining operations. Use --tools full with init or serve if your client needs every operation listed directly.

The default connection uses a local process. Optional HTTP transport binds only to the local machine; Codexa does not ship a public remote server.

The everyday workflow

Use Codexa when it resolves uncertainty. A small fix in a known file may need only direct inspection and the project's normal tests. No ceremony is required for changing a comma. A change spanning several files benefits more from planning and review.

For a coding assistant, a useful request is:

Find where login timeouts are handled. Use Codexa if the target or impact is unclear. Before a substantial edit, save a change plan. Make the change, run the relevant checks, and review the result against the plan. Tell me what remains unverified.

You can also run that workflow yourself. This example assumes your repository has src/auth.ts; substitute a real file and task:

bash
codexa change-plan . --task "Adjust the login timeout" --file src/auth.ts --task-id login-timeout --save-snapshot

Read the plan, make the edits, and run the checks appropriate to your project. Then review the work before committing, while the edits are still visible as local changes:

bash
codexa post-edit-review . --task-id login-timeout

Report checks you actually ran with --ran-command. For example, only if npm test is a real check in your project and you ran it:

bash
codexa post-edit-review . --task-id login-timeout --ran-command "npm test"

That flag records a claim; it does not execute the command. Codexa checks whether the reported command could cover the relevant work. A command that hides failures, such as npm test || true, does not earn credit. Codexa cannot detect a completely fabricated report.

For a formal handoff, codexa prove . --task-id login-timeout summarizes the saved plan, available evidence, and unresolved gaps. Supply actual command reports or selected verification artifacts when the handoff needs them.

Startup and edit hooks reduce manual steps, but their reviews do not replace one final review with the actual test evidence. Detailed workflow, invariants, and repeat-attempt controls are in the reference.

A few useful commands

Run these from the project root, using your own file names and questions:

CommandPurpose
codexa search . --query "password reset"Find a starting point.
codexa explain . --file src/auth.tsInspect a file and its relationships.
codexa impact . --file src/auth.tsSee what a change could affect.
codexa diff-impact .Inspect the impact of uncommitted changes.
codexa test-plan . --diffGet test suggestions for current edits.
codexa status .Check freshness and parser errors without refreshing.
codexa watch .Keep the index updated during a session; stop with Ctrl+C.
codexa doctor .Diagnose local setup problems.

Most context commands refresh an outdated index automatically. Use codexa --help, codexa <command> --help, or the command reference for more options.

Review pull requests

Codexa can generate a report for a committed branch without an AI assistant. From a clean checkout of that branch, with origin/main available locally:

bash
git fetch origincodexa review . --base origin/main --head HEADcodexa review . --base origin/main --head HEAD --format json

Replace origin/main if your repository uses a different base branch. Codexa compares changes since the branches' common ancestor. HEAD must match the checked-out commit, and the index must represent that clean checkout.

To add the same review to GitHub Actions:

bash
codexa init . --ci

Review and commit the generated .github/workflows/codexa-review.yml with your normal PR process. It checks out the PR's exact head, uses read-only repository permissions, and writes results to the Actions summary and annotations. It does not post PR comments or run your project's tests. Keep your existing CI.

The default observe mode reports findings without blocking on them. warn adds warning annotations. Explicit fail mode can block on local plan drift, an unavailable requested local plan, or reported command failures. Suggested but unrun tests alone do not fail the review. Invalid inputs and setup errors can fail in any mode.

See committed change receipts for plan comparison, trust limits, and CI options.

What gets written to your repository?

LocationContentsUsual Git treatment
.codex/codebase/Generated maps, relationships, and index.Ignore; regenerate per checkout.
.codex/cache/Saved plans, session notes, review state, and optional caches.Ignore; keep local evidence private.
.codex/static-analysis/Imported or explicitly generated scanner reports.Ignore.
.codex/config.toml, .codex/hooks.jsonCodex connection and hooks from init.Usually local; share deliberately.
.mcp.jsonClaude connection, when requested.Inspect paths and existing servers before sharing.
AGENTS.md, CLAUDE.mdManaged workflow block, only with the corresponding flag.Share if useful to your team.
.codex/policies/Optional JSON policies for proof cards.Share if they express team policy.
.github/workflows/codexa-review.ymlOptional GitHub Actions review.Commit to enable it.

Add these generated paths to your project's .gitignore (Codexa does not add them for you):

gitignore
.codex/codebase/.codex/cache/.codex/static-analysis/

If your MCP config and hooks are local to your machine, ignore those files too. Avoid ignoring the entire .codex/ directory if your team tracks policies or setup scripts there. Inspect generated launch paths before committing wiring; init supports portable wiring for already-tracked files. Each teammate and fresh checkout still needs its own install and index.

Re-running init refreshes Codexa's managed configuration and preserves other MCP server entries. Optional instruction blocks replace only the region between Codexa's markers. --policy-pack creates local proof policies without replacing existing policy files. See the setup reference for portability and managed-file behavior.

Support, privacy, and limits

  • Language support: TypeScript, JavaScript, and Python get the deepest parsing. Rust, Go, and Java get shallower declarations and relationships. Other recognized files receive lighter facts. External symbol reports can extend coverage; this is not full compiler-level understanding of every language.
  • Coverage: Codexa reads supported Git-visible files, including unignored new files. It skips common generated/dependency directories and source files larger than 2 MiB. Impact analysis follows at most three relationship steps; dynamic behavior and large repositories can need additional investigation.
  • Privacy: Default indexing and queries run locally without model calls. Context returned to an AI assistant is handled under that assistant's data policy. Optional OpenAI embeddings send selected source text and queries to OpenAI; optional TypeSafe reranking sends queries and candidate source snippets to TypeSafe. Both are off by default.
  • Execution: MCP tools can update Codexa's generated state, but do not edit your source files or run verification commands. Optional AutoVerify lets edit hooks run selected local checks after explicit user-owned configuration. It is off by default and is not a sandbox.
  • Evidence: Directly observed facts, inferred relationships, and guesses carry different confidence labels. Reported verification is distinguished from AutoVerify execution. A proof card records evidence and gaps; it does not certify that your code is correct or secure.

There is no web dashboard or hosted indexing service to operate. Optional embeddings, TypeSafe, language-server assistance, scanner imports, session memory, and AutoVerify are documented in the reference.

Troubleshooting

SymptomWhat to check
codexa is not foundReopen your terminal, check npm's global executable directory is on PATH, or use the npx alternative.
Installation fails building a native dependencyCheck Node.js is 22+; Tree-sitter dependencies may need your platform's native build tools when a prebuilt binary is unavailable.
The assistant cannot see CodexaRun codexa doctor ., confirm the repository path, then reload that project in the assistant. In Codex, check project trust and /mcp.
“Current-thread MCP: unverified”The CLI cannot inspect your assistant's live connection. Check the assistant's active server list; this alone is not an installation failure.
Missing, stale, or mismatched indexRun codexa index . in the actual checkout. Never copy an index from another worktree.
Parser errors or missing relationshipsCheck codexa status ., language support, ignored files, and source-size limits. A degraded result is incomplete evidence.
Committed review refuses to runResolve local changes, check out the requested head, and rebuild the index. Use post-edit-review for uncommitted edits.
Hooks fail on native WindowsRe-run init with --no-hooks for MCP-only use, or use WSL for shell hooks.

Updating or removing Codexa

Update with npm install -g @mirnoorata/codexa@latest, re-run your chosen init command in each repository, and reload the assistant connection. Reuse optional flags such as --claude or --agents-md to refresh those integrations. Plain init preserves the existing tool profile; use --tools core to switch it.

To remove Codexa, first disable its server/plugin and remove only its managed config entries, hooks, and instruction blocks. Preserve other tools' settings. Then run npm uninstall -g @mirnoorata/codexa. Generated indexes can be removed; export any plans or evidence you want to keep before deleting .codex/cache/. Remove its CI workflow too if you enabled one. There is no all-in-one uninstall command.

Codex Project Worktrees And Local Setup

A Git worktree is another checkout of the same repository. Run codexa init inside each one so its configuration and index match its own code. Automate that step in your project's setup if you create worktrees frequently.

When developing Codexa itself, this repository includes a Codex local environment and bootstrap scripts that install locked dependencies, build the package, and verify worktree setup. Those scripts are for this repository; ordinary users do not need to copy them. See the worktree and recovery guide.

For contributors and curious readers

Codexa's engine is TypeScript. Its main path is:

text
Repository → local index → relevant context and change analysis → evidence report
AreaWhere to look
Installation and commandssrc/init.ts, src/cli.ts
File discovery, parsing, and relationshipssrc/indexer/, src/parser/, src/resolver.ts, src/graph.ts
Search, plans, review, and test evidencesrc/query/, src/prove.ts
Assistant tools and local session statesrc/mcp/, src/session-memory/
Host integrations and CIplugins/codexa/, integrations/claude-code/, action.yml
Verification and packagingtests/, scripts/

To build from source:

bash
git clone https://github.com/mirnoorata/codexa.gitcd codexanpm cinpm run buildnpm linknpm run check

npm link makes this checkout's codexa command available locally; skip it if you prefer node dist/cli.js. The full gate builds and type-checks the package, checks hygiene and public paths, runs tests, and checks the startup context budget. See Contributing and the architecture reference.

Public Proof

The repository includes reproducible retrieval evaluations and an agent A/B harness. These measure different things: finding useful context does not by itself prove that an assistant finishes tasks faster or better. An archived small agent pilot showed extra overhead without a completion benefit; it is not evidence of universal savings. Results, dates, caveats, and reproduction commands are kept in Public Proof.

GitHub Release Timeline

GitHub Releases are the visible source timeline for the current project. Maintainers normally use Release Automation. An explicitly requested manual npm run release:github generates a changelog-style summary, changed-area summary, restore instructions, and forward-only PR rollback commands. See the manual release reference.

Release Automation

Release Please prepares version/changelog PRs and GitHub Releases using the repository's GITHUB_TOKEN. This does not publish npm on every main merge: ordinary changes land first, and npm publishing follows a published release. See release automation and the public release checklist.

npm Package Publishing

The maintainer workflow publishes through GitHub Actions and npm trusted publishing. It runs after an explicit Release Please dispatch or a manually published GitHub Release (release: published), not a tag push alone. After its release and security checks, the workflow runs:

bash
npm publish --registry https://registry.npmjs.org --access public --tag latest --provenance --ignore-scripts

Package users only need the installation instructions above. Maintainers can find authentication and recovery procedures in the publishing reference.

Help and license

Use Discussions for questions and Issues for reproducible bugs. Report vulnerabilities through private security advisories; see SECURITY.md.

Codexa is licensed under MIT.

來源:README.md,提交 a00e138

工具

0
SourceWeft 尚未在沙箱中啟動過該軟體包,因此其工具未知。

版本歷史

4
  1. v0.20.1最新Oct 1, 2026
  2. v0.20.0Sep 19, 2026
  3. v0.19.0Sep 18, 2026
  4. v0.18.0Sep 16, 2026

評分

已滿足適用檢查項的 50%

該評分衡量此收錄條目的完整程度,依據註冊中心條目、端點與公開來源計算得出。它不是對伺服器本身的評價,也不表示伺服器安全或目前可用:可連通性是帶日期的檢查結果,評分也不包含安裝量或使用者評價。

  • 近 30 天內可連通25 分

    請保持端點能夠回應 MCP 握手;SourceWeft 每 30 天探測一次。

  • 已宣告認證方式10 分

    請在註冊中心條目中宣告憑證請求標頭,或保持端點能夠回應探測,以便判定其認證方式。

  • 已列出工具15 分

    請讓伺服器在無憑證時回應 tools/list,或發布可在沙箱中無憑證啟動的軟體包。

  • 描述必需15 分
  • 圖示10 分
  • 文件15 分
  • 授權條款10 分