Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions INSTALL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Install

This repository is the source of truth for the consolidated Codex enhancement stack.

## One-command bootstrap

From a fresh clone:

```bash
./scripts/bootstrap.sh
```

That installs the `method-forge` skills into `"$CODEX_HOME/skills"` by symlink, so the local Codex App can discover them.

## Recommended flow for teammates

1. Clone the repository.
2. Run `./scripts/bootstrap.sh`.
3. Open the repository root as a Codex workspace.
4. When the repo changes, pull the latest revision and re-run the bootstrap script.

## Notes

- The repository keeps the three subsystems together under:
- `knowledge-base/`
- `memory-system/`
- `method-forge/`
- The bootstrap script only installs skills. It does not overwrite existing Codex memory data.
- If you want the global memory system refreshed for a workspace, use the memory-system refresh workflow in `memory-system/`.

5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,8 @@ The intended priority order is:

Use the subdirectory that matches the task. If a task spans systems, keep the work in this repo and follow the narrowest applicable instructions first.

## Install

Start here: [INSTALL.md](INSTALL.md)

The one-command bootstrap installs the `method-forge` skills into `"$CODEX_HOME/skills"` without touching existing Codex memory data.
2 changes: 1 addition & 1 deletion memory-system/AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
- 完成重要设计或实现后,运行:

```bash
python3 /Users/wz/.codex/scripts/refresh_memory.py --workspace-root "/Users/wz/project/codex-enhanced-system/memory-system"
python3 /Users/wz/.codex/scripts/refresh_memory.py --workspace-root "$(git rev-parse --show-toplevel)"
```

## 当前原则
Expand Down
2 changes: 1 addition & 1 deletion memory-system/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
全局运行入口是:

```bash
python3 /Users/wz/.codex/scripts/refresh_memory.py --workspace-root "/Users/wz/project/codex-enhanced-system/memory-system"
python3 /Users/wz/.codex/scripts/refresh_memory.py --workspace-root "$(git rev-parse --show-toplevel)"
```

本工作区里的实现源码当前保存在:
Expand Down
2 changes: 1 addition & 1 deletion memory-system/tests/test_refresh_strict_original_memory.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from pathlib import Path


SCRIPT_PATH = Path("/Users/wz/project/codex-enhanced-system/memory-system/scripts/refresh_strict_original_memory.py")
SCRIPT_PATH = Path(__file__).resolve().parents[1] / "scripts" / "refresh_strict_original_memory.py"


def load_module():
Expand Down
2 changes: 1 addition & 1 deletion method-forge/AGENTS.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# method-forge Rules

- 开工前先读共享 memory guides;重要工作完成后运行 `python3 /Users/wz/.codex/scripts/refresh_memory.py --workspace-root /Users/wz/project/codex-enhanced-system/method-forge`。
- 开工前先读共享 memory guides;重要工作完成后运行 `python3 /Users/wz/.codex/scripts/refresh_memory.py --workspace-root "$(git rev-parse --show-toplevel)"`。
- 本 workspace 只实现方法层,不重复实现 Codex App 原生的 multi-agent、worktrees、diff review、git/PR、background automations、sandbox/approvals、skill loading。
- 会话内流程编排统一叫 `orchestrations`;`automations` 只指 Codex App 原生后台任务。
- 本文件只放硬规则;解释性内容一律放到 `docs/method/`。
Expand Down
58 changes: 29 additions & 29 deletions method-forge/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,15 +71,15 @@ route-request

## 快速使用

1. 从 [orchestrations/route-request/README.md](/Users/wz/project/codex-enhanced-system/method-forge/orchestrations/route-request/README.md) 开始,对请求做 intake 和分流。
2. 当 `need_spec=true` 时,进入 [orchestrations/spec-flow/README.md](/Users/wz/project/codex-enhanced-system/method-forge/orchestrations/spec-flow/README.md)。
3. 以 [docs/templates/](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates) 中的模板产出中间文档。
4. 实现完成后,始终走 [orchestrations/verify-and-memory/README.md](/Users/wz/project/codex-enhanced-system/method-forge/orchestrations/verify-and-memory/README.md)。
1. 从 [orchestrations/route-request/README.md](orchestrations/route-request/README.md) 开始,对请求做 intake 和分流。
2. 当 `need_spec=true` 时,进入 [orchestrations/spec-flow/README.md](orchestrations/spec-flow/README.md)。
3. 以 [docs/templates/](docs/templates) 中的模板产出中间文档。
4. 实现完成后,始终走 [orchestrations/verify-and-memory/README.md](orchestrations/verify-and-memory/README.md)。

如果你不想手动分步骤,可以直接触发入口 skill:

- [method-forge-execute/SKILL.md](/Users/wz/project/codex-enhanced-system/method-forge/skills/method-forge-execute/SKILL.md)
- [method-forge-autonomous-execution/SKILL.md](/Users/wz/project/codex-enhanced-system/method-forge/skills/method-forge-autonomous-execution/SKILL.md)
- [method-forge-execute/SKILL.md](skills/method-forge-execute/SKILL.md)
- [method-forge-autonomous-execution/SKILL.md](skills/method-forge-autonomous-execution/SKILL.md)

一句话用法:

Expand All @@ -89,28 +89,28 @@ route-request

## 核心文档

- 流程说明:[docs/method/workflow.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/workflow.md)
- Skill 契约:[docs/method/skill-contracts.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/skill-contracts.md)
- Orchestration 规则:[docs/method/orchestration-rules.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/orchestration-rules.md)
- Codex 原生边界:[docs/method/codex-native-boundaries.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/codex-native-boundaries.md)
- 单入口执行 skill:[skills/method-forge-execute/SKILL.md](/Users/wz/project/codex-enhanced-system/method-forge/skills/method-forge-execute/SKILL.md)
- autonomous 执行扩展:[docs/method/autonomous-execution.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/autonomous-execution.md)
- 自动激活规则:[docs/method/activation-rules.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/activation-rules.md)
- autonomous 入口 skill:[skills/method-forge-autonomous-execution/SKILL.md](/Users/wz/project/codex-enhanced-system/method-forge/skills/method-forge-autonomous-execution/SKILL.md)
- 恢复规则:[docs/method/resume-rules.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/resume-rules.md)
- 防死循环规则:[docs/method/loop-guard-rules.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/loop-guard-rules.md)
- 运行态模板:[docs/templates/run-state-template.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates/run-state-template.md)
- heartbeat prompt 模板:[docs/templates/autonomous-heartbeat-prompt-template.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates/autonomous-heartbeat-prompt-template.md)
- `v1` 验收报告:[docs/method/v1-acceptance-report.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/v1-acceptance-report.md)
- `v1.5` 补强报告:[docs/method/v1.5-hardening-report.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/v1.5-hardening-report.md)
- 失败回退规则:[docs/method/failure-rework-rules.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/failure-rework-rules.md)
- 模板 lint 规则:[docs/method/template-lint-rules.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/template-lint-rules.md)
- 流程健康检查:[docs/method/workflow-health-check.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/workflow-health-check.md)
- 消费方接入说明:[docs/method/consumer-adoption.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/consumer-adoption.md)
- 消费方 `AGENTS` 草案:[docs/templates/consumer-agents-rules-template.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates/consumer-agents-rules-template.md)
- 健康检查模板:[docs/templates/workflow-health-report-template.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates/workflow-health-report-template.md)
- 健康检查样例:[docs/method/examples/health-check/workflow-health-report.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/examples/health-check/workflow-health-report.md)
- 轻量 preset 入口:[docs/presets/minimal-change-package/README.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/presets/minimal-change-package/README.md)
- 流程说明:[docs/method/workflow.md](docs/method/workflow.md)
- Skill 契约:[docs/method/skill-contracts.md](docs/method/skill-contracts.md)
- Orchestration 规则:[docs/method/orchestration-rules.md](docs/method/orchestration-rules.md)
- Codex 原生边界:[docs/method/codex-native-boundaries.md](docs/method/codex-native-boundaries.md)
- 单入口执行 skill:[skills/method-forge-execute/SKILL.md](skills/method-forge-execute/SKILL.md)
- autonomous 执行扩展:[docs/method/autonomous-execution.md](docs/method/autonomous-execution.md)
- 自动激活规则:[docs/method/activation-rules.md](docs/method/activation-rules.md)
- autonomous 入口 skill:[skills/method-forge-autonomous-execution/SKILL.md](skills/method-forge-autonomous-execution/SKILL.md)
- 恢复规则:[docs/method/resume-rules.md](docs/method/resume-rules.md)
- 防死循环规则:[docs/method/loop-guard-rules.md](docs/method/loop-guard-rules.md)
- 运行态模板:[docs/templates/run-state-template.md](docs/templates/run-state-template.md)
- heartbeat prompt 模板:[docs/templates/autonomous-heartbeat-prompt-template.md](docs/templates/autonomous-heartbeat-prompt-template.md)
- `v1` 验收报告:[docs/method/v1-acceptance-report.md](docs/method/v1-acceptance-report.md)
- `v1.5` 补强报告:[docs/method/v1.5-hardening-report.md](docs/method/v1.5-hardening-report.md)
- 失败回退规则:[docs/method/failure-rework-rules.md](docs/method/failure-rework-rules.md)
- 模板 lint 规则:[docs/method/template-lint-rules.md](docs/method/template-lint-rules.md)
- 流程健康检查:[docs/method/workflow-health-check.md](docs/method/workflow-health-check.md)
- 消费方接入说明:[docs/method/consumer-adoption.md](docs/method/consumer-adoption.md)
- 消费方 `AGENTS` 草案:[docs/templates/consumer-agents-rules-template.md](docs/templates/consumer-agents-rules-template.md)
- 健康检查模板:[docs/templates/workflow-health-report-template.md](docs/templates/workflow-health-report-template.md)
- 健康检查样例:[docs/method/examples/health-check/workflow-health-report.md](docs/method/examples/health-check/workflow-health-report.md)
- 轻量 preset 入口:[docs/presets/minimal-change-package/README.md](docs/presets/minimal-change-package/README.md)

## 当前版本

Expand Down Expand Up @@ -142,7 +142,7 @@ route-request
如果你希望在每个 worker 里支持显式 autonomous 请求或恢复既有 autonomous run,还需要:

- 让入口 skill 全局可见
- 采用 [activation-rules.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/activation-rules.md) 中的触发规则
- 采用 [activation-rules.md](docs/method/activation-rules.md) 中的触发规则

当前也已经补上一个消费方可直接复用的轻量落地包:

Expand Down
6 changes: 3 additions & 3 deletions method-forge/docs/method/activation-rules.md
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,6 @@ autonomous mode 的监听者使用 Codex 原生 heartbeat automation,内层默

## 8. 配套文件

- autonomous 扩展:[docs/method/autonomous-execution.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/autonomous-execution.md)
- autonomous 入口 skill:[skills/method-forge-autonomous-execution/SKILL.md](/Users/wz/project/codex-enhanced-system/method-forge/skills/method-forge-autonomous-execution/SKILL.md)
- 消费方 `AGENTS` 草案:[docs/templates/consumer-agents-rules-template.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates/consumer-agents-rules-template.md)
- autonomous 扩展:[docs/method/autonomous-execution.md](autonomous-execution.md)
- autonomous 入口 skill:[skills/method-forge-autonomous-execution/SKILL.md](../../skills/method-forge-autonomous-execution/SKILL.md)
- 消费方 `AGENTS` 草案:[docs/templates/consumer-agents-rules-template.md](../templates/consumer-agents-rules-template.md)
10 changes: 5 additions & 5 deletions method-forge/docs/method/autonomous-execution.md
Original file line number Diff line number Diff line change
Expand Up @@ -137,8 +137,8 @@ autonomous 周期恢复时应按以下顺序读取:

## 10. 配套文件

- 恢复规则:[docs/method/resume-rules.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/resume-rules.md)
- 防死循环规则:[docs/method/loop-guard-rules.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/loop-guard-rules.md)
- 运行态模板:[docs/templates/run-state-template.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates/run-state-template.md)
- 周期报告模板:[docs/templates/autonomous-cycle-report-template.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates/autonomous-cycle-report-template.md)
- heartbeat prompt 草案:[docs/templates/autonomous-heartbeat-prompt-template.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates/autonomous-heartbeat-prompt-template.md)
- 恢复规则:[docs/method/resume-rules.md](resume-rules.md)
- 防死循环规则:[docs/method/loop-guard-rules.md](loop-guard-rules.md)
- 运行态模板:[docs/templates/run-state-template.md](../templates/run-state-template.md)
- 周期报告模板:[docs/templates/autonomous-cycle-report-template.md](../templates/autonomous-cycle-report-template.md)
- heartbeat prompt 草案:[docs/templates/autonomous-heartbeat-prompt-template.md](../templates/autonomous-heartbeat-prompt-template.md)
18 changes: 9 additions & 9 deletions method-forge/docs/method/consumer-adoption.md
Original file line number Diff line number Diff line change
Expand Up @@ -109,15 +109,15 @@

当前已提供以下配套:

- 接入说明:[docs/method/consumer-adoption.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/consumer-adoption.md)
- autonomous 扩展说明:[docs/method/autonomous-execution.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/autonomous-execution.md)
- 自动激活规则:[docs/method/activation-rules.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/activation-rules.md)
- autonomous 入口 skill:[skills/method-forge-autonomous-execution/SKILL.md](/Users/wz/project/codex-enhanced-system/method-forge/skills/method-forge-autonomous-execution/SKILL.md)
- 单入口 skill:[skills/method-forge-execute/SKILL.md](/Users/wz/project/codex-enhanced-system/method-forge/skills/method-forge-execute/SKILL.md)
- preset 入口:[docs/presets/minimal-change-package/README.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/presets/minimal-change-package/README.md)
- `AGENTS.md` 硬规则草案:[docs/templates/consumer-agents-rules-template.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates/consumer-agents-rules-template.md)
- 变更包索引模板:[docs/templates/package-index-template.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates/package-index-template.md)
- 落地检查清单模板:[docs/templates/adoption-checklist-template.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates/adoption-checklist-template.md)
- 接入说明:[docs/method/consumer-adoption.md](consumer-adoption.md)
- autonomous 扩展说明:[docs/method/autonomous-execution.md](autonomous-execution.md)
- 自动激活规则:[docs/method/activation-rules.md](activation-rules.md)
- autonomous 入口 skill:[skills/method-forge-autonomous-execution/SKILL.md](../../skills/method-forge-autonomous-execution/SKILL.md)
- 单入口 skill:[skills/method-forge-execute/SKILL.md](../../skills/method-forge-execute/SKILL.md)
- preset 入口:[docs/presets/minimal-change-package/README.md](../presets/minimal-change-package/README.md)
- `AGENTS.md` 硬规则草案:[docs/templates/consumer-agents-rules-template.md](../templates/consumer-agents-rules-template.md)
- 变更包索引模板:[docs/templates/package-index-template.md](../templates/package-index-template.md)
- 落地检查清单模板:[docs/templates/adoption-checklist-template.md](../templates/adoption-checklist-template.md)

## 8. 当前边界

Expand Down
2 changes: 1 addition & 1 deletion method-forge/docs/method/skill-contracts.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

- 输入尽量来自已存在的请求、仓库上下文和上一步文档
- 输出以单一主文档为准,不把真相源散落在聊天文本里
- 默认使用 [docs/templates/](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates) 中的模板
- 默认使用 [docs/templates/](../templates) 中的模板
- 不直接写长期 memory
- 不改造 knowledge base 本体
- 不包装 Codex 原生工程能力
Expand Down
4 changes: 2 additions & 2 deletions method-forge/docs/method/workflow-health-check.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,5 +73,5 @@ workflow health check 用于判断一套 `method-forge` 流程是否还在健康

当前已提供:

- 模板:[docs/templates/workflow-health-report-template.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/templates/workflow-health-report-template.md)
- 样例:[docs/method/examples/health-check/workflow-health-report.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/examples/health-check/workflow-health-report.md)
- 模板:[docs/templates/workflow-health-report-template.md](../templates/workflow-health-report-template.md)
- 样例:[docs/method/examples/health-check/workflow-health-report.md](examples/health-check/workflow-health-report.md)
4 changes: 2 additions & 2 deletions method-forge/docs/method/workflow.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ docs/specs/<change-id>/

如果要把这套方法层接到别的 workspace,上述目录约定的轻量落地方式见:

- [docs/method/consumer-adoption.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/method/consumer-adoption.md)
- [docs/presets/minimal-change-package/README.md](/Users/wz/project/codex-enhanced-system/method-forge/docs/presets/minimal-change-package/README.md)
- [docs/method/consumer-adoption.md](consumer-adoption.md)
- [docs/presets/minimal-change-package/README.md](../presets/minimal-change-package/README.md)

## 3. 主流程

Expand Down
Loading