Agent 智能体

Nexus-Agent|自主软件工程编码代理

Nexus-Agent

开源自托管 AI 编码代理,用 ReAct 循环、AST 语法预校验和沙箱工具完成代码编写、重构与 DevOps 任务的命令行或网页端操作。

获取与使用

需要部署

按官方资料自行安装或部署

使用难度待核验
国内可用性待核验

2026-11-08 更新 · 本站尚未实测

项目介绍

Agent 智能体 · 2026-11-08 更新 · 本站尚未实测

Nexus-Agent(仓库名 parkain707/nexus-agent)是 README 自述的开源自主软件工程代理,主要面向代码编写、重构与 DevOps 类任务。项目采用 Python 编写,仓库元数据将语言标为 Python,README 给出的兼容解释器版本为 Python 3.10 / 3.11 / 3.12。

按文档描述,它并非单纯的提示词链,而是以 ReAct 循环为核心,搭配 AST 语法预校验、SQLite 记忆和受安全守卫的工具总线,并提供命令行 TUI 与 Web 仪表盘两套界面。需要说明:上述能力均来自 README 自述与仓库徽章,本页未进行独立实测,实际表现、稳定性与安全边界均待核验。仓库当前未归档,最终以仓库状态为准。

核心能力

点击能力名称查看输入、输出和原文依据。

  • 自愈 ReAct 循环:README 称可捕获测试失败与 stderr,定位原因并修补代码。
  • AST 感知代码引擎:写入或修改文件前检查 Python 语法树,声称可避免语法损坏的提交。
  • 双界面:命令行富文本 TUI,以及通过 WebSocket 流式展示代理思考与工具执行的 Web 仪表盘。
  • 分层记忆:工作记忆加 SQLite 持久反思日志;README 还列出代码快照与回滚功能。
  • 内置工具:文件读写编辑、目录遍历、带超时与危险命令黑名单的沙箱 Shell、grep/glob 搜索、Git 状态/差异/提交、网页搜索与抓取。
  • 离线模拟引擎:README 称可用零 API Key 的确定性 Mock 提供方离线运行整套流程。
  • 多模型提供方:架构图列出 OpenAI/DeepSeek、Anthropic Claude、Google Gemini、本地 Ollama/vLLM 与 Mock,具体接线方式需查源码。

实际应用场景

适用场景

适合希望在本机或自有服务器上部署编码代理的开发者,例如:

  1. 让代理根据自然语言指令生成文件并补充单元测试;
  2. 对既有 Python 项目做小范围重构与查询优化;
  3. 在版本控制工作区内自动查看 diff、提交变更;
  4. 通过 Web 界面观察代理执行过程,或接入自定义工具。

不适合把仓库中未标注完成的路线图项当作现成功能:多代理协作、思维树搜索、浏览器 DOM 自动化均标记为未完成。

安装与接入

README 给出的主要方式(命令均为原文):

pip install "git+https://github.com/parkain707/nexus-agent.git"

从源码安装:

git clone https://github.com/parkain707/nexus-agent.git
cd nexus-agent
pip install -e .

Docker 启动:docker compose up --build,文档称 Web 仪表盘位于 http://localhost:8000。

运行示例:nexus-agent run "..."、nexus-agent web --port 8000。使用云端模型时 README 示例设置了 OPENAI_API_KEY 并指定 --provider openai --model gpt-4o;其他提供方的密钥与参数在本次资料中未给出,待核验。仓库未提供 MCP 配置或服务端配置文件(采集结果为 HTTP 404),因此不能按 MCP 服务接入。

使用条件与限制

是否需要部署
需自行准备运行环境,具体要求见正文
是否需要注册
账号和认证要求见正文;未明确说明的项目仍待核验
是否需要 API Key
待核验
费用与额度
费用边界见正文,项目许可不代表模型或托管服务免费
所需权限
待核验
许可证与服务条款
待核验

