wtf-p 0.4.0 → 0.5.0
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.
- package/README.md +146 -226
- package/bin/commands/doctor.js +88 -2
- package/bin/commands/install-logic.js +121 -26
- package/bin/commands/status.js +22 -4
- package/bin/commands/update.js +5 -4
- package/bin/install.js +66 -26
- package/bin/lib/checkpoint.js +183 -0
- package/bin/lib/context-primer.js +214 -0
- package/bin/lib/manifest.js +62 -2
- package/bin/lib/utils.js +22 -1
- package/bin/uninstall.js +270 -111
- package/core/write-the-f-paper/references/agent-model-matrix.md +62 -0
- package/core/write-the-f-paper/references/checkpoints.md +160 -9
- package/core/write-the-f-paper/references/context-fidelity.md +153 -0
- package/core/write-the-f-paper/references/deviation-rules.md +150 -0
- package/core/write-the-f-paper/references/git-integration.md +80 -0
- package/core/write-the-f-paper/references/orchestrator-pattern.md +167 -0
- package/core/write-the-f-paper/references/planning-config.md +135 -0
- package/core/write-the-f-paper/references/ui-brand.md +186 -0
- package/core/write-the-f-paper/templates/UAT.md +80 -0
- package/core/write-the-f-paper/templates/base-prefs.yaml +42 -0
- package/core/write-the-f-paper/templates/config.json +31 -5
- package/core/write-the-f-paper/workflows/create-outline.wcn.md +1 -1
- package/core/write-the-f-paper/workflows/execute-outline.md +163 -0
- package/core/write-the-f-paper/workflows/execute-outline.wcn.md +73 -0
- package/core/write-the-f-paper/workflows/execute-section.wcn.md +141 -169
- package/core/write-the-f-paper/workflows/plan-section.wcn.md +96 -103
- package/core/write-the-f-paper/workflows/research-gap.md +27 -3
- package/core/write-the-f-paper/workflows/research-gap.wcn.md +18 -1
- package/core/write-the-f-paper/workflows/verify-work.md +251 -0
- package/core/write-the-f-paper/workflows/verify-work.wcn.md +74 -0
- package/package.json +19 -7
- package/vendors/claude/.claude-plugin/plugin.json +2 -2
- package/vendors/claude/agents/wtfp/argument-verifier.md +189 -0
- package/vendors/claude/agents/wtfp/citation-expert.md +1 -1
- package/vendors/claude/agents/wtfp/citation-formatter.md +1 -1
- package/vendors/claude/agents/wtfp/coherence-checker.md +167 -0
- package/vendors/claude/agents/wtfp/outliner.md +259 -0
- package/vendors/claude/agents/wtfp/plan-checker.md +249 -0
- package/vendors/claude/agents/wtfp/prose-polisher.md +166 -0
- package/vendors/claude/agents/wtfp/research-synthesizer.md +215 -0
- package/vendors/claude/agents/wtfp/section-planner.md +364 -0
- package/vendors/claude/agents/wtfp/section-reviewer.md +182 -0
- package/vendors/claude/agents/wtfp/section-writer.md +312 -0
- package/vendors/claude/commands/wtfp/add-todo.md +108 -0
- package/vendors/claude/commands/wtfp/analyze-bib.md +58 -236
- package/vendors/claude/commands/wtfp/audit-milestone.md +286 -0
- package/vendors/claude/commands/wtfp/check-refs.md +60 -133
- package/vendors/claude/commands/wtfp/check-todos.md +152 -0
- package/vendors/claude/commands/wtfp/checkpoint.md +105 -0
- package/vendors/claude/commands/wtfp/contribute.md +1 -1
- package/vendors/claude/commands/wtfp/create-outline.md +109 -195
- package/vendors/claude/commands/wtfp/create-poster.md +1 -1
- package/vendors/claude/commands/wtfp/create-slides.md +1 -1
- package/vendors/claude/commands/wtfp/discuss-section.md +1 -1
- package/vendors/claude/commands/wtfp/execute-outline.md +257 -0
- package/vendors/claude/commands/wtfp/export-latex.md +1 -1
- package/vendors/claude/commands/wtfp/help.md +174 -280
- package/vendors/claude/commands/wtfp/insert-section.md +1 -1
- package/vendors/claude/commands/wtfp/list-assumptions.md +1 -1
- package/vendors/claude/commands/wtfp/map-project.md +35 -124
- package/vendors/claude/commands/wtfp/new-paper.md +85 -320
- package/vendors/claude/commands/wtfp/pause-writing.md +1 -1
- package/vendors/claude/commands/wtfp/plan-milestone-gaps.md +255 -0
- package/vendors/claude/commands/wtfp/plan-revision.md +1 -1
- package/vendors/claude/commands/wtfp/plan-section.md +165 -190
- package/vendors/claude/commands/wtfp/polish-prose.md +66 -118
- package/vendors/claude/commands/wtfp/progress.md +82 -254
- package/vendors/claude/commands/wtfp/quick.md +107 -0
- package/vendors/claude/commands/wtfp/remove-section.md +1 -1
- package/vendors/claude/commands/wtfp/report-bug.md +1 -1
- package/vendors/claude/commands/wtfp/request-feature.md +1 -1
- package/vendors/claude/commands/wtfp/research-gap.md +138 -150
- package/vendors/claude/commands/wtfp/resume-writing.md +1 -1
- package/vendors/claude/commands/wtfp/review-section.md +55 -333
- package/vendors/claude/commands/wtfp/settings.md +197 -0
- package/vendors/claude/commands/wtfp/submit-milestone.md +248 -99
- package/vendors/claude/commands/wtfp/update.md +112 -0
- package/vendors/claude/commands/wtfp/verify-work.md +254 -0
- package/vendors/claude/commands/wtfp/write-section.md +144 -180
- package/vendors/gemini/agents/wtfp/argument-verifier.md +184 -0
- package/vendors/gemini/agents/wtfp/citation-expert.md +41 -0
- package/vendors/gemini/agents/wtfp/citation-formatter.md +38 -0
- package/vendors/gemini/agents/wtfp/coherence-checker.md +162 -0
- package/vendors/gemini/agents/wtfp/outliner.md +252 -0
- package/vendors/gemini/agents/wtfp/plan-checker.md +244 -0
- package/vendors/gemini/agents/wtfp/prose-polisher.md +158 -0
- package/vendors/gemini/agents/wtfp/research-synthesizer.md +205 -0
- package/vendors/gemini/agents/wtfp/section-planner.md +355 -0
- package/vendors/gemini/agents/wtfp/section-reviewer.md +175 -0
- package/vendors/gemini/agents/wtfp/section-writer.md +304 -0
- package/vendors/gemini/commands/wtfp/add-todo.toml +102 -0
- package/vendors/gemini/commands/wtfp/analyze-bib.toml +126 -0
- package/vendors/gemini/commands/wtfp/audit-milestone.toml +278 -0
- package/vendors/gemini/commands/wtfp/check-refs.toml +123 -0
- package/vendors/gemini/commands/wtfp/check-todos.toml +145 -0
- package/vendors/gemini/commands/wtfp/checkpoint.toml +96 -0
- package/vendors/gemini/commands/wtfp/contribute.toml +269 -0
- package/vendors/gemini/commands/wtfp/create-outline.toml +180 -0
- package/vendors/gemini/commands/wtfp/create-poster.toml +36 -0
- package/vendors/gemini/commands/wtfp/create-slides.toml +35 -0
- package/vendors/gemini/commands/wtfp/discuss-section.toml +62 -0
- package/vendors/gemini/commands/wtfp/execute-outline.toml +247 -0
- package/vendors/gemini/commands/wtfp/export-latex.toml +209 -0
- package/vendors/gemini/commands/wtfp/help.toml +184 -0
- package/vendors/gemini/commands/wtfp/insert-section.toml +123 -0
- package/vendors/gemini/commands/wtfp/list-assumptions.toml +104 -0
- package/vendors/gemini/commands/wtfp/map-project.toml +99 -0
- package/vendors/gemini/commands/wtfp/new-paper.toml +160 -0
- package/vendors/gemini/commands/wtfp/pause-writing.toml +140 -0
- package/vendors/gemini/commands/wtfp/plan-milestone-gaps.toml +249 -0
- package/vendors/gemini/commands/wtfp/plan-revision.toml +171 -0
- package/vendors/gemini/commands/wtfp/plan-section.toml +212 -0
- package/vendors/gemini/commands/wtfp/polish-prose.toml +114 -0
- package/vendors/gemini/commands/wtfp/progress.toml +145 -0
- package/vendors/gemini/commands/wtfp/quick.toml +96 -0
- package/vendors/gemini/commands/wtfp/remove-section.toml +140 -0
- package/vendors/gemini/commands/wtfp/report-bug.toml +126 -0
- package/vendors/gemini/commands/wtfp/request-feature.toml +155 -0
- package/vendors/gemini/commands/wtfp/research-gap.toml +214 -0
- package/vendors/gemini/commands/wtfp/resume-writing.toml +136 -0
- package/vendors/gemini/commands/wtfp/review-section.toml +121 -0
- package/vendors/gemini/commands/wtfp/settings.toml +191 -0
- package/vendors/gemini/commands/wtfp/submit-milestone.toml +351 -0
- package/vendors/gemini/commands/wtfp/update.toml +107 -0
- package/vendors/gemini/commands/wtfp/verify-work.toml +245 -0
- package/vendors/gemini/commands/wtfp/write-section.toml +228 -0
- package/vendors/opencode/agents/wtfp/argument-verifier.md +184 -0
- package/vendors/opencode/agents/wtfp/citation-expert.md +41 -0
- package/vendors/opencode/agents/wtfp/citation-formatter.md +38 -0
- package/vendors/opencode/agents/wtfp/coherence-checker.md +162 -0
- package/vendors/opencode/agents/wtfp/outliner.md +252 -0
- package/vendors/opencode/agents/wtfp/plan-checker.md +244 -0
- package/vendors/opencode/agents/wtfp/prose-polisher.md +158 -0
- package/vendors/opencode/agents/wtfp/research-synthesizer.md +205 -0
- package/vendors/opencode/agents/wtfp/section-planner.md +355 -0
- package/vendors/opencode/agents/wtfp/section-reviewer.md +175 -0
- package/vendors/opencode/agents/wtfp/section-writer.md +304 -0
- package/vendors/opencode/commands/wtfp/add-todo.md +103 -0
- package/vendors/opencode/commands/wtfp/analyze-bib.md +127 -0
- package/vendors/opencode/commands/wtfp/audit-milestone.md +279 -0
- package/vendors/opencode/commands/wtfp/check-refs.md +124 -0
- package/vendors/opencode/commands/wtfp/check-todos.md +146 -0
- package/vendors/opencode/commands/wtfp/checkpoint.md +97 -0
- package/vendors/opencode/commands/wtfp/contribute.md +266 -0
- package/vendors/opencode/commands/wtfp/create-outline.md +181 -0
- package/vendors/opencode/commands/wtfp/create-poster.md +37 -0
- package/vendors/opencode/commands/wtfp/create-slides.md +36 -0
- package/vendors/opencode/commands/wtfp/discuss-section.md +63 -0
- package/vendors/opencode/commands/wtfp/execute-outline.md +248 -0
- package/vendors/opencode/commands/wtfp/export-latex.md +210 -0
- package/vendors/opencode/commands/wtfp/help.md +185 -0
- package/vendors/opencode/commands/wtfp/insert-section.md +124 -0
- package/vendors/opencode/commands/wtfp/list-assumptions.md +105 -0
- package/vendors/opencode/commands/wtfp/map-project.md +100 -0
- package/vendors/opencode/commands/wtfp/new-paper.md +161 -0
- package/vendors/opencode/commands/wtfp/pause-writing.md +141 -0
- package/vendors/opencode/commands/wtfp/plan-milestone-gaps.md +250 -0
- package/vendors/opencode/commands/wtfp/plan-revision.md +174 -0
- package/vendors/opencode/commands/wtfp/plan-section.md +214 -0
- package/vendors/opencode/commands/wtfp/polish-prose.md +115 -0
- package/vendors/opencode/commands/wtfp/progress.md +146 -0
- package/vendors/opencode/commands/wtfp/quick.md +97 -0
- package/vendors/opencode/commands/wtfp/remove-section.md +141 -0
- package/vendors/opencode/commands/wtfp/report-bug.md +127 -0
- package/vendors/opencode/commands/wtfp/request-feature.md +156 -0
- package/vendors/opencode/commands/wtfp/research-gap.md +215 -0
- package/vendors/opencode/commands/wtfp/resume-writing.md +137 -0
- package/vendors/opencode/commands/wtfp/review-section.md +123 -0
- package/vendors/opencode/commands/wtfp/settings.md +192 -0
- package/vendors/opencode/commands/wtfp/submit-milestone.md +352 -0
- package/vendors/opencode/commands/wtfp/update.md +108 -0
- package/vendors/opencode/commands/wtfp/verify-work.md +246 -0
- package/vendors/opencode/commands/wtfp/write-section.md +228 -0
- package/vendors/claude/agents/wtfp/citation-retriever.md +0 -31
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: wtfp:analyze-bib
|
|
3
|
-
description: Analyze
|
|
3
|
+
description: Analyze bibliography and map citations to sections
|
|
4
4
|
argument-hint: "[bib-file]"
|
|
5
5
|
allowed-tools:
|
|
6
6
|
- Read
|
|
@@ -8,24 +8,25 @@ allowed-tools:
|
|
|
8
8
|
- Write
|
|
9
9
|
- Glob
|
|
10
10
|
- Grep
|
|
11
|
+
- Task
|
|
11
12
|
- AskUserQuestion
|
|
12
13
|
- WebFetch
|
|
13
14
|
---
|
|
14
15
|
|
|
16
|
+
<execution_context>
|
|
17
|
+
@~/.claude/write-the-f-paper/templates/project-context/bibliography.md
|
|
18
|
+
</execution_context>
|
|
19
|
+
|
|
15
20
|
<objective>
|
|
16
21
|
Deep analysis of BibTeX bibliography to inform writing strategy.
|
|
17
22
|
|
|
18
|
-
|
|
19
|
-
Output: REFS.md with citation strategy mapped to your paper's sections.
|
|
20
|
-
</objective>
|
|
23
|
+
**Orchestrator role:** Locate bib file, run deterministic indexing/impact tools, resolve model profile, spawn citation-expert agent for analysis, present results.
|
|
21
24
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
@~/.claude/write-the-f-paper/templates/project-context/bibliography.md
|
|
25
|
-
</execution_context>
|
|
25
|
+
Output: REFS.md with citation strategy mapped to paper sections.
|
|
26
|
+
</objective>
|
|
26
27
|
|
|
27
28
|
<context>
|
|
28
|
-
BibTeX file: $ARGUMENTS (optional
|
|
29
|
+
BibTeX file: $ARGUMENTS (optional — auto-detects .bib files if not provided)
|
|
29
30
|
|
|
30
31
|
**Load project context:**
|
|
31
32
|
@.planning/PROJECT.md
|
|
@@ -35,281 +36,102 @@ BibTeX file: $ARGUMENTS (optional - auto-detects .bib files if not provided)
|
|
|
35
36
|
|
|
36
37
|
<process>
|
|
37
38
|
|
|
38
|
-
|
|
39
|
-
**Find BibTeX file:**
|
|
39
|
+
## 1. Validate Environment and Resolve Model Profile
|
|
40
40
|
|
|
41
41
|
```bash
|
|
42
|
-
# Find .bib files
|
|
43
42
|
find . -name "*.bib" -type f 2>/dev/null | grep -v node_modules | grep -v .git | head -10
|
|
44
43
|
```
|
|
45
44
|
|
|
46
|
-
If multiple found,
|
|
47
|
-
If none found, exit with error.
|
|
48
|
-
</step>
|
|
49
|
-
|
|
50
|
-
<step name="parse_entries">
|
|
51
|
-
**Parse BibTeX Index:**
|
|
52
|
-
|
|
53
|
-
Use the specialized indexer tool to get a structured JSON summary of the bibliography. This handles large files efficiently.
|
|
45
|
+
If multiple found, ask via AskUserQuestion. If none found, exit with error.
|
|
54
46
|
|
|
55
47
|
```bash
|
|
56
|
-
|
|
57
|
-
node ~/.claude/bin/bib-index.js index "$ARGUMENTS"
|
|
48
|
+
MODEL_PROFILE=$(cat .planning/config.json 2>/dev/null | grep -o '"model_profile"[[:space:]]*:[[:space:]]*"[^"]*"' | grep -o '"[^"]*"$' | tr -d '"' || echo "balanced")
|
|
58
49
|
```
|
|
59
|
-
*(If $ARGUMENTS is empty, use the file found in previous step)*
|
|
60
50
|
|
|
61
|
-
|
|
51
|
+
| Agent | quality | balanced | budget |
|
|
52
|
+
|-------|---------|----------|--------|
|
|
53
|
+
| citation-expert | opus | sonnet | haiku |
|
|
62
54
|
|
|
63
|
-
|
|
64
|
-
**Impact Analysis:**
|
|
65
|
-
|
|
66
|
-
Analyze citation metrics (citations, velocity, age) to identify seminal and rising papers.
|
|
55
|
+
## 2. Run Deterministic Tools
|
|
67
56
|
|
|
68
57
|
```bash
|
|
69
|
-
node ~/.claude/bin/
|
|
58
|
+
node ~/.claude/bin/bib-index.js index "$BIB_FILE"
|
|
59
|
+
node ~/.claude/bin/analyze-impact.js "$BIB_FILE"
|
|
70
60
|
```
|
|
71
61
|
|
|
72
|
-
|
|
73
|
-
1. **Seminal Works** (>1000 citations)
|
|
74
|
-
2. **Rising Stars** (High citation velocity)
|
|
75
|
-
3. **Review Suggested** (Old, low impact)
|
|
76
|
-
|
|
77
|
-
</step>
|
|
78
|
-
|
|
79
|
-
<step name="temporal_analysis">
|
|
80
|
-
**Temporal Analysis:**
|
|
81
|
-
|
|
82
|
-
Analyze the JSON output from the parse_entries step.
|
|
83
|
-
|
|
84
|
-
Categorize entries by the `year` field in the JSON:
|
|
85
|
-
- **Foundational** (10+ years old)
|
|
86
|
-
- **Established** (5-10 years)
|
|
87
|
-
- **Recent** (2-5 years)
|
|
88
|
-
- **Cutting edge** (<2 years)
|
|
89
|
-
|
|
90
|
-
Produce the "Temporal Distribution" table based on these counts.
|
|
91
|
-
</step>
|
|
62
|
+
Capture JSON output from indexer and impact analysis results.
|
|
92
63
|
|
|
93
|
-
|
|
94
|
-
**Topic Clustering:**
|
|
64
|
+
## 3. Read Context Files
|
|
95
65
|
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
2. Group papers with overlapping terminology
|
|
100
|
-
3. Label clusters with descriptive names
|
|
101
|
-
|
|
102
|
-
```markdown
|
|
103
|
-
## Topic Clusters
|
|
104
|
-
|
|
105
|
-
### Cluster 1: [Theme Name]
|
|
106
|
-
**Papers:** [key1], [key2], [key3]
|
|
107
|
-
**Common themes:** [extracted keywords]
|
|
108
|
-
**Use for:** [which section this supports]
|
|
109
|
-
|
|
110
|
-
### Cluster 2: [Theme Name]
|
|
111
|
-
**Papers:** [key4], [key5]
|
|
112
|
-
**Common themes:** [extracted keywords]
|
|
113
|
-
**Use for:** [which section this supports]
|
|
66
|
+
```bash
|
|
67
|
+
PROJECT_CONTENT=$(cat .planning/PROJECT.md)
|
|
68
|
+
OUTLINE_CONTENT=$(cat .planning/structure/outline.md 2>/dev/null)
|
|
114
69
|
```
|
|
115
70
|
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
<step name="identify_seminal">
|
|
119
|
-
**Verify Seminal Works:**
|
|
120
|
-
|
|
121
|
-
Review the "Seminal Works" list from the Impact Analysis step.
|
|
122
|
-
|
|
123
|
-
```markdown
|
|
124
|
-
## Seminal Works (Verified High Impact)
|
|
71
|
+
## 4. Spawn citation-expert Agent
|
|
125
72
|
|
|
126
|
-
| Key | Title | Citations | Why Seminal |
|
|
127
|
-
|-----|-------|-----------|-------------|
|
|
128
|
-
| [key] | [title] | [N] | [reason] |
|
|
129
73
|
```
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
- question: "Which of these are definitely seminal works in your field?"
|
|
134
|
-
- multiSelect: true
|
|
135
|
-
- options: [top candidates] + "None of these" + "Let me add others"
|
|
136
|
-
|
|
137
|
-
</step>
|
|
138
|
-
|
|
139
|
-
<step name="map_to_sections">
|
|
140
|
-
**Map Citations to Sections:**
|
|
141
|
-
|
|
142
|
-
Based on venue template and topic clusters, suggest where each citation belongs:
|
|
143
|
-
|
|
144
|
-
Read outline.md to get section structure.
|
|
145
|
-
|
|
146
|
-
For each section, identify relevant citations:
|
|
147
|
-
|
|
148
|
-
```markdown
|
|
149
|
-
## Citation Map
|
|
150
|
-
|
|
151
|
-
### Section 1: Introduction
|
|
152
|
-
**Purpose:** Establish problem importance, cite motivation
|
|
153
|
-
**Suggested citations:**
|
|
154
|
-
- [key1] — establishes the problem exists
|
|
155
|
-
- [key2] — shows prior failed attempts
|
|
156
|
-
- [key3] — motivates urgency
|
|
157
|
-
|
|
158
|
-
### Section 2: Background
|
|
159
|
-
**Purpose:** Technical foundations
|
|
160
|
-
**Suggested citations:**
|
|
161
|
-
- [key4] — defines key concept X
|
|
162
|
-
- [key5] — introduces method Y
|
|
163
|
-
|
|
164
|
-
### Section 3: Approach
|
|
165
|
-
**Purpose:** Your contribution (cite sparingly)
|
|
166
|
-
**Suggested citations:**
|
|
167
|
-
- [key6] — technique you build on
|
|
168
|
-
|
|
169
|
-
### Section 4: Evaluation
|
|
170
|
-
**Purpose:** Comparison baselines
|
|
171
|
-
**Suggested citations:**
|
|
172
|
-
- [key7] — baseline method 1
|
|
173
|
-
- [key8] — baseline method 2
|
|
174
|
-
|
|
175
|
-
### Section 5: Related Work
|
|
176
|
-
**Purpose:** Position in literature (cite heavily)
|
|
177
|
-
**Suggested citations:**
|
|
178
|
-
- [key9], [key10] — similar approaches
|
|
179
|
-
- [key11], [key12] — alternative methods
|
|
180
|
-
- [key13] — concurrent work
|
|
74
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
75
|
+
WTF-P ► ANALYZING BIBLIOGRAPHY
|
|
76
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
181
77
|
```
|
|
182
78
|
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
```markdown
|
|
191
|
-
## Potential Gaps
|
|
192
|
-
|
|
193
|
-
| Section | Gap | Suggestion |
|
|
194
|
-
|---------|-----|------------|
|
|
195
|
-
| Background | No citation for [concept] | Search for foundational paper on X |
|
|
196
|
-
| Related Work | Missing [approach type] | Add recent work on Y |
|
|
197
|
-
| Evaluation | Only [N] baselines | Consider adding [method] |
|
|
79
|
+
```
|
|
80
|
+
Task(
|
|
81
|
+
prompt="First, read ~/.claude/agents/wtfp/citation-expert.md for your role.\n\n" + analysis_prompt,
|
|
82
|
+
subagent_type="general-purpose",
|
|
83
|
+
model="{expert_model}",
|
|
84
|
+
description="Analyze bibliography"
|
|
85
|
+
)
|
|
198
86
|
```
|
|
199
87
|
|
|
200
|
-
|
|
201
|
-
- header: "Gaps"
|
|
202
|
-
- question: "Any topics you know you need to cite but don't have in your .bib yet?"
|
|
203
|
-
- options:
|
|
204
|
-
- "No gaps" — Coverage looks good
|
|
205
|
-
- "Missing some" — I'll list what I need
|
|
206
|
-
- "Not sure" — Help me identify gaps
|
|
207
|
-
|
|
208
|
-
</step>
|
|
209
|
-
|
|
210
|
-
<step name="write_refs">
|
|
211
|
-
**Create REFS.md:**
|
|
212
|
-
|
|
213
|
-
Write to `.planning/sources/REFS.md`:
|
|
214
|
-
|
|
215
|
-
```markdown
|
|
216
|
-
# Citation Strategy
|
|
217
|
-
|
|
218
|
-
## Bibliography: [filename.bib]
|
|
219
|
-
**Total entries:** [N]
|
|
220
|
-
**Analysis date:** [date]
|
|
221
|
-
|
|
222
|
-
## Impact Analysis
|
|
223
|
-
[From impact_analysis step]
|
|
224
|
-
- Seminal Works (>1000 citations)
|
|
225
|
-
- Rising Stars (High Velocity)
|
|
226
|
-
- Review Suggested (Low Impact/Old)
|
|
227
|
-
|
|
228
|
-
## Temporal Distribution
|
|
229
|
-
[From temporal_analysis step]
|
|
230
|
-
|
|
231
|
-
## Topic Clusters
|
|
232
|
-
[From cluster_topics step]
|
|
233
|
-
|
|
234
|
-
## Citation Map by Section
|
|
235
|
-
[From map_to_sections step]
|
|
236
|
-
|
|
237
|
-
## Potential Gaps
|
|
238
|
-
[From identify_gaps step]
|
|
239
|
-
|
|
240
|
-
## Quick Reference
|
|
88
|
+
Analysis prompt includes: `<bib_index>` with parsed entries, `<impact_analysis>` with metrics, `<project_context>` with PROJECT + outline, `<output>` targeting `.planning/sources/REFS.md`.
|
|
241
89
|
|
|
242
|
-
|
|
243
|
-
- [key1] — [one-liner why]
|
|
244
|
-
- [key2] — [one-liner why]
|
|
90
|
+
Agent performs: temporal analysis, topic clustering, seminal work identification, section mapping, gap identification.
|
|
245
91
|
|
|
246
|
-
|
|
247
|
-
- [key3] — [one-liner why]
|
|
92
|
+
## 5. Handle Expert Return
|
|
248
93
|
|
|
249
|
-
|
|
250
|
-
- [key4] — [one-liner why]
|
|
94
|
+
**`## ANALYSIS COMPLETE`:** Present summary, ask user to confirm seminal works via AskUserQuestion.
|
|
251
95
|
|
|
252
|
-
|
|
253
|
-
*Generated by /wtfp:analyze-bib*
|
|
254
|
-
*Review and adjust as you write*
|
|
255
|
-
```
|
|
96
|
+
**`## ANALYSIS BLOCKED`:** Present blocker (missing .bib, empty file, etc.), ask user how to proceed.
|
|
256
97
|
|
|
257
|
-
|
|
98
|
+
## 6. Commit
|
|
258
99
|
|
|
259
|
-
<step name="commit">
|
|
260
100
|
```bash
|
|
261
101
|
git add .planning/sources/REFS.md
|
|
262
|
-
git commit -m "
|
|
263
|
-
refs: analyze bibliography for citation strategy
|
|
264
|
-
|
|
265
|
-
- Entries: [N] total
|
|
266
|
-
- Clusters: [N] topic groups
|
|
267
|
-
- Seminal works: [N] identified
|
|
268
|
-
- Citation map: all sections covered
|
|
269
|
-
EOF
|
|
270
|
-
)"
|
|
102
|
+
git commit -m "refs: analyze bibliography for citation strategy"
|
|
271
103
|
```
|
|
272
104
|
|
|
273
|
-
</
|
|
105
|
+
</process>
|
|
106
|
+
|
|
107
|
+
<offer_next>
|
|
274
108
|
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
109
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
110
|
+
WTF-P ► BIBLIOGRAPHY ANALYZED ✓
|
|
111
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
278
112
|
|
|
279
|
-
- Source: [filename.bib]
|
|
280
113
|
- Entries: [N]
|
|
281
114
|
- Topic clusters: [N]
|
|
282
115
|
- Seminal works: [N]
|
|
283
116
|
- Citation map: .planning/sources/REFS.md
|
|
284
117
|
|
|
285
|
-
|
|
118
|
+
───────────────────────────────────────────
|
|
286
119
|
|
|
287
|
-
|
|
120
|
+
## ▶ Next Up
|
|
288
121
|
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
## Next Up
|
|
292
|
-
|
|
293
|
-
**Create outline** — use citation map to inform section planning
|
|
294
|
-
|
|
295
|
-
`/wtfp:create-outline`
|
|
122
|
+
`/wtfp:create-outline` — use citation map to inform section planning
|
|
296
123
|
|
|
297
|
-
|
|
124
|
+
<sub>`/clear` first → fresh context window</sub>
|
|
298
125
|
|
|
299
|
-
|
|
300
|
-
```
|
|
126
|
+
───────────────────────────────────────────
|
|
301
127
|
|
|
302
|
-
</
|
|
303
|
-
|
|
304
|
-
</process>
|
|
128
|
+
</offer_next>
|
|
305
129
|
|
|
306
130
|
<success_criteria>
|
|
307
131
|
- [ ] BibTeX file parsed completely
|
|
308
|
-
- [ ]
|
|
309
|
-
- [ ]
|
|
310
|
-
- [ ]
|
|
311
|
-
- [ ]
|
|
312
|
-
- [ ] Gaps identified
|
|
313
|
-
- [ ] REFS.md created in .planning/sources/
|
|
132
|
+
- [ ] Impact analysis run
|
|
133
|
+
- [ ] Citation-expert spawned with full context
|
|
134
|
+
- [ ] REFS.md created with citation strategy
|
|
135
|
+
- [ ] Seminal works confirmed with user
|
|
314
136
|
- [ ] Committed to git
|
|
315
137
|
</success_criteria>
|
|
@@ -0,0 +1,286 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: wtfp:audit-milestone
|
|
3
|
+
description: Run pre-submission checks on sections, citations, and word counts
|
|
4
|
+
allowed-tools:
|
|
5
|
+
- Read
|
|
6
|
+
- Bash
|
|
7
|
+
- Write
|
|
8
|
+
- Glob
|
|
9
|
+
- Grep
|
|
10
|
+
- AskUserQuestion
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
<objective>
|
|
14
|
+
Check paper readiness before submission.
|
|
15
|
+
|
|
16
|
+
Runs 5 audit checks:
|
|
17
|
+
1. Section completion status
|
|
18
|
+
2. Argument coverage (all claims addressed)
|
|
19
|
+
3. Word targets (within tolerance)
|
|
20
|
+
4. Citation completeness (all resolved)
|
|
21
|
+
5. Review status (all sections reviewed)
|
|
22
|
+
|
|
23
|
+
Produces MILESTONE-AUDIT.md with pass/gap for each criterion.
|
|
24
|
+
</objective>
|
|
25
|
+
|
|
26
|
+
<process>
|
|
27
|
+
|
|
28
|
+
<step name="validate">
|
|
29
|
+
**Step 1: Validate Environment**
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
[ ! -f .planning/PROJECT.md ] && echo "ERROR: No PROJECT.md found" && exit 1
|
|
33
|
+
[ ! -f .planning/ROADMAP.md ] && echo "ERROR: No ROADMAP.md found" && exit 1
|
|
34
|
+
[ ! -f .planning/STATE.md ] && echo "ERROR: No STATE.md found" && exit 1
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
</step>
|
|
38
|
+
|
|
39
|
+
<step name="banner">
|
|
40
|
+
**Step 2: Display Banner**
|
|
41
|
+
|
|
42
|
+
```
|
|
43
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
44
|
+
WTF-P ► AUDITING MILESTONE
|
|
45
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
46
|
+
|
|
47
|
+
Running 5 pre-submission checks...
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
</step>
|
|
51
|
+
|
|
52
|
+
<step name="check_sections">
|
|
53
|
+
**Check 1: Section Completion**
|
|
54
|
+
|
|
55
|
+
Read ROADMAP.md. For each section entry:
|
|
56
|
+
- Is it marked `[x]` complete?
|
|
57
|
+
- Extract section name and completion status
|
|
58
|
+
|
|
59
|
+
Count:
|
|
60
|
+
- `TOTAL_SECTIONS`: Number of section entries
|
|
61
|
+
- `COMPLETE_SECTIONS`: Number with `[x]`
|
|
62
|
+
- `INCOMPLETE_SECTIONS`: Number with `[ ]`
|
|
63
|
+
|
|
64
|
+
**Result:**
|
|
65
|
+
- PASS if `COMPLETE_SECTIONS == TOTAL_SECTIONS`
|
|
66
|
+
- GAP if any sections incomplete
|
|
67
|
+
|
|
68
|
+
Store result:
|
|
69
|
+
```
|
|
70
|
+
CHECK_1_STATUS="{PASS|GAP}"
|
|
71
|
+
CHECK_1_DETAIL="{M}/{N} complete"
|
|
72
|
+
CHECK_1_GAPS="{list of incomplete section names, if any}"
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
</step>
|
|
76
|
+
|
|
77
|
+
<step name="check_arguments">
|
|
78
|
+
**Check 2: Argument Coverage**
|
|
79
|
+
|
|
80
|
+
Read `.planning/structure/argument-map.md` if it exists.
|
|
81
|
+
|
|
82
|
+
Extract all claims (lines starting with `- **Claim**:` or numbered claims).
|
|
83
|
+
|
|
84
|
+
For each claim:
|
|
85
|
+
- Search paper content files (`paper/` directory or equivalent)
|
|
86
|
+
- Check if evidence of the claim being addressed exists
|
|
87
|
+
|
|
88
|
+
**Result:**
|
|
89
|
+
- PASS if all claims addressed
|
|
90
|
+
- GAP listing unaddressed claims
|
|
91
|
+
|
|
92
|
+
Store result:
|
|
93
|
+
```
|
|
94
|
+
CHECK_2_STATUS="{PASS|GAP}"
|
|
95
|
+
CHECK_2_DETAIL="{M}/{N} claims addressed"
|
|
96
|
+
CHECK_2_GAPS="{list of unaddressed claims, if any}"
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
If argument-map.md doesn't exist:
|
|
100
|
+
```
|
|
101
|
+
CHECK_2_STATUS="SKIP"
|
|
102
|
+
CHECK_2_DETAIL="No argument-map.md found"
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
</step>
|
|
106
|
+
|
|
107
|
+
<step name="check_words">
|
|
108
|
+
**Check 3: Word Targets**
|
|
109
|
+
|
|
110
|
+
Read `.planning/structure/outline.md` for word budget per section.
|
|
111
|
+
|
|
112
|
+
For each section:
|
|
113
|
+
- Count actual words in the paper content file
|
|
114
|
+
- Compare to target from outline
|
|
115
|
+
|
|
116
|
+
**Tolerance:** +/- 15% of target per section
|
|
117
|
+
|
|
118
|
+
**Result:**
|
|
119
|
+
- PASS if all sections within range
|
|
120
|
+
- GAP listing sections outside range (with actual vs target)
|
|
121
|
+
|
|
122
|
+
Store result:
|
|
123
|
+
```
|
|
124
|
+
CHECK_3_STATUS="{PASS|GAP}"
|
|
125
|
+
CHECK_3_DETAIL="{N}/{M} sections within range"
|
|
126
|
+
CHECK_3_GAPS="{list of sections outside range: 'Section X: Y words (target: Z, variance: +/-W%)'}"
|
|
127
|
+
```
|
|
128
|
+
|
|
129
|
+
If outline.md doesn't exist or has no word targets:
|
|
130
|
+
```
|
|
131
|
+
CHECK_3_STATUS="SKIP"
|
|
132
|
+
CHECK_3_DETAIL="No word targets defined in outline.md"
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
</step>
|
|
136
|
+
|
|
137
|
+
<step name="check_citations">
|
|
138
|
+
**Check 4: Citation Completeness**
|
|
139
|
+
|
|
140
|
+
Scan all paper content files for citation patterns:
|
|
141
|
+
- `(Author, Year)` - APA style
|
|
142
|
+
- `\cite{key}` - LaTeX style
|
|
143
|
+
- `[@key]` - Pandoc/markdown style
|
|
144
|
+
- `[N]` - IEEE style
|
|
145
|
+
|
|
146
|
+
Cross-reference with bibliography file:
|
|
147
|
+
- `references.bib` (BibTeX)
|
|
148
|
+
- `.planning/sources/bibliography.md`
|
|
149
|
+
- Any `.bib` files in project
|
|
150
|
+
|
|
151
|
+
Check for:
|
|
152
|
+
1. **Uncited references**: Entries in bibliography not cited in text
|
|
153
|
+
2. **Undefined citations**: Citations in text not in bibliography
|
|
154
|
+
|
|
155
|
+
**Result:**
|
|
156
|
+
- PASS if all citations resolved
|
|
157
|
+
- GAP listing issues
|
|
158
|
+
|
|
159
|
+
Store result:
|
|
160
|
+
```
|
|
161
|
+
CHECK_4_STATUS="{PASS|GAP}"
|
|
162
|
+
CHECK_4_DETAIL="{N} issues found"
|
|
163
|
+
CHECK_4_GAPS="{list: 'Uncited: [keys]', 'Undefined: [keys]'}"
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
If no bibliography file found:
|
|
167
|
+
```
|
|
168
|
+
CHECK_4_STATUS="SKIP"
|
|
169
|
+
CHECK_4_DETAIL="No bibliography file found"
|
|
170
|
+
```
|
|
171
|
+
|
|
172
|
+
</step>
|
|
173
|
+
|
|
174
|
+
<step name="check_reviews">
|
|
175
|
+
**Check 5: Review Status**
|
|
176
|
+
|
|
177
|
+
For each section:
|
|
178
|
+
- Check if review SUMMARY.md exists in `.planning/sections/{section}/`
|
|
179
|
+
- Or check if "review: pass" noted in section summary
|
|
180
|
+
|
|
181
|
+
**Result:**
|
|
182
|
+
- PASS if all sections reviewed
|
|
183
|
+
- GAP listing unreviewed sections
|
|
184
|
+
|
|
185
|
+
Store result:
|
|
186
|
+
```
|
|
187
|
+
CHECK_5_STATUS="{PASS|GAP}"
|
|
188
|
+
CHECK_5_DETAIL="{M}/{N} sections reviewed"
|
|
189
|
+
CHECK_5_GAPS="{list of unreviewed sections}"
|
|
190
|
+
```
|
|
191
|
+
|
|
192
|
+
</step>
|
|
193
|
+
|
|
194
|
+
<step name="write_audit">
|
|
195
|
+
**Step 3: Write MILESTONE-AUDIT.md**
|
|
196
|
+
|
|
197
|
+
Determine overall status:
|
|
198
|
+
- `OVERALL="PASS"` if all checks pass or skip
|
|
199
|
+
- `OVERALL="GAPS FOUND"` if any check has GAP status
|
|
200
|
+
|
|
201
|
+
Write `.planning/MILESTONE-AUDIT.md`:
|
|
202
|
+
|
|
203
|
+
```markdown
|
|
204
|
+
# Milestone Audit
|
|
205
|
+
|
|
206
|
+
**Date:** {YYYY-MM-DD}
|
|
207
|
+
**Overall:** {PASS | GAPS FOUND}
|
|
208
|
+
|
|
209
|
+
## Results
|
|
210
|
+
|
|
211
|
+
| Check | Status | Details |
|
|
212
|
+
|-------|--------|---------|
|
|
213
|
+
| Section Completion | {PASS/GAP/SKIP} | {CHECK_1_DETAIL} |
|
|
214
|
+
| Argument Coverage | {PASS/GAP/SKIP} | {CHECK_2_DETAIL} |
|
|
215
|
+
| Word Targets | {PASS/GAP/SKIP} | {CHECK_3_DETAIL} |
|
|
216
|
+
| Citation Completeness | {PASS/GAP/SKIP} | {CHECK_4_DETAIL} |
|
|
217
|
+
| Review Status | {PASS/GAP/SKIP} | {CHECK_5_DETAIL} |
|
|
218
|
+
|
|
219
|
+
## Gaps
|
|
220
|
+
|
|
221
|
+
{For each GAP status, create a subsection:}
|
|
222
|
+
|
|
223
|
+
### {Check Name}
|
|
224
|
+
- **Status:** gap
|
|
225
|
+
- **Finding:** {what's missing}
|
|
226
|
+
- **Affected:** {sections/claims/files}
|
|
227
|
+
- **Recommendation:** {what to do}
|
|
228
|
+
|
|
229
|
+
{If no gaps:}
|
|
230
|
+
No gaps found. Paper is ready for submission.
|
|
231
|
+
|
|
232
|
+
## Summary
|
|
233
|
+
|
|
234
|
+
{If PASS: "Paper is ready for submission. Run `/wtfp:submit-milestone {version}` to archive."}
|
|
235
|
+
{If GAPS: "Found {N} gaps requiring attention. Run `/wtfp:plan-milestone-gaps` to create fix plans."}
|
|
236
|
+
```
|
|
237
|
+
|
|
238
|
+
</step>
|
|
239
|
+
|
|
240
|
+
<step name="present_results">
|
|
241
|
+
**Step 4: Present Results**
|
|
242
|
+
|
|
243
|
+
```
|
|
244
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
245
|
+
WTF-P ► AUDIT COMPLETE
|
|
246
|
+
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
247
|
+
|
|
248
|
+
Overall: {PASS | GAPS FOUND}
|
|
249
|
+
|
|
250
|
+
Results:
|
|
251
|
+
✓ Section Completion: {details}
|
|
252
|
+
✓ Argument Coverage: {details}
|
|
253
|
+
✓ Word Targets: {details}
|
|
254
|
+
✓ Citation Completeness: {details}
|
|
255
|
+
✓ Review Status: {details}
|
|
256
|
+
|
|
257
|
+
{Use ✓ for PASS, ✗ for GAP, — for SKIP}
|
|
258
|
+
|
|
259
|
+
Audit saved to: .planning/MILESTONE-AUDIT.md
|
|
260
|
+
|
|
261
|
+
───────────────────────────────────────────
|
|
262
|
+
|
|
263
|
+
## Next Up
|
|
264
|
+
|
|
265
|
+
{If PASS:}
|
|
266
|
+
**Ready to submit:**
|
|
267
|
+
`/wtfp:submit-milestone {version}`
|
|
268
|
+
|
|
269
|
+
{If GAPS:}
|
|
270
|
+
**Fix gaps first:**
|
|
271
|
+
`/wtfp:plan-milestone-gaps` - Create fix plans from audit
|
|
272
|
+
|
|
273
|
+
───────────────────────────────────────────
|
|
274
|
+
```
|
|
275
|
+
|
|
276
|
+
</step>
|
|
277
|
+
|
|
278
|
+
</process>
|
|
279
|
+
|
|
280
|
+
<success_criteria>
|
|
281
|
+
- [ ] Environment validated
|
|
282
|
+
- [ ] 5 audit checks run (section, argument, word, citation, review)
|
|
283
|
+
- [ ] MILESTONE-AUDIT.md created with pass/gap per check
|
|
284
|
+
- [ ] Gaps include actionable recommendations
|
|
285
|
+
- [ ] Next steps offered based on result
|
|
286
|
+
</success_criteria>
|