{"_id":"o-yuan","_rev":"5-48361ed38161b1f5956a16476cac1618","name":"o-yuan","dist-tags":{"latest":"3.1.2"},"versions":{"3.0.0":{"name":"o-yuan","version":"3.0.0","keywords":["agent","ai","llm","automation","openai","deepseek","gui-automation","self-hosted","multi-model","tool-calling","chatbot","assistant","developer-tools"],"author":{"name":"ZnFr60"},"license":"MIT","_id":"o-yuan@3.0.0","maintainers":[{"name":"znfr60","email":"19812818211@163.com"}],"homepage":"https://github.com/ZnFr60/O-yuan-Agent","bugs":{"url":"https://github.com/ZnFr60/O-yuan-Agent/issues"},"bin":{"oyuan":"bin/oyuan.js","o-yuan":"bin/oyuan.js"},"dist":{"shasum":"87ec0cfc58ffc5c70b298c3bf3273d6fa202d2bb","tarball":"https://registry.npmjs.org/o-yuan/-/o-yuan-3.0.0.tgz","fileCount":70,"integrity":"sha512-GQVTiFjHND/APN3svvAm4/HH51pGl/CrgLDg8+4ZMeZwKYPGO6O9kK4lHGad46VyDdaXr5GatlmYxvBLbp4cpA==","signatures":[{"sig":"MEQCIC7j9Idzs5TFyYbx9O29LYrrDE7OeLSGhJ+08TOPhUP1AiAmFZPVKGK5HChBIqm6OziQeSNohdjCS2gR/1emaFA+HA==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":449782},"main":"src/js/server.js","engines":{"node":">=16"},"gitHead":"1234d6a207d06bf7ea37721de790ef63d0e6826c","gypfile":true,"scripts":{"dev":"node src/js/server.js --dev","test":"node tests/run-tests.js","build":"node-gyp rebuild","oyuan":"node bin/oyuan.js","start":"node src/js/server.js","install":"node-gyp rebuild","build:win":"node-gyp rebuild --arch=x64","build:arm64":"node-gyp rebuild --arch=arm64","build:clean":"node-gyp clean && node-gyp rebuild"},"_npmUser":{"name":"znfr60","email":"19812818211@163.com"},"repository":{"url":"git+https://github.com/ZnFr60/O-yuan-Agent.git","type":"git"},"_npmVersion":"10.8.2","description":"O-yuan (启原) - 跨平台通用智能体 Agent，自研架构，28+内置工具，多模型合议，GUI自动化，持久化Shell，完全自托管","directories":{},"_nodeVersion":"20.20.2","dependencies":{"ws":"^8.21.3","node-addon-api":"^8.0.0"},"preferGlobal":true,"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/o-yuan_3.0.0_1788066716903_0.6374747880597116","host":"s3://npm-registry-packages-npm-production"}},"3.0.1":{"name":"o-yuan","version":"3.0.1","keywords":["agent","ai","llm","automation","openai","deepseek","gui-automation","self-hosted","multi-model","tool-calling","chatbot","assistant","developer-tools"],"author":{"name":"ZnFr60"},"license":"MIT","_id":"o-yuan@3.0.1","maintainers":[{"name":"znfr60","email":"19812818211@163.com"}],"homepage":"https://github.com/ZnFr60/O-yuan-Agent","bugs":{"url":"https://github.com/ZnFr60/O-yuan-Agent/issues"},"bin":{"oyuan":"bin/oyuan.js","o-yuan":"bin/oyuan.js"},"dist":{"shasum":"ec60959bad50ad517bc1759407aa36516f42994e","tarball":"https://registry.npmjs.org/o-yuan/-/o-yuan-3.0.1.tgz","fileCount":71,"integrity":"sha512-EdJ2Mk360wYQjHXbCMJpCPfQTZYxgCsZWdXDYvEC9/nQtmqJYw0QpsyS4CYOD6sYy8FeOgRtF85meg/wxDMCQg==","signatures":[{"sig":"MEUCIAdG9pVgB7HqJ7y3Obvf9nDTbXMY8d27V0tA9nEiBQUHAiEA5OhQYFjVd5STdd6OHhq8ShAQBlOHJmTqGtU1XSLCeRM=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":936935},"main":"src/js/server.js","engines":{"node":">=16"},"gypfile":false,"scripts":{"dev":"node src/js/server.js --dev","test":"node tests/run-tests.js","build":"node-gyp rebuild","oyuan":"node bin/oyuan.js","start":"node src/js/server.js","install":"node -e \"console.log('[o-yuan] install: native build skipped, using prebuilt binary / JS fallback')\"","build:win":"node-gyp rebuild --arch=x64","build:arm64":"node-gyp rebuild --arch=arm64","build:clean":"node-gyp clean && node-gyp rebuild"},"_npmUser":{"name":"znfr60","email":"19812818211@163.com"},"repository":{"url":"git+https://github.com/ZnFr60/O-yuan-Agent.git","type":"git"},"_npmVersion":"10.9.8","description":"O-yuan (启原) - 跨平台通用智能体 Agent，自研架构，28+内置工具，多模型合议，GUI自动化，持久化Shell，完全自托管","directories":{},"_nodeVersion":"22.23.2","dependencies":{"ws":"^8.21.3","node-addon-api":"^8.0.0"},"preferGlobal":true,"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/o-yuan_3.0.1_1788655807799_0.3703252429798476","host":"s3://npm-registry-packages-npm-production"}},"3.1.0":{"name":"o-yuan","version":"3.1.0","keywords":["agent","ai","llm","automation","openai","deepseek","gui-automation","self-hosted","multi-model","tool-calling","chatbot","assistant","developer-tools"],"author":{"name":"ZnFr60"},"license":"MIT","_id":"o-yuan@3.1.0","maintainers":[{"name":"znfr60","email":"19812818211@163.com"}],"homepage":"https://github.com/ZnFr60/O-yuan-Agent","bugs":{"url":"https://github.com/ZnFr60/O-yuan-Agent/issues"},"bin":{"oyuan":"bin/oyuan.js","o-yuan":"bin/oyuan.js"},"dist":{"shasum":"ee90baa7e99aa9dbeb0a283174c4a5ecb11bcc30","tarball":"https://registry.npmjs.org/o-yuan/-/o-yuan-3.1.0.tgz","fileCount":71,"integrity":"sha512-f9ZBT9FNp88/O/TIGE9yfKPEh2+1Xz/kLXulOmcEXSoLol9OzErCbDlkiZ01bL57cKPiew5uIA0Uxwke/Tjmfw==","signatures":[{"sig":"MEYCIQDWH/uwkSpEYpX9ABD9t3Spr5uqrTxG3VQl1JzEWuwEdwIhAPz8yzTjBW6UJj2Yj5fjy591OFnmyJYgDtGG49wRyxqx","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEUCIBSgmEAWWa22LO9fTNtfnJo6/iu7M9uUAwLKN1eirJ2QAiEA+3YHPnuwvu3tUDxolRy9iIvq+Dz2NCk1EZJFkA4fUHo=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":944995},"main":"src/js/server.js","engines":{"node":">=16"},"gitHead":"608fef4c4ae5c24e961a80585040f4ff46c2ae5e","gypfile":false,"scripts":{"dev":"node src/js/server.js --dev","test":"node tests/run-tests.js","build":"node-gyp rebuild","oyuan":"node bin/oyuan.js","start":"node src/js/server.js","install":"node -e \"console.log('[o-yuan] install: native build skipped, using prebuilt binary / JS fallback')\"","build:win":"node-gyp rebuild --arch=x64","build:arm64":"node-gyp rebuild --arch=arm64","build:clean":"node-gyp clean && node-gyp rebuild"},"_npmUser":{"name":"znfr60","email":"19812818211@163.com"},"repository":{"url":"git+https://github.com/ZnFr60/O-yuan-Agent.git","type":"git"},"_npmVersion":"10.9.8","description":"O-yuan (启原) - 跨平台通用智能体 Agent，自研架构，28+内置工具，多模型合议，GUI自动化，持久化Shell，完全自托管","directories":{},"_nodeVersion":"22.23.2","dependencies":{"ws":"^8.21.3","node-addon-api":"^8.0.0"},"preferGlobal":true,"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/o-yuan_3.1.0_1789268625721_0.6769068829219209","host":"s3://npm-registry-packages-npm-production"}},"3.1.1":{"name":"o-yuan","version":"3.1.1","keywords":["agent","ai","llm","automation","openai","deepseek","gui-automation","self-hosted","multi-model","tool-calling","chatbot","assistant","developer-tools"],"author":{"name":"ZnFr60"},"license":"MIT","_id":"o-yuan@3.1.1","maintainers":[{"name":"znfr60","email":"19812818211@163.com"}],"homepage":"https://github.com/ZnFr60/O-yuan-Agent","bugs":{"url":"https://github.com/ZnFr60/O-yuan-Agent/issues"},"bin":{"oyuan":"bin/oyuan.js","o-yuan":"bin/oyuan.js"},"dist":{"shasum":"94b8a2443464ea24a10ad799169ced4dd770ab82","tarball":"https://registry.npmjs.org/o-yuan/-/o-yuan-3.1.1.tgz","fileCount":71,"integrity":"sha512-qyvljGA1tibBbSSfCc4/ofjrmWND4O16PqIcrFmcONxZz1l80b9ZRuIXxWX3wsRLispYi2dkaSNpXoZM3z3UUw==","signatures":[{"sig":"MEYCIQDI2TC5DOONndzOr6UV3MAZHFnlpJ0dQcM9Zw3HzRxtpQIhAIs3hayD0fv9c5OET2GSRJDZ6lyxOu5i+ShVLVEAz5/K","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEUCIBQ/I/2jNBFuG01HUqwLOmHCX8rN9UJ/Nuxtg1XjwPYNAiEA29YafHzw+UOxtS0XI7EJl3CYsG3IfFJSbDKGWI0i4Nw=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":945025},"main":"src/js/server.js","engines":{"node":">=16"},"gitHead":"7ad87493a3fc8ee08af4a41b3d27574df1ca43c9","gypfile":false,"scripts":{"dev":"node src/js/server.js --dev","test":"node tests/run-tests.js","build":"node-gyp rebuild","oyuan":"node bin/oyuan.js","start":"node src/js/server.js","install":"node -e \"console.log('[o-yuan] install: native build skipped, using prebuilt binary / JS fallback')\"","build:win":"node-gyp rebuild --arch=x64","build:arm64":"node-gyp rebuild --arch=arm64","build:clean":"node-gyp clean && node-gyp rebuild"},"_npmUser":{"name":"znfr60","email":"19812818211@163.com"},"repository":{"url":"git+https://github.com/ZnFr60/O-yuan-Agent.git","type":"git"},"_npmVersion":"10.9.8","description":"O-yuan (启原) - 跨平台通用智能体 Agent，自研架构，28+内置工具，多模型合议，GUI自动化，持久化Shell，完全自托管","directories":{},"_nodeVersion":"22.23.2","dependencies":{"ws":"^8.21.3","node-addon-api":"^8.0.0"},"preferGlobal":true,"_hasShrinkwrap":false,"_npmOperationalInternal":{"tmp":"tmp/o-yuan_3.1.1_1789268985323_0.5701595166586289","host":"s3://npm-registry-packages-npm-production"}},"3.1.2":{"_id":"o-yuan@3.1.2","bin":{"oyuan":"bin/oyuan.js","o-yuan":"bin/oyuan.js"},"bugs":{"url":"https://github.com/ZnFr60/O-yuan-Agent/issues"},"dist":{"shasum":"8d8617b9edc559a484fca1e219db8a405ab7afcb","tarball":"https://registry.npmjs.org/o-yuan/-/o-yuan-3.1.2.tgz","fileCount":71,"integrity":"sha512-q1QOPQwxz5NrRCqlQoHB19CmJCfYaOIgHpwlghhVl5oQq0LXDTnIKFesmn2nDgNPjQSqmL2+l1o9nr9d6FeIGA==","signatures":[{"sig":"MEQCIBXvhYAPJS6IMD1Xz9cNBK+DDUgnaLsOb6dm8Oy6IuqdAiBXmIt7f4m+G1xiU3GmMwYsdf860/h5BE15Sdl8MEsPpw==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEQCIDxeOct8RLfB0tOFSbJB5A8NE29vCPKDBI1VEqFM6THIAiBcaTBqVqjM7mx0aazZXc/uU8GYib98TSEQk5CJccirRA=="}],"unpackedSize":945068},"main":"src/js/server.js","name":"o-yuan","author":{"name":"ZnFr60"},"engines":{"node":">=16"},"gitHead":"ed8ccac9c939c1113497964567bd8428a111d6ec","gypfile":false,"license":"MIT","scripts":{"dev":"node src/js/server.js --dev","test":"node tests/run-tests.js","build":"node-gyp rebuild","oyuan":"node bin/oyuan.js","start":"node src/js/server.js","install":"node -e \"console.log('[o-yuan] install: native build skipped, using prebuilt binary / JS fallback')\"","build:win":"node-gyp rebuild --arch=x64","build:arm64":"node-gyp rebuild --arch=arm64","build:clean":"node-gyp clean && node-gyp rebuild"},"version":"3.1.2","_npmUser":{"name":"znfr60","email":"19812818211@163.com"},"homepage":"https://github.com/ZnFr60/O-yuan-Agent","keywords":["agent","ai","llm","automation","openai","deepseek","gui-automation","self-hosted","multi-model","tool-calling","chatbot","assistant","developer-tools"],"repository":{"url":"git+https://github.com/ZnFr60/O-yuan-Agent.git","type":"git"},"_npmVersion":"10.9.8","description":"O-yuan (启原) - 跨平台通用智能体 Agent，自研架构，28+内置工具，多模型合议，GUI自动化，持久化Shell，完全自托管","directories":{},"maintainers":[{"name":"znfr60","email":"19812818211@163.com"}],"_nodeVersion":"22.23.2","dependencies":{"ws":"^8.21.3","node-addon-api":"^8.0.0"},"preferGlobal":true,"_hasShrinkwrap":false,"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/o-yuan_3.1.2_1789271238310_0.9878425880094333"}}},"time":{"created":"2026-08-30T05:11:56.709Z","modified":"2026-09-13T03:47:18.540Z","3.0.0":"2026-08-30T05:11:57.058Z","3.0.1":"2026-09-06T00:50:07.969Z","3.1.0":"2026-09-13T03:03:45.829Z","3.1.1":"2026-09-13T03:09:45.407Z","3.1.2":"2026-09-13T03:47:18.406Z"},"bugs":{"url":"https://github.com/ZnFr60/O-yuan-Agent/issues"},"author":{"name":"ZnFr60"},"license":"MIT","homepage":"https://github.com/ZnFr60/O-yuan-Agent","keywords":["agent","ai","llm","automation","openai","deepseek","gui-automation","self-hosted","multi-model","tool-calling","chatbot","assistant","developer-tools"],"repository":{"url":"git+https://github.com/ZnFr60/O-yuan-Agent.git","type":"git"},"description":"O-yuan (启原) - 跨平台通用智能体 Agent，自研架构，28+内置工具，多模型合议，GUI自动化，持久化Shell，完全自托管","maintainers":[{"name":"znfr60","email":"19812818211@163.com"}],"readme":"# O-yuan (启原) v3.0\r\n\r\n> Cross-platform universal intelligent Agent — self-developed architecture that reproduces and improves the core capabilities of mainstream industry Agents.\r\n>\r\n> 跨平台通用智能体 Agent — 自研架构，复现并完善业界主流 Agent 的核心能力。\r\n\r\n## Introduction / 项目简介\r\n\r\nO-yuan (启原) is a fully self-hosted universal intelligent Agent that adopts a hybrid architecture of **Node.js upper-layer scheduling + C++ native extensions (optional)**. The design goal is to provide tool calling, multi-model deliberation, GUI automation, persistent Shell, and other capabilities comparable to commercial Agents while maintaining minimal dependencies.\r\n\r\nO-yuan（启原）是一个完全自托管的通用智能体 Agent，采用 **Node.js 上层调度 + C++ 原生扩展（可选）** 的混合架构。设计目标是在保持极简依赖的前提下，提供媲美商业 Agent 的工具调用、多模型合议、GUI 自动化、持久化 Shell 等能力。\r\n\r\n**Core Philosophy / 核心哲学**: Security policies are determined by developers themselves. Configurations are stored in plain text, no sandbox enforcement, no password authentication — all security boundaries are left to users to build as needed.\r\n\r\n**核心哲学**：安全策略由开发者自行决定。配置明文存储、无沙箱强制、无密码鉴权——所有安全边界交给使用者按需搭建。\r\n\r\n## Core Features / 核心特性\r\n\r\n### 🤖 Agent Loop (Native function calling / 原生 function calling)\r\n- Native tool calling loop based on OpenAI standard `tool_calls`\r\n- 基于 OpenAI 标准 `tool_calls` 的原生工具调用循环\r\n- No hard step limit (default 50 steps, configurable)\r\n- 无步数硬限制（默认 50 步，可配置）\r\n- No tool result truncation, complete return\r\n- 无工具结果截断，完整返回\r\n- Support parallel calling of multiple tools in the same round\r\n- 支持同一轮并行调用多个工具\r\n- Streaming output (real-time token-by-token rendering)\r\n- 流式输出（token 逐块实时渲染）\r\n\r\n### 🔀 Multi-Model Deliberation Scheduling / 多模型合议调度\r\n- Four modes: `fast` (quick return) / `equal` (equal voting) / `weighted` (weighted voting) / `deep` (deep secondary summary)\r\n- 四种模式：`fast`（快速返回）/ `equal`（均等投票）/ `weighted`（加权投票）/ `deep`（深度二次汇总）\r\n- Support designating a **primary model (coordinator)** responsible for summarizing results from multiple parties\r\n- 支持指定**主模型（协调者）**，负责汇总多方结果\r\n- Automatic model failure blacklist (automatically skipped after consecutive failures reach threshold)\r\n- 模型故障自动黑名单（连续失败达阈值自动跳过）\r\n- Thinking depth control (native temperature mapping / prompt_override reasoning constraints)\r\n- 思考深度控制（native 温度映射 / prompt_override 推理约束）\r\n\r\n### 🛠 28 Built-in Tools / 28 个内置工具\r\n\r\n| Category / 分类 | Tools / 工具 |\r\n|------|------|\r\n| **Filesystem / 文件系统** | `list_dir`、`read_file`、`write_file`、`edit_file`、`search_files`、`glob` |\r\n| **Shell** | `shell_exec` (persistent / 持久化)、`shell_status`、`shell_cd`、`shell_close`、`run_command` |\r\n| **Code Execution / 代码运行** | `run_code` (Python / JavaScript isolated execution / 隔离执行) |\r\n| **Network / 网络** | `web_fetch` (web page fetching, HTML auto-converted to plain text / 网页获取，HTML 自动转纯文本) |\r\n| **Development / 开发** | `git` (status/log/diff/commit/branch/pull/push etc. / 等)、`todo` (task management / 任务管理) |\r\n| **GUI Automation / GUI 自动化** | `gui_screenshot`、`gui_mouse`、`gui_keyboard`、`gui_screen`、`gui_screencrop` |\r\n| **Agent** | `subagent` (sub-agent delegation, supports process isolation / 子代理委派，支持进程隔离) |\r\n| **Others / 其他** | `kb_query` (knowledge base / 知识库)、`web_search`、`load_skill`、`workflow` |\r\n\r\n### 🖥 GUI Automation / GUI 自动化\r\n- Virtual mouse/keyboard/screenshot based on Python + pyautogui\r\n- 基于 Python + pyautogui 的虚拟鼠标/键盘/截屏\r\n- Support vision models to directly view images for operation\r\n- 支持 vision 模型直接看图操作\r\n- Automatic screenshot injection (auto-capture when screen-related intent is detected)\r\n- 自动截图注入（检测到屏幕相关意图时自动截屏）\r\n\r\n### 💾 Persistence & Local Storage / 持久化与本地存储\r\n- Conversation history: `logs/sessions.json` (structured / 结构化) + `logs/conversations/*.txt` (human-readable plain text / 人类可读明文)\r\n- 对话历史：`logs/sessions.json`（结构化）+ `logs/conversations/*.txt`（人类可读明文）\r\n- Configuration: `config/config.json` (plain text JSON, includes API Key / 明文 JSON，含 API Key)\r\n- 配置：`config/config.json`（明文 JSON，含 API Key）\r\n- Knowledge base: `config/kb/` (local RAG / 本地 RAG)\r\n- 知识库：`config/kb/`（本地 RAG）\r\n- Character roles: `config/roles/`\r\n- 角色人设：`config/roles/`\r\n- Skill packs: `config/skills/`\r\n- 技能包：`config/skills/`\r\n\r\n### 🎨 Frontend Interface / 前端界面\r\n- Dark / light theme toggle\r\n- 暗色 / 明亮主题切换\r\n- Real-time streaming output\r\n- 实时流式输出\r\n- Tool calling process visualization (collapsible cards showing parameters + result summary)\r\n- 工具调用过程可视化（可折叠卡片，显示参数 + 结果摘要）\r\n- Think process collapsed display\r\n- Think 思考过程折叠展示\r\n- Quick model switching in input box\r\n- 输入框模型快速切换\r\n- Conversation history sidebar (highlight on selection)\r\n- 会话历史侧边栏（选中高亮）\r\n- Workflow stage progress bar\r\n- 工作流阶段进度条\r\n\r\n## Installation / 安装\r\n\r\n### Requirements / 环境要求\r\n- Node.js >= 16\r\n- Python 3.x (required for GUI automation, optional / GUI 自动化需要，可选)\r\n- pyautogui + Pillow (required for GUI automation, `pip install pyautogui Pillow` / GUI 自动化需要)\r\n\r\n### Method 1: NPM Global Install (Recommended / 推荐)\r\n\r\n```bash\r\n# Global install / 全局安装\r\nnpm install -g o-yuan\r\n\r\n# Start service / 启动服务\r\noyuan start\r\n\r\n# Or specify port / 或指定端口\r\noyuan start --port 8080\r\n\r\n# Check status / 查看状态\r\noyuan status\r\n\r\n# Check config path / 查看配置路径\r\noyuan config\r\n```\r\n\r\nThen open `http://127.0.0.1:3088` in your browser\r\n\r\n然后浏览器打开 `http://127.0.0.1:3088`\r\n\r\n### Method 2: One-Click Deployment Script / 一键部署脚本\r\n\r\n**Windows (PowerShell):**\r\n```powershell\r\n# After cloning the repo, execute in the project directory\r\n# 克隆仓库后，在项目目录执行\r\n.\\install.ps1\r\n\r\n# Optional parameters / 可选参数\r\n.\\install.ps1 -SkipBuild      # Skip C++ compilation (use JS fallback / 跳过 C++ 编译，用 JS 降级)\r\n.\\install.ps1 -StartNow       # Start immediately after installation / 安装后立即启动\r\n.\\install.ps1 -Port 8080      # Specify port / 指定端口\r\n```\r\n\r\n**Linux / macOS:**\r\n```bash\r\n# After cloning the repo, execute in the project directory\r\n# 克隆仓库后，在项目目录执行\r\nchmod +x install.sh\r\n./install.sh\r\n\r\n# Optional parameters / 可选参数\r\n./install.sh --skip-build      # Skip C++ compilation / 跳过 C++ 编译\r\n./install.sh --port=8080       # Specify port / 指定端口\r\n```\r\n\r\n### Method 3: Install from Source / 从源码安装\r\n\r\n```bash\r\n# Clone the repo / 克隆仓库\r\ngit clone https://github.com/ZnFr60/O-yuan.git\r\ncd O-yuan\r\n\r\n# Install dependencies (minimal, only node-addon-api + ws / 极少，仅 node-addon-api + ws)\r\nnpm install\r\n\r\n# Start service / 启动服务\r\nnpm start\r\n```\r\n\r\nThen open `http://127.0.0.1:3088` in your browser\r\n\r\n然后浏览器打开 `http://127.0.0.1:3088`\r\n\r\n### C++ Native Extension (Optional, Performance Acceleration / 可选，性能加速)\r\n\r\n```bash\r\n# Windows\r\nnpm run build:win\r\n\r\n# macOS / Linux\r\nnpm run build\r\n```\r\n\r\nAutomatically falls back to pure JS implementation when not compiled, with full functionality.\r\n\r\n未编译时自动降级为纯 JS 实现，功能完整。\r\n\r\n## Configuration / 配置\r\n\r\nOn first launch, `config/config.json` will be automatically generated from `config/config.default.json`.\r\n\r\n首次启动会自动从 `config/config.default.json` 生成 `config/config.json`。\r\n\r\n### Model Configuration / 模型配置\r\n\r\nAdd in Settings page → Model Management:\r\n\r\n在设置页面 → 模型管理中添加：\r\n\r\n| Field / 字段 | Description / 说明 |\r\n|------|------|\r\n| Name / 名称 | Custom display name / 自定义显示名 |\r\n| Model ID / 模型 ID | e.g. `deepseek-chat`、`gpt-4o-mini` |\r\n| Base URL | Provider API address / 供应商 API 地址 |\r\n| API Key | Secret key (displayed as password by default, toggleable visibility / 密钥，默认密码形式显示，可切换可见) |\r\n| Weight / 权重 | Voting weight during deliberation (0-2 / 合议时的投票权重) |\r\n| Primary Model / 主模型 | Set as deliberation coordinator (single select / 设为合议协调者，单选) |\r\n| Thinking Control / 思考控制 | native (temperature mapping / 温度映射) / prompt_override (reasoning constraints / 推理约束) |\r\n| Vision | Whether image recognition is supported / 是否支持图像识别 |\r\n\r\nSupports any OpenAI-compatible API: DeepSeek, OpenAI, Qwen, Zhipu, Ollama, etc.\r\n\r\n支持任意 OpenAI 兼容 API：DeepSeek、OpenAI、通义千问、智谱、Ollama 等。\r\n\r\n### Permission Levels / 权限等级\r\n\r\n| Level / 等级 | Capabilities / 能力 |\r\n|------|------|\r\n| `none` | Chat only, no tools / 仅对话，无工具 |\r\n| `medium` | Read-only tools (file read, search, screenshot / 只读工具：文件读取、搜索、截图) |\r\n| `full` | All tools (command execution, file writing, GUI control / 全部工具：命令执行、文件写入、GUI 控制) |\r\n\r\nDefault is `full`, developers adjust as needed.\r\n\r\n默认 `full`，开发者自行调整。\r\n\r\n## Architecture / 架构\r\n\r\n```\r\n┌─────────────────────────────────────────┐\r\n│          Frontend (public/)             │\r\n│  HTML + CSS + Vanilla JS (no framework) │\r\n│  前端 HTML + CSS + 原生 JS（无框架依赖）│\r\n└──────────────────┬──────────────────────┘\r\n                   │ HTTP / SSE\r\n┌──────────────────▼──────────────────────┐\r\n│       Service Layer (src/js/server.js)  │\r\n│  REST API + SSE streaming + static files│\r\n│  服务层 REST API + SSE 流式 + 静态文件  │\r\n├──────────────────────────────────────────┤\r\n│     Core Scheduling (src/js/core/)      │\r\n│  agent-loop · config · session · logger │\r\n│  核心调度 permissions · hooks · features│\r\n│                   · cache                │\r\n├──────────────────────────────────────────┤\r\n│    Model Layer (src/js/deliberation/)   │\r\n│  scheduler · provider · model-profiles  │\r\n│  模型层                                  │\r\n├──────────────────────────────────────────┤\r\n│      Tools Layer (src/js/tools/)        │\r\n│  tool-runner · filesystem · shell        │\r\n│  code-runtime · git · todo · gui         │\r\n│  工具层 subagent · search · rag · plugins│\r\n├──────────────────────────────────────────┤\r\n│   Native Extension (src/cpp/) Optional   │\r\n│  C++ Addon (perf boost, auto-fallback)   │\r\n│  原生扩展（性能加速，未编译自动降级）    │\r\n└──────────────────────────────────────────┘\r\n```\r\n\r\n## Security Notice / 安全说明\r\n\r\nThis project **does not include by default** the following security mechanisms, which developers should build as needed:\r\n\r\n本项目**默认不包含**以下安全机制，由开发者按需自行搭建：\r\n\r\n- ❌ Command sandbox (no blacklist/whitelist filtering / 无黑名单/白名单过滤)\r\n- ❌ Dangerous operation approval confirmation / 危险操作审批确认\r\n- ❌ LAN access password / 局域网访问密码\r\n- ❌ Configuration encryption (API Key stored in plain text / API Key 明文存储)\r\n- ❌ Operation audit log / 操作审计日志\r\n\r\n**The only retained security control**: Three-level permission system (none / medium / full).\r\n\r\n**保留的唯一安全控制**：三级权限等级（none / medium / full）。\r\n\r\n> ⚠️ This project is intended for developers and technical users. When deploying in untrusted environments, please add network isolation, container sandbox, reverse proxy authentication, and other security measures as needed.\r\n>\r\n> ⚠️ 本项目面向开发者和技术用户。在不可信环境部署时，请自行添加网络隔离、容器沙箱、反向代理鉴权等安全措施。\r\n\r\n## License / 许可证\r\n\r\nMIT License\r\n","readmeFilename":"README.md"}