superlab 0.1.1 → 0.1.3

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.
Files changed (34) hide show
  1. package/README.md +21 -18
  2. package/README.zh-CN.md +20 -16
  3. package/lib/i18n.cjs +594 -7
  4. package/lib/install.cjs +31 -0
  5. package/package-assets/claude/commands/lab/spec.md +1 -1
  6. package/package-assets/codex/prompts/lab-spec.md +1 -1
  7. package/package-assets/shared/changes/README.md +10 -0
  8. package/package-assets/shared/config/workflow.json +5 -0
  9. package/package-assets/shared/context/decisions.md +11 -0
  10. package/package-assets/shared/context/evidence-index.md +16 -0
  11. package/package-assets/shared/context/mission.md +27 -0
  12. package/package-assets/shared/context/open-questions.md +11 -0
  13. package/package-assets/shared/context/state.md +19 -0
  14. package/package-assets/shared/examples/minimal-uplift-workflow.md +4 -4
  15. package/package-assets/shared/skills/lab/SKILL.md +37 -10
  16. package/package-assets/shared/skills/lab/references/brainstorming-integration.md +21 -0
  17. package/package-assets/shared/skills/lab/references/workflow.md +1 -1
  18. package/package-assets/shared/skills/lab/stages/idea.md +13 -0
  19. package/package-assets/shared/skills/lab/stages/iterate.md +21 -0
  20. package/package-assets/shared/skills/lab/stages/report.md +19 -0
  21. package/package-assets/shared/skills/lab/stages/review.md +30 -0
  22. package/package-assets/shared/skills/lab/stages/run.md +17 -0
  23. package/package-assets/shared/skills/lab/stages/spec.md +36 -17
  24. package/package-assets/shared/skills/lab/stages/write.md +27 -3
  25. package/package-assets/shared/templates/design.md +5 -5
  26. package/package-assets/shared/templates/paper-section.tex +10 -0
  27. package/package-assets/shared/templates/paper.tex +29 -0
  28. package/package-assets/shared/templates/proposal.md +4 -4
  29. package/package-assets/shared/templates/review-checklist.md +23 -0
  30. package/package-assets/shared/templates/spec.md +4 -6
  31. package/package-assets/shared/templates/tasks.md +3 -5
  32. package/package.json +3 -3
  33. package/package-assets/shared/scripts/check_openspec.sh +0 -10
  34. package/package-assets/shared/scripts/openspec_change.sh +0 -50
package/README.md CHANGED
@@ -8,7 +8,7 @@ It combines:
8
8
 
9
9
  - command adapters for Codex and Claude
10
10
  - a shared `/lab` skill with stage-specific rules
11
- - OpenSpec-compatible `spec-driven` artifacts
11
+ - lab-native change artifacts under `.superlab/changes/`
12
12
  - bounded Ralph Wiggum style iteration for experiments
13
13
  - helper scripts for run registration and evaluation summaries
14
14
 
@@ -45,6 +45,8 @@ This writes:
45
45
  - `.codex/skills/lab/`
46
46
  - `.claude/commands/lab/*.md`
47
47
  - `.claude/skills/lab/`
48
+ - `.superlab/config/workflow.json`
49
+ - `.superlab/changes/`
48
50
  - `.superlab/templates/`
49
51
  - `.superlab/scripts/`
50
52
  - `.superlab/examples/`
@@ -77,27 +79,26 @@ superlab init --lang zh
77
79
  superlab init --lang en
