hermes-task-framework 1.0.0__py3-none-any.whl
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.
- hermes_task_framework-1.0.0.dist-info/METADATA +7 -0
- hermes_task_framework-1.0.0.dist-info/RECORD +56 -0
- hermes_task_framework-1.0.0.dist-info/WHEEL +5 -0
- hermes_task_framework-1.0.0.dist-info/licenses/LICENSE +1 -0
- hermes_task_framework-1.0.0.dist-info/top_level.txt +1 -0
- task-framework/__init__.py +2 -0
- task-framework/skills/task-external-repos-pattern/SKILL.md +165 -0
- task-framework/skills/task-framework/CHANGELOG.md +45 -0
- task-framework/skills/task-framework/SKILL.md +1365 -0
- task-framework/skills/task-framework/docs/TASKS.md +3 -0
- task-framework/skills/task-framework/docs/architecture.dot +65 -0
- task-framework/skills/task-framework/docs/architecture.svg +188 -0
- task-framework/skills/task-framework/docs/product-requirements.md +65 -0
- task-framework/skills/task-framework/references/auto-runner.md +32 -0
- task-framework/skills/task-framework/references/composites/code-review-session.md +30 -0
- task-framework/skills/task-framework/references/composites/research.md +45 -0
- task-framework/skills/task-framework/references/composites/software-dev.md +41 -0
- task-framework/skills/task-framework/references/document-analysis-workflow.md +95 -0
- task-framework/skills/task-framework/references/file-safety-lesson.md +38 -0
- task-framework/skills/task-framework/references/generating-output-documents.md +166 -0
- task-framework/skills/task-framework/references/operations/code-write.md +30 -0
- task-framework/skills/task-framework/references/operations/document-write.md +185 -0
- task-framework/skills/task-framework/references/operations/info-search.md +27 -0
- task-framework/skills/task-framework/references/operations/web-research.md +57 -0
- task-framework/skills/task-framework/references/policy-time-metadata.md +137 -0
- task-framework/skills/task-framework/references/research-workflow.md +220 -0
- task-framework/skills/task-framework/references/task-format-validation.md +25 -0
- task-framework/skills/task-framework/references/task-hash-naming.md +40 -0
- task-framework/skills/task-framework/references/task-lifecycle-example.md +122 -0
- task-framework/skills/task-framework/references/task-overview-discovery.md +31 -0
- task-framework/skills/task-framework/references/task-types/analysis.md +60 -0
- task-framework/skills/task-framework/references/task-types/external-audit.md +56 -0
- task-framework/skills/task-framework/references/task-types/video-production-pipeline.md +77 -0
- task-framework/skills/task-framework/scripts/__init__.py +0 -0
- task-framework/skills/task-framework/scripts/__pycache__/manage_task.cpython-312.pyc +0 -0
- task-framework/skills/task-framework/scripts/__pycache__/task_ref.cpython-312.pyc +0 -0
- task-framework/skills/task-framework/scripts/__pycache__/update-index.cpython-311.pyc +0 -0
- task-framework/skills/task-framework/scripts/__pycache__/update-index.cpython-312.pyc +0 -0
- task-framework/skills/task-framework/scripts/convert_md_to_pdf.py +236 -0
- task-framework/skills/task-framework/scripts/manage_task.py +442 -0
- task-framework/skills/task-framework/scripts/task-runner.sh +42 -0
- task-framework/skills/task-framework/scripts/task_ref.py +119 -0
- task-framework/skills/task-framework/scripts/update-index.py +293 -0
- task-framework/skills/task-framework/templates/TASK.md +114 -0
- task-framework/skills/task-framework/templates/TASK_MEMORY.md +27 -0
- task-framework/skills/task-framework/templates/run.py +187 -0
- task-framework/skills/task-lifecycle-edge-cases/SKILL.md +84 -0
- task-framework/skills/task-lifecycle-edge-cases/references/task-5d5a1a-recovery-example.md +67 -0
- task-framework/skills/task-lifecycle-portability/SKILL.md +128 -0
- task-framework/skills/task-lifecycle-portability/references/design-session-20260611.md +32 -0
- task-framework/skills/task-lifecycle-portability/references/output-model-design.md +55 -0
- task-framework/skills/task-lifecycle-portability/references/pipeline-output-transition.md +41 -0
- task-framework/skills/task-lifecycle-portability/references/task-recovery-5d5a1a-example.md +27 -0
- task-framework/skills/task-lifecycle-portability/references/task-recovery-procedure.md +63 -0
- task-framework/skills/task-timestamp-convention/SKILL.md +72 -0
- task-framework/skills/task-tracker/SKILL.md +80 -0
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
# Parallel Research Workflow
|
|
2
|
+
|
|
3
|
+
Use delegate_task with parallel subagents for comprehensive research tasks. Each subagent covers one well-scoped direction and produces structured markdown files.
|
|
4
|
+
|
|
5
|
+
## When to Use
|
|
6
|
+
|
|
7
|
+
- Market research / competitive analysis
|
|
8
|
+
- Policy and regulatory research
|
|
9
|
+
- Technology landscape scanning
|
|
10
|
+
- Multi-angle topic investigations
|
|
11
|
+
- Any research that can be naturally split into independent streams
|
|
12
|
+
|
|
13
|
+
## Phased Research Lifecycle
|
|
14
|
+
|
|
15
|
+
Complex research projects benefit from a phased approach where each phase produces output that feeds the next:
|
|
16
|
+
|
|
17
|
+
| Phase | Focus | Delegation pattern | Output |
|
|
18
|
+
|-------|-------|-------------------|--------|
|
|
19
|
+
| 1 — Broad scoping | Initial search, landscape overview | Inline (manual search) | README.md + 2-3 docs/ files |
|
|
20
|
+
| 2 — Deep dive | Competitor/product deep research | 1 subagent (multiple competitors serial) | 5-6 competitor-*.md files |
|
|
21
|
+
| 3 — Comprehensive | Policy + patents + keywords + ecosystem | 3 parallel subagents | 5+ docs covering all dimensions |
|
|
22
|
+
| 4 — Technical feasibility | Deep technical analysis | 1 deep subagent | 1 large comprehensive doc |
|
|
23
|
+
| 5 — Synthesis | Cross-document compilation | 1 synthesis subagent reading all prior docs | Final product plan doc |
|
|
24
|
+
|
|
25
|
+
### Phase transition flow
|
|
26
|
+
|
|
27
|
+
After each phase completes:
|
|
28
|
+
|
|
29
|
+
1. Read the subagent summary (not just the file — check the summary section)
|
|
30
|
+
2. Verify files were written: `ls -lh docs/`
|
|
31
|
+
3. Mark the phase `[x]` in TASK.md
|
|
32
|
+
4. Update README.md with a summary table of new docs
|
|
33
|
+
5. Present cross-document insights to the user
|
|
34
|
+
6. If the user provides additional guidance (new keywords, new angles), capture it in TASK.md's Notes section, then adjust the next phase's scope
|
|
35
|
+
7. Ask "continue to next phase?" before proceeding
|
|
36
|
+
|
|
37
|
+
## Delegation Patterns by Phase Type
|
|
38
|
+
|
|
39
|
+
### Broad scoping (Phase 1)
|
|
40
|
+
**Strategy:** Inline. Do the searches yourself, compile into docs manually.
|
|
41
|
+
|
|
42
|
+
### Multi-competitor deep dive (Phase 2)
|
|
43
|
+
**Strategy:** One subagent, many targets. Give it a list of 5-8 competitors and let it work through them serially within one delegate_task call. Each competitor gets its own file.
|
|
44
|
+
|
|
45
|
+
```python
|
|
46
|
+
delegate_task(
|
|
47
|
+
goal="Research 6 competitors in this market",
|
|
48
|
+
context="""...
|
|
49
|
+
# Save each as docs/competitor-<name>.md
|
|
50
|
+
# Each file must end with a 启示 (Implications) section
|
|
51
|
+
""",
|
|
52
|
+
toolsets=["terminal", "file", "browser"]
|
|
53
|
+
)
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
### Multi-dimensional research (Phase 3)
|
|
57
|
+
**Strategy:** Parallel subagents, each covering a different dimension. Split by natural fault lines (policy / technology / products / ecosystem), not by source.
|
|
58
|
+
|
|
59
|
+
```python
|
|
60
|
+
delegate_task(
|
|
61
|
+
tasks=[
|
|
62
|
+
{"goal": "Research policy & industry reports", ...},
|
|
63
|
+
{"goal": "Research patents & expanded keywords", ...},
|
|
64
|
+
{"goal": "Research companion products & startups", ...},
|
|
65
|
+
]
|
|
66
|
+
)
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
Each subagent produces 1-2 docs. The content should be non-overlapping.
|
|
70
|
+
|
|
71
|
+
### Deep technical analysis (Phase 4)
|
|
72
|
+
**Strategy:** One deep subagent with a comprehensive spec. Give it 7-8 required sections as a template, lots of context from prior phases.
|
|
73
|
+
|
|
74
|
+
### Synthesis / product planning (Phase 5)
|
|
75
|
+
**Strategy:** One synthesis subagent with instructions to READ all prior docs, then produce the final document. Grant `file` toolset so it can read existing material.
|
|
76
|
+
|
|
77
|
+
```python
|
|
78
|
+
delegate_task(
|
|
79
|
+
goal="Synthesize all research into product plan",
|
|
80
|
+
context=f"""Read all docs from docs/ directory, then produce product-plan-draft.md
|
|
81
|
+
with 8 chapters...""",
|
|
82
|
+
toolsets=["terminal", "file"]
|
|
83
|
+
)
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
## Split the research domain
|
|
87
|
+
|
|
88
|
+
Identify natural fault lines and split into parallel tasks:
|
|
89
|
+
|
|
90
|
+
| Good split | Bad split |
|
|
91
|
+
|-----------|-----------|
|
|
92
|
+
| Competitor A / Competitor B / Competitor C | Feature 1 of A / Feature 2 of A / History of A |
|
|
93
|
+
| Policy / Patents / Products | Same source queried 3 ways |
|
|
94
|
+
| Domestic / International / Technology | Overlapping company lists |
|
|
95
|
+
|
|
96
|
+
Each task must be **independent** — no shared intermediate state.
|
|
97
|
+
|
|
98
|
+
## Write task specs with explicit output directives
|
|
99
|
+
|
|
100
|
+
Each subagent's prompt must include:
|
|
101
|
+
|
|
102
|
+
```
|
|
103
|
+
1. Research scope (what to search)
|
|
104
|
+
2. Output file path (absolute, where to save)
|
|
105
|
+
3. File format (sections, required headers)
|
|
106
|
+
4. Naming convention (prefix conventions like `competitor-`, `paper-`, `policy-`)
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
Example task spec:
|
|
110
|
+
|
|
111
|
+
```
|
|
112
|
+
"context": "输出文件:~/studio/project/tasks/*.research/docs/competitor-qinjia.md
|
|
113
|
+
格式规范:
|
|
114
|
+
# 亲家科技
|
|
115
|
+
## 产品体系
|
|
116
|
+
(功能模块列表)
|
|
117
|
+
## 目标客户
|
|
118
|
+
## 技术栈
|
|
119
|
+
## 案例
|
|
120
|
+
## 启示(对本项目的参考价值)"
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
## Run parallel subagents
|
|
124
|
+
|
|
125
|
+
```python
|
|
126
|
+
delegate_task(
|
|
127
|
+
tasks=[
|
|
128
|
+
{"goal": "...", "context": "...", "toolsets": ["terminal", "file", "browser"]},
|
|
129
|
+
{"goal": "...", "context": "...", "toolsets": ["terminal", "file", "browser"]},
|
|
130
|
+
{"goal": "...", "context": "...", "toolsets": ["terminal", "file", "browser"]},
|
|
131
|
+
]
|
|
132
|
+
)
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
Max concurrent tasks for this user: 3. Time budget: ~5-10 min each.
|
|
136
|
+
|
|
137
|
+
## Compile results
|
|
138
|
+
|
|
139
|
+
After all subagents return:
|
|
140
|
+
|
|
141
|
+
1. Read the summary sections of each result
|
|
142
|
+
2. Verify files were actually written (`ls -lh docs/`)
|
|
143
|
+
3. Update `TASK.md`: mark the phase as `[x]`
|
|
144
|
+
4. Update `README.md`: add a summary table of collected docs
|
|
145
|
+
5. Present cross-document insights to the user
|
|
146
|
+
|
|
147
|
+
## Output File Naming Convention
|
|
148
|
+
|
|
149
|
+
| Prefix | Use case |
|
|
150
|
+
|--------|----------|
|
|
151
|
+
| `competitor-<company>.md` | One company/competitor per file |
|
|
152
|
+
| `paper-<short-title>.md` | Academic paper review |
|
|
153
|
+
| `policy-<topic>-<year>.md` | Policy/regulatory research |
|
|
154
|
+
| `patent-<direction>.md` | Patent landscape |
|
|
155
|
+
| `extended-keywords-<topic>.md` | Keyword-expanded product discovery |
|
|
156
|
+
| `companion-products.md` | Companion/care products |
|
|
157
|
+
| `startup-bp-landscape.md` | Startup business model analysis |
|
|
158
|
+
| `industry-report-<topic>.md` | Market data and forecasts |
|
|
159
|
+
| `architecture-proposal.md` | Technical architecture design |
|
|
160
|
+
| `tech-feasibility-analysis.md` | Technology stack evaluation |
|
|
161
|
+
| `product-plan-draft.md` | Final product plan |
|
|
162
|
+
|
|
163
|
+
Each file should include a "启示" (Implications) section at the end showing relevance to the project.
|
|
164
|
+
|
|
165
|
+
## Research Methodology Tips
|
|
166
|
+
|
|
167
|
+
### Keyword expansion
|
|
168
|
+
|
|
169
|
+
Start with a core term and snowball outward. Example:
|
|
170
|
+
|
|
171
|
+
```
|
|
172
|
+
康养
|
|
173
|
+
├── 银发经济
|
|
174
|
+
├── 智慧助老
|
|
175
|
+
├── 居家适老化改造
|
|
176
|
+
├── 慢病管理
|
|
177
|
+
├── 医养结合
|
|
178
|
+
├── 社区养老
|
|
179
|
+
├── 老年人陪护
|
|
180
|
+
└── AI陪聊
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
Each expanded keyword surfaces a different set of products, companies, and policy frameworks. Review the user's guidance mid-project — they may suggest additional keywords that were not in the original scope. Capture these in TASK.md's Notes section and incorporate into the next phase.
|
|
184
|
+
|
|
185
|
+
### Multi-source strategy
|
|
186
|
+
|
|
187
|
+
| Source | Type | What to look for |
|
|
188
|
+
|--------|------|-----------------|
|
|
189
|
+
| arXiv | Academic | Foundation research, emerging techniques |
|
|
190
|
+
| 中国专利数据库 | Patent | Productized technology, applicant landscape |
|
|
191
|
+
| 36氪/IT桔子 | Startup | Funding rounds, business models, pitch decks |
|
|
192
|
+
| 政府网站 (gov.cn) | Policy | Directives, pilot programs, subsidy criteria |
|
|
193
|
+
| Company websites | Product | Feature lists, pricing, case studies, team |
|
|
194
|
+
| 工信部目录 | Directory | Approved products, vendor lists |
|
|
195
|
+
|
|
196
|
+
### Output quality tracking
|
|
197
|
+
|
|
198
|
+
After each phase, log the cumulative document count and line count so the user can see progress:
|
|
199
|
+
|
|
200
|
+
```bash
|
|
201
|
+
find docs/ -name '*.md' -exec wc -l {} + | sort -rn
|
|
202
|
+
du -sh .
|
|
203
|
+
```
|
|
204
|
+
|
|
205
|
+
### User guidance integration mid-project
|
|
206
|
+
|
|
207
|
+
When the user provides additional research directions mid-project (common in exploratory research):
|
|
208
|
+
|
|
209
|
+
1. Add the new directions to TASK.md as a bullet list under "## Notes" or a dedicated "## 新增调研方向" section
|
|
210
|
+
2. Update the next phase's scope to incorporate them
|
|
211
|
+
3. Don't restart — fold into the next delegation call
|
|
212
|
+
|
|
213
|
+
### Pitfalls
|
|
214
|
+
|
|
215
|
+
- **Chinese search engines block bots** — Bing.cn with `&cc=cn` works sometimes, but expect 50% failure. Use gov.cn and 36氪 as fallback sources.
|
|
216
|
+
- **Company websites return 403** — some older Chinese sites block non-China IPs. Use cached pages or third-party descriptions.
|
|
217
|
+
- **Pricing is rarely public** — Chinese B-end SaaS products rarely list prices. Infer from case study size and funding data.
|
|
218
|
+
- **Subagent summaries can be wrong** — always verify file writes with `ls -lh` after delegation returns.
|
|
219
|
+
- **Subagent output limits** — very large research docs (>800 lines) may approach context limits. Split into 2 documents if a single subagent produces huge output.
|
|
220
|
+
- **Parallel task independence** — subagents cannot read each other's output mid-run. Each must be fully self-contained with all context provided in the prompt.
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# TASK.md Format Validation Checklist
|
|
2
|
+
|
|
3
|
+
Systematic checklist for validating a TASK.md against the `project-tasks` skill spec.
|
|
4
|
+
|
|
5
|
+
## Section Checklist
|
|
6
|
+
|
|
7
|
+
- [ ] **`# Task: <Name>`** — Title matches the task directory name (after the timestamp prefix)
|
|
8
|
+
- [ ] **`## Status`** — Header present. Next line is `active | paused | completed | cancelled — <reason>`. Parsable by `grep -m1 '^## Status'`
|
|
9
|
+
- [ ] **`## Goal`** — Single one-liner describing what the task achieves
|
|
10
|
+
- [ ] **`## Pre-checks`** — Section name is EXACTLY `## Pre-checks` (not `Pre-check results`, `Pre-checks (executed X)`, etc.). The executor checks for this exact string. If the section exists, checkboxes follow directly under it (not under a subheading like `### 待决策事项`)
|
|
11
|
+
- [ ] **`## 环境要求`** — Table format with at minimum columns: `项目`, `最低要求`, `说明`. Present when the task has environment dependencies
|
|
12
|
+
- [ ] **`## Checklist`** — Phase headings (`### Phase N — ...`) with `[ ]` / `[x]` items. Optional `BREAK:` lines between phases
|
|
13
|
+
- [ ] **`## Notes`** — Free-form section at the bottom. Contains decisions, reference links, or research summaries that don't belong in Pre-checks
|
|
14
|
+
|
|
15
|
+
## Common Deviations (check for these)
|
|
16
|
+
|
|
17
|
+
| Deviation | Fix |
|
|
18
|
+
|-----------|-----|
|
|
19
|
+
| `## Pre-check results` or `## Pre-checks results` | Rename to `## Pre-checks` |
|
|
20
|
+
| Pre-check checkbox items under a subheading (`### 待决策事项`) | Move checkboxes directly under `## Pre-checks` |
|
|
21
|
+
| Research notes/results inline in Pre-checks section | Move detailed findings to `## Notes`; keep Pre-checks as compact checkboxes only |
|
|
22
|
+
| Stray table-syntax artifacts (`|## Pre-checks`) | Remove leading `|` and trailing `|` from section headers |
|
|
23
|
+
| Status line missing the dash format | Rewrite as `active — <reason>` (space, em-dash, space) |
|
|
24
|
+
| `BREAK:` line inside a code block | BREAK must be unformatted markdown text, not inside backticks |
|
|
25
|
+
| No `## 环境要求` when task needs specific tools/API keys/env vars | Add the table with accurate minimum requirements |
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# Task Hash Naming Convention
|
|
2
|
+
|
|
3
|
+
## Why the hash must be in the directory name
|
|
4
|
+
|
|
5
|
+
`resolve_ref()` in `scripts/task_ref.py` locates tasks by globbing `*{hash_id}*` against the `tasks/` directory:
|
|
6
|
+
|
|
7
|
+
```python
|
|
8
|
+
matches = glob.glob(os.path.join(TASKS_ROOT, f'*{hash_id}*'))
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
This matches **directory names**, not file contents. If the hash is only in `.hermes-task.json` and not in the directory name, the glob returns nothing and `ref:` lookups fail with `FileNotFoundError`.
|
|
12
|
+
|
|
13
|
+
## The convention
|
|
14
|
+
|
|
15
|
+
```
|
|
16
|
+
tasks/YYYYMMDD-HHMMSS.<name>-<hash6>/
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
The hash suffix at the end of the directory name ensures:
|
|
20
|
+
- `resolve_ref('ref:<hash6>/...')` can find the task by matching `*<hash6>*`
|
|
21
|
+
- The timestamp + name part remains human-readable
|
|
22
|
+
- The hash is globally unique, so no collisions even with identical task names
|
|
23
|
+
|
|
24
|
+
Example:
|
|
25
|
+
```
|
|
26
|
+
tasks/20260605-233355.health-sales-demo-5d5a1a/
|
|
27
|
+
├── .hermes-task.json ← hash: "5d5a1a", name: "health-sales-demo-5d5a1a"
|
|
28
|
+
├── TASK.md
|
|
29
|
+
└── ...
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## What NOT to do
|
|
33
|
+
|
|
34
|
+
- ❌ Do NOT omit the hash from the dir name — `ref:` resolution breaks
|
|
35
|
+
- ❌ Do NOT use sequential version suffixes (`-v1`, `-v2`) — they're not hash-based and convey no identity
|
|
36
|
+
- ❌ Do NOT `mv` task directories manually — use task-framework tools. Manual rename breaks the `ref:` system across all referring tasks until the directory name is updated to match
|
|
37
|
+
|
|
38
|
+
## Consistency with phase directories
|
|
39
|
+
|
|
40
|
+
Phase output directories use the same `<short-name>-<hash6>/` pattern (e.g. `tts-a3f8c2/`, `compositing-c9f3a2/`). The task directory is just the top-level version of the same convention: `<ts>.<name>-<hash6>/`.
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
# Task Lifecycle Walkthrough
|
|
2
|
+
|
|
3
|
+
This example traces a paper-reproduction task from creation through completion.
|
|
4
|
+
|
|
5
|
+
## 1. Create
|
|
6
|
+
|
|
7
|
+
For code/tool tasks, create logs/ only:
|
|
8
|
+
|
|
9
|
+
```
|
|
10
|
+
ts=$(date '+%Y%m%d-%H%M%S')
|
|
11
|
+
mkdir -p "tasks/${ts}.paper-reproduction/logs/"
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
For research/documentation tasks, also create docs/:
|
|
15
|
+
|
|
16
|
+
```
|
|
17
|
+
ts=$(date '+%Y%m%d-%H%M%S')
|
|
18
|
+
mkdir -p "tasks/${ts}.kangyang-center-research/logs/"
|
|
19
|
+
mkdir -p "tasks/${ts}.kangyang-center-research/docs/"
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
Result: `tasks/20260601-164001.paper-reproduction/` (code) or
|
|
23
|
+
`tasks/20260602-041236.kangyang-center-research/` (research)
|
|
24
|
+
|
|
25
|
+
## 2. Status — active
|
|
26
|
+
|
|
27
|
+
TASK.md starts with:
|
|
28
|
+
|
|
29
|
+
```markdown
|
|
30
|
+
## Status
|
|
31
|
+
|
|
32
|
+
active — running pre-checks
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
## 3. Pre-checks (optional)
|
|
36
|
+
|
|
37
|
+
Present when uncertainty exists:
|
|
38
|
+
|
|
39
|
+
```markdown
|
|
40
|
+
## Pre-checks
|
|
41
|
+
|
|
42
|
+
- [ ] Can DeepSeek API replace GPT-4?
|
|
43
|
+
- [ ] Can uv replace conda?
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
Agent:
|
|
47
|
+
1. Reads Pre-checks section
|
|
48
|
+
2. For each `[ ]`, researches and writes `logs/precheck.YYYYMMDD-HHMMSS.md`
|
|
49
|
+
3. Marks `[ ]` → `[x] conclusion`
|
|
50
|
+
4. When all done, presents summary and pauses for user confirmation
|
|
51
|
+
|
|
52
|
+
After confirmation, `## Pre-checks` section is typically kept with `[x]` items (history) or deleted entirely.
|
|
53
|
+
|
|
54
|
+
## Checklist with BREAK
|
|
55
|
+
|
|
56
|
+
```markdown
|
|
57
|
+
## Checklist
|
|
58
|
+
|
|
59
|
+
- [x] Phase 1 — Environment setup ← already done
|
|
60
|
+
- [ ] Phase 2 — Run experiments
|
|
61
|
+
- [ ] BREAK: Check initial results before proceeding
|
|
62
|
+
- [ ] Phase 3 — Verify against paper
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
Agent iterates:
|
|
66
|
+
- `[x]` → skip
|
|
67
|
+
- `[ ] Phase 1` → skip (already checked)
|
|
68
|
+
- `[ ] Phase 2` → execute, then continue
|
|
69
|
+
- `[ ] BREAK: ...` → stop, output summary + message, wait for user
|
|
70
|
+
|
|
71
|
+
## 5. User confirms BREAK
|
|
72
|
+
|
|
73
|
+
Agent rewrites TASK.md:
|
|
74
|
+
|
|
75
|
+
```markdown
|
|
76
|
+
- [x] DONE: Check initial results before proceeding
|
|
77
|
+
- [ ] Phase 3 — Verify against paper
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
Execution resumes on next `task_run`.
|
|
81
|
+
|
|
82
|
+
## 6. Completion
|
|
83
|
+
|
|
84
|
+
When all `[ ]` are `[x]`, the agent sets:
|
|
85
|
+
|
|
86
|
+
```markdown
|
|
87
|
+
## Status
|
|
88
|
+
|
|
89
|
+
completed — all phases done, ASR matches paper
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
## Directory structure at end
|
|
93
|
+
|
|
94
|
+
For a **code/tool task** (paper reproduction):
|
|
95
|
+
|
|
96
|
+
```
|
|
97
|
+
tasks/
|
|
98
|
+
└── 20260601-164001.paper-reproduction/
|
|
99
|
+
├── README.md
|
|
100
|
+
├── TASK.md
|
|
101
|
+
└── logs/
|
|
102
|
+
├── precheck.20260601-164001.md
|
|
103
|
+
├── output.20260601-164500.log
|
|
104
|
+
├── error.20260601-164500.log
|
|
105
|
+
├── output.20260601-171200.log
|
|
106
|
+
└── error.20260601-171200.log
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
For a **research/documentation task** (康养中心调研):
|
|
110
|
+
|
|
111
|
+
```
|
|
112
|
+
tasks/
|
|
113
|
+
└── 20260602-041236.kangyang-center-research/
|
|
114
|
+
├── README.md ← overview + key findings summary
|
|
115
|
+
├── TASK.md ← checklist (Phase 1-5)
|
|
116
|
+
├── docs/ ← organized markdown research materials
|
|
117
|
+
│ ├── paper-summaries.md
|
|
118
|
+
│ ├── product-categories.md
|
|
119
|
+
│ └── architecture-proposal.md
|
|
120
|
+
└── logs/
|
|
121
|
+
└── summary.20260602-120000.log
|
|
122
|
+
```
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Task Overview Discovery
|
|
2
|
+
|
|
3
|
+
When asked to list or update a summary of all tasks, use this approach rather than relying on a potentially stale root README.md.
|
|
4
|
+
|
|
5
|
+
## Approach
|
|
6
|
+
|
|
7
|
+
1. Scan the `tasks/` directory for subdirectories matching `YYYYMMDD-HHMMSS.*` pattern
|
|
8
|
+
2. For each, read the `README.md` to extract:
|
|
9
|
+
- **Title** (`# Title` — first H1)
|
|
10
|
+
- **Description** (first line after H1)
|
|
11
|
+
- **Status** (`## Status` section or inline mention)
|
|
12
|
+
3. Present a compact table to the user
|
|
13
|
+
|
|
14
|
+
## Fallback When README.md is Empty
|
|
15
|
+
|
|
16
|
+
If a task directory has no README.md, check for `TASK.md` and extract the first H1 and status section.
|
|
17
|
+
|
|
18
|
+
## Index File Maintenance
|
|
19
|
+
|
|
20
|
+
The root `tasks/README.md` is the canonical index. After any read/update, regenerate it with the `update-task-index` script from the skill's SKILL.md.
|
|
21
|
+
|
|
22
|
+
## Output Format
|
|
23
|
+
|
|
24
|
+
Prefer a compact pipe-delimited table for terminal readability:
|
|
25
|
+
|
|
26
|
+
```
|
|
27
|
+
| Directory | Title | Status | Description |
|
|
28
|
+
|-----------+-------+--------+-------------|
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
Avoid bullet lists or verbose paragraphs for listing purposes.
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
# analysis 任务生命周期
|
|
2
|
+
|
|
3
|
+
## 创建
|
|
4
|
+
|
|
5
|
+
1. 创建 `tasks/<ts>.<name>-<hash6>/` 目录,含 `input/` `output/` `scripts/`
|
|
6
|
+
2. 从 inbox 复制源文件(PDF、DOCX、图片等)到 `input/`
|
|
7
|
+
3. 写入 `TASK.md`,Data Flow 中将源文件路径写为 `input/<filename>`
|
|
8
|
+
4. 写入 `.hermes-task.json`
|
|
9
|
+
|
|
10
|
+
## 执行
|
|
11
|
+
|
|
12
|
+
1. 从 `input/` 读取源文件
|
|
13
|
+
2. 生成分析文档写入 `output/docs/`
|
|
14
|
+
3. **如果 TASK.md 有 `## Repo` 字段:** 设计文档/分析报告放到 Repo 路径下(如 `{Repo}/docs/`),而不是 `output/docs/`
|
|
15
|
+
4. 执行日志仍写入 `output/logs/`(日志始终在 task 目录)
|
|
16
|
+
5. 最终交付物在上一步确定的路径中(Repo docs/ 或 output/docs/)
|
|
17
|
+
|
|
18
|
+
示例目录结构:
|
|
19
|
+
|
|
20
|
+
```
|
|
21
|
+
tasks/<ts>.<name>-<hash6>/
|
|
22
|
+
├── input/
|
|
23
|
+
│ └── source.pdf
|
|
24
|
+
├── output/
|
|
25
|
+
│ ├── docs/
|
|
26
|
+
│ │ ├── 01-pdf-analysis.md
|
|
27
|
+
│ │ ├── 02-prd-overview.md
|
|
28
|
+
│ │ └── 03-prd-modules.md
|
|
29
|
+
│ └── logs/
|
|
30
|
+
│ └── output.20260610-152823.log
|
|
31
|
+
├── TASK.md
|
|
32
|
+
├── README.md
|
|
33
|
+
├── TASK_MEMORY.md
|
|
34
|
+
└── .hermes-task.json
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
## 修改
|
|
38
|
+
|
|
39
|
+
- 修改 TASK.md checklist 正常进行
|
|
40
|
+
- 不需要重跑已完成的 phase,除非修改了对应的输入
|
|
41
|
+
|
|
42
|
+
## 清理
|
|
43
|
+
|
|
44
|
+
`task_reset --hard` 执行:
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
rm -rf output/ # 删除所有生成文档和日志
|
|
48
|
+
# 重置 TASK.md checkboxes
|
|
49
|
+
# 重置状态为 active
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
如果 task 有自定义清理需求(如保留特定目录),创建 `scripts/clean.sh` 覆盖默认行为。
|
|
53
|
+
|
|
54
|
+
`input/` 不受影响。
|
|
55
|
+
|
|
56
|
+
## 完成
|
|
57
|
+
|
|
58
|
+
1. 确认所有交付物在 `output/docs/` 中
|
|
59
|
+
2. 更新 TASK.md 状态为 `completed`
|
|
60
|
+
3. 运行 `python3 ~/.hermes/skills/software-development/task-framework/scripts/update-index.py` 更新索引
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
# external-audit 任务生命周期
|
|
2
|
+
|
|
3
|
+
## 创建
|
|
4
|
+
|
|
5
|
+
1. 创建 `tasks/<ts>.<name>-<hash6>/` 目录,含 `output/` `scripts/`(不需要 `input/`)
|
|
6
|
+
2. 在 TASK.md 的 Data Flow 中列出**外部源文件路径**(绝对路径,如 `~/project/docs/*.md`)
|
|
7
|
+
3. 写入 `TASK.md`,注明"不可修改外部文件"
|
|
8
|
+
4. 写入 `.hermes-task.json`
|
|
9
|
+
|
|
10
|
+
## 执行
|
|
11
|
+
|
|
12
|
+
1. 通过绝对路径读取外部源文件(`read_file`, `search_files` 工具)
|
|
13
|
+
2. 将分析产出写入 `output/docs/`
|
|
14
|
+
3. **如果 TASK.md 有 `## Repo` 字段:** 分析报告/审计文档放到 Repo 路径下(如 `{Repo}/docs/`),而不是 `output/docs/`
|
|
15
|
+
4. 执行日志仍写入 `output/logs/`(日志始终在 task 目录)
|
|
16
|
+
5. 最终交付物在上一步确定的路径中(Repo docs/ 或 output/docs/)
|
|
17
|
+
|
|
18
|
+
**🔴 核心纪律:不得以任何方式修改 input 中引用的外部路径下的文件。** 不允许 `write_file`、`patch`、`terminal(mv/cp/rm)` 等操作触及外部路径。
|
|
19
|
+
|
|
20
|
+
示例目录结构:
|
|
21
|
+
|
|
22
|
+
```
|
|
23
|
+
tasks/<ts>.<name>-<hash6>/
|
|
24
|
+
├── output/
|
|
25
|
+
│ ├── docs/
|
|
26
|
+
│ │ ├── 01-platform-audit.md
|
|
27
|
+
│ │ └── 02-recommendations.md
|
|
28
|
+
│ └── logs/
|
|
29
|
+
│ └── output.20260610-152823.log
|
|
30
|
+
├── TASK.md
|
|
31
|
+
├── README.md
|
|
32
|
+
└── .hermes-task.json
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
## 修改
|
|
36
|
+
|
|
37
|
+
- 修改 TASK.md checklist 正常进行
|
|
38
|
+
- 如果需要重新分析,重新读取外部文件即可
|
|
39
|
+
|
|
40
|
+
## 清理
|
|
41
|
+
|
|
42
|
+
`task_reset --hard` 执行:
|
|
43
|
+
|
|
44
|
+
```bash
|
|
45
|
+
rm -rf output/ # 删除所有分析文档和日志
|
|
46
|
+
# 重置 TASK.md checkboxes
|
|
47
|
+
# 重置状态为 active
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
外部文件不受影响(本来就不在任务目录内)。
|
|
51
|
+
|
|
52
|
+
## 完成
|
|
53
|
+
|
|
54
|
+
1. 确认所有交付物在 `output/docs/` 中
|
|
55
|
+
2. 更新 TASK.md 状态为 `completed`
|
|
56
|
+
3. 运行 `python3 ~/.hermes/skills/software-development/task-framework/scripts/update-index.py` 更新索引
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
# video-pipeline 任务生命周期
|
|
2
|
+
|
|
3
|
+
## 创建
|
|
4
|
+
|
|
5
|
+
1. 通过 `task_create --skill browser-screen-record-task` 创建
|
|
6
|
+
2. 创建 `tasks/<ts>.<name>-<hash6>/` 目录,含 `input/` `output/` `scripts/`
|
|
7
|
+
3. 用户填写的 `REQUIREMENTS.md` 和 `images/`(封面图片)放在 `input/`
|
|
8
|
+
4. `browser-screen-record-task` 的 `scripts/create_task.py` 生成初始 `TASK.md`
|
|
9
|
+
5. 写入 `.hermes-task.json`
|
|
10
|
+
|
|
11
|
+
## 执行
|
|
12
|
+
|
|
13
|
+
完整的 5 阶段流水线,使用 `pipeline.py` 驱动:
|
|
14
|
+
|
|
15
|
+
| Phase | 生成到 | 说明 |
|
|
16
|
+
|-------|--------|------|
|
|
17
|
+
| 0 | 自身 | 解析 REQUIREMENTS.md → 翻译(如需要) |
|
|
18
|
+
| 1a | `output/tts-<hash6>/` | TTS 音频 |
|
|
19
|
+
| 1b | `output/image-slideshow-<hash6>/` | 封面视频 |
|
|
20
|
+
| 1c | `output/subtitle-gen-<hash6>/` | 字幕 |
|
|
21
|
+
| 2 | `output/` | 计算时间线 → RECORDING.md + COMPOSITING.md |
|
|
22
|
+
| 3 | `output/browser-video-recording-<hash6>/` | 浏览器录屏 |
|
|
23
|
+
| 4 | `output/compositing-<hash6>/` | 合成最终视频 |
|
|
24
|
+
|
|
25
|
+
示例目录结构(执行后):
|
|
26
|
+
|
|
27
|
+
```
|
|
28
|
+
tasks/<ts>.<name>-<hash6>/
|
|
29
|
+
├── input/
|
|
30
|
+
│ ├── REQUIREMENTS.md
|
|
31
|
+
│ └── images/
|
|
32
|
+
│ └── cover.png
|
|
33
|
+
├── output/
|
|
34
|
+
│ ├── tts-a3f8c2/
|
|
35
|
+
│ │ ├── audio_000001.mp3
|
|
36
|
+
│ │ └── audio_manifest.json
|
|
37
|
+
│ ├── image-slideshow-a3f8c2/
|
|
38
|
+
│ │ └── slideshow.mp4
|
|
39
|
+
│ ├── subtitle-gen-a3f8c2/
|
|
40
|
+
│ │ └── subtitle_0001.mp4
|
|
41
|
+
│ ├── browser-video-recording-a3f8c2/
|
|
42
|
+
│ │ └── video.mp4
|
|
43
|
+
│ ├── compositing-a3f8c2/
|
|
44
|
+
│ │ └── output.mp4
|
|
45
|
+
│ ├── RECORDING.md
|
|
46
|
+
│ └── COMPOSITING.md
|
|
47
|
+
├── TASK.md
|
|
48
|
+
├── README.md
|
|
49
|
+
├── TASK_MEMORY.md
|
|
50
|
+
└── .hermes-task.json
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
> **迁移说明:** 现有 pipeline 任务(如 `health-sales-demo-5d5a1a`)可能还把 REQUIREMENTS.md 和 images/ 放在根目录。后续对此任务操作时,应迁移到 `input/` + `output/` 模型。
|
|
54
|
+
|
|
55
|
+
## 修改
|
|
56
|
+
|
|
57
|
+
- **禁止修改 REQUIREMENTS.md** — 需要改时告知用户,让用户自己改
|
|
58
|
+
- 修改后需要重新执行 pipeline
|
|
59
|
+
|
|
60
|
+
## 清理
|
|
61
|
+
|
|
62
|
+
```bash
|
|
63
|
+
# 方式 A(推荐):通过 pipeline.py
|
|
64
|
+
cd tasks/<ts>.<name>-<hash6>/
|
|
65
|
+
python3 ~/.hermes/skills/media/video-production-pipeline/scripts/pipeline.py --clean
|
|
66
|
+
|
|
67
|
+
# 方式 B:通用清理(input/ 安全)
|
|
68
|
+
rm -rf output/
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
`input/` 中的 REQUIREMENTS.md 和 images/ 不受影响。
|
|
72
|
+
|
|
73
|
+
## 完成
|
|
74
|
+
|
|
75
|
+
1. 确认 `output/compositing-<hash6>/output.mp4` 存在且可播放(ffprobe 验证)
|
|
76
|
+
2. 更新 TASK.md 状态为 `completed`
|
|
77
|
+
3. 运行 `python3 ~/.hermes/skills/software-development/task-framework/scripts/update-index.py` 更新索引
|
|
File without changes
|
|
Binary file
|
|
Binary file
|