权限费用与限制

  • 权限:代理可执行 Shell、读写文件并操作 Git,权限范围较大;README 仅提到超时与危险命令黑名单,未给出完整沙箱隔离方案,实际安全边界待核验。
  • 费用:项目以 MIT 协议开源,但使用云端模型会产生第三方 API 费用,价格以各服务商为准,本页不报具体价格;离线 Mock 模式是否完全免费仍以实际运行情况为准。
  • 平台:README 提到 Windows 双击 start.bat、macOS/Linux 运行 start.sh,但脚本实际可用性与国内网络下的 pip/GitHub 访问情况待核验。README 中 Cloudflare 演示链接为临时地址,可能失效,不应视为稳定在线服务。
  • 规模:仓库星标与 Fork 数很少,成熟度、维护持续性待核验;README 的测试徽章与对比表为作者自述,未经独立复现。

国内使用情况

网友核验 用户经验分享

与站长实测独立,不代表官方认证或本站已实测。

我要核验
0 位参与者0 份有效分项记录

最近核验:暂无有效核验。参与人数按当前项目有效身份去重;不同核验项分别统计,不合并成用户总结果。仅统计审核通过且未过期的记录。

分项统计、有效期与样本量
核验项目有效人数成功 / 部分 / 失败 / 无法判断成功率最近核验 / 有效期
官方网站访问00 / 0 / 0 / 0样本不足暂无 / 7 天
GitHub 仓库访问00 / 0 / 0 / 0样本不足暂无 / 7 天
安装与运行00 / 0 / 0 / 0样本不足暂无 / 30 天
官方服务国内连接 / MCP 连接00 / 0 / 0 / 0样本不足暂无 / 30 天
国内网络情况00 / 0 / 0 / 0样本不足暂无 / 7 天
国内模型兼容性00 / 0 / 0 / 0样本不足暂无 / 30 天
自定义 API00 / 0 / 0 / 0样本不足暂无 / 30 天
海外服务依赖
00 / 0 / 0 / 0样本不足暂无 / 30 天
海外账号要求
00 / 0 / 0 / 0样本不足暂无 / 30 天
中文界面
00 / 0 / 0 / 0样本不足暂无 / 30 天
客户端兼容性00 / 0 / 0 / 0样本不足暂无 / 30 天
账号及费用信息
00 / 0 / 0 / 0样本不足暂无 / 30 天

成功率 = 成功 ÷(成功 + 部分成功 + 失败);无法判断不计入分母。至少 5 份可判断结果才显示成功率。账号、费用、海外依赖与语言等事实项,成功表示核查结论与资料吻合,具体观察另行统计;不表示免费或没有海外依赖。不同网络、客户端和版本的结果不能直接等同。

最近有效核验

暂无审核通过且未过期的网友核验。欢迎提交真实使用记录。

查看全部有效核验 →

国内实测状态:国内可用性待核验。协议兼容和官方资料说明不等于国内网络可用。

官方网站访问
尚未实测 待核验
GitHub 仓库访问
尚未实测 待核验
官方服务国内连接
尚未实测 待核验
国内网络情况
尚未实测 待核验
国内模型兼容性
尚未实测 待核验
自定义 API
尚未实测 待核验
海外服务依赖
尚未实测 待核验
海外账号要求
尚未实测 待核验
中文界面
尚未实测 待核验
国内最后核验时间
尚未实测

许可与国内使用

仓库根目录 LICENSE 为 MIT License,版权声明为 2026 Nexus Agent Core Legion,允许使用、复制、修改、合并、发布、分发、再许可与销售,需保留版权与许可声明,软件按“原样”提供、不附担保。开源许可不等于模型推理、云服务或后续功能免费。国内用户访问 GitHub、pip 源及境外模型 API 可能需要额外网络条件;国内模型兼容性资料未说明,待核验。

以上内容为待人工审核草稿,能力与安全结论均以 README 自述为依据。

项目资料与来源

GitHub 仓库 ↗

官方文档 ↗

字段依据与待核验事项

access:来源确认 · pip install "git+https://github.com/parkain707/nexus-agent.git"

project_type:来源确认 · Nexus-Agent is an open-source, production-grade autonomous software engineering agent designed to solve complex coding, refactoring, and devops tasks end-to-end.

原始 README(折叠技术参考)
<div align="center">