78
80
  ```
79
81
 
80
- This language setting only affects installed command and skill text shown to the user. It does not control experiment outputs, reports, or the final paper language.
82
+ This installer also writes `.superlab/config/workflow.json`, which is the global contract for:
83
+
84
+ - `workflow_language`
85
+ - `paper_language`
86
+ - `paper_format`
87
+
88
+ Stages should follow that file rather than guess language locally.
81
89
 
82
90
  ## Requirements
83
91
 
84
92
  - Node.js 18+
85
93
  - Python 3.10+
86
94
  - Git
87
- - OpenSpec CLI installed and available as `openspec-cn`
88
-
89
- Check the dependency with:
90
-
91
- ```bash
92
- bash .superlab/scripts/check_openspec.sh
93
- ```
94
95
 
95
96
  `/lab:write` ships with vendored paper-writing references under the installed `lab` skill, so it does not depend on an extra runtime skill installation.
96
97
 
97
98
  ## Command Set
98
99
 
99
100
  - `/lab:idea` researches an idea, critiques it, and writes the initial research framing.
100
- - `/lab:spec` converts the approved idea into OpenSpec `proposal`, `design`, `spec`, and `tasks` artifacts.
101
+ - `/lab:spec` converts the approved idea into one `.superlab/changes/<change-id>/` directory.
101
102
  - `/lab:run` executes a small-scale validation run and establishes the evaluation pipeline.
102
103
  - `/lab:iterate` runs bounded experiment loops with fixed mission, explicit thresholds, and per-round reports.
103
104
  - `/lab:review` audits documents and results in reviewer mode.
@@ -121,23 +122,25 @@ See the source command docs in [commands/codex/lab.md](/Users/zhouhao119/coding/
121
122
  ## Typical Flow
122
123
 
123
124
  1. Run `/lab:idea` to produce the initial idea artifact.
124
- 2. Run `/lab:spec` to convert the idea into OpenSpec `spec-driven` artifacts.
125
+ 2. Run `/lab:spec` to convert the idea into one self-contained lab change directory.
125
126
  3. Run `/lab:run` to verify the experiment path and register the first run.
126
127
  4. Run `/lab:iterate` to improve against fixed targets using bounded iterations.
127
128
  5. Run `/lab:review` whenever you need reviewer-grade critique.
128
129
  6. Run `/lab:report` to synthesize the final report.
129
130
  7. Run `/lab:write` to draft paper sections from stable report evidence.
130
131
 
131
- `/lab:write` typically writes:
132
+ `/lab:write` writes final manuscript output to:
133
+
134
+ - `docs/paper/paper.tex`
135
+ - `docs/paper/sections/*.tex`
136
+
137
+ Internal writing-control artifacts stay under:
132
138
 
133
- - `docs/lab/paper/plan.md`
134
- - `docs/lab/paper/sections/*.md`
135
- - `docs/lab/paper/write-iterations/*.md`
139
+ - `.superlab/write/plan.md`
140
+ - `.superlab/write/iterations/*.md`
136
141
 
137
142
  ## Helper Scripts
138
143
 
139
- - `scripts/check_openspec.sh` checks whether OpenSpec CLI is available.
140
- - `scripts/openspec_change.sh` wraps common OpenSpec change commands for instructions, status, and validation.
141
144
  - `scripts/register_run.py` records run metadata in a JSON registry.
142
145
  - `scripts/eval_report.py` normalizes metrics into a comparable summary.
143
146
  - `scripts/summarize_iterations.py` rolls multiple iteration summaries into one file.
@@ -154,4 +157,4 @@ See the source command docs in [commands/codex/lab.md](/Users/zhouhao119/coding/
154
157
 
155
158
  ## Attribution
156
159
 
157
- `superlab` is OpenSpec-compatible and borrows workflow discipline ideas from OpenSpec, superpowers, and Ralph Wiggum style bounded iteration. Its vendored writing references are adapted from `Research-Paper-Writing-Skills`. It is an independent workflow package, not an official OpenSpec project.
160
+ `superlab` borrows workflow discipline ideas from OpenSpec, superpowers, and Ralph Wiggum style bounded iteration. Its vendored writing references are adapted from `Research-Paper-Writing-Skills`.
package/README.zh-CN.md CHANGED
@@ -6,7 +6,7 @@
6
6
 
7
7
  - Codex 和 Claude 的命令安装入口
8
8
  - 共享的 `/lab` skill
9
- - 兼容 OpenSpec `spec-driven` 的工件模板
9
+ - 基于 `lab` 自己目录约定的 change 工件
10
10
  - 带有 Ralph Wiggum 风格边界控制的实验迭代
11
11
  - 运行登记、评估汇总和结果校验脚本
12
12
 
@@ -43,6 +43,8 @@ npx github:zhouhaoUCAS/superlab init
43
43
  - `.codex/skills/lab/`
44
44
  - `.claude/commands/lab/*.md`
45
45
  - `.claude/skills/lab/`
46
+ - `.superlab/config/workflow.json`
47
+ - `.superlab/changes/`
46
48
  - `.superlab/templates/`
47
49
  - `.superlab/scripts/`
48
50
  - `.superlab/examples/`
@@ -75,27 +77,26 @@ superlab init --lang zh
75
77
  superlab init --lang en
76
78
  ```
77
79
 
78
- 这个语言设置只影响安装到 `.codex/`、`.claude/` 的命令和技能展示文案,不影响实验输出、report 内容或最终论文语言。
80
+ 安装器还会写入 `.superlab/config/workflow.json`。这个文件是全局约束,至少控制:
81
+
82
+ - `workflow_language`
83
+ - `paper_language`
84
+ - `paper_format`
85
+
86
+ 后续 stage 应该按这个配置决定语言和论文格式,而不是各模板自己猜。
79
87
 
80
88
  ## 依赖
81
89
 
82
90
  - Node.js 18+
83
91
  - Python 3.10+
84
92
  - Git
85
- - OpenSpec CLI,并且命令名为 `openspec-cn`
86
-
87
- 检查 OpenSpec CLI:
88
-
89
- ```bash
90
- bash .superlab/scripts/check_openspec.sh
91
- ```
92
93
 
93
94
  `/lab:write` 自带 vendored 的 paper-writing 章节参考,不再依赖额外安装一个运行时写作 skill。
94
95
 
95
96
  ## 命令集合
96
97
 
97
98
  - `/lab:idea` 调研 idea、文献、数据集、指标和 baseline,并输出初始方案。
98
- - `/lab:spec` 把批准后的方案转换成 OpenSpec `proposal`、`design`、`spec`、`tasks`。
99
+ - `/lab:spec` 把批准后的方案转换成一个统一的 `.superlab/changes/<change-id>/` 目录。
99
100
  - `/lab:run` 执行最小可运行实验,并建立首版评估链路。
100
101
  - `/lab:iterate` 以固定 mission、固定阈值和最大轮次做有边界的实验迭代。
101
102
  - `/lab:review` 以审稿人模式检查方法、对照、公平性、泄漏和统计问题。
@@ -114,11 +115,15 @@ bash .superlab/scripts/check_openspec.sh
114
115
  7. 最后用 `/lab:report` 产出总报告。
115
116
  8. 用 `/lab:write` 把稳定结果写成论文各 section。
116
117
 
117
- `/lab:write` 通常会写入:
118
+ `/lab:write` 最终只把论文写入:
119
+
120
+ - `docs/paper/paper.tex`
121
+ - `docs/paper/sections/*.tex`
122
+
123
+ 内部写作控制工件放在:
118
124
 
119
- - `docs/lab/paper/plan.md`
120
- - `docs/lab/paper/sections/*.md`
121
- - `docs/lab/paper/write-iterations/*.md`
125
+ - `.superlab/write/plan.md`
126
+ - `.superlab/write/iterations/*.md`
122
127
 
123
128
  ## 仓库内容
124
129
 
@@ -127,7 +132,6 @@ bash .superlab/scripts/check_openspec.sh
127
132
  - `skills/lab/` 是仓库开发时使用的共享 workflow 定义。
128
133
  - `templates/` 是研究工件模板。
129
134
  - `scripts/` 是运行登记、评估汇总和结果校验脚本。
130
- - 其中 `scripts/openspec_change.sh` 对 `instructions/status/validate` 做了一个最小 OpenSpec wrapper。
131
135
  - `tests/` 是脚本与安装器测试。
132
136
  - `examples/` 是最小端到端示例。
133
137
  - `docs/release.md` 是发布到 npm 的操作说明。
@@ -136,4 +140,4 @@ bash .superlab/scripts/check_openspec.sh
136
140
 
137
141
  ## 致谢
138
142
 
139
- `superlab` 兼容 OpenSpec,并借鉴了 OpenSpec、superpowers 和 Ralph Wiggum 的流程纪律。随包提供的写作参考改编自 `Research-Paper-Writing-Skills`。它是一个独立的开源工作流包,不是 OpenSpec 官方项目。
143
+ `superlab` 借鉴了 OpenSpec、superpowers 和 Ralph Wiggum 的流程纪律。随包提供的写作参考改编自 `Research-Paper-Writing-Skills`。