@winton979/task-cli 1.2.0 → 1.2.1

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 (3) hide show
  1. package/README.md +6 -4
  2. package/package.json +1 -1
  3. package/src/init.js +91 -21
package/README.md CHANGED
@@ -10,7 +10,7 @@ Designed for:
10
10
 
11
11
  Task CLI provides a lightweight alternative to heavyweight spec-driven workflows by combining:
12
12
 
13
- * Requirement clarification (via Grill Me)
13
+ * Requirement clarification (prefer Grill Me, fallback built in)
14
14
  * Brief generation
15
15
  * Implementation
16
16
  * Review
@@ -34,7 +34,7 @@ task init
34
34
 
35
35
  ## Prerequisites
36
36
 
37
- Task CLI relies on a Grill Me compatible skill for requirement exploration.
37
+ Task CLI can use a Grill Me compatible skill for requirement and bug exploration.
38
38
 
39
39
  Recommended:
40
40
 
@@ -44,6 +44,8 @@ npx add-skill PJ-SBN-593844/skill-grill-me
44
44
 
45
45
  Compatible Grill Me implementations may also work.
46
46
 
47
+ If no Grill Me compatible skill is installed, `task-fast`, `task-explore`, and `bug-explore` fall back to built-in clarification prompts.
48
+
47
49
  ---
48
50
 
49
51
  ## Usage
@@ -59,7 +61,7 @@ After initialization, Task CLI creates the `.ai/` workspace and installs workflo
59
61
 
60
62
  Use `task refresh` in existing projects to remove and reinstall only the workflow skills managed by task-cli. It does not delete your `.ai` briefs, internal archives, or decision log.
61
63
 
62
- Use `task doctor` to check whether the required directories exist, whether managed skills are missing or outdated, and whether the `.gitignore` rules are present.
64
+ Use `task doctor` to check whether the required directories exist, whether managed skills are missing or outdated, whether a local Grill Me companion was detected, and whether the `.gitignore` rules are present.
63
65
 
64
66
  ---
65
67
 
@@ -237,4 +239,4 @@ task doctor
237
239
  MIT
238
240
 
239
241
  > Task CLI does not install Grill Me automatically.
240
- > Users remain free to choose any Grill Me compatible implementation.
242
+ > Users remain free to choose any Grill Me compatible implementation, and the explore skills fall back to built-in clarification if none is installed.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@winton979/task-cli",
3
- "version": "1.2.0",
3
+ "version": "1.2.1",
4
4
  "description": "Lightweight task workflow CLI for AI-assisted development",
5
5
  "license": "MIT",
6
6
  "type": "module",
package/src/init.js CHANGED
@@ -1,3 +1,5 @@
1
+ import chalk from 'chalk';
2
+
1
3
  const TASK_ACTIVE_DIR = '.ai/tasks/active';
2
4
  const TASK_ARCHIVE_DIR = '.ai/tasks/archive';
3
5
  const BUG_ACTIVE_DIR = '.ai/bugs/active';
@@ -11,6 +13,12 @@ const GITIGNORE_BLOCK = [
11
13
  '.ai/bugs/active/*.md',
12
14
  ].join('\n');
13
15
 
16
+ const GRILL_ME_HINTS = [
17
+ 'grill-me',
18
+ 'skill-grill-me',
19
+ 'grill me',
20
+ ];
21
+
14
22
  const SKILLS = {
15
23
  'task-fast': {
16
24
  name: 'task-fast',
@@ -27,19 +35,20 @@ Handle a small requirement in one continuous workflow with minimal ceremony.
27
35
 
28
36
  Workflow
29
37
 
30
- 1. Clarify the requirement just enough to remove ambiguity.
31
- 2. Create a concise task brief and save it to:
38
+ 1. If a Grill Me compatible skill is available in the current environment, use it for requirement clarification.
39
+ 2. If no Grill Me compatible skill is available, clarify the requirement yourself with focused questions just far enough to remove ambiguity.
40
+ 3. Create a concise task brief and save it to:
32
41
 
33
42
  .ai/tasks/active/YYYY-MM-DD-task-name.md
34
43
 
35
- 3. Show the brief before coding.
36
- 4. If the user does not object, implement immediately.
37
- 5. Verify the result against the acceptance criteria.
38
- 6. Archive the brief automatically by moving it to:
44
+ 4. Show the brief before coding.
45
+ 5. If the user does not object, implement immediately.
46
+ 6. Verify the result against the acceptance criteria.
47
+ 7. Archive the brief automatically by moving it to:
39
48
 
40
49
  .ai/tasks/archive/YYYY-MM-DD-task-name.md
41
50
 
42
- 7. Summarize the outcome and any follow-up risks.
51
+ 8. Summarize the outcome and any follow-up risks.
43
52
 
44
53
  Task Brief Format
45
54
 
@@ -91,15 +100,16 @@ Clarify requirements and leave behind a ready-to-execute brief.
91
100
 
92
101
  Workflow
93
102
 
94
- 1. Explore the requirement through focused questions.
95
- 2. Continue until the task is sufficiently understood.
96
- 3. Do not write code.
97
- 4. Do not create implementation details.
98
- 5. Once the requirement is clear, generate a concise task brief and save it to:
103
+ 1. If a Grill Me compatible skill is available in the current environment, use it for requirement exploration.
104
+ 2. If no Grill Me compatible skill is available, explore the requirement yourself through focused questions.
105
+ 3. Continue until the task is sufficiently understood.
106
+ 4. Do not write code.
107
+ 5. Do not create implementation details.
108
+ 6. Once the requirement is clear, generate a concise task brief and save it to:
99
109
 
100
110
  .ai/tasks/active/YYYY-MM-DD-task-name.md
101
111
 
102
- 6. Show the saved brief and stop.
112
+ 7. Show the saved brief and stop.
103
113
 
104
114
  Task Brief Format
105
115
 
@@ -270,22 +280,23 @@ Investigate a bug and leave behind a ready-to-fix brief.
270
280
 
271
281
  Rules
272
282
 
273
- 1. Do not write code.
274
- 2. Do not suggest fixes before enough evidence exists.
275
- 3. Identify root cause candidates.
276
- 4. Ask focused questions.
277
- 5. Request evidence whenever possible.
278
- 6. Separate:
283
+ 1. If a Grill Me compatible skill is available in the current environment, use it for bug exploration.
284
+ 2. If no Grill Me compatible skill is available, ask focused questions and drive the investigation yourself.
285
+ 3. Do not write code.
286
+ 4. Do not suggest fixes before enough evidence exists.
287
+ 5. Identify root cause candidates.
288
+ 6. Request evidence whenever possible.
289
+ 7. Separate:
279
290
 
280
291
  * observed behavior
281
292
  * expected behavior
282
293
  * assumptions
283
294
 
284
- 7. Once the bug is sufficiently understood, generate a brief and save it to:
295
+ 8. Once the bug is sufficiently understood, generate a brief and save it to:
285
296
 
286
297
  .ai/bugs/active/YYYY-MM-DD-bug-name.md
287
298
 
288
- 8. Show the saved brief and stop.
299
+ 9. Show the saved brief and stop.
289
300
 
290
301
  Bug Brief Format
291
302
 
@@ -484,6 +495,49 @@ function skillFilePath(path, cwd, skillRoot, skillName) {
484
495
  return path.join(cwd, skillRoot, skillName, 'SKILL.md');
485
496
  }
486
497
 
498
+ function hasGrillMeHint(value) {
499
+ const normalized = value.toLowerCase();
500
+ return GRILL_ME_HINTS.some((hint) => normalized.includes(hint));
501
+ }
502
+
503
+ function detectLocalGrillMeSkill(fs, path, cwd, skillRoot) {
504
+ const root = path.join(cwd, skillRoot);
505
+ if (!fs.existsSync(root)) {
506
+ return null;
507
+ }
508
+
509
+ for (const entry of fs.readdirSync(root, { withFileTypes: true })) {
510
+ if (!entry.isDirectory()) {
511
+ continue;
512
+ }
513
+
514
+ if (MANAGED_SKILL_NAMES.includes(entry.name)) {
515
+ continue;
516
+ }
517
+
518
+ if (hasGrillMeHint(entry.name)) {
519
+ return entry.name;
520
+ }
521
+
522
+ const skillPath = path.join(root, entry.name, 'SKILL.md');
523
+ if (!fs.existsSync(skillPath)) {
524
+ continue;
525
+ }
526
+
527
+ const content = fs.readFileSync(skillPath, 'utf-8');
528
+ const metadata = content
529
+ .split('---')
530
+ .slice(1, 2)
531
+ .join('\n');
532
+
533
+ if (hasGrillMeHint(metadata)) {
534
+ return entry.name;
535
+ }
536
+ }
537
+
538
+ return null;
539
+ }
540
+
487
541
  function logCheck(log, ok, label, detail) {
488
542
  if (ok) {
489
543
  log.chalk.green(` OK ${label}${detail ? ` - ${detail}` : ''}`);
@@ -680,6 +734,22 @@ export function doctor(cwd, { fs, path, log }) {
680
734
  }
681
735
  }
682
736
 
737
+ const grillMeFindings = [
738
+ [CLAUDE_SKILLS_DIR, detectLocalGrillMeSkill(fs, path, cwd, CLAUDE_SKILLS_DIR)],
739
+ [CODEX_SKILLS_DIR, detectLocalGrillMeSkill(fs, path, cwd, CODEX_SKILLS_DIR)],
740
+ ];
741
+
742
+ for (const [skillRoot, skillName] of grillMeFindings) {
743
+ if (skillName) {
744
+ logCheck(log, true, `${skillRoot} Grill Me companion`, `detected ${skillName}`);
745
+ continue;
746
+ }
747
+
748
+ console.log(chalk.yellow(
749
+ ` WARN ${skillRoot} Grill Me companion - not detected locally; task-fast, task-explore, and bug-explore will use built-in clarification fallback`
750
+ ));
751
+ }
752
+
683
753
  const gitignorePath = path.join(cwd, '.gitignore');
684
754
  const gitignore = fs.existsSync(gitignorePath)
685
755
  ? fs.readFileSync(gitignorePath, 'utf-8')