helloloop 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,11 +1,11 @@
1
1
  {
2
2
  "name": "helloloop",
3
- "version": "0.1.1",
4
- "description": "Backlog-driven continuous repository execution for Codex with verification loops and explicit skill and CLI entrypoints.",
3
+ "version": "0.1.2",
4
+ "description": "面向 Codex backlog 驱动持续开发插件,支持进度分析、验证循环与显式 skill / CLI 入口。",
5
5
  "author": {
6
6
  "name": "HelloLoop"
7
7
  },
8
- "license": "MIT",
8
+ "license": "Apache-2.0",
9
9
  "keywords": [
10
10
  "codex",
11
11
  "helloloop",
@@ -16,8 +16,8 @@
16
16
  "skills": "./skills/",
17
17
  "interface": {
18
18
  "displayName": "HelloLoop",
19
- "shortDescription": "Continuous repo execution with backlog and Ralph Loop guards",
20
- "longDescription": "HelloLoop packages backlog-driven continuous development for Codex as an official plugin bundle with explicit skill and CLI entrypoints.",
19
+ "shortDescription": "基于 backlog 的持续仓库开发与验证循环",
20
+ "longDescription": "HelloLoop 把基于 backlog 的持续开发能力封装为官方 Codex 插件 bundle,支持自动分析进度、生成后续任务,并通过显式 skill / CLI 入口接续推进。",
21
21
  "developerName": "HelloLoop",
22
22
  "category": "Coding",
23
23
  "capabilities": [
@@ -25,7 +25,7 @@
25
25
  "Write"
26
26
  ],
27
27
  "defaultPrompt": [
28
- "Use HelloLoop to inspect backlog state and keep this repo moving with explicit run-loop commands."
28
+ "使用 HelloLoop 分析当前 backlog 与开发进度,并通过显式命令持续推进这个仓库。"
29
29
  ],
30
30
  "brandColor": "#0F766E"
31
31
  }
package/LICENSE ADDED
@@ -0,0 +1,176 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ https://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
package/README.md CHANGED
@@ -1,70 +1,57 @@
1
1
  # HelloLoop
2
2
 
3
- `HelloLoop` 是一个面向 Codex 的独立插件,用来把“按 backlog 持续推进仓库开发”这件事标准化、可追踪、可验证地跑起来。
3
+ `HelloLoop` 是一个面向 Codex 的独立插件,用来把“根据开发文档接续推进仓库开发”这件事标准化、可追踪、可验证地跑起来。
4
4
 
5
- 它不只是在单轮对话里改一段代码,而是把任务队列、必读文档、执行约束、验证命令和运行记录统一放进目标仓库的 `.helloloop/` 目录,让 Codex 可以按明确流程持续接续开发。
5
+ 它会先分析当前仓库真实代码与开发文档之间的差距,再把后续任务、运行状态、执行记录统一写入目标仓库根目录的 `.helloloop/`,让 Codex 能持续接着做,而不是每轮都重新交代背景。
6
6
 
7
7
  命令入口按 `Node.js 20+` 设计,支持 Windows、macOS 和 Linux。
8
8
 
9
9
  ## 目录
10
10
 
11
- - [HelloLoop 是什么](#helloloop-是什么)
12
- - [核心能力](#核心能力)
13
- - [适用场景](#适用场景)
11
+ - [核心定位](#核心定位)
14
12
  - [安装](#安装)
15
13
  - [快速开始](#快速开始)
14
+ - [路径规则](#路径规则)
15
+ - [安全底线](#安全底线)
16
16
  - [命令速查](#命令速查)
17
17
  - [状态目录](#状态目录)
18
- - [工作机制](#工作机制)
18
+ - [在 Codex 中使用](#在-codex-中使用)
19
+ - [许可证](#许可证)
19
20
  - [仓库结构](#仓库结构)
20
21
  - [相关文档](#相关文档)
21
22
 
22
- ## HelloLoop 是什么
23
+ ## 核心定位
23
24
 
24
- `HelloLoop` 解决的是以下问题:
25
+ `HelloLoop` 适合这样的场景:
25
26
 
26
- - 你的仓库里已经有开发文档、任务拆解或 backlog
27
- - 你希望 Codex 能按顺序接着做,而不是每次都从头解释背景
28
- - 你希望每一轮执行前都自动带上项目状态、必读文档和实现约束
29
- - 你希望每次运行后都留下状态记录、验证结果和运行痕迹
27
+ - 仓库里已经有 `docs/`、方案包、任务文档或阶段说明
28
+ - 代码已经做了一部分,需要先判断“现在做到哪里了”
29
+ - 你希望自动生成足够细的后续 backlog,而不是得到一句“继续开发”
30
+ - 你希望后续每轮执行都带着状态、约束、文档和验证命令继续推进
31
+ - 你希望在开发文档约束不完整时,仍然有一层稳定、安全的执行底线
30
32
 
31
- 围绕这个目标,`HelloLoop` 提供了一套明确的仓库内执行模型:
33
+ 围绕这个目标,`HelloLoop` 做四件事:
32
34
 
33
- 1. 从 backlog 中选择当前可执行任务
34
- 2. 汇总项目上下文、任务目标和约束
35
- 3. 生成面向 Codex 的执行提示
36
- 4. 调用 Codex 完成实现
37
- 5. 执行验证命令
38
- 6. 回写状态、日志和运行记录
35
+ 1. 自动发现项目仓库与开发文档
36
+ 2. 对比当前代码和文档目标,判断真实进度
37
+ 3. 生成或刷新 `.helloloop/backlog.json`
38
+ 4. 驱动 Codex 按 backlog 接续执行并留下运行记录
39
39
 
40
- ## 核心能力
40
+ 同时,`HelloLoop` 自带一层内建安全底线:
41
41
 
42
- - **插件安装**:安装到 Codex Home,作为独立插件使用
43
- - **仓库初始化**:在目标仓库生成 `.helloloop/` 状态目录
44
- - **任务调度**:基于优先级、依赖、风险等级挑选下一任务
45
- - **干跑预览**:先看下一任务、提示词和验证命令,再决定是否执行
46
- - **单轮执行**:执行一个任务并回写结果
47
- - **循环执行**:连续执行多个任务,直到完成、阻塞或达到上限
48
- - **验证联动**:优先使用任务级验证命令,缺省时读取仓库验证配置
49
- - **运行留痕**:把提示词、stdout、stderr、验证输出沉淀到 `runs/`
50
-
51
- ## 适用场景
52
-
53
- - 你有一套开发文档,希望 Codex 接续完成后续开发
54
- - 你有清晰 backlog,希望 AI 按队列逐项推进
55
- - 你希望把“任务、约束、验证、结果”都放在仓库里长期维护
56
- - 你希望执行失败后不是停住,而是能按既定策略继续推进
57
- - 你希望多人协作时,每个人都能快速看懂当前任务状态
42
+ - 开发文档缺少必要约束时,自动补上默认工程约束
43
+ - Windows 端优先使用 `pwsh`,也支持 `bash`(如 Git Bash)和 `powershell`,但不回退到 `cmd`
44
+ - 所有流程都要求避免静默失败、危险命令和隐私信息泄露
58
45
 
59
46
  ## 安装
60
47
 
61
- ### 通过 npm / npx 安装
48
+ ### npm / npx
62
49
 
63
50
  ```powershell
64
51
  npx helloloop install --codex-home <CODEX_HOME>
65
52
  ```
66
53
 
67
- ### 从源码仓库安装
54
+ ### 源码仓库
68
55
 
69
56
  ```powershell
70
57
  node ./scripts/helloloop.mjs install --codex-home <CODEX_HOME>
@@ -76,17 +63,7 @@ node ./scripts/helloloop.mjs install --codex-home <CODEX_HOME>
76
63
  pwsh -NoLogo -NoProfile -File .\scripts\install-home-plugin.ps1 -CodexHome <CODEX_HOME>
77
64
  ```
78
65
 
79
- 安装完成后,插件会被放到:
80
-
81
- ```text
82
- <CODEX_HOME>\plugins\helloloop
83
- ```
84
-
85
- 同时会更新:
86
-
87
- ```text
88
- <CODEX_HOME>\.agents\plugins\marketplace.json
89
- ```
66
+ 安装完成后,插件会复制到 `<CODEX_HOME>/plugins/helloloop`,并更新 `<CODEX_HOME>/.agents/plugins/marketplace.json`。
90
67
 
91
68
  ## 快速开始
92
69
 
@@ -96,68 +73,106 @@ pwsh -NoLogo -NoProfile -File .\scripts\install-home-plugin.ps1 -CodexHome <CODE
96
73
  npx helloloop install --codex-home <CODEX_HOME>
97
74
  ```
98
75
 
99
- 之后的日常命令推荐直接使用:
76
+ ### 2. 进入目标项目或开发文档目录
77
+
78
+ 最短命令就是:
100
79
 
101
80
  ```powershell
102
- npx helloloop <command> [options]
81
+ npx helloloop
103
82
  ```
104
83
 
105
- 如果你已经全局安装过:
84
+ 默认规则如下:
85
+
86
+ - 当前目录是项目仓库根目录时:自动查找开发文档并分析当前进度
87
+ - 当前目录本身是开发文档目录时:优先尝试反推目标仓库
88
+ - 分析完成后:自动生成或刷新目标仓库根目录下的 `.helloloop/`
89
+
90
+ 如果你只知道一个路径,也可以只传一个位置:
106
91
 
107
92
  ```powershell
108
- helloloop <command> [options]
93
+ npx helloloop <PATH>
109
94
  ```
110
95
 
111
- Codex 当前会话里,也可以直接运行同样的 `npx helloloop ...` 命令,不需要重开终端。
96
+ 这里的 `<PATH>` 只能传一个,可以是:
97
+
98
+ - 项目仓库路径
99
+ - 开发文档目录
100
+ - 开发文档文件
112
101
 
113
- ### 2. 在目标仓库初始化 `.helloloop/`
102
+ ### 3. 查看下一任务
114
103
 
115
104
  ```powershell
116
- npx helloloop init --repo <REPO_ROOT>
105
+ npx helloloop next
117
106
  ```
118
107
 
119
- 初始化完成后,模板会落在目标仓库根目录下的 `.helloloop/`,而不是插件目录本身。
120
-
121
- ### 3. 检查运行条件
108
+ ### 4. 执行一次或连续执行
122
109
 
123
110
  ```powershell
124
- npx helloloop doctor --repo <REPO_ROOT>
111
+ npx helloloop run-once
112
+ npx helloloop run-loop --max-tasks 2
125
113
  ```
126
114
 
127
- ### 4. 查看状态与下一任务
115
+ 如果你已经做了全局安装,也可以把 `npx helloloop` 简写成 `helloloop`。
116
+
117
+ ## 路径规则
118
+
119
+ - 不传路径:默认分析当前目录
120
+ - 只传一个路径:自动判断它是仓库路径还是开发文档路径
121
+ - 已给开发文档但无法确定仓库:停止并提示补充 `--repo`
122
+ - 已给仓库但找不到开发文档:停止并提示补充 `--docs`
123
+ - `--repo` 和 `--docs` 是高级覆盖选项,不是主工作流
124
+
125
+ 推荐优先使用:
128
126
 
129
127
  ```powershell
130
- npx helloloop status --repo <REPO_ROOT>
131
- npx helloloop next --repo <REPO_ROOT>
128
+ npx helloloop
129
+ npx helloloop <PATH>
132
130
  ```
133
131
 
134
- ### 5. 执行一个任务或连续执行
132
+ 只有在自动发现无法收敛时,再显式补充:
135
133
 
136
134
  ```powershell
137
- npx helloloop run-once --repo <REPO_ROOT>
138
- npx helloloop run-loop --repo <REPO_ROOT> --max-tasks 2
135
+ npx helloloop --repo <REPO_ROOT> --docs <DOCS_PATH>
139
136
  ```
140
137
 
138
+ ## 安全底线
139
+
140
+ - `HelloLoop` 会始终附加一组内建安全底线,覆盖 shell 安全、EHRB 命令阻断、跨平台兼容和静默失败防护。
141
+ - 如果项目开发文档或 `.helloloop/project.json` 已有明确约束,则优先使用项目约束;内建安全底线继续作为最低边界。
142
+ - 如果项目没有给出必要约束,则自动启用默认工程约束,例如代码是事实源、体积控制、验证必须执行、阻塞必须明确说明。
143
+ - Windows 环境下,`HelloLoop` 优先使用 `pwsh`,也支持 `bash`(如 Git Bash)和 `powershell`;如果这些安全 shell 都不可用,会直接停止,而不是回退到 `cmd.exe`。
144
+ - macOS / Linux 环境下,`HelloLoop` 优先使用 `bash`,没有 `bash` 时再回退到 `sh`。
145
+
141
146
  ## 命令速查
142
147
 
143
148
  | 命令 | 作用 |
144
149
  | --- | --- |
145
- | `install` | 安装插件到 Codex Home,并更新插件 marketplace |
146
- | `init` | 初始化目标仓库的 `.helloloop/` |
147
- | `doctor` | 检查 Codex、插件文件和目标仓库配置是否齐备 |
148
- | `status` | 查看 backlog 汇总、当前状态和下一任务 |
149
- | `next` | 生成下一任务预览,不真正调用 Codex |
150
+ | `analyze` | 自动发现仓库与开发文档,分析进度并刷新 `.helloloop/` |
151
+ | `next` | 预览下一任务,不真正执行 |
150
152
  | `run-once` | 执行一个任务 |
151
153
  | `run-loop` | 连续执行多个任务 |
154
+ | `status` | 查看 backlog 汇总与当前状态 |
155
+ | `doctor` | 检查 Codex、插件 bundle 与目标仓库是否满足运行条件 |
156
+ | `init` | 手动初始化 `.helloloop/` 模板 |
157
+ | `install` | 安装插件到 Codex Home |
158
+
159
+ 除 `install` 外,其余命令都可以直接在目标仓库目录执行;如果不在目标仓库目录,也可以补一个路径:
160
+
161
+ ```powershell
162
+ npx helloloop next <PATH>
163
+ npx helloloop run-once <PATH>
164
+ npx helloloop status <PATH>
165
+ ```
152
166
 
153
167
  ### 常用选项
154
168
 
155
169
  | 选项 | 说明 |
156
170
  | --- | --- |
157
- | `--repo <dir>` | 目标仓库根目录,默认当前目录 |
171
+ | `--repo <dir>` | 高级选项:显式指定项目仓库根目录 |
172
+ | `--docs <dir\|file>` | 高级选项:显式指定开发文档目录或文件 |
158
173
  | `--codex-home <dir>` | 指定 Codex Home |
159
174
  | `--config-dir <dir>` | 指定状态目录名,默认 `.helloloop` |
160
- | `--dry-run` | 只生成提示词和预览,不真正调用 Codex |
175
+ | `--dry-run` | 只生成提示和预览,不真正调用 Codex |
161
176
  | `--task-id <id>` | 指定执行某个任务 |
162
177
  | `--max-tasks <n>` | `run-loop` 最多执行的任务数 |
163
178
  | `--max-attempts <n>` | 每种策略的最大重试次数 |
@@ -177,7 +192,7 @@ helloloop:helloloop
177
192
 
178
193
  ## 状态目录
179
194
 
180
- `HelloLoop` 默认在目标仓库根目录创建 `.helloloop/`,用来保存 backlog、策略配置、运行状态和执行留痕。
195
+ `HelloLoop` 默认在目标仓库根目录创建 `.helloloop/`,而不是写回插件目录自身。
181
196
 
182
197
  典型结构如下:
183
198
 
@@ -191,50 +206,26 @@ helloloop:helloloop
191
206
  └── runs/
192
207
  ```
193
208
 
194
- 各文件作用如下:
209
+ 各文件职责如下:
195
210
 
196
- - `backlog.json`:任务列表、优先级、风险、依赖、验收条件
197
- - `policy.json`:循环上限、重试策略、Codex 执行参数
198
- - `project.json`:全局必读文档、实现约束、任务规划提示
211
+ - `backlog.json`:接续开发任务列表
212
+ - `policy.json`:循环上限、重试策略和 Codex 参数
213
+ - `project.json`:开发文档入口和全局约束
199
214
  - `status.json`:最近一次运行的机器可读状态
200
215
  - `STATE.md`:面向人的当前进展摘要
201
- - `runs/`:每次执行的提示词、日志和验证输出
202
-
203
- ## 工作机制
204
-
205
- ### 任务模型
206
-
207
- `backlog.json` 中的任务通常包含以下字段:
208
-
209
- - `id`:任务唯一标识
210
- - `title`:任务标题
211
- - `status`:`pending`、`in_progress`、`done`、`failed`、`blocked`
212
- - `priority`:`P0` 到 `P3`
213
- - `risk`:`low`、`medium`、`high`、`critical`
214
- - `goal`:本任务要达成的目标
215
- - `docs`:执行前必须阅读的文档
216
- - `paths`:本任务主要涉及的目录
217
- - `acceptance`:验收条件
218
- - `dependsOn`:依赖的上游任务
219
- - `verify`:任务专属验证命令
216
+ - `runs/`:提示词、stdout、stderr、验证输出等运行留痕
220
217
 
221
- ### 执行流程
218
+ ## 在 Codex 中使用
222
219
 
223
- `HelloLoop` 在每一轮执行中会完成这些事情:
220
+ 可以。
224
221
 
225
- 1. 找出当前可执行任务
226
- 2. 读取仓库状态、任务描述和必读文档
227
- 3. 生成清晰的 Codex 执行提示
228
- 4. 运行 Codex 完成开发
229
- 5. 执行验证命令
230
- 6. 更新任务状态和运行记录
222
+ - 在当前 Codex 会话里,直接运行 `npx helloloop ...` 即可,不需要重开终端
223
+ - 如果你使用的是全局安装后的 `helloloop` 短命令,是否需要新终端取决于你的 shell 是否已经刷新 PATH
224
+ - `HelloLoop` 负责组织分析、backlog 和执行流程,真正的代码分析与开发仍然通过本机 `codex` CLI 完成
231
225
 
232
- ### 风险控制
226
+ ## 许可证
233
227
 
234
- - 默认优先自动执行 `low` 风险任务
235
- - 较高风险任务需要显式允许
236
- - 存在未完成依赖时,任务不会被挑选执行
237
- - 存在未收束的执行状态时,循环会停止并等待处理
228
+ `HelloLoop` 使用 `Apache-2.0` 许可证,许可证文件位于仓库根目录 `LICENSE`。
238
229
 
239
230
  ## 仓库结构
240
231
 
@@ -252,12 +243,12 @@ helloloop/
252
243
 
253
244
  其中:
254
245
 
255
- - `src/` 用来放 `HelloLoop` 的实际实现逻辑,例如任务选择、状态加载、执行流程、提示词生成和安装流程
256
- - `tests/` 用来做回归验证,确保 CLI、模板、插件 bundle 和执行流程没有被改坏
246
+ - `src/` `HelloLoop` 的实际实现逻辑,例如路径发现、分析提示词生成、运行调度和安装流程
247
+ - `tests/` 放回归测试,确保 CLI、安装链路、bundle 结构和分析流程没有被改坏
257
248
  - `templates/` 是初始化目标仓库时写入 `.helloloop/` 的模板来源
258
249
 
259
250
  ## 相关文档
260
251
 
261
- - `docs/README.md`:插件 bundle 结构补充说明
262
- - `docs/install.md`:安装说明
263
- - `docs/plugin-standard.md`:官方插件结构与标准对照
252
+ - `docs/install.md`:安装与日常使用方式
253
+ - `docs/README.md`:插件 bundle 结构说明
254
+ - `docs/plugin-standard.md`:官方插件结构与当前实现映射
package/package.json CHANGED
@@ -1,7 +1,10 @@
1
1
  {
2
2
  "name": "helloloop",
3
- "version": "0.1.1",
4
- "description": "Standalone Codex plugin bundle for backlog-driven repository execution with Ralph Loop guards",
3
+ "version": "0.1.2",
4
+ "description": "面向 Codex 的独立插件 bundle,用于基于 backlog 持续推进仓库开发并执行验证循环",
5
+ "author": "HelloWind",
6
+ "license": "Apache-2.0",
7
+ "homepage": "https://github.com/hellowind777/helloloop",
5
8
  "type": "module",
6
9
  "repository": {
7
10
  "type": "git",
@@ -15,6 +18,7 @@
15
18
  },
16
19
  "files": [
17
20
  ".codex-plugin",
21
+ "LICENSE",
18
22
  "README.md",
19
23
  "bin",
20
24
  "package.json",
@@ -24,7 +28,7 @@
24
28
  "templates"
25
29
  ],
26
30
  "scripts": {
27
- "test": "node --test tests/cli_surface.test.mjs tests/install_script.test.mjs tests/process_shell.test.mjs tests/ralph_loop.test.mjs tests/plugin_bundle.test.mjs"
31
+ "test": "node --test tests/analyze_cli.test.mjs tests/cli_surface.test.mjs tests/install_script.test.mjs tests/process_shell.test.mjs tests/prompt_guardrails.test.mjs tests/ralph_loop.test.mjs tests/plugin_bundle.test.mjs"
28
32
  },
29
33
  "engines": {
30
34
  "node": ">=20"
@@ -1,51 +1,55 @@
1
1
  ---
2
2
  name: helloloop
3
- description: Use when the user wants Codex to keep shipping repo work across turns, bootstrap HelloLoop, or inspect backlog-driven execution state through the pure official plugin bundle.
3
+ description: 当用户希望 Codex 先分析仓库当前进度,再生成 backlog 并按队列持续接续开发时使用。
4
4
  ---
5
5
 
6
6
  # HelloLoop
7
7
 
8
- Use this plugin when the task is continuous repository execution rather than a single chat-turn change.
8
+ 当任务目标不是单轮对话里改一点代码,而是要基于开发文档持续推进整个仓库时,使用这个插件。
9
9
 
10
- ## Official Plugin Boundary
10
+ ## 插件边界
11
11
 
12
- - This bundle root is the official plugin surface for HelloLoop.
13
- - It ships standard Codex plugin metadata through `.codex-plugin/plugin.json` and a plugin skill through `skills/`.
14
- - This plugin is designed around explicit skill and CLI entrypoints.
12
+ - 当前 bundle 根目录就是 `HelloLoop` 的官方插件目录。
13
+ - 插件元数据位于 `.codex-plugin/plugin.json`,执行逻辑位于 `skills/`、`bin/`、`scripts/`、`src/`、`templates/`。
14
+ - 运行状态统一写入目标仓库根目录下的 `.helloloop/`。
15
15
 
16
- ## Setup
16
+ ## 使用前准备
17
17
 
18
- 1. Install with `npx helloloop install --codex-home <CODEX_HOME>` or use `scripts/install-home-plugin.ps1`.
19
- 2. From the target repository, run `npx helloloop doctor --repo <repo-root>`.
20
- 3. From the target repository, run `npx helloloop init --repo <repo-root>`.
18
+ 1. 先通过 `npx helloloop install --codex-home <CODEX_HOME>` `scripts/install-home-plugin.ps1` 安装插件。
19
+ 2. 打开目标项目仓库目录,或者打开开发文档所在目录。
20
+ 3. 运行 `npx helloloop` `npx helloloop <path>`。
21
+ 4. 如果无法自动判断仓库路径或开发文档路径,就停下来提示用户补充;`--repo` 和 `--docs` 只作为显式覆盖选项使用。
21
22
 
22
- ## Operating Model
23
+ ## 工作模式
23
24
 
24
- - `.helloloop/` is the default CLI and backlog state directory.
25
- - The installed plugin bundle keeps runtime files such as `src/`, `templates/`, `bin/`, `scripts/`, and `skills/`.
26
- - Source-only materials such as `docs/` and `tests/` stay in the development repository.
25
+ - 代码是事实源,开发文档是目标源。
26
+ - `HelloLoop` 会先分析当前真实进度,再生成或刷新 `.helloloop/backlog.json`。
27
+ - 后续开发通过 `next`、`run-once`、`run-loop` backlog 接续推进。
28
+ - 真正的代码分析与实现仍由本机 `codex` CLI 完成。
27
29
 
28
- ## Invocation
30
+ ## 核心命令
29
31
 
30
- - In official Codex plugin mode, plugin skills are namespaced with `plugin_name:`.
31
- - For this plugin, the unambiguous skill name is `helloloop:helloloop`.
32
- - Explicitly naming the `helloloop` plugin should also bias Codex toward this skill.
33
- - Do not promise bare `$helloloop` is the official invocation form.
32
+ - `npx helloloop`
33
+ - `npx helloloop <path>`
34
+ - `npx helloloop next`
35
+ - `npx helloloop run-once`
36
+ - `npx helloloop run-loop --max-tasks <n>`
34
37
 
35
- ## Primary Commands
38
+ ## 高级命令
36
39
 
37
- - `npx helloloop status --repo <repo-root>`
38
- - `npx helloloop next --repo <repo-root>`
39
- - `npx helloloop run-once --repo <repo-root>`
40
- - `npx helloloop run-loop --repo <repo-root>`
40
+ - `npx helloloop status`
41
+ - `npx helloloop doctor`
42
+ - `npx helloloop init`
43
+ - `npx helloloop --repo <repo-root> --docs <docs-path>`
41
44
 
42
- ## Reporting Rules
45
+ ## 调用方式
43
46
 
44
- - State explicitly that the plugin runs in pure official plugin mode.
45
- - Keep Ralph Loop guardrails and repo verification intact.
47
+ - 在官方 Codex 插件模式下,明确的 skill 名称是 `helloloop:helloloop`。
48
+ - 在对话里显式提到 `helloloop` 插件,也会帮助 Codex 更准确地命中这个 skill。
46
49
 
47
- ## Docs
50
+ ## 参考文档
48
51
 
49
- - Source repo main guide: `docs/README.md`
50
- - Source repo installation note: `docs/install.md`
51
- - Source repo official standard and runtime boundary: `docs/plugin-standard.md`
52
+ - 主说明:`README.md`
53
+ - 安装说明:`docs/install.md`
54
+ - Bundle 说明:`docs/README.md`
55
+ - 插件标准映射:`docs/plugin-standard.md`