zelari-code 0.7.9 → 0.7.11
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/LICENSE +37 -37
- package/README.md +320 -295
- package/bin/zelari-code.js +62 -62
- package/dist/cli/app.js +33 -3
- package/dist/cli/app.js.map +1 -1
- package/dist/cli/components/LiveRegion.js +7 -3
- package/dist/cli/components/LiveRegion.js.map +1 -1
- package/dist/cli/components/SelectList.js +67 -0
- package/dist/cli/components/SelectList.js.map +1 -0
- package/dist/cli/components/Spinner.js +51 -0
- package/dist/cli/components/Spinner.js.map +1 -0
- package/dist/cli/components/SplashScreen.js +85 -85
- package/dist/cli/components/StatusBar.js +42 -34
- package/dist/cli/components/StatusBar.js.map +1 -1
- package/dist/cli/headless.js +10 -10
- package/dist/cli/hooks/useSlashDispatch.js +11 -1
- package/dist/cli/hooks/useSlashDispatch.js.map +1 -1
- package/dist/cli/keyStore.js +2 -2
- package/dist/cli/keyStore.js.map +1 -1
- package/dist/cli/main.bundled.js +15146 -14919
- package/dist/cli/main.bundled.js.map +4 -4
- package/dist/cli/main.js +1 -1
- package/dist/cli/main.js.map +1 -1
- package/dist/cli/modelDiscovery.js +42 -5
- package/dist/cli/modelDiscovery.js.map +1 -1
- package/dist/cli/provider/openai-compatible.js +4 -2
- package/dist/cli/provider/openai-compatible.js.map +1 -1
- package/dist/cli/slashCommands.js +22 -5
- package/dist/cli/slashCommands.js.map +1 -1
- package/dist/cli/slashHandlers/provider.js +102 -5
- package/dist/cli/slashHandlers/provider.js.map +1 -1
- package/package.json +2 -2
- package/dist/agents/advancedTools.js +0 -115
- package/dist/agents/advancedTools.js.map +0 -1
- package/dist/agents/councilApi.js +0 -375
- package/dist/agents/councilApi.js.map +0 -1
- package/dist/agents/councilDirectives.js +0 -100
- package/dist/agents/councilDirectives.js.map +0 -1
- package/dist/agents/promoteMember.js +0 -210
- package/dist/agents/promoteMember.js.map +0 -1
- package/dist/agents/promptModules.js +0 -139
- package/dist/agents/promptModules.js.map +0 -1
- package/dist/agents/roles.js +0 -299
- package/dist/agents/roles.js.map +0 -1
- package/dist/agents/skills/builtin/debugging.js +0 -248
- package/dist/agents/skills/builtin/debugging.js.map +0 -1
- package/dist/agents/skills/builtin/docs.js +0 -301
- package/dist/agents/skills/builtin/docs.js.map +0 -1
- package/dist/agents/skills/builtin/git-ops.js +0 -301
- package/dist/agents/skills/builtin/git-ops.js.map +0 -1
- package/dist/agents/skills/builtin/planning.js +0 -335
- package/dist/agents/skills/builtin/planning.js.map +0 -1
- package/dist/agents/skills/builtin/refactoring.js +0 -261
- package/dist/agents/skills/builtin/refactoring.js.map +0 -1
- package/dist/agents/skills/builtin/review.js +0 -302
- package/dist/agents/skills/builtin/review.js.map +0 -1
- package/dist/agents/skills/builtin/testing.js +0 -245
- package/dist/agents/skills/builtin/testing.js.map +0 -1
- package/dist/agents/skills.js +0 -272
- package/dist/agents/skills.js.map +0 -1
- package/dist/agents/systemPromptBuilder.js +0 -151
- package/dist/agents/systemPromptBuilder.js.map +0 -1
- package/dist/agents/toolSchemas.js +0 -249
- package/dist/agents/toolSchemas.js.map +0 -1
- package/dist/agents/tools.js +0 -196
- package/dist/agents/tools.js.map +0 -1
- package/dist/agents/vaultTools.js +0 -134
- package/dist/agents/vaultTools.js.map +0 -1
- package/dist/cli/components/CollapsibleToolOutput.js +0 -43
- package/dist/cli/components/CollapsibleToolOutput.js.map +0 -1
- package/dist/cli/components/Header.js +0 -38
- package/dist/cli/components/Header.js.map +0 -1
- package/dist/main/core/AgentHarness.js +0 -467
- package/dist/main/core/AgentHarness.js.map +0 -1
- package/dist/main/core/providerStream.js +0 -99
- package/dist/main/core/providerStream.js.map +0 -1
- package/dist/main/core/sessionJsonl.js +0 -99
- package/dist/main/core/sessionJsonl.js.map +0 -1
- package/dist/main/core/tools/auditLog.js +0 -26
- package/dist/main/core/tools/auditLog.js.map +0 -1
- package/dist/main/core/tools/builtin/filesystem.js +0 -110
- package/dist/main/core/tools/builtin/filesystem.js.map +0 -1
- package/dist/main/core/tools/builtin/listFiles.js +0 -86
- package/dist/main/core/tools/builtin/listFiles.js.map +0 -1
- package/dist/main/core/tools/builtin/search.js +0 -56
- package/dist/main/core/tools/builtin/search.js.map +0 -1
- package/dist/main/core/tools/builtin/shell.js +0 -51
- package/dist/main/core/tools/builtin/shell.js.map +0 -1
- package/dist/main/core/tools/registry.js +0 -71
- package/dist/main/core/tools/registry.js.map +0 -1
- package/dist/main/core/tools/toolTypes.js +0 -8
- package/dist/main/core/tools/toolTypes.js.map +0 -1
- package/dist/main/core/tools/zodBridge.js +0 -56
- package/dist/main/core/tools/zodBridge.js.map +0 -1
- package/dist/shared/eventBus.js +0 -104
- package/dist/shared/eventBus.js.map +0 -1
- package/dist/shared/events.js +0 -73
- package/dist/shared/events.js.map +0 -1
- package/dist/shared/index.js +0 -8
- package/dist/shared/index.js.map +0 -1
- package/dist/types/context.js +0 -3
- package/dist/types/context.js.map +0 -1
- package/dist/types/index.js +0 -2
- package/dist/types/index.js.map +0 -1
- package/dist/types/knowledge.js +0 -2
- package/dist/types/knowledge.js.map +0 -1
- package/dist/types/systemTypes.js +0 -10
- package/dist/types/systemTypes.js.map +0 -1
|
@@ -1,245 +0,0 @@
|
|
|
1
|
-
import { registerCodingSkill } from '../../skills.js';
|
|
2
|
-
const CLARIFICATION_PROTOCOL = `
|
|
3
|
-
|
|
4
|
-
WHEN TO ASK THE USER (clarification):
|
|
5
|
-
If a single missing fact would materially change your output (target platform, scope, a binary design choice with significant trade-offs, a constraint you cannot safely assume), pause and ask the user by appending EXACTLY this block at the end of your message:
|
|
6
|
-
|
|
7
|
-
---QUESTION---
|
|
8
|
-
{ "question": "One focused question", "choices": ["Option A", "Option B", "Option C"], "context": "Why this matters" }
|
|
9
|
-
---END---
|
|
10
|
-
|
|
11
|
-
Rules for clarifications:
|
|
12
|
-
- Ask AT MOST ONE question per turn, and only when genuinely blocked.
|
|
13
|
-
- Prefer a small set of concrete "choices" (2-4). The user can still type a custom answer.
|
|
14
|
-
- Do NOT ask for information that could be reasonably assumed or already in shared context.
|
|
15
|
-
- If you can proceed with a sound documented assumption, DO SO instead of asking.`;
|
|
16
|
-
const writeUnitTests = {
|
|
17
|
-
id: 'write-unit-tests',
|
|
18
|
-
version: '1.0.0',
|
|
19
|
-
name: 'Write Unit Tests',
|
|
20
|
-
description: 'TDD-style test generation for a function or module. Output: 5-10 focused unit tests covering happy paths, edge cases (empty/null/boundary), error paths. Each test has one assertion. Uses Vitest patterns (the project standard).',
|
|
21
|
-
category: 'test',
|
|
22
|
-
requiredRoles: ['oracle', 'atlas'],
|
|
23
|
-
requiredTools: ['read_file'],
|
|
24
|
-
estimatedCost: 'medium',
|
|
25
|
-
enabledByDefault: true,
|
|
26
|
-
builtin: true,
|
|
27
|
-
triggers: [
|
|
28
|
-
'A function or module has no tests',
|
|
29
|
-
'Coverage report shows a specific function is untested',
|
|
30
|
-
'A new utility is added (helper, formatter, validator)',
|
|
31
|
-
'A bug is fixed and a regression test is needed',
|
|
32
|
-
],
|
|
33
|
-
antiPatterns: [
|
|
34
|
-
'Integration scenarios (multi-component) — use write-integration-tests',
|
|
35
|
-
'A bug report exists — use regression-test instead (more focused)',
|
|
36
|
-
'Performance benchmarks — those need write-bench-test, not unit tests',
|
|
37
|
-
],
|
|
38
|
-
requires: [],
|
|
39
|
-
relatedSkills: ['regression-test', 'test-coverage-analysis'],
|
|
40
|
-
tags: ['test', 'unit-test', 'tdd', 'vitest', 'coverage'],
|
|
41
|
-
examples: [
|
|
42
|
-
{
|
|
43
|
-
input: 'Write unit tests for src/lib/formatDuration.ts',
|
|
44
|
-
output: {
|
|
45
|
-
testFile: 'tests/unit/formatDuration.test.ts',
|
|
46
|
-
tests: [
|
|
47
|
-
{ name: 'formats 0 ms as "0s"', input: 0, expected: '0s' },
|
|
48
|
-
{ name: 'formats 45 seconds as "45s"', input: 45000, expected: '45s' },
|
|
49
|
-
{ name: 'formats 1 minute as "1m"', input: 60000, expected: '1m' },
|
|
50
|
-
{ name: 'formats 1h 23m for long duration', input: 4980000, expected: '1h 23m' },
|
|
51
|
-
{ name: 'formats 2d for >24h', input: 172800000, expected: '2d' },
|
|
52
|
-
{ name: 'throws on negative duration', input: -1000, expectedThrows: 'Negative duration' },
|
|
53
|
-
{ name: 'throws on NaN', input: NaN, expectedThrows: 'NaN duration' },
|
|
54
|
-
{ name: 'respects compact style option', input: 60000, options: { style: 'compact' }, expected: '1m' },
|
|
55
|
-
],
|
|
56
|
-
},
|
|
57
|
-
},
|
|
58
|
-
],
|
|
59
|
-
outputSchema: '{ testFile: string; tests: Array<{ name: string; input: unknown; expected?: unknown; options?: Record<string, unknown>; expectedThrows?: string }> }',
|
|
60
|
-
systemPromptFragment: `You are writing Vitest unit tests for a function or module.
|
|
61
|
-
|
|
62
|
-
## Methodology
|
|
63
|
-
1. **Read the source**: understand the function signature, branches, error paths.
|
|
64
|
-
2. **Identify happy paths**: at least 2 tests for typical inputs.
|
|
65
|
-
3. **Identify edge cases** (boundaries): 0, 1, max, empty array, empty string.
|
|
66
|
-
4. **Identify error paths**: invalid input, network errors, partial data.
|
|
67
|
-
5. **Write one test per assertion** — easier to debug when a test fails.
|
|
68
|
-
6. **Use Vitest patterns**: describe/it/expect, vi.fn() for mocks, vi.spyOn for stubs.
|
|
69
|
-
|
|
70
|
-
## Test naming
|
|
71
|
-
- Use \`describe('moduleName', () => { it('does X when Y', ...) })\`.
|
|
72
|
-
- Test name describes behavior, not implementation.
|
|
73
|
-
- Group related tests in the same describe block.
|
|
74
|
-
|
|
75
|
-
## Output format (JSON-typed)
|
|
76
|
-
- testFile: string (the file path)
|
|
77
|
-
- tests: Array<{ name, input, expected, options?, expectedThrows? }>
|
|
78
|
-
|
|
79
|
-
## Anti-patterns to avoid
|
|
80
|
-
- Tests that always pass (tautologies)
|
|
81
|
-
- Tests with multiple assertions (split into separate tests)
|
|
82
|
-
- Tests that depend on test execution order
|
|
83
|
-
- Snapshot tests for non-deterministic output
|
|
84
|
-
|
|
85
|
-
Stay under 500 words.${CLARIFICATION_PROTOCOL}`,
|
|
86
|
-
};
|
|
87
|
-
const writeIntegrationTests = {
|
|
88
|
-
id: 'write-integration-tests',
|
|
89
|
-
version: '1.0.0',
|
|
90
|
-
name: 'Write Integration Tests',
|
|
91
|
-
description: 'Generate end-to-end scenario tests that span multiple components. Tests verify the integration boundary, not individual units. Uses real subsystems (or close mocks) to catch contract mismatches.',
|
|
92
|
-
category: 'test',
|
|
93
|
-
requiredRoles: ['oracle', 'hephaestus'],
|
|
94
|
-
requiredTools: ['read_file', 'grep_content'],
|
|
95
|
-
estimatedCost: 'medium',
|
|
96
|
-
enabledByDefault: true,
|
|
97
|
-
builtin: true,
|
|
98
|
-
triggers: [
|
|
99
|
-
'A new feature spans 2+ modules',
|
|
100
|
-
'A new API endpoint needs end-to-end coverage',
|
|
101
|
-
'A refactor changes module boundaries — verify behavior preserved',
|
|
102
|
-
'A bug was caused by a contract mismatch between two modules',
|
|
103
|
-
],
|
|
104
|
-
antiPatterns: [
|
|
105
|
-
'Single-component logic — use write-unit-tests',
|
|
106
|
-
'Performance benchmarks — use a dedicated perf test',
|
|
107
|
-
'Visual regression (UI snapshot) — needs screenshot diff tooling',
|
|
108
|
-
],
|
|
109
|
-
requires: ['write-unit-tests'],
|
|
110
|
-
relatedSkills: ['write-unit-tests', 'regression-test'],
|
|
111
|
-
tags: ['test', 'integration', 'e2e', 'contract', 'multi-component'],
|
|
112
|
-
examples: [
|
|
113
|
-
{
|
|
114
|
-
input: 'Integration test for "user uploads file → RAG indexes → user queries"',
|
|
115
|
-
output: {
|
|
116
|
-
testFile: 'tests/integration/upload-query.test.ts',
|
|
117
|
-
scenarios: [
|
|
118
|
-
{ name: 'uploaded file appears in search results within 5s', steps: ['create test vault', 'upload doc.md', 'wait 1s for indexer', 'query "doc.md"', 'expect result'] },
|
|
119
|
-
{ name: 'deleted file removed from search results', steps: ['upload + query (sanity)', 'delete file', 'wait 1s', 'query', 'expect no result'] },
|
|
120
|
-
{ name: 'concurrent uploads maintain ordering', steps: ['upload 10 files in parallel', 'query each', 'expect all 10 found'] },
|
|
121
|
-
{ name: 'corrupt file (binary garbage) does not crash indexer', steps: ['upload binary garbage', 'wait 5s', 'expect vault accessible (no crash)'] },
|
|
122
|
-
],
|
|
123
|
-
contracts: [
|
|
124
|
-
{ between: 'vault + indexer', contract: 'indexer subscribes to vault:created events and processes new files within 5s' },
|
|
125
|
-
{ between: 'indexer + search', contract: 'search returns docs only after indexer has flushed their embeddings to SQLite' },
|
|
126
|
-
],
|
|
127
|
-
},
|
|
128
|
-
},
|
|
129
|
-
],
|
|
130
|
-
outputSchema: '{ testFile: string; scenarios: Array<{ name: string; steps: string[] }>; contracts: Array<{ between: string; contract: string }> }',
|
|
131
|
-
systemPromptFragment: `You are writing integration tests that span multiple components.
|
|
132
|
-
|
|
133
|
-
## Methodology
|
|
134
|
-
1. **Identify the integration boundary**: which 2+ components interact?
|
|
135
|
-
2. **Document the contract**: what does component A promise to component B?
|
|
136
|
-
3. **Test the contract, not the internals**: verify the OBSERVABLE behavior, not the implementation.
|
|
137
|
-
4. **Use real subsystems where possible**: in-memory SQLite instead of mocks; fake HTTP server instead of stubbed client.
|
|
138
|
-
5. **Each scenario is a complete user story**: setup → action → verify.
|
|
139
|
-
|
|
140
|
-
## Output format (JSON-typed)
|
|
141
|
-
- testFile: string
|
|
142
|
-
- scenarios: Array<{ name, steps[] }>
|
|
143
|
-
- contracts: Array<{ between, contract }>
|
|
144
|
-
|
|
145
|
-
## Integration test principles
|
|
146
|
-
- **Minimal mocks**: mock only the OUTSIDE world (network, disk, time), not your own code
|
|
147
|
-
- **Real data**: use realistic test data, not "foo" / "bar"
|
|
148
|
-
- **Deterministic**: avoid timing-based assertions (use polling with timeout)
|
|
149
|
-
- **Cleanup**: each scenario should leave the system in a clean state
|
|
150
|
-
|
|
151
|
-
Stay under 500 words.${CLARIFICATION_PROTOCOL}`,
|
|
152
|
-
};
|
|
153
|
-
const regressionTest = {
|
|
154
|
-
id: 'regression-test',
|
|
155
|
-
version: '1.0.0',
|
|
156
|
-
name: 'Regression Test',
|
|
157
|
-
description: 'Convert a bug report into a permanent regression test. The test must fail on the BUGGY code (pre-fix), pass on the FIXED code (post-fix), and stay in the suite forever to prevent the bug from coming back.',
|
|
158
|
-
category: 'test',
|
|
159
|
-
requiredRoles: ['oracle'],
|
|
160
|
-
requiredTools: ['write_file'],
|
|
161
|
-
estimatedCost: 'low',
|
|
162
|
-
enabledByDefault: true,
|
|
163
|
-
builtin: true,
|
|
164
|
-
triggers: [
|
|
165
|
-
'A bug is fixed and a regression test is needed',
|
|
166
|
-
'A user reports a recurring bug ("this used to work")',
|
|
167
|
-
'A flaky test that intermittently fails',
|
|
168
|
-
'A bug found in code review',
|
|
169
|
-
],
|
|
170
|
-
antiPatterns: [
|
|
171
|
-
'The bug has not been fixed yet — first fix, then add regression test',
|
|
172
|
-
'The bug is in test code itself — fix the test',
|
|
173
|
-
'A bug that requires impossible-to-mock state (real network, real browser)',
|
|
174
|
-
],
|
|
175
|
-
requires: [],
|
|
176
|
-
relatedSkills: ['write-unit-tests', 'reproduce-bug'],
|
|
177
|
-
tags: ['test', 'regression', 'bug-fix', 'permanent-test'],
|
|
178
|
-
examples: [
|
|
179
|
-
{
|
|
180
|
-
input: 'Bug: "Council shows duplicate user message at session resume" was just fixed in commit a3f9d',
|
|
181
|
-
output: {
|
|
182
|
-
testFile: 'tests/regression/duplicate-user-message.test.ts',
|
|
183
|
-
test: `import { describe, it, expect } from 'vitest';
|
|
184
|
-
import { runCouncilPure } from '../agents/councilApi';
|
|
185
|
-
|
|
186
|
-
describe('regression: duplicate user message at session resume', () => {
|
|
187
|
-
it('does not render duplicate user message when session resumes with duplicate input', async () => {
|
|
188
|
-
const messages = [
|
|
189
|
-
{ role: 'user' as const, content: 'hi' },
|
|
190
|
-
{ role: 'user' as const, content: 'hi' }, // duplicate from session resume
|
|
191
|
-
];
|
|
192
|
-
const mockProvider = async function* () {
|
|
193
|
-
yield { kind: 'text' as const, delta: 'response' };
|
|
194
|
-
yield { kind: 'finish' as const, reason: 'stop' };
|
|
195
|
-
};
|
|
196
|
-
const events = [];
|
|
197
|
-
for await (const e of runCouncilPure('hi', {
|
|
198
|
-
model: 'test', provider: 'test',
|
|
199
|
-
messages,
|
|
200
|
-
tools: [],
|
|
201
|
-
councilSize: 1,
|
|
202
|
-
debateMode: false,
|
|
203
|
-
ragContext: '',
|
|
204
|
-
workspaceContext: '',
|
|
205
|
-
providerStream: mockProvider,
|
|
206
|
-
}, {})) {
|
|
207
|
-
events.push(e);
|
|
208
|
-
}
|
|
209
|
-
const userMessageDeltas = events.filter(e => e.type === 'message_delta').length;
|
|
210
|
-
expect(userMessageDeltas).toBe(1); // exactly 1, not 2
|
|
211
|
-
});
|
|
212
|
-
});`,
|
|
213
|
-
whyRegression: 'Bug was reported 3 times in the last month. The fix (dedup user messages on session resume) was in commit a3f9d. This test guards against future refactors breaking the dedup logic.',
|
|
214
|
-
bugCommit: 'a3f9d',
|
|
215
|
-
},
|
|
216
|
-
},
|
|
217
|
-
],
|
|
218
|
-
outputSchema: '{ testFile: string; test: string; whyRegression: string; bugCommit: string }',
|
|
219
|
-
systemPromptFragment: `You are converting a fixed bug into a permanent regression test.
|
|
220
|
-
|
|
221
|
-
## Methodology
|
|
222
|
-
1. **Confirm the bug is FIXED**: check git log / recent commits for the fix.
|
|
223
|
-
2. **Write the test**: it should FAIL if you revert the fix (verify this mentally).
|
|
224
|
-
3. **Add a comment** in the test file linking to the bug commit.
|
|
225
|
-
4. **Place in tests/regression/**: separate from unit tests for visibility.
|
|
226
|
-
|
|
227
|
-
## Output format (JSON-typed)
|
|
228
|
-
- testFile: string
|
|
229
|
-
- test: string (the full test code, runnable as-is)
|
|
230
|
-
- whyRegression: string (why this test should stay forever)
|
|
231
|
-
- bugCommit: string (the commit hash that fixed the bug)
|
|
232
|
-
|
|
233
|
-
## Regression test principles
|
|
234
|
-
- **One test per bug** — easier to identify which regression fired
|
|
235
|
-
- **Reference the bug commit** in a comment so future devs understand the history
|
|
236
|
-
- **Minimal repro** — strip to the essential trigger, don't include unrelated setup
|
|
237
|
-
- **Never delete a regression test** without a written justification (the bug came back once, it'll come back again)
|
|
238
|
-
|
|
239
|
-
Stay under 300 words.${CLARIFICATION_PROTOCOL}`,
|
|
240
|
-
};
|
|
241
|
-
// Register in topological order
|
|
242
|
-
registerCodingSkill(writeUnitTests);
|
|
243
|
-
registerCodingSkill(writeIntegrationTests);
|
|
244
|
-
registerCodingSkill(regressionTest);
|
|
245
|
-
//# sourceMappingURL=testing.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"testing.js","sourceRoot":"","sources":["../../../../src/agents/skills/builtin/testing.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AAEtD,MAAM,sBAAsB,GAAG;;;;;;;;;;;;;kFAamD,CAAC;AAEnF,MAAM,cAAc,GAA0B;IAC5C,EAAE,EAAE,kBAAkB;IACtB,OAAO,EAAE,OAAO;IAChB,IAAI,EAAE,kBAAkB;IACxB,WAAW,EAAE,oOAAoO;IACjP,QAAQ,EAAE,MAAM;IAChB,aAAa,EAAE,CAAC,QAAQ,EAAE,OAAO,CAAC;IAClC,aAAa,EAAE,CAAC,WAAW,CAAC;IAC5B,aAAa,EAAE,QAAQ;IACvB,gBAAgB,EAAE,IAAI;IACtB,OAAO,EAAE,IAAI;IACb,QAAQ,EAAE;QACR,mCAAmC;QACnC,uDAAuD;QACvD,uDAAuD;QACvD,gDAAgD;KACjD;IACD,YAAY,EAAE;QACZ,uEAAuE;QACvE,kEAAkE;QAClE,sEAAsE;KACvE;IACD,QAAQ,EAAE,EAAE;IACZ,aAAa,EAAE,CAAC,iBAAiB,EAAE,wBAAwB,CAAC;IAC5D,IAAI,EAAE,CAAC,MAAM,EAAE,WAAW,EAAE,KAAK,EAAE,QAAQ,EAAE,UAAU,CAAC;IACxD,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
|
2
|
-
PLANNING: 'planning',
|
|
3
|
-
REFACTOR: 'refactor',
|
|
4
|
-
DEBUG: 'debug',
|
|
5
|
-
REVIEW: 'review',
|
|
6
|
-
TEST: 'test',
|
|
7
|
-
DOCS: 'docs',
|
|
8
|
-
OPS: 'ops',
|
|
9
|
-
GIT: 'git',
|
|
10
|
-
DB: 'db',
|
|
11
|
-
MAINT: 'maint',
|
|
12
|
-
};
|
|
13
|
-
/**
|
|
14
|
-
* Skill catalog — packages of capability assignable to agents.
|
|
15
|
-
*
|
|
16
|
-
* Each skill injects a systemPromptFragment into the agent's prompt and
|
|
17
|
-
* declares the tools it requires.
|
|
18
|
-
*/
|
|
19
|
-
export const SKILL_CATALOG = [
|
|
20
|
-
{
|
|
21
|
-
id: 'vault-manager',
|
|
22
|
-
version: '1.0.0',
|
|
23
|
-
tags: ['knowledge', 'vault', 'notes'],
|
|
24
|
-
relatedSkills: ['document-writer'],
|
|
25
|
-
name: 'Vault Manager',
|
|
26
|
-
description: 'Create, edit, search and link markdown documents in the Knowledge Vault using [[wikilinks]], #tags and YAML frontmatter.',
|
|
27
|
-
category: 'vault',
|
|
28
|
-
color: '#3b82f6',
|
|
29
|
-
enabledByDefault: true,
|
|
30
|
-
builtin: true,
|
|
31
|
-
requiredTools: ['createDocument', 'updateDocument', 'searchDocuments', 'linkDocuments'],
|
|
32
|
-
systemPromptFragment: `You can manage the Knowledge Vault directly.
|
|
33
|
-
- Documents are markdown files with a path (e.g. "notes/architecture"), title, content, tags, and optional category.
|
|
34
|
-
- Connect documents with [[wikilinks]]: write [[target]] or [[target|alias]] inside the content.
|
|
35
|
-
- Add #hashtags anywhere in the content to tag a document.
|
|
36
|
-
- Optional YAML frontmatter may precede the body (key: value lines wrapped in ---).
|
|
37
|
-
- Prefer creating durable notes over answering in chat when the information is reusable.`,
|
|
38
|
-
},
|
|
39
|
-
{
|
|
40
|
-
id: 'project-planner',
|
|
41
|
-
version: '1.0.0',
|
|
42
|
-
tags: ['planning', 'project', 'tasks'],
|
|
43
|
-
relatedSkills: [],
|
|
44
|
-
name: 'Project Planner',
|
|
45
|
-
description: 'Structured project planning with phases, tasks, subtasks, dependencies and milestones.',
|
|
46
|
-
category: 'project',
|
|
47
|
-
color: '#10b981',
|
|
48
|
-
enabledByDefault: true,
|
|
49
|
-
builtin: true,
|
|
50
|
-
requiredTools: ['createTask', 'createPhase', 'createMilestone', 'updateTask'],
|
|
51
|
-
systemPromptFragment: `You plan projects hierarchically.
|
|
52
|
-
- Decompose work into phases, then tasks within phases.
|
|
53
|
-
- For each task include: title, description, priority (low|medium|high|critical), and optional tags/subtasks.
|
|
54
|
-
- Define milestones to mark key deliverables.
|
|
55
|
-
- When relevant, reference file paths and acceptance criteria.`,
|
|
56
|
-
},
|
|
57
|
-
{
|
|
58
|
-
id: 'idea-synthesizer',
|
|
59
|
-
version: '1.0.0',
|
|
60
|
-
tags: ['ideation', 'creativity'],
|
|
61
|
-
relatedSkills: [],
|
|
62
|
-
name: 'Idea Synthesizer',
|
|
63
|
-
description: 'Generate, cluster and evaluate creative ideas using divergent thinking.',
|
|
64
|
-
category: 'ideas',
|
|
65
|
-
color: '#f59e0b',
|
|
66
|
-
enabledByDefault: true,
|
|
67
|
-
builtin: true,
|
|
68
|
-
requiredTools: ['addIdea', 'clusterIdeas'],
|
|
69
|
-
systemPromptFragment: `You generate and organize ideas.
|
|
70
|
-
- Produce a diverse set of ideas, then cluster related ones.
|
|
71
|
-
- Tag ideas consistently and assign a category.
|
|
72
|
-
- Evaluate feasibility and novelty briefly.`,
|
|
73
|
-
},
|
|
74
|
-
{
|
|
75
|
-
id: 'mind-mapper',
|
|
76
|
-
version: '1.0.0',
|
|
77
|
-
tags: ['knowledge', 'graph', 'visualization'],
|
|
78
|
-
relatedSkills: [],
|
|
79
|
-
name: 'Mind Mapper',
|
|
80
|
-
description: 'Build structured mind maps (root → branches → leaves) and connect them to vault documents.',
|
|
81
|
-
category: 'mindmap',
|
|
82
|
-
color: '#06b6d4',
|
|
83
|
-
enabledByDefault: false,
|
|
84
|
-
builtin: true,
|
|
85
|
-
requiredTools: ['buildMindMap', 'addNode', 'linkNodes', 'createMindMapNode'],
|
|
86
|
-
systemPromptFragment: `You build mind maps as JSON structures.
|
|
87
|
-
- Root → branches → leaves.
|
|
88
|
-
- Each node has a label and short content.
|
|
89
|
-
- Use semantic colors and connect nodes that relate to vault documents.`,
|
|
90
|
-
},
|
|
91
|
-
{
|
|
92
|
-
id: 'research-analyst',
|
|
93
|
-
version: '1.0.0',
|
|
94
|
-
tags: ['research', 'rag', 'analysis'],
|
|
95
|
-
relatedSkills: [],
|
|
96
|
-
name: 'Research Analyst',
|
|
97
|
-
description: 'Query the RAG knowledge base, synthesize findings and cite sources.',
|
|
98
|
-
category: 'analysis',
|
|
99
|
-
color: '#a855f7',
|
|
100
|
-
enabledByDefault: true,
|
|
101
|
-
builtin: true,
|
|
102
|
-
requiredTools: ['searchRAG', 'searchDocuments'],
|
|
103
|
-
systemPromptFragment: `You research using the retrieval system.
|
|
104
|
-
- Use searchRAG / searchDocuments to find relevant prior knowledge before answering.
|
|
105
|
-
- Cite sources by title when you rely on retrieved content.
|
|
106
|
-
- Structure analyses with clear sections and a conclusion.`,
|
|
107
|
-
},
|
|
108
|
-
{
|
|
109
|
-
id: 'document-writer',
|
|
110
|
-
version: '1.0.0',
|
|
111
|
-
tags: ['writing', 'documentation'],
|
|
112
|
-
relatedSkills: [],
|
|
113
|
-
name: 'Document Writer',
|
|
114
|
-
description: 'Write high-quality technical or narrative documents into the vault.',
|
|
115
|
-
category: 'writing',
|
|
116
|
-
color: '#ec4899',
|
|
117
|
-
enabledByDefault: false,
|
|
118
|
-
builtin: true,
|
|
119
|
-
requiredTools: ['createDocument', 'updateDocument'],
|
|
120
|
-
systemPromptFragment: `You write polished documents.
|
|
121
|
-
- Choose an appropriate structure (guide, spec, reference, narrative).
|
|
122
|
-
- Maintain a consistent tone and voice.
|
|
123
|
-
- Use headings, lists, and code blocks where helpful; link related notes with [[wikilinks]].`,
|
|
124
|
-
},
|
|
125
|
-
];
|
|
126
|
-
/** Default skill assignments per agent id. */
|
|
127
|
-
const DEFAULT_AGENT_SKILLS = {
|
|
128
|
-
sisyphus: ['project-planner', 'research-analyst'],
|
|
129
|
-
prometheus: ['project-planner', 'vault-manager'],
|
|
130
|
-
hephaestus: ['idea-synthesizer', 'mind-mapper', 'document-writer'],
|
|
131
|
-
atlas: ['mind-mapper', 'research-analyst'],
|
|
132
|
-
oracle: ['research-analyst'],
|
|
133
|
-
chairman: ['vault-manager', 'project-planner', 'idea-synthesizer'],
|
|
134
|
-
};
|
|
135
|
-
/** Get all skills in a given category. */
|
|
136
|
-
export function getSkillsByCategory(cat) {
|
|
137
|
-
return SKILL_CATALOG.filter((s) => s.category === cat);
|
|
138
|
-
}
|
|
139
|
-
/** Get a skill by id. */
|
|
140
|
-
export function getSkillById(id) {
|
|
141
|
-
return SKILL_CATALOG.find((s) => s.id === id);
|
|
142
|
-
}
|
|
143
|
-
/**
|
|
144
|
-
* Resolve the default skills for an agent.
|
|
145
|
-
* Custom/user-defined agents default to an empty set (configured via UI).
|
|
146
|
-
*/
|
|
147
|
-
export function resolveAgentSkills(agentId) {
|
|
148
|
-
const ids = DEFAULT_AGENT_SKILLS[agentId] ?? [];
|
|
149
|
-
return ids
|
|
150
|
-
.map((id) => getSkillById(id))
|
|
151
|
-
.filter((s) => s !== undefined);
|
|
152
|
-
}
|
|
153
|
-
/** All builtin skill ids (useful for the settings UI). */
|
|
154
|
-
export function getBuiltinSkillIds() {
|
|
155
|
-
return SKILL_CATALOG.filter((s) => s.builtin).map((s) => s.id);
|
|
156
|
-
}
|
|
157
|
-
/**
|
|
158
|
-
* List all skills (built-in + custom). Returns a fresh array — safe to mutate.
|
|
159
|
-
* Uses SkillMetadata type.
|
|
160
|
-
*/
|
|
161
|
-
export function listSkills() {
|
|
162
|
-
return [...SKILL_CATALOG];
|
|
163
|
-
}
|
|
164
|
-
/**
|
|
165
|
-
* Get a skill by ID, returned as SkillMetadata.
|
|
166
|
-
* Returns undefined if not found.
|
|
167
|
-
*/
|
|
168
|
-
export function getSkillMetadata(id) {
|
|
169
|
-
return SKILL_CATALOG.find((s) => s.id === id);
|
|
170
|
-
}
|
|
171
|
-
/**
|
|
172
|
-
* Register a custom skill (user-defined or MCP-discovered). If a skill
|
|
173
|
-
* with the same id already exists, it is replaced.
|
|
174
|
-
*/
|
|
175
|
-
export function registerSkill(skill) {
|
|
176
|
-
const idx = SKILL_CATALOG.findIndex((s) => s.id === skill.id);
|
|
177
|
-
if (idx >= 0) {
|
|
178
|
-
SKILL_CATALOG[idx] = skill;
|
|
179
|
-
}
|
|
180
|
-
else {
|
|
181
|
-
SKILL_CATALOG.push(skill);
|
|
182
|
-
}
|
|
183
|
-
}
|
|
184
|
-
/**
|
|
185
|
-
* Remove a skill by ID. Returns true if removed, false if not found.
|
|
186
|
-
* Built-in skills (skill.builtin === true) cannot be removed.
|
|
187
|
-
*/
|
|
188
|
-
export function unregisterSkill(id) {
|
|
189
|
-
const skill = SKILL_CATALOG.find((s) => s.id === id);
|
|
190
|
-
if (!skill)
|
|
191
|
-
return false;
|
|
192
|
-
if (skill.builtin)
|
|
193
|
-
return false;
|
|
194
|
-
const idx = SKILL_CATALOG.indexOf(skill);
|
|
195
|
-
SKILL_CATALOG.splice(idx, 1);
|
|
196
|
-
return true;
|
|
197
|
-
}
|
|
198
|
-
/**
|
|
199
|
-
* Find all skills matching a tag (exact match).
|
|
200
|
-
*/
|
|
201
|
-
export function findSkillsByTag(tag) {
|
|
202
|
-
return SKILL_CATALOG.filter((s) => s.tags?.includes(tag));
|
|
203
|
-
}
|
|
204
|
-
/**
|
|
205
|
-
* Find all skills matching any of the given IDs.
|
|
206
|
-
* Unknown IDs are silently skipped.
|
|
207
|
-
*/
|
|
208
|
-
export function findSkillsByIds(ids) {
|
|
209
|
-
const idSet = new Set(ids);
|
|
210
|
-
return SKILL_CATALOG.filter((s) => idSet.has(s.id));
|
|
211
|
-
}
|
|
212
|
-
/**
|
|
213
|
-
* Resolve skill dependencies in topological order. Returns empty array
|
|
214
|
-
* if a dependency is missing (caller should handle gracefully).
|
|
215
|
-
*/
|
|
216
|
-
export function resolveSkillDependencies(id) {
|
|
217
|
-
const start = SKILL_CATALOG.find((s) => s.id === id);
|
|
218
|
-
if (!start)
|
|
219
|
-
return [];
|
|
220
|
-
// Skills currently have no 'requires' field, so topological sort is trivial.
|
|
221
|
-
return [start];
|
|
222
|
-
}
|
|
223
|
-
/** Empty catalog of coding skills — populated by Task 13.4. */
|
|
224
|
-
export const CODING_SKILL_CATALOG = [];
|
|
225
|
-
/** List all coding skills (fresh array). */
|
|
226
|
-
export function listCodingSkills() {
|
|
227
|
-
return [...CODING_SKILL_CATALOG];
|
|
228
|
-
}
|
|
229
|
-
/** Get a coding skill by id. */
|
|
230
|
-
export function getCodingSkillById(id) {
|
|
231
|
-
return CODING_SKILL_CATALOG.find((s) => s.id === id);
|
|
232
|
-
}
|
|
233
|
-
/** Find all coding skills in a category. */
|
|
234
|
-
export function findCodingSkillsByCategory(category) {
|
|
235
|
-
return CODING_SKILL_CATALOG.filter((s) => s.category === category);
|
|
236
|
-
}
|
|
237
|
-
/** Find all coding skills matching a tag. */
|
|
238
|
-
export function findCodingSkillsByTag(tag) {
|
|
239
|
-
return CODING_SKILL_CATALOG.filter((s) => s.tags.includes(tag));
|
|
240
|
-
}
|
|
241
|
-
/**
|
|
242
|
-
* Validate that all `requires` references point to existing skill IDs.
|
|
243
|
-
* Returns an array of error messages (empty = valid).
|
|
244
|
-
*
|
|
245
|
-
* Note: This is a runtime check. Compile-time validation requires the
|
|
246
|
-
* TypeScript type to express the cross-reference; we use a manual
|
|
247
|
-
* registration API that throws on invalid requires.
|
|
248
|
-
*/
|
|
249
|
-
export function validateCodingSkillRequires(skill) {
|
|
250
|
-
const errors = [];
|
|
251
|
-
for (const reqId of skill.requires) {
|
|
252
|
-
if (!CODING_SKILL_CATALOG.some((s) => s.id === reqId)) {
|
|
253
|
-
errors.push(`Skill "${skill.id}" requires unknown skill "${reqId}"`);
|
|
254
|
-
}
|
|
255
|
-
}
|
|
256
|
-
return errors;
|
|
257
|
-
}
|
|
258
|
-
/** Register a coding skill (called by Task 13.4 when populating the catalog). */
|
|
259
|
-
export function registerCodingSkill(skill) {
|
|
260
|
-
const errors = validateCodingSkillRequires(skill);
|
|
261
|
-
if (errors.length > 0) {
|
|
262
|
-
throw new Error(`Cannot register coding skill: ${errors.join('; ')}`);
|
|
263
|
-
}
|
|
264
|
-
const idx = CODING_SKILL_CATALOG.findIndex((s) => s.id === skill.id);
|
|
265
|
-
if (idx >= 0) {
|
|
266
|
-
CODING_SKILL_CATALOG[idx] = skill;
|
|
267
|
-
}
|
|
268
|
-
else {
|
|
269
|
-
CODING_SKILL_CATALOG.push(skill);
|
|
270
|
-
}
|
|
271
|
-
}
|
|
272
|
-
//# sourceMappingURL=skills.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"skills.js","sourceRoot":"","sources":["../../src/agents/skills.ts"],"names":[],"mappings":"AA2BA,MAAM,CAAC,MAAM,eAAe,GAAG;IAC7B,QAAQ,EAAE,UAAU;IACpB,QAAQ,EAAE,UAAU;IACpB,KAAK,EAAE,OAAO;IACd,MAAM,EAAE,QAAQ;IAChB,IAAI,EAAE,MAAM;IACZ,IAAI,EAAE,MAAM;IACZ,GAAG,EAAE,KAAK;IACV,GAAG,EAAE,KAAK;IACV,EAAE,EAAE,IAAI;IACR,KAAK,EAAE,OAAO;CACN,CAAC;AA0CX;;;;;GAKG;AACH,MAAM,CAAC,MAAM,aAAa,GAAoB;IAC5C;QACE,EAAE,EAAE,eAAe;QACnB,OAAO,EAAE,OAAO;QAChB,IAAI,EAAE,CAAC,WAAW,EAAE,OAAO,EAAE,OAAO,CAAC;QACrC,aAAa,EAAE,CAAC,iBAAiB,CAAC;QAClC,IAAI,EAAE,eAAe;QACrB,WAAW,EAAE,0HAA0H;QACvI,QAAQ,EAAE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