mirror of
https://github.com/hansjone/oclaw.git
synced 2026-10-09 03:30:48 +08:00
docs: add out-of-the-box quickstart and cross-links
Add Chinese quickstart in README, env file step in OPEN_SOURCE_QUICKSTART, and RUNBOOK pointer to the one-page checklist. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
parent
b0e0c05d8a
commit
4444a8040e
3 changed files with 76 additions and 0 deletions
62
README.md
62
README.md
|
|
@ -2,12 +2,72 @@
|
|||
|
||||
This repository is fully consolidated under `oclaw/`.
|
||||
|
||||
## 开箱即用(从零跑起来)
|
||||
|
||||
面向第一次在本机跑通 **网关 + Admin + Chat** 的最短路径(Windows)。不需要微信/WhatsApp 也能先调试界面与模型。
|
||||
|
||||
### 前置条件
|
||||
|
||||
- **系统**:Windows 10/11,PowerShell
|
||||
- **Python**:3.11+(脚本会在仓库根创建 `.venv`,后续命令始终用该环境)
|
||||
- **Node.js**:22+(官方微信插件 / 部分 sidecar 需要;若暂时只用浏览器访问 Admin/Chat,可先只准备 Python,按需再装 Node)
|
||||
- **npm**:随 Node 安装(同上,按需)
|
||||
|
||||
### 环境与密钥(推荐先做)
|
||||
|
||||
1. **进程环境文件**:从模板复制一份,按需填写端口、密钥等(勿提交真实密钥文件)。
|
||||
|
||||
```powershell
|
||||
copy _local\system.env.example _local\system.env
|
||||
```
|
||||
|
||||
网关入口会加载 `_local/system.env`;已在系统或启动脚本里 export 的变量优先级更高。
|
||||
|
||||
2. **LLM**:可在 **Admin** 后台配置 Provider / 模型与密钥;也可在 `_local/system.env` 里设置 `OPENAI_API_KEY`、`OPENAI_BASE_URL` 等兜底。完整清单见 `docs/ENVIRONMENT_VARIABLES.md`。
|
||||
|
||||
### 命令(仓库根目录执行)
|
||||
|
||||
```powershell
|
||||
powershell -ExecutionPolicy Bypass -File .\scripts\bootstrap_venv.ps1
|
||||
powershell -ExecutionPolicy Bypass -File .\scripts\start_gateway.ps1 -SkipInstall -Background
|
||||
```
|
||||
|
||||
或使用 **一键后台启动全栈**(未安装的微信/WhatsApp sidecar 会告警并跳过,不阻塞 Admin/Chat):
|
||||
|
||||
```powershell
|
||||
powershell -ExecutionPolicy Bypass -File .\scripts\start_all.ps1 -Background
|
||||
```
|
||||
|
||||
### 打开页面
|
||||
|
||||
- Admin:`http://127.0.0.1:8787/admin`
|
||||
- Chat:`http://127.0.0.1:8787/chat`
|
||||
|
||||
### 常见问题
|
||||
|
||||
- **8787 端口占用 / 重启不生效**:`powershell -ExecutionPolicy Bypass -File .\scripts\stop_gateway.ps1 -Force` 后再启动。
|
||||
- **更细的从零教程**:`docs/RUNBOOK.md` →「开源快速安装(从零到跑起来)」。
|
||||
|
||||
### 可选:运维专家(network_ops)与 netx
|
||||
|
||||
若要在 ops 专家模式下调 **netx** 告警库,需单独启动 netx 服务,并在 `_local/system.env` 中配置 `OCLAW_NETX_BASE_URL`(及可选的 `OCLAW_NETX_API_TOKEN`)。说明见 `docs/NETX_MCP_INTEGRATION.md`。
|
||||
|
||||
---
|
||||
|
||||
## Quickstart (Open Source)
|
||||
|
||||
### Prerequisites
|
||||
- Python 3.11+
|
||||
- Node.js 22+ (required by the official Weixin plugin)
|
||||
|
||||
### Recommended first run (env file)
|
||||
|
||||
```powershell
|
||||
copy _local\system.env.example _local\system.env
|
||||
```
|
||||
|
||||
Edit `_local/system.env` as needed. Gateway loads this file at startup.
|
||||
|
||||
### 1) Bootstrap venv (Windows)
|
||||
|
||||
```powershell
|
||||
|
|
@ -47,6 +107,8 @@ Full runbook (recommended): see `docs/RUNBOOK.md` → “开源快速安装(
|
|||
|
||||
Minimal onboarding guide: `docs/OPEN_SOURCE_QUICKSTART.md`.
|
||||
|
||||
Chinese zero-to-running checklist: see **开箱即用(从零跑起来)** at the top of this README.
|
||||
|
||||
## Layers
|
||||
- `runtime/`: core execution loop, routing, skill runtime, hook runtime
|
||||
- `interfaces/`: transport adapters (HTTP/WS)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue