@deimoscloud/coreai 0.1.14 → 0.1.16
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/agents/_templates/ic-engineer.md +99 -14
- package/agents/_templates/reviewer.md +95 -13
- package/agents/android-engineer.md +289 -0
- package/agents/backend-engineer.md +287 -0
- package/agents/database-administrator.md +289 -0
- package/agents/devops-engineer.md +323 -0
- package/agents/{examples/engineering-manager.md → engineering-manager.md} +208 -171
- package/agents/frontend-engineer.md +287 -0
- package/agents/product-manager.md +371 -0
- package/agents/react-engineer.md +289 -0
- package/agents/react-native-engineer.md +289 -0
- package/agents/software-security-engineer.md +451 -0
- package/agents/software-solutions-architect.md +469 -0
- package/agents/sre-huawei-cloud-architect.md +289 -0
- package/agents/sre-iac-specialist.md +289 -0
- package/agents/sre-kubernetes-specialist.md +289 -0
- package/agents/sre-network-specialist.md +289 -0
- package/agents/wearos-engineer.md +289 -0
- package/dist/cli/index.js +281 -55
- package/dist/cli/index.js.map +1 -1
- package/dist/index.d.ts +78 -51
- package/dist/index.js +265 -44
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/schemas/agent.schema.json +140 -3
- package/agents/android-engineer.yaml +0 -74
- package/agents/backend-engineer.yaml +0 -72
- package/agents/database-administrator.yaml +0 -74
- package/agents/devops-engineer.yaml +0 -72
- package/agents/engineering-manager.yaml +0 -70
- package/agents/examples/android-engineer.md +0 -302
- package/agents/examples/backend-engineer.md +0 -320
- package/agents/examples/devops-engineer.md +0 -742
- package/agents/examples/frontend-engineer.md +0 -58
- package/agents/examples/product-manager.md +0 -315
- package/agents/examples/qa-engineer.md +0 -371
- package/agents/examples/security-engineer.md +0 -525
- package/agents/examples/solutions-architect.md +0 -351
- package/agents/examples/wearos-engineer.md +0 -359
- package/agents/frontend-engineer.yaml +0 -72
- package/agents/product-manager.yaml +0 -75
- package/agents/react-engineer.yaml +0 -74
- package/agents/react-native-engineer.yaml +0 -74
- package/agents/software-security-engineer.yaml +0 -74
- package/agents/software-solutions-architect.yaml +0 -73
- package/agents/sre-huawei-cloud-architect.yaml +0 -74
- package/agents/sre-iac-specialist.yaml +0 -74
- package/agents/sre-kubernetes-specialist.yaml +0 -74
- package/agents/sre-network-specialist.yaml +0 -74
- package/agents/wearos-engineer.yaml +0 -74
package/dist/index.d.ts
CHANGED
|
@@ -165,13 +165,17 @@ declare function getConfigPath(startDir?: string): string | null;
|
|
|
165
165
|
*
|
|
166
166
|
* TypeScript types corresponding to the JSON schema at schemas/agent.schema.json
|
|
167
167
|
*/
|
|
168
|
+
/** @deprecated Used only for YAML backward compatibility. Will be removed when YAML support is dropped. */
|
|
168
169
|
type AgentType = 'ic-engineer' | 'manager' | 'specialist' | 'coordinator';
|
|
170
|
+
/** @deprecated Used only for YAML backward compatibility. Will be removed when YAML support is dropped. */
|
|
169
171
|
type WorkflowType = 'ticket-implementation' | 'bug-investigation' | 'code-review' | 'planning-estimation' | 'product-planning';
|
|
172
|
+
/** @deprecated Used only for YAML backward compatibility. Will be removed when YAML support is dropped. */
|
|
170
173
|
interface AgentExpertise {
|
|
171
174
|
primary?: string[];
|
|
172
175
|
tech_stack?: string;
|
|
173
176
|
[key: string]: unknown;
|
|
174
177
|
}
|
|
178
|
+
/** @deprecated Used only for YAML backward compatibility. Will be removed when YAML support is dropped. */
|
|
175
179
|
interface AgentPrinciples {
|
|
176
180
|
code_quality?: string[];
|
|
177
181
|
testing?: string[];
|
|
@@ -179,34 +183,91 @@ interface AgentPrinciples {
|
|
|
179
183
|
performance?: string[];
|
|
180
184
|
[key: string]: string[] | undefined;
|
|
181
185
|
}
|
|
186
|
+
/** @deprecated Used only for YAML backward compatibility. Will be removed when YAML support is dropped. */
|
|
182
187
|
interface AgentBehaviors {
|
|
183
188
|
workflow?: WorkflowType;
|
|
184
189
|
quality_gates?: string;
|
|
185
190
|
[key: string]: unknown;
|
|
186
191
|
}
|
|
192
|
+
/** @deprecated Used only for YAML backward compatibility. Will be removed when YAML support is dropped. */
|
|
187
193
|
interface AgentContextSources {
|
|
188
194
|
shared?: string[];
|
|
189
195
|
personal?: string[];
|
|
190
196
|
}
|
|
197
|
+
/** @deprecated Used only for YAML backward compatibility. Will be removed when YAML support is dropped. */
|
|
198
|
+
interface AgentKnowledgeLibraryControl {
|
|
199
|
+
objectives?: string;
|
|
200
|
+
decisions?: string;
|
|
201
|
+
dependencies?: string;
|
|
202
|
+
index?: string;
|
|
203
|
+
}
|
|
204
|
+
/** @deprecated Used only for YAML backward compatibility. Will be removed when YAML support is dropped. */
|
|
205
|
+
interface AgentKnowledgeLibraryShared {
|
|
206
|
+
context?: string;
|
|
207
|
+
architecture?: string;
|
|
208
|
+
prd?: string;
|
|
209
|
+
remote?: string[];
|
|
210
|
+
}
|
|
211
|
+
/** @deprecated Used only for YAML backward compatibility. Will be removed when YAML support is dropped. */
|
|
212
|
+
interface AgentKnowledgeLibraryPersonal {
|
|
213
|
+
context?: string;
|
|
214
|
+
history?: string;
|
|
215
|
+
inbox?: string;
|
|
216
|
+
outbox?: string;
|
|
217
|
+
tech?: string;
|
|
218
|
+
control?: AgentKnowledgeLibraryControl;
|
|
219
|
+
}
|
|
220
|
+
/** @deprecated Used only for YAML backward compatibility. Will be removed when YAML support is dropped. */
|
|
221
|
+
interface AgentKnowledgeLibrary {
|
|
222
|
+
shared?: AgentKnowledgeLibraryShared;
|
|
223
|
+
personal?: AgentKnowledgeLibraryPersonal;
|
|
224
|
+
}
|
|
225
|
+
/** @deprecated Used only for YAML backward compatibility. Will be removed when YAML support is dropped. */
|
|
191
226
|
interface AgentCommunication {
|
|
192
227
|
inbox?: string;
|
|
193
228
|
outbox?: string;
|
|
229
|
+
message_format?: string;
|
|
230
|
+
outbox_format?: string;
|
|
231
|
+
processed_dir?: string;
|
|
232
|
+
}
|
|
233
|
+
/** @deprecated Used only for YAML backward compatibility. Will be removed when YAML support is dropped. */
|
|
234
|
+
interface AgentStartupProtocol {
|
|
235
|
+
first_session?: string[];
|
|
236
|
+
subsequent?: string[];
|
|
237
|
+
}
|
|
238
|
+
/** @deprecated Used only for YAML backward compatibility. Will be removed when YAML support is dropped. */
|
|
239
|
+
interface AgentProtocols {
|
|
240
|
+
startup?: AgentStartupProtocol;
|
|
241
|
+
completion?: string[];
|
|
194
242
|
}
|
|
195
243
|
/**
|
|
196
|
-
*
|
|
244
|
+
* Agent definition.
|
|
245
|
+
* For MD agents: role, type, display_name, description, tools are used.
|
|
246
|
+
* For deprecated YAML agents: all fields may be populated.
|
|
197
247
|
*/
|
|
198
248
|
interface AgentDefinition {
|
|
199
249
|
role: string;
|
|
200
250
|
type: AgentType;
|
|
201
251
|
display_name: string;
|
|
202
252
|
description: string;
|
|
253
|
+
/** @deprecated YAML-only. In MD agents, responsibilities are in the template body. */
|
|
203
254
|
responsibilities?: string[];
|
|
255
|
+
/** @deprecated YAML-only. In MD agents, expertise is in the template body. */
|
|
204
256
|
expertise?: AgentExpertise;
|
|
257
|
+
/** @deprecated YAML-only. In MD agents, skills are in the template body. */
|
|
205
258
|
skills?: string[];
|
|
259
|
+
/** @deprecated YAML-only. In MD agents, principles are in the template body. */
|
|
206
260
|
principles?: AgentPrinciples;
|
|
261
|
+
/** @deprecated YAML-only. In MD agents, behaviors are in the template body. */
|
|
207
262
|
behaviors?: AgentBehaviors;
|
|
263
|
+
/** @deprecated YAML-only. Use knowledge_library or MD template body instead. */
|
|
208
264
|
context_sources?: AgentContextSources;
|
|
265
|
+
/** @deprecated YAML-only. In MD agents, knowledge library structure is in the template body. */
|
|
266
|
+
knowledge_library?: AgentKnowledgeLibrary;
|
|
267
|
+
/** @deprecated YAML-only. In MD agents, communication details are in the template body. */
|
|
209
268
|
communication?: AgentCommunication;
|
|
269
|
+
/** @deprecated YAML-only. In MD agents, protocols are in the template body. */
|
|
270
|
+
protocols?: AgentProtocols;
|
|
210
271
|
/**
|
|
211
272
|
* Claude Code tools available to this agent.
|
|
212
273
|
* If not specified, defaults to: Read, Write, Edit, Bash, Glob, Grep
|
|
@@ -214,7 +275,7 @@ interface AgentDefinition {
|
|
|
214
275
|
tools?: string[];
|
|
215
276
|
}
|
|
216
277
|
/**
|
|
217
|
-
*
|
|
278
|
+
* @deprecated Used only for YAML backward compatibility.
|
|
218
279
|
*/
|
|
219
280
|
interface ResolvedAgentDefinition extends AgentDefinition {
|
|
220
281
|
expertise?: AgentExpertise & {
|
|
@@ -240,7 +301,8 @@ interface AgentMetadata {
|
|
|
240
301
|
/**
|
|
241
302
|
* Agent Loader
|
|
242
303
|
*
|
|
243
|
-
* Handles loading
|
|
304
|
+
* Handles loading agent definitions from Markdown templates (primary)
|
|
305
|
+
* and YAML files (deprecated, backward compatible).
|
|
244
306
|
*/
|
|
245
307
|
|
|
246
308
|
declare class AgentError extends Error {
|
|
@@ -251,14 +313,17 @@ declare class AgentError extends Error {
|
|
|
251
313
|
type AgentErrorCode = 'NOT_FOUND' | 'PARSE_ERROR' | 'VALIDATION_ERROR' | 'READ_ERROR';
|
|
252
314
|
/**
|
|
253
315
|
* Parse YAML content into an agent definition
|
|
316
|
+
* @deprecated Use Markdown agent files instead
|
|
254
317
|
*/
|
|
255
318
|
declare function parseAgentYaml(content: string, filePath?: string): unknown;
|
|
256
319
|
/**
|
|
257
320
|
* Validate parsed YAML against agent schema
|
|
321
|
+
* @deprecated Use Markdown agent files instead
|
|
258
322
|
*/
|
|
259
323
|
declare function validateAgentDefinition(agent: unknown): AgentDefinition;
|
|
260
324
|
/**
|
|
261
|
-
* Load
|
|
325
|
+
* Load an agent definition from a file (MD or YAML).
|
|
326
|
+
* MD files are the primary format. YAML files are deprecated but supported.
|
|
262
327
|
*/
|
|
263
328
|
declare function loadAgentFromFile(filePath: string): AgentDefinition;
|
|
264
329
|
/**
|
|
@@ -327,60 +392,30 @@ declare function resolveAgentDefinition(agent: AgentDefinition, config?: CoreAIC
|
|
|
327
392
|
/**
|
|
328
393
|
* Agent Compiler
|
|
329
394
|
*
|
|
330
|
-
*
|
|
395
|
+
* Processes agent Markdown templates with variable substitution.
|
|
396
|
+
* For deprecated YAML agents, falls back to structural transformation.
|
|
331
397
|
*/
|
|
332
398
|
|
|
333
399
|
/**
|
|
334
400
|
* Options for compiling agents
|
|
335
401
|
*/
|
|
336
402
|
interface CompileOptions {
|
|
337
|
-
/**
|
|
338
|
-
* Output directory for compiled markdown files.
|
|
339
|
-
* Default: .claude/agents
|
|
340
|
-
*/
|
|
341
403
|
outputDir?: string;
|
|
342
|
-
/**
|
|
343
|
-
* Core agents directory (built-in agents).
|
|
344
|
-
* Default: uses package's agents/ directory
|
|
345
|
-
*/
|
|
346
404
|
coreAgentsDir?: string;
|
|
347
|
-
/**
|
|
348
|
-
* Custom agents directory (project-specific agents).
|
|
349
|
-
* Default: coreai/agents in project root
|
|
350
|
-
*/
|
|
351
405
|
customAgentsDir?: string;
|
|
352
|
-
/**
|
|
353
|
-
* Project root directory.
|
|
354
|
-
* Default: process.cwd()
|
|
355
|
-
*/
|
|
356
406
|
projectRoot?: string;
|
|
357
|
-
/**
|
|
358
|
-
* Filter function to select which agents to compile.
|
|
359
|
-
* Returns true to include the agent, false to exclude.
|
|
360
|
-
*/
|
|
361
407
|
filter?: (agent: AgentDefinition) => boolean;
|
|
362
|
-
/**
|
|
363
|
-
* MCP server names to include as tools.
|
|
364
|
-
* These will be added to the agent's tools as mcp__<server-name>.
|
|
365
|
-
* Example: ['github', 'postgres'] -> 'mcp__github, mcp__postgres'
|
|
366
|
-
*/
|
|
367
408
|
mcpServers?: string[];
|
|
368
409
|
}
|
|
369
410
|
/**
|
|
370
411
|
* Result of compiling agents
|
|
371
412
|
*/
|
|
372
413
|
interface CompileResult {
|
|
373
|
-
/**
|
|
374
|
-
* Successfully compiled agents
|
|
375
|
-
*/
|
|
376
414
|
compiled: {
|
|
377
415
|
role: string;
|
|
378
416
|
source: AgentSource;
|
|
379
417
|
outputPath: string;
|
|
380
418
|
}[];
|
|
381
|
-
/**
|
|
382
|
-
* Agents that failed to compile
|
|
383
|
-
*/
|
|
384
419
|
errors: {
|
|
385
420
|
role: string;
|
|
386
421
|
source: AgentSource;
|
|
@@ -388,30 +423,22 @@ interface CompileResult {
|
|
|
388
423
|
}[];
|
|
389
424
|
}
|
|
390
425
|
/**
|
|
391
|
-
* Generate markdown content from a resolved agent definition
|
|
392
|
-
*
|
|
393
|
-
* The output includes YAML frontmatter required by Claude Code for subagent detection.
|
|
394
|
-
* See: https://code.claude.com/docs/en/sub-agents
|
|
395
|
-
*
|
|
396
|
-
* @param agent - Resolved agent definition
|
|
397
|
-
* @param mcpServers - Optional MCP server names to include as tools
|
|
426
|
+
* Generate markdown content from a resolved YAML agent definition.
|
|
427
|
+
* @deprecated Use MD templates instead. This exists for backward compatibility with YAML agents.
|
|
398
428
|
*/
|
|
399
429
|
declare function generateAgentMarkdown(agent: AgentDefinition, mcpServers?: string[]): string;
|
|
400
430
|
/**
|
|
401
|
-
* Compile a single agent
|
|
402
|
-
*
|
|
403
|
-
*
|
|
404
|
-
* @param config - Optional CoreAI config for variable resolution
|
|
405
|
-
* @param mcpServers - Optional MCP server names to include as tools
|
|
431
|
+
* Compile a single agent.
|
|
432
|
+
* MD templates use simple variable substitution.
|
|
433
|
+
* YAML files use the deprecated structural transformation.
|
|
406
434
|
*/
|
|
407
|
-
declare function compileAgent(agent: AgentDefinition, config?: CoreAIConfig, mcpServers?: string[]): string;
|
|
435
|
+
declare function compileAgent(agent: AgentDefinition, filePath: string, config?: CoreAIConfig, mcpServers?: string[]): string;
|
|
408
436
|
/**
|
|
409
437
|
* Load all agents from core and custom directories
|
|
410
438
|
*/
|
|
411
439
|
declare function loadAllAgents(options?: CompileOptions): Map<string, AgentMetadata>;
|
|
412
440
|
/**
|
|
413
|
-
* Filter agents based on team configuration
|
|
414
|
-
* Custom and override agents are always included regardless of team filter.
|
|
441
|
+
* Filter agents based on team configuration
|
|
415
442
|
*/
|
|
416
443
|
declare function filterAgentsByTeam(agents: Map<string, AgentMetadata>, config?: CoreAIConfig): Map<string, AgentMetadata>;
|
|
417
444
|
/**
|