```
  _   _ _____ _   _ _   _ ____        _     ____ _____ _   _ _____ 
 | \ | | ____| \ | | | | / ___|      / \   / ___| ____| \ | |_   _|
 |  \| |  _| |  \| | | | \___ \     / _ \ | |  _|  _| |  \| | | |  
 | |\  | |___| |\  | |_| |___) |   / ___ \| |_| | |___| |\  | | |  
 |_| \_|_____|_| \_|\___/|____/   /_/   \_\\____|_____|_| \_| |_|  
```

# NEXUS-AGENT

### Next-Generation Autonomous AI Engineering & Orchestration Agent

[![CI](https://github.com/parkain707/nexus-agent/actions/workflows/ci.yml/badge.svg)](https://github.com/parkain707/nexus-agent/actions/workflows/ci.yml)
[![Coverage](https://img.shields.io/badge/Coverage-100%25-success?style=for-the-badge&logo=codecov&logoColor=white)]()
[![Python](https://img.shields.io/badge/Python-3.10%20%7C%203.11%20%7C%203.12-blue?style=for-the-badge&logo=python&logoColor=white)](https://www.python.org/)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow?style=for-the-badge&logo=opensourceinitiative&logoColor=white)](LICENSE)
[![Release](https://img.shields.io/github/v/release/parkain707/nexus-agent?color=orange&style=for-the-badge&logo=github)](https://github.com/parkain707/nexus-agent/releases)
[![GitHub Stars](https://img.shields.io/github/stars/parkain707/nexus-agent?style=social)](https://github.com/parkain707/nexus-agent/stargazers)
[![GitHub Forks](https://img.shields.io/github/forks/parkain707/nexus-agent?style=social)](https://github.com/parkain707/nexus-agent/network/members)

[**English**](README.md) | [**한국어 설명서 (README_KO.md)**](README_KO.md)

</div>

<p align="center">
  <img src="docs/assets/hero-banner.jpg" alt="Nexus-Agent Cyberpunk Mission Control" width="100%" />
</p>

> 🌐 **Live Interactive Web Demo**: [https://furnished-altered-incurred-webshots.trycloudflare.com](https://furnished-altered-incurred-webshots.trycloudflare.com)  
> *Experience the Cyberpunk Glassmorphic Mission Control in real-time with zero installation!*

---

## ⚡ What is Nexus-Agent?

**Nexus-Agent** is an open-source, production-grade autonomous software engineering agent designed to solve complex coding, refactoring, and devops tasks end-to-end.

Unlike brittle wrapper scripts that blindly chain prompts or hallucinate syntax errors, **Nexus-Agent** features:
1. **Self-Healing ReAct Loop**: Automatically captures test failures and `stderr`, pinpoints root causes, and patches code.
2. **AST-Aware Code Engine**: Verifies Python syntax trees *before* writing or modifying files, completely preventing syntax-broken commits.
3. **Dual-Engine UX**: 
   - 💻 **Rich TUI Terminal**: Colorful live diffs, spinners, step-by-step thinking visualization.
   - 🌐 **Cyberpunk Glassmorphism Web Dashboard**: Real-time WebSocket streaming of agent thoughts, live tool execution telemetry, and interactive controls.
4. **Hierarchical SQLite Memory**: Token-efficient working memory plus persistent SQLite reflection logs to learn from mistakes.
5. **Zero-API-Key Deterministic Mock Engine**: Test the entire agent suite offline in 1 second without spending a single cent on API tokens!

---

## 📊 Feature Comparison Matrix

| Feature | Nexus-Agent | AutoGPT | CrewAI | LangGraph | OpenManus |
| :--- | :---: | :---: | :---: | :---: | :---: |
| **Self-Healing AST Syntax Pre-Validation** | **Yes (Built-in)** | No | No | Custom only | No |
| **Dual Interface (Rich TUI + Glassmorphism Web)** | **Yes (Out-of-box)** | CLI only | Web optional | Custom only | CLI only |
| **Offline Zero-Key Deterministic Testing** | **Yes (1-sec CI)** | No | No | No | No |
| **Sandboxed Shell with Blacklist Guard** | **Yes** | Partial | Needs Docker | Custom only | Partial |
| **SQLite Mistake & Reflection Memory** | **Yes** | Vector DB | Key-value | State Graph | No |
| **Single-Command Docker Deployment** | **Yes** | Yes | Yes | Complex | No |

---

## 🚀 30-Second Quickstart

### 1. Installation

#### 📦 1-Line Global Installation (Recommended)

```bash
pip install "git+https://github.com/parkain707/nexus-agent.git"
```

#### ⚡ 1-Click Instant Launch (No setup needed)

- **Windows**: Simply double-click **`start.bat`**! It automatically configures the environment, starts the server, and pops up your browser.
- **Mac / Linux**: Run `chmod +x start.sh && ./start.sh`.

#### 💻 From Source (Developer Mode)

```bash
git clone https://github.com/parkain707/nexus-agent.git
cd nexus-agent
pip install -e .
```

### 🖥️ Run in Terminal (CLI Mode)

```bash
# Runs immediately with offline demo mode (zero cost, zero API keys!)
nexus-agent run "Create a fibonacci generator in fib.py and verify with unit tests"
```

To run with live cloud LLMs:
```bash
export OPENAI_API_KEY="sk-..."
nexus-agent run "Refactor database models and optimize queries" --provider openai --model gpt-4o
```

### 🌐 Launch the Web Mission Control Dashboard

```bash
nexus-agent web --port 8000
```
> [!TIP]
> Executing `nexus-agent web` automatically opens **`http://localhost:8000`** in your default browser! If port 8000 is occupied, it automatically shifts to the next available port.

---

## 🏗️ Architecture

```mermaid
graph TD
    User([User / Developer]) -->|CLI or Browser| UI[Dual Interface Layer]
    
    subgraph UI [Interface Layer]
        CLI[Rich TUI Interactive Terminal]
        Web[Cyberpunk Glassmorphism Dashboard]
    end

    UI --> Core[Nexus Core Engine]

    subgraph Core [Autonomous Core Engine]
        ReAct[ReAct Loop & Self-Healing Controller]
        LoopDet[Anti-Loop Detector]
        Memory[Hierarchical Memory: Working + SQLite Store]
        ToolBus[Sandboxed Tool Bus & Security Guard]
    end

    subgraph Tools [Safety-Guarded Tools]
        AST[AST-Aware File & Diff Engine]
        Shell[Sandboxed Shell Executor]
        Git[Git Workspace Controller]
        Search[Web & Code Search]
    end

    subgraph LLM [Multi-Provider Layer]
        Mock[Deterministic Mock Provider]
        OpenAI[OpenAI / DeepSeek]
        Claude[Anthropic Claude]
        Gemini[Google Gemini]
        Ollama[Local Ollama / vLLM]
    end

    ReAct --> Memory
    ReAct --> LoopDet
    ReAct --> ToolBus
    ToolBus --> Tools
    ReAct -.-> LLM
```

---

## 🛠️ Built-in Tool Arsenal

Nexus-Agent comes equipped with a comprehensive suite of safety-guarded engineering tools:

- `read_file`: Line-range slicing and file content inspection.
- `write_file`: Writes files with **AST syntax pre-validation** (rejects invalid Python syntax before disk write).
- `edit_file`: Performs surgical text replacement with automated unified diff preview.
- `list_dir`: Structured directory tree explorer.
- `execute_command`: Sandboxed shell execution with execution timeouts and destructive command blacklisting.
- `grep_search`: High-speed regex code search with line number snippets.
- `find_files`: Glob-based file locator.
- `git_status` / `git_diff` / `git_commit`: Autonomous version control management.
- `web_search` / `web_fetch`: Real-time documentation querying.

---

## 🧩 Writing Custom Tools in 5 Lines

You can effortlessly extend Nexus-Agent with domain-specific tools:

```python
from pydantic import BaseModel, Field
from nexus_agent.tools import BaseTool, create_default_registry
from nexus_agent import NexusAgent

class SlackAlertInput(BaseModel):
    channel: str = Field(..., description="Target Slack channel")
    message: str = Field(..., description="Alert text")

class SlackAlertTool(BaseTool):
    name = "send_slack_alert"
    description = "Send notifications to company Slack channels."
    args_schema = SlackAlertInput

    def run(self, channel: str, message: str) -> str:
        # Your notification logic here
        return f"Alert dispatched to {channel}: {message}"

# Register and run
registry = create_default_registry()
registry.register(SlackAlertTool())
agent = NexusAgent(registry=registry)
```

---

## 🐳 Docker Deployment

```bash
# 1-command startup
docker compose up --build
```
The Web Dashboard will be immediately available at `http://localhost:8000`.

---

## 🧪 Running Tests

Nexus-Agent boasts a 100% pass rate across unit, integration, and E2E self-healing test suites:

```bash
pytest -v
```

Output:
```text
tests/e2e/test_autonomous_coding.py::test_e2e_autonomous_coding_and_self_healing PASSED
tests/test_agent_core.py::test_agent_react_execution_flow PASSED
tests/test_agent_core.py::test_agent_loop_detection PASSED
tests/test_memory.py::test_working_memory_sliding_window PASSED
tests/test_memory.py::test_persistent_knowledge_and_reflection PASSED
tests/test_memory.py::test_snapshot_and_rollback PASSED
tests/test_schema_and_llm.py::test_schema_instantiation PASSED
tests/test_tools.py::test_file_ops_ast_validation PASSED
tests/test_tools.py::test_shell_command_sandbox_and_blacklist PASSED
tests/test_tools.py::test_diagram_generator PASSED
tests/test_web_api.py::test_web_status_endpoint PASSED
tests/test_web_api.py::test_chat_endpoint PASSED
tests/test_web_api.py::test_snapshots_api_and_rollback PASSED
tests/test_cli_scaffold.py::test_scaffold_fastapi PASSED
tests/test_cli_scaffold.py::test_scaffold_cli PASSED
tests/test_cli_scaffold.py::test_scaffold_custom_tool PASSED
...
======================= 20 passed in 1.86s =======================
```

---

## 🗺️ Roadmap

- [x] Autonomous ReAct loop with self-healing error recovery
- [x] AST-aware syntax pre-validation
- [x] Time-travel code snapshots & 1-click rollback
- [x] Dual-interface (Rich TUI + Cyberpunk Glassmorphism Web)
- [x] Offline Deterministic Mock provider for zero-cost testing
- [x] SQLite persistent reflection journal
- [x] Instant code scaffolding (`fastapi`, `cli`, `custom-tool`)
- [ ] Multi-agent collaborative swarm mode
- [ ] Tree-of-Thought (ToT) branch search
- [ ] Browser-use visual DOM automation

---

## 📣 Community & Viral Launch

Looking to share or contribute to Nexus-Agent? Check out our ready-to-use launch and sharing kits in [`launch/`](launch/README.md):
- [GeekNews Submission Kit](launch/GEEKNEWS_KO.md)
- [Hacker News Show HN](launch/HACKERNEWS_SHOW_HN.md)
- [Reddit r/LocalLLaMA & r/Python](launch/REDDIT_LOCALLAMA.md)
- [X/Twitter Viral Thread](launch/TWITTER_X_THREAD.md)
- [Velog / Technical Blog Post](launch/VELOG_POST_KO.md)

---

## ⭐ Star History

[![Star History Chart](https://api.star-history.com/svg?repos=parkain707/nexus-agent&type=Date)](https://star-history.com/#parkain707/nexus-agent&Date)

---

## 🤝 Contributing & License

Contributions, bug reports, and feature proposals are warmly welcomed! Please check [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines.

Distributed under the **MIT License**. See [LICENSE](LICENSE) for details.
历史前置条件说明(补充参考)

Python 3.10/3.11/3.12(README 标注);pip 与 Git;可选 Docker;使用云端模型需自备对应 API Key(README 仅示例 OPENAI_API_KEY),其他提供方参数待核验;访问 GitHub、pip 源及境外模型 API 可能需网络条件;费用与国内兼容性待核验。

项目来源与清单版权许可

https://github.com/parkain707/nexus-agent

整理来源:https://github.com/slavakurilyak/awesome-ai-agents

清单版权与许可:

MIT License

Copyright (c) 2024 Slava Kurilyak

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.