oh-my-claude-sisyphus 3.0.11 → 3.1.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 +23 -1
- package/agents/build-fixer-low.md +83 -0
- package/agents/build-fixer.md +160 -0
- package/agents/code-reviewer-low.md +82 -0
- package/agents/code-reviewer.md +115 -0
- package/agents/planner.md +83 -0
- package/agents/security-reviewer-low.md +83 -0
- package/agents/security-reviewer.md +186 -0
- package/agents/tdd-guide-low.md +81 -0
- package/agents/tdd-guide.md +165 -0
- package/commands/build-fix.md +55 -0
- package/commands/code-review.md +47 -0
- package/commands/ralph.md +9 -0
- package/commands/security-review.md +47 -0
- package/commands/tdd.md +54 -0
- package/dist/__tests__/hud-agents.test.js +13 -10
- package/dist/__tests__/hud-agents.test.js.map +1 -1
- package/dist/__tests__/installer.test.js +1 -1
- package/dist/cli/index.js +0 -0
- package/dist/hooks/bridge.d.ts.map +1 -1
- package/dist/hooks/bridge.js +15 -3
- package/dist/hooks/bridge.js.map +1 -1
- package/dist/hooks/keyword-detector/index.d.ts +1 -1
- package/dist/hooks/keyword-detector/index.d.ts.map +1 -1
- package/dist/hooks/keyword-detector/index.js +2 -1
- package/dist/hooks/keyword-detector/index.js.map +1 -1
- package/dist/hooks/ralph-loop/index.d.ts +0 -20
- package/dist/hooks/ralph-loop/index.d.ts.map +1 -1
- package/dist/hooks/ralph-loop/index.js +6 -40
- package/dist/hooks/ralph-loop/index.js.map +1 -1
- package/dist/hooks/ultrawork-state/index.d.ts +3 -1
- package/dist/hooks/ultrawork-state/index.d.ts.map +1 -1
- package/dist/hooks/ultrawork-state/index.js +3 -2
- package/dist/hooks/ultrawork-state/index.js.map +1 -1
- package/dist/hud/elements/limits.d.ts +1 -1
- package/dist/hud/elements/limits.d.ts.map +1 -1
- package/dist/hud/elements/limits.js +35 -2
- package/dist/hud/elements/limits.js.map +1 -1
- package/dist/hud/elements/todos.d.ts +1 -1
- package/dist/hud/elements/todos.js +3 -3
- package/dist/hud/elements/todos.js.map +1 -1
- package/dist/hud/render.js +6 -6
- package/dist/hud/render.js.map +1 -1
- package/dist/hud/types.d.ts +4 -0
- package/dist/hud/types.d.ts.map +1 -1
- package/dist/hud/types.js.map +1 -1
- package/dist/hud/usage-api.d.ts.map +1 -1
- package/dist/hud/usage-api.js +32 -6
- package/dist/hud/usage-api.js.map +1 -1
- package/dist/installer/hooks.d.ts +5 -0
- package/dist/installer/hooks.d.ts.map +1 -1
- package/dist/installer/hooks.js +20 -0
- package/dist/installer/hooks.js.map +1 -1
- package/dist/installer/index.d.ts +1 -1
- package/dist/installer/index.js +2 -2
- package/dist/installer/index.js.map +1 -1
- package/docs/CLAUDE.md +13 -1
- package/package.json +1 -1
- package/skills/omc-setup/SKILL.md +95 -0
- package/skills/ralph/SKILL.md +9 -0
- package/skills/ultrawork/SKILL.md +9 -5
- package/dist/__tests__/learned-skills/config.test.d.ts +0 -2
- package/dist/__tests__/learned-skills/config.test.d.ts.map +0 -1
- package/dist/__tests__/learned-skills/config.test.js +0 -37
- package/dist/__tests__/learned-skills/config.test.js.map +0 -1
- package/dist/__tests__/learned-skills/detector.test.d.ts +0 -2
- package/dist/__tests__/learned-skills/detector.test.d.ts.map +0 -1
- package/dist/__tests__/learned-skills/detector.test.js +0 -99
- package/dist/__tests__/learned-skills/detector.test.js.map +0 -1
- package/dist/__tests__/learned-skills/finder.test.d.ts +0 -2
- package/dist/__tests__/learned-skills/finder.test.d.ts.map +0 -1
- package/dist/__tests__/learned-skills/finder.test.js +0 -59
- package/dist/__tests__/learned-skills/finder.test.js.map +0 -1
- package/dist/__tests__/learned-skills/loader.test.d.ts +0 -2
- package/dist/__tests__/learned-skills/loader.test.d.ts.map +0 -1
- package/dist/__tests__/learned-skills/loader.test.js +0 -69
- package/dist/__tests__/learned-skills/loader.test.js.map +0 -1
- package/dist/__tests__/learned-skills/parser.test.d.ts +0 -2
- package/dist/__tests__/learned-skills/parser.test.d.ts.map +0 -1
- package/dist/__tests__/learned-skills/parser.test.js +0 -81
- package/dist/__tests__/learned-skills/parser.test.js.map +0 -1
- package/dist/__tests__/learned-skills/validator.test.d.ts +0 -2
- package/dist/__tests__/learned-skills/validator.test.d.ts.map +0 -1
- package/dist/__tests__/learned-skills/validator.test.js +0 -85
- package/dist/__tests__/learned-skills/validator.test.js.map +0 -1
- package/dist/agents/document-writer.d.ts +0 -11
- package/dist/agents/document-writer.d.ts.map +0 -1
- package/dist/agents/document-writer.js +0 -209
- package/dist/agents/document-writer.js.map +0 -1
- package/dist/agents/frontend-engineer.d.ts +0 -11
- package/dist/agents/frontend-engineer.d.ts.map +0 -1
- package/dist/agents/frontend-engineer.js +0 -115
- package/dist/agents/frontend-engineer.js.map +0 -1
- package/dist/agents/librarian.d.ts +0 -12
- package/dist/agents/librarian.d.ts.map +0 -1
- package/dist/agents/librarian.js +0 -103
- package/dist/agents/librarian.js.map +0 -1
- package/dist/agents/metis.d.ts +0 -12
- package/dist/agents/metis.d.ts.map +0 -1
- package/dist/agents/metis.js +0 -117
- package/dist/agents/metis.js.map +0 -1
- package/dist/agents/momus.d.ts +0 -12
- package/dist/agents/momus.d.ts.map +0 -1
- package/dist/agents/momus.js +0 -128
- package/dist/agents/momus.js.map +0 -1
- package/dist/agents/multimodal-looker.d.ts +0 -11
- package/dist/agents/multimodal-looker.d.ts.map +0 -1
- package/dist/agents/multimodal-looker.js +0 -70
- package/dist/agents/multimodal-looker.js.map +0 -1
- package/dist/agents/oracle.d.ts +0 -13
- package/dist/agents/oracle.d.ts.map +0 -1
- package/dist/agents/oracle.js +0 -191
- package/dist/agents/oracle.js.map +0 -1
- package/dist/agents/orchestrator-sisyphus.d.ts +0 -11
- package/dist/agents/orchestrator-sisyphus.d.ts.map +0 -1
- package/dist/agents/orchestrator-sisyphus.js +0 -115
- package/dist/agents/orchestrator-sisyphus.js.map +0 -1
- package/dist/agents/prometheus.d.ts +0 -12
- package/dist/agents/prometheus.d.ts.map +0 -1
- package/dist/agents/prometheus.js +0 -195
- package/dist/agents/prometheus.js.map +0 -1
- package/dist/agents/sisyphus-junior.d.ts +0 -12
- package/dist/agents/sisyphus-junior.d.ts.map +0 -1
- package/dist/agents/sisyphus-junior.js +0 -93
- package/dist/agents/sisyphus-junior.js.map +0 -1
- package/dist/hooks/learned-skills/config.d.ts +0 -53
- package/dist/hooks/learned-skills/config.d.ts.map +0 -1
- package/dist/hooks/learned-skills/config.js +0 -103
- package/dist/hooks/learned-skills/config.js.map +0 -1
- package/dist/hooks/learned-skills/constants.d.ts +0 -24
- package/dist/hooks/learned-skills/constants.d.ts.map +0 -1
- package/dist/hooks/learned-skills/constants.js +0 -26
- package/dist/hooks/learned-skills/constants.js.map +0 -1
- package/dist/hooks/learned-skills/detection-hook.d.ts +0 -39
- package/dist/hooks/learned-skills/detection-hook.d.ts.map +0 -1
- package/dist/hooks/learned-skills/detection-hook.js +0 -83
- package/dist/hooks/learned-skills/detection-hook.js.map +0 -1
- package/dist/hooks/learned-skills/detector.d.ts +0 -30
- package/dist/hooks/learned-skills/detector.d.ts.map +0 -1
- package/dist/hooks/learned-skills/detector.js +0 -150
- package/dist/hooks/learned-skills/detector.js.map +0 -1
- package/dist/hooks/learned-skills/finder.d.ts +0 -21
- package/dist/hooks/learned-skills/finder.d.ts.map +0 -1
- package/dist/hooks/learned-skills/finder.js +0 -117
- package/dist/hooks/learned-skills/finder.js.map +0 -1
- package/dist/hooks/learned-skills/index.d.ts +0 -62
- package/dist/hooks/learned-skills/index.d.ts.map +0 -1
- package/dist/hooks/learned-skills/index.js +0 -137
- package/dist/hooks/learned-skills/index.js.map +0 -1
- package/dist/hooks/learned-skills/loader.d.ts +0 -20
- package/dist/hooks/learned-skills/loader.d.ts.map +0 -1
- package/dist/hooks/learned-skills/loader.js +0 -107
- package/dist/hooks/learned-skills/loader.js.map +0 -1
- package/dist/hooks/learned-skills/parser.d.ts +0 -21
- package/dist/hooks/learned-skills/parser.d.ts.map +0 -1
- package/dist/hooks/learned-skills/parser.js +0 -190
- package/dist/hooks/learned-skills/parser.js.map +0 -1
- package/dist/hooks/learned-skills/promotion.d.ts +0 -29
- package/dist/hooks/learned-skills/promotion.d.ts.map +0 -1
- package/dist/hooks/learned-skills/promotion.js +0 -87
- package/dist/hooks/learned-skills/promotion.js.map +0 -1
- package/dist/hooks/learned-skills/types.d.ts +0 -109
- package/dist/hooks/learned-skills/types.d.ts.map +0 -1
- package/dist/hooks/learned-skills/types.js +0 -8
- package/dist/hooks/learned-skills/types.js.map +0 -1
- package/dist/hooks/learned-skills/validator.d.ts +0 -15
- package/dist/hooks/learned-skills/validator.d.ts.map +0 -1
- package/dist/hooks/learned-skills/validator.js +0 -87
- package/dist/hooks/learned-skills/validator.js.map +0 -1
- package/dist/hooks/learned-skills/writer.d.ts +0 -27
- package/dist/hooks/learned-skills/writer.d.ts.map +0 -1
- package/dist/hooks/learned-skills/writer.js +0 -126
- package/dist/hooks/learned-skills/writer.js.map +0 -1
- package/dist/hooks/mnemosyne/config.d.ts +0 -53
- package/dist/hooks/mnemosyne/config.d.ts.map +0 -1
- package/dist/hooks/mnemosyne/config.js +0 -103
- package/dist/hooks/mnemosyne/config.js.map +0 -1
- package/dist/hooks/mnemosyne/constants.d.ts +0 -24
- package/dist/hooks/mnemosyne/constants.d.ts.map +0 -1
- package/dist/hooks/mnemosyne/constants.js +0 -26
- package/dist/hooks/mnemosyne/constants.js.map +0 -1
- package/dist/hooks/mnemosyne/detection-hook.d.ts +0 -39
- package/dist/hooks/mnemosyne/detection-hook.d.ts.map +0 -1
- package/dist/hooks/mnemosyne/detection-hook.js +0 -83
- package/dist/hooks/mnemosyne/detection-hook.js.map +0 -1
- package/dist/hooks/mnemosyne/detector.d.ts +0 -30
- package/dist/hooks/mnemosyne/detector.d.ts.map +0 -1
- package/dist/hooks/mnemosyne/detector.js +0 -150
- package/dist/hooks/mnemosyne/detector.js.map +0 -1
- package/dist/hooks/mnemosyne/finder.d.ts +0 -21
- package/dist/hooks/mnemosyne/finder.d.ts.map +0 -1
- package/dist/hooks/mnemosyne/finder.js +0 -117
- package/dist/hooks/mnemosyne/finder.js.map +0 -1
- package/dist/hooks/mnemosyne/index.d.ts +0 -62
- package/dist/hooks/mnemosyne/index.d.ts.map +0 -1
- package/dist/hooks/mnemosyne/index.js +0 -137
- package/dist/hooks/mnemosyne/index.js.map +0 -1
- package/dist/hooks/mnemosyne/loader.d.ts +0 -20
- package/dist/hooks/mnemosyne/loader.d.ts.map +0 -1
- package/dist/hooks/mnemosyne/loader.js +0 -113
- package/dist/hooks/mnemosyne/loader.js.map +0 -1
- package/dist/hooks/mnemosyne/parser.d.ts +0 -21
- package/dist/hooks/mnemosyne/parser.d.ts.map +0 -1
- package/dist/hooks/mnemosyne/parser.js +0 -190
- package/dist/hooks/mnemosyne/parser.js.map +0 -1
- package/dist/hooks/mnemosyne/promotion.d.ts +0 -29
- package/dist/hooks/mnemosyne/promotion.d.ts.map +0 -1
- package/dist/hooks/mnemosyne/promotion.js +0 -87
- package/dist/hooks/mnemosyne/promotion.js.map +0 -1
- package/dist/hooks/mnemosyne/types.d.ts +0 -109
- package/dist/hooks/mnemosyne/types.d.ts.map +0 -1
- package/dist/hooks/mnemosyne/types.js +0 -8
- package/dist/hooks/mnemosyne/types.js.map +0 -1
- package/dist/hooks/mnemosyne/validator.d.ts +0 -15
- package/dist/hooks/mnemosyne/validator.d.ts.map +0 -1
- package/dist/hooks/mnemosyne/validator.js +0 -87
- package/dist/hooks/mnemosyne/validator.js.map +0 -1
- package/dist/hooks/mnemosyne/writer.d.ts +0 -27
- package/dist/hooks/mnemosyne/writer.d.ts.map +0 -1
- package/dist/hooks/mnemosyne/writer.js +0 -126
- package/dist/hooks/mnemosyne/writer.js.map +0 -1
- package/dist/hooks/sisyphus-orchestrator/constants.d.ts +0 -23
- package/dist/hooks/sisyphus-orchestrator/constants.d.ts.map +0 -1
- package/dist/hooks/sisyphus-orchestrator/constants.js +0 -142
- package/dist/hooks/sisyphus-orchestrator/constants.js.map +0 -1
- package/dist/hooks/sisyphus-orchestrator/index.d.ts +0 -113
- package/dist/hooks/sisyphus-orchestrator/index.d.ts.map +0 -1
- package/dist/hooks/sisyphus-orchestrator/index.js +0 -309
- package/dist/hooks/sisyphus-orchestrator/index.js.map +0 -1
- package/dist/hud/sisyphus-state.d.ts +0 -31
- package/dist/hud/sisyphus-state.d.ts.map +0 -1
- package/dist/hud/sisyphus-state.js +0 -163
- package/dist/hud/sisyphus-state.js.map +0 -1
|
@@ -1,126 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Skill Writer
|
|
3
|
-
*
|
|
4
|
-
* Writes skill files to disk with proper formatting.
|
|
5
|
-
*/
|
|
6
|
-
import { writeFileSync, existsSync } from 'fs';
|
|
7
|
-
import { join } from 'path';
|
|
8
|
-
import { ensureSkillsDir, getSkillsDir } from './finder.js';
|
|
9
|
-
import { generateSkillFrontmatter } from './parser.js';
|
|
10
|
-
import { validateExtractionRequest } from './validator.js';
|
|
11
|
-
import { DEBUG_ENABLED } from './constants.js';
|
|
12
|
-
/**
|
|
13
|
-
* Generate a unique skill ID.
|
|
14
|
-
*/
|
|
15
|
-
function generateSkillId() {
|
|
16
|
-
const timestamp = Date.now().toString(36);
|
|
17
|
-
const random = Math.random().toString(36).slice(2, 6);
|
|
18
|
-
return `skill-${timestamp}-${random}`;
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* Sanitize a string for use as filename.
|
|
22
|
-
*/
|
|
23
|
-
function sanitizeFilename(name) {
|
|
24
|
-
return name
|
|
25
|
-
.toLowerCase()
|
|
26
|
-
.replace(/[^a-z0-9]+/g, '-')
|
|
27
|
-
.replace(/^-+|-+$/g, '')
|
|
28
|
-
.slice(0, 50);
|
|
29
|
-
}
|
|
30
|
-
/**
|
|
31
|
-
* Write a new skill from extraction request.
|
|
32
|
-
*/
|
|
33
|
-
export function writeSkill(request, projectRoot, skillName) {
|
|
34
|
-
// Validate first
|
|
35
|
-
const validation = validateExtractionRequest(request);
|
|
36
|
-
if (!validation.valid) {
|
|
37
|
-
return {
|
|
38
|
-
success: false,
|
|
39
|
-
error: `Quality validation failed: ${validation.missingFields.join(', ')}`,
|
|
40
|
-
validation,
|
|
41
|
-
};
|
|
42
|
-
}
|
|
43
|
-
// Ensure directory exists
|
|
44
|
-
if (!ensureSkillsDir(request.targetScope, projectRoot || undefined)) {
|
|
45
|
-
return {
|
|
46
|
-
success: false,
|
|
47
|
-
error: `Failed to create skills directory for scope: ${request.targetScope}`,
|
|
48
|
-
validation,
|
|
49
|
-
};
|
|
50
|
-
}
|
|
51
|
-
// Generate metadata
|
|
52
|
-
const metadata = {
|
|
53
|
-
id: generateSkillId(),
|
|
54
|
-
name: skillName,
|
|
55
|
-
description: request.problem.slice(0, 200),
|
|
56
|
-
source: 'extracted',
|
|
57
|
-
createdAt: new Date().toISOString(),
|
|
58
|
-
triggers: request.triggers,
|
|
59
|
-
tags: request.tags,
|
|
60
|
-
quality: validation.score,
|
|
61
|
-
usageCount: 0,
|
|
62
|
-
};
|
|
63
|
-
// Generate content
|
|
64
|
-
const frontmatter = generateSkillFrontmatter(metadata);
|
|
65
|
-
const content = `${frontmatter}
|
|
66
|
-
|
|
67
|
-
# Problem
|
|
68
|
-
|
|
69
|
-
${request.problem}
|
|
70
|
-
|
|
71
|
-
# Solution
|
|
72
|
-
|
|
73
|
-
${request.solution}
|
|
74
|
-
`;
|
|
75
|
-
// Write to file
|
|
76
|
-
const filename = `${sanitizeFilename(skillName)}.md`;
|
|
77
|
-
const skillsDir = getSkillsDir(request.targetScope, projectRoot || undefined);
|
|
78
|
-
const filePath = join(skillsDir, filename);
|
|
79
|
-
// Check for duplicates
|
|
80
|
-
if (existsSync(filePath)) {
|
|
81
|
-
return {
|
|
82
|
-
success: false,
|
|
83
|
-
error: `Skill file already exists: ${filename}`,
|
|
84
|
-
validation,
|
|
85
|
-
};
|
|
86
|
-
}
|
|
87
|
-
try {
|
|
88
|
-
writeFileSync(filePath, content);
|
|
89
|
-
return {
|
|
90
|
-
success: true,
|
|
91
|
-
path: filePath,
|
|
92
|
-
validation,
|
|
93
|
-
};
|
|
94
|
-
}
|
|
95
|
-
catch (e) {
|
|
96
|
-
if (DEBUG_ENABLED) {
|
|
97
|
-
console.error('[mnemosyne] Error writing skill file:', e);
|
|
98
|
-
}
|
|
99
|
-
return {
|
|
100
|
-
success: false,
|
|
101
|
-
error: `Failed to write skill file: ${e}`,
|
|
102
|
-
validation,
|
|
103
|
-
};
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
/**
|
|
107
|
-
* Check if a skill with similar triggers already exists.
|
|
108
|
-
*/
|
|
109
|
-
export function checkDuplicateTriggers(triggers, projectRoot) {
|
|
110
|
-
// Import dynamically to avoid circular dependency
|
|
111
|
-
const { loadAllSkills } = require('./loader.js');
|
|
112
|
-
const skills = loadAllSkills(projectRoot);
|
|
113
|
-
const normalizedTriggers = new Set(triggers.map(t => t.toLowerCase()));
|
|
114
|
-
for (const skill of skills) {
|
|
115
|
-
const skillTriggers = skill.metadata.triggers.map((t) => t.toLowerCase());
|
|
116
|
-
const overlap = skillTriggers.filter((t) => normalizedTriggers.has(t));
|
|
117
|
-
if (overlap.length >= triggers.length * 0.5) {
|
|
118
|
-
return {
|
|
119
|
-
isDuplicate: true,
|
|
120
|
-
existingSkillId: skill.metadata.id,
|
|
121
|
-
};
|
|
122
|
-
}
|
|
123
|
-
}
|
|
124
|
-
return { isDuplicate: false };
|
|
125
|
-
}
|
|
126
|
-
//# sourceMappingURL=writer.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"writer.js","sourceRoot":"","sources":["../../../src/hooks/mnemosyne/writer.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,IAAI,CAAC;AAC/C,OAAO,EAAE,IAAI,EAAE,MAAM,MAAM,CAAC;AAC5B,OAAO,EAAE,eAAe,EAAE,YAAY,EAAE,MAAM,aAAa,C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ates and configuration for orchestrator behavior enforcement.
|
|
5
|
-
*
|
|
6
|
-
* Adapted from oh-my-opencode's sisyphus-orchestrator hook.
|
|
7
|
-
*/
|
|
8
|
-
export declare const HOOK_NAME = "sisyphus-orchestrator";
|
|
9
|
-
/** Paths that orchestrator IS allowed to modify directly */
|
|
10
|
-
export declare const ALLOWED_PATH_PREFIX = ".sisyphus/";
|
|
11
|
-
/** Tools that perform file modifications */
|
|
12
|
-
export declare const WRITE_EDIT_TOOLS: string[];
|
|
13
|
-
/** Reminder when orchestrator performs direct file work */
|
|
14
|
-
export declare const DIRECT_WORK_REMINDER = "\n\n---\n\n[SYSTEM REMINDER - DELEGATION REQUIRED]\n\nYou just performed direct file modifications outside `.sisyphus/`.\n\n**You are an ORCHESTRATOR, not an IMPLEMENTER.**\n\nAs an orchestrator, you should:\n- **DELEGATE** implementation work to subagents via the Task tool\n- **VERIFY** the work done by subagents\n- **COORDINATE** multiple tasks and ensure completion\n\nYou should NOT:\n- Write code directly (except for `.sisyphus/` files like plans and notepads)\n- Make direct file edits outside `.sisyphus/`\n- Implement features yourself\n\n**If you need to make changes:**\n1. Use the Task tool to delegate to an appropriate subagent\n2. Provide clear instructions in the prompt\n3. Verify the subagent's work after completion\n\n---\n";
|
|
15
|
-
/** Strong warning when orchestrator tries to modify source files */
|
|
16
|
-
export declare const ORCHESTRATOR_DELEGATION_REQUIRED = "\n\n---\n\n[CRITICAL SYSTEM DIRECTIVE - DELEGATION REQUIRED]\n\n**STOP. YOU ARE VIOLATING ORCHESTRATOR PROTOCOL.**\n\nYou (orchestrator-sisyphus) are attempting to directly modify a file outside `.sisyphus/`.\n\n**Path attempted:** $FILE_PATH\n\n---\n\n**THIS IS FORBIDDEN** (except for VERIFICATION purposes)\n\nAs an ORCHESTRATOR, you MUST:\n1. **DELEGATE** all implementation work via the Task tool\n2. **VERIFY** the work done by subagents (reading files is OK)\n3. **COORDINATE** - you orchestrate, you don't implement\n\n**ALLOWED direct file operations:**\n- Files inside `.sisyphus/` (plans, notepads, drafts)\n- Reading files for verification\n- Running diagnostics/tests\n\n**FORBIDDEN direct file operations:**\n- Writing/editing source code\n- Creating new files outside `.sisyphus/`\n- Any implementation work\n\n---\n\n**IF THIS IS FOR VERIFICATION:**\nProceed if you are verifying subagent work by making a small fix.\nBut for any substantial changes, USE the Task tool.\n\n**CORRECT APPROACH:**\n```\nTask tool with subagent_type=\"sisyphus-junior\"\nprompt=\"[specific single task with clear acceptance criteria]\"\n```\n\nDELEGATE. DON'T IMPLEMENT.\n\n---\n";
|
|
17
|
-
/** Continuation prompt for boulder state */
|
|
18
|
-
export declare const BOULDER_CONTINUATION_PROMPT = "[SYSTEM REMINDER - BOULDER CONTINUATION]\n\nYou have an active work plan with incomplete tasks. Continue working.\n\nRULES:\n- Proceed without asking for permission\n- Mark each checkbox [x] in the plan file when done\n- Use the notepad at .sisyphus/notepads/{PLAN_NAME}/ to record learnings\n- Do not stop until all tasks are complete\n- If blocked, document the blocker and move to the next task";
|
|
19
|
-
/** Verification reminder for subagent work */
|
|
20
|
-
export declare const VERIFICATION_REMINDER = "**MANDATORY VERIFICATION - SUBAGENTS LIE**\n\nSubagents FREQUENTLY claim completion when:\n- Tests are actually FAILING\n- Code has type/lint ERRORS\n- Implementation is INCOMPLETE\n- Patterns were NOT followed\n\n**YOU MUST VERIFY EVERYTHING YOURSELF:**\n\n1. Run tests yourself - Must PASS (not \"agent said it passed\")\n2. Read the actual code - Must match requirements\n3. Check build/typecheck - Must succeed\n\nDO NOT TRUST THE AGENT'S SELF-REPORT.\nVERIFY EACH CLAIM WITH YOUR OWN TOOL CALLS.";
|
|
21
|
-
/** Directive for subagents to refuse multi-task requests */
|
|
22
|
-
export declare const SINGLE_TASK_DIRECTIVE = "\n\n[SYSTEM DIRECTIVE - SINGLE TASK ONLY]\n\n**STOP. READ THIS BEFORE PROCEEDING.**\n\nIf you were NOT given **exactly ONE atomic task**, you MUST:\n1. **IMMEDIATELY REFUSE** this request\n2. **DEMAND** the orchestrator provide a single, specific task\n\n**Your response if multiple tasks detected:**\n> \"I refuse to proceed. You provided multiple tasks. An orchestrator's impatience destroys work quality.\n>\n> PROVIDE EXACTLY ONE TASK. One file. One change. One verification.\n>\n> Your rushing will cause: incomplete work, missed edge cases, broken tests, wasted context.\"\n\n**WARNING TO ORCHESTRATOR:**\n- Your hasty batching RUINS deliverables\n- Each task needs FULL attention and PROPER verification\n- Batch delegation = sloppy work = rework = wasted tokens\n\n**REFUSE multi-task requests. DEMAND single-task clarity.**\n";
|
|
23
|
-
//# sourceMappingURL=constants.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../src/hooks/sisyphus-orchestrator/constants.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,eAAO,MAAM,SAAS,0BAA0B,CAAC;AAEjD,4DAA4D;AAC5D,eAAO,MAAM,mBAAmB,eAAe,CAAC;AAEhD,4CAA4C;AAC5C,eAAO,MAAM,gBAAgB,UAAqC,CAAC;AAEnE,2DAA2D;AAC3D,eAAO,MAAM,oBAAoB,8uBA0BhC,CAAC;AAEF,oEAAoE;AACpE,eAAO,MAAM,gCAAgC,4pCA8C5C,CAAC;AAEF,4CAA4C;AAC5C,eAAO,MAAM,2BAA2B,kZASqB,CAAC;AAE9D,8CAA8C;AAC9C,eAAO,MAAM,qBAAqB,yfAeU,CAAC;AAE7C,4DAA4D;AAC5D,eAAO,MAAM,qBAAqB,u0BAuBjC,CAAC"}
|
|
@@ -1,142 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Sisyphus Orchestrator Constants
|
|
3
|
-
*
|
|
4
|
-
* Message templates and configuration for orchestrator behavior enforcement.
|
|
5
|
-
*
|
|
6
|
-
* Adapted from oh-my-opencode's sisyphus-orchestrator hook.
|
|
7
|
-
*/
|
|
8
|
-
export const HOOK_NAME = 'sisyphus-orchestrator';
|
|
9
|
-
/** Paths that orchestrator IS allowed to modify directly */
|
|
10
|
-
export const ALLOWED_PATH_PREFIX = '.sisyphus/';
|
|
11
|
-
/** Tools that perform file modifications */
|
|
12
|
-
export const WRITE_EDIT_TOOLS = ['Write', 'Edit', 'write', 'edit'];
|
|
13
|
-
/** Reminder when orchestrator performs direct file work */
|
|
14
|
-
export const DIRECT_WORK_REMINDER = `
|
|
15
|
-
|
|
16
|
-
---
|
|
17
|
-
|
|
18
|
-
[SYSTEM REMINDER - DELEGATION REQUIRED]
|
|
19
|
-
|
|
20
|
-
You just performed direct file modifications outside \`.sisyphus/\`.
|
|
21
|
-
|
|
22
|
-
**You are an ORCHESTRATOR, not an IMPLEMENTER.**
|
|
23
|
-
|
|
24
|
-
As an orchestrator, you should:
|
|
25
|
-
- **DELEGATE** implementation work to subagents via the Task tool
|
|
26
|
-
- **VERIFY** the work done by subagents
|
|
27
|
-
- **COORDINATE** multiple tasks and ensure completion
|
|
28
|
-
|
|
29
|
-
You should NOT:
|
|
30
|
-
- Write code directly (except for \`.sisyphus/\` files like plans and notepads)
|
|
31
|
-
- Make direct file edits outside \`.sisyphus/\`
|
|
32
|
-
- Implement features yourself
|
|
33
|
-
|
|
34
|
-
**If you need to make changes:**
|
|
35
|
-
1. Use the Task tool to delegate to an appropriate subagent
|
|
36
|
-
2. Provide clear instructions in the prompt
|
|
37
|
-
3. Verify the subagent's work after completion
|
|
38
|
-
|
|
39
|
-
---
|
|
40
|
-
`;
|
|
41
|
-
/** Strong warning when orchestrator tries to modify source files */
|
|
42
|
-
export const ORCHESTRATOR_DELEGATION_REQUIRED = `
|
|
43
|
-
|
|
44
|
-
---
|
|
45
|
-
|
|
46
|
-
[CRITICAL SYSTEM DIRECTIVE - DELEGATION REQUIRED]
|
|
47
|
-
|
|
48
|
-
**STOP. YOU ARE VIOLATING ORCHESTRATOR PROTOCOL.**
|
|
49
|
-
|
|
50
|
-
You (orchestrator-sisyphus) are attempting to directly modify a file outside \`.sisyphus/\`.
|
|
51
|
-
|
|
52
|
-
**Path attempted:** $FILE_PATH
|
|
53
|
-
|
|
54
|
-
---
|
|
55
|
-
|
|
56
|
-
**THIS IS FORBIDDEN** (except for VERIFICATION purposes)
|
|
57
|
-
|
|
58
|
-
As an ORCHESTRATOR, you MUST:
|
|
59
|
-
1. **DELEGATE** all implementation work via the Task tool
|
|
60
|
-
2. **VERIFY** the work done by subagents (reading files is OK)
|
|
61
|
-
3. **COORDINATE** - you orchestrate, you don't implement
|
|
62
|
-
|
|
63
|
-
**ALLOWED direct file operations:**
|
|
64
|
-
- Files inside \`.sisyphus/\` (plans, notepads, drafts)
|
|
65
|
-
- Reading files for verification
|
|
66
|
-
- Running diagnostics/tests
|
|
67
|
-
|
|
68
|
-
**FORBIDDEN direct file operations:**
|
|
69
|
-
- Writing/editing source code
|
|
70
|
-
- Creating new files outside \`.sisyphus/\`
|
|
71
|
-
- Any implementation work
|
|
72
|
-
|
|
73
|
-
---
|
|
74
|
-
|
|
75
|
-
**IF THIS IS FOR VERIFICATION:**
|
|
76
|
-
Proceed if you are verifying subagent work by making a small fix.
|
|
77
|
-
But for any substantial changes, USE the Task tool.
|
|
78
|
-
|
|
79
|
-
**CORRECT APPROACH:**
|
|
80
|
-
\`\`\`
|
|
81
|
-
Task tool with subagent_type="sisyphus-junior"
|
|
82
|
-
prompt="[specific single task with clear acceptance criteria]"
|
|
83
|
-
\`\`\`
|
|
84
|
-
|
|
85
|
-
DELEGATE. DON'T IMPLEMENT.
|
|
86
|
-
|
|
87
|
-
---
|
|
88
|
-
`;
|
|
89
|
-
/** Continuation prompt for boulder state */
|
|
90
|
-
export const BOULDER_CONTINUATION_PROMPT = `[SYSTEM REMINDER - BOULDER CONTINUATION]
|
|
91
|
-
|
|
92
|
-
You have an active work plan with incomplete tasks. Continue working.
|
|
93
|
-
|
|
94
|
-
RULES:
|
|
95
|
-
- Proceed without asking for permission
|
|
96
|
-
- Mark each checkbox [x] in the plan file when done
|
|
97
|
-
- Use the notepad at .sisyphus/notepads/{PLAN_NAME}/ to record learnings
|
|
98
|
-
- Do not stop until all tasks are complete
|
|
99
|
-
- If blocked, document the blocker and move to the next task`;
|
|
100
|
-
/** Verification reminder for subagent work */
|
|
101
|
-
export const VERIFICATION_REMINDER = `**MANDATORY VERIFICATION - SUBAGENTS LIE**
|
|
102
|
-
|
|
103
|
-
Subagents FREQUENTLY claim completion when:
|
|
104
|
-
- Tests are actually FAILING
|
|
105
|
-
- Code has type/lint ERRORS
|
|
106
|
-
- Implementation is INCOMPLETE
|
|
107
|
-
- Patterns were NOT followed
|
|
108
|
-
|
|
109
|
-
**YOU MUST VERIFY EVERYTHING YOURSELF:**
|
|
110
|
-
|
|
111
|
-
1. Run tests yourself - Must PASS (not "agent said it passed")
|
|
112
|
-
2. Read the actual code - Must match requirements
|
|
113
|
-
3. Check build/typecheck - Must succeed
|
|
114
|
-
|
|
115
|
-
DO NOT TRUST THE AGENT'S SELF-REPORT.
|
|
116
|
-
VERIFY EACH CLAIM WITH YOUR OWN TOOL CALLS.`;
|
|
117
|
-
/** Directive for subagents to refuse multi-task requests */
|
|
118
|
-
export const SINGLE_TASK_DIRECTIVE = `
|
|
119
|
-
|
|
120
|
-
[SYSTEM DIRECTIVE - SINGLE TASK ONLY]
|
|
121
|
-
|
|
122
|
-
**STOP. READ THIS BEFORE PROCEEDING.**
|
|
123
|
-
|
|
124
|
-
If you were NOT given **exactly ONE atomic task**, you MUST:
|
|
125
|
-
1. **IMMEDIATELY REFUSE** this request
|
|
126
|
-
2. **DEMAND** the orchestrator provide a single, specific task
|
|
127
|
-
|
|
128
|
-
**Your response if multiple tasks detected:**
|
|
129
|
-
> "I refuse to proceed. You provided multiple tasks. An orchestrator's impatience destroys work quality.
|
|
130
|
-
>
|
|
131
|
-
> PROVIDE EXACTLY ONE TASK. One file. One change. One verification.
|
|
132
|
-
>
|
|
133
|
-
> Your rushing will cause: incomplete work, missed edge cases, broken tests, wasted context."
|
|
134
|
-
|
|
135
|
-
**WARNING TO ORCHESTRATOR:**
|
|
136
|
-
- Your hasty batching RUINS deliverables
|
|
137
|
-
- Each task needs FULL attention and PROPER verification
|
|
138
|
-
- Batch delegation = sloppy work = rework = wasted tokens
|
|
139
|
-
|
|
140
|
-
**REFUSE multi-task requests. DEMAND single-task clarity.**
|
|
141
|
-
`;
|
|
142
|
-
//# sourceMappingURL=constants.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../../src/hooks/sisyphus-orchestrator/constants.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,MAAM,CAAC,MAAM,SAAS,GAAG,uBAAuB,CAAC;AAEjD,4DAA4D;AAC5D,MAAM,CAAC,MAAM,mBAAmB,GAAG,YAAY,CAAC;AAEhD,4CAA4C;AAC5C,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAAC,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;AAEnE,2DAA2D;AAC3D,MAAM,CAAC,MAAM,oBAAoB,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;CA0BnC,CAAC;AAEF,oEAAoE;AACpE,MAAM,CAAC,MAAM,gCAAgC,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA8C/C,CAAC;AAEF,4CAA4C;AAC5C,MAAM,CAAC,MAAM,2BAA2B,GAAG;;;;;;;;;6DASkB,CAAC;AAE9D,8CAA8C;AAC9C,MAAM,CAAC,MAAM,qBAAqB,GAAG;;;;;;;;;;;;;;;4CAeO,CAAC;AAE7C,4DAA4D;AAC5D,MAAM,CAAC,MAAM,qBAAqB,GAAG;;;;;;;;;;;;;;;;;;;;;;;CAuBpC,CAAC"}
|
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Sisyphus Orchestrator Hook
|
|
3
|
-
*
|
|
4
|
-
* Enforces orchestrator behavior - delegation over direct implementation.
|
|
5
|
-
* When an orchestrator agent tries to directly modify files outside .sisyphus/,
|
|
6
|
-
* this hook injects reminders to delegate to subagents instead.
|
|
7
|
-
*
|
|
8
|
-
* Adapted from oh-my-opencode's sisyphus-orchestrator hook for shell-based hooks.
|
|
9
|
-
*/
|
|
10
|
-
export * from './constants.js';
|
|
11
|
-
/**
|
|
12
|
-
* Input for tool execution hooks
|
|
13
|
-
*/
|
|
14
|
-
export interface ToolExecuteInput {
|
|
15
|
-
toolName: string;
|
|
16
|
-
toolInput?: Record<string, unknown>;
|
|
17
|
-
sessionId?: string;
|
|
18
|
-
directory?: string;
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* Output for tool execution hooks
|
|
22
|
-
*/
|
|
23
|
-
export interface ToolExecuteOutput {
|
|
24
|
-
continue: boolean;
|
|
25
|
-
message?: string;
|
|
26
|
-
modifiedOutput?: string;
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
* Git file change statistics
|
|
30
|
-
*/
|
|
31
|
-
interface GitFileStat {
|
|
32
|
-
path: string;
|
|
33
|
-
added: number;
|
|
34
|
-
removed: number;
|
|
35
|
-
status: 'modified' | 'added' | 'deleted';
|
|
36
|
-
}
|
|
37
|
-
/**
|
|
38
|
-
* Check if a file path is allowed for direct orchestrator modification
|
|
39
|
-
*/
|
|
40
|
-
export declare function isAllowedPath(filePath: string): boolean;
|
|
41
|
-
/**
|
|
42
|
-
* Check if a tool is a write/edit tool
|
|
43
|
-
*/
|
|
44
|
-
export declare function isWriteEditTool(toolName: string): boolean;
|
|
45
|
-
/**
|
|
46
|
-
* Get git diff statistics for the working directory
|
|
47
|
-
*/
|
|
48
|
-
export declare function getGitDiffStats(directory: string): GitFileStat[];
|
|
49
|
-
/**
|
|
50
|
-
* Format file changes for display
|
|
51
|
-
*/
|
|
52
|
-
export declare function formatFileChanges(stats: GitFileStat[]): string;
|
|
53
|
-
/**
|
|
54
|
-
* Build verification reminder with session context
|
|
55
|
-
*/
|
|
56
|
-
export declare function buildVerificationReminder(sessionId?: string): string;
|
|
57
|
-
/**
|
|
58
|
-
* Build orchestrator reminder with plan progress
|
|
59
|
-
*/
|
|
60
|
-
export declare function buildOrchestratorReminder(planName: string, progress: {
|
|
61
|
-
total: number;
|
|
62
|
-
completed: number;
|
|
63
|
-
}, sessionId?: string): string;
|
|
64
|
-
/**
|
|
65
|
-
* Build boulder continuation message
|
|
66
|
-
*/
|
|
67
|
-
export declare function buildBoulderContinuation(planName: string, remaining: number, total: number): string;
|
|
68
|
-
/**
|
|
69
|
-
* Process pre-tool-use hook for orchestrator
|
|
70
|
-
* Returns warning message if orchestrator tries to modify non-allowed paths
|
|
71
|
-
*/
|
|
72
|
-
export declare function processOrchestratorPreTool(input: ToolExecuteInput): ToolExecuteOutput;
|
|
73
|
-
/**
|
|
74
|
-
* Process post-tool-use hook for orchestrator
|
|
75
|
-
* Adds reminders after file modifications and Task delegations
|
|
76
|
-
*/
|
|
77
|
-
export declare function processOrchestratorPostTool(input: ToolExecuteInput, output: string): ToolExecuteOutput;
|
|
78
|
-
/**
|
|
79
|
-
* Check if boulder has incomplete tasks and build continuation prompt
|
|
80
|
-
*/
|
|
81
|
-
export declare function checkBoulderContinuation(directory: string): {
|
|
82
|
-
shouldContinue: boolean;
|
|
83
|
-
message?: string;
|
|
84
|
-
};
|
|
85
|
-
/**
|
|
86
|
-
* Create sisyphus orchestrator hook handlers
|
|
87
|
-
*/
|
|
88
|
-
export declare function createSisyphusOrchestratorHook(directory: string): {
|
|
89
|
-
/**
|
|
90
|
-
* Hook name identifier
|
|
91
|
-
*/
|
|
92
|
-
name: string;
|
|
93
|
-
/**
|
|
94
|
-
* Pre-tool execution handler
|
|
95
|
-
*/
|
|
96
|
-
preTool: (toolName: string, toolInput: Record<string, unknown>) => ToolExecuteOutput;
|
|
97
|
-
/**
|
|
98
|
-
* Post-tool execution handler
|
|
99
|
-
*/
|
|
100
|
-
postTool: (toolName: string, toolInput: Record<string, unknown>, output: string) => ToolExecuteOutput;
|
|
101
|
-
/**
|
|
102
|
-
* Check for boulder continuation on session idle
|
|
103
|
-
*/
|
|
104
|
-
checkContinuation: () => {
|
|
105
|
-
shouldContinue: boolean;
|
|
106
|
-
message?: string;
|
|
107
|
-
};
|
|
108
|
-
/**
|
|
109
|
-
* Get single task directive for subagent prompts
|
|
110
|
-
*/
|
|
111
|
-
getSingleTaskDirective: () => string;
|
|
112
|
-
};
|
|
113
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/hooks/sisyphus-orchestrator/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAuBH,cAAc,gBAAgB,CAAC;AAE/B;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACpC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,QAAQ,EAAE,OAAO,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED;;GAEG;AACH,UAAU,WAAW;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,UAAU,GAAG,OAAO,GAAG,SAAS,CAAC;CAC1C;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAGvD;AAED;;GAEG;AACH,wBAAgB,eAAe,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAEzD;AAED;;GAEG;AACH,wBAAgB,eAAe,CAAC,SAAS,EAAE,MAAM,GAAG,WAAW,EAAE,CAmDhE;AAED;;GAEG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,WAAW,E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