ai-skill-interface 1.4.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 ADDED
@@ -0,0 +1,579 @@
1
+ # ai-skill-interface
2
+
3
+ ## Directive
4
+ <instruction>
5
+ Skills are interfaces: each skill defines WHAT must be achieved — never HOW.
6
+ You are the implementation: read the skill → inspect this project → fulfill the contract using this project's own language, tools, and conventions.
7
+ One skill works for any project, any language, any AI — because you are the adapter.
8
+ </instruction>
9
+
10
+ ## Installation
11
+
12
+ ```bash
13
+ # npm — installs skills to ~/.claude/skills/
14
+ npx ai-skill-interface
15
+
16
+ # pip — installs skills to ~/.claude/skills/
17
+ pip install ai-skill-interface && ai-skill-interface
18
+
19
+ # git submodule — wires skills into your project's CLAUDE.md
20
+ curl -sL https://raw.githubusercontent.com/jaemyeong-hwnag/ai-skill-interface/main/scripts/submodule-install.sh | sh
21
+ ```
22
+
23
+ ## How Skills Are Loaded
24
+
25
+ Each skill lives in `skills/<name>/SKILL.md`. When an AI reads this repository, it loads the relevant skill files directly. The README serves as the index and auto-selection guide; each skill's full definition is below and in its own file.
26
+
27
+ ## Context Signals
28
+
29
+ Detect these signals before selecting skills:
30
+
31
+ ```
32
+ change.type : code | ai-feature | explicit
33
+ change.scope : core-logic | interface | infra | test | docs
34
+ arch.pattern : hexagonal | layered | none
35
+ quality.status : no-tests | low-coverage | high-coverage
36
+ ai.complexity : single-call | pipeline | stateful | multi-agent
37
+ action.risk : reversible | irreversible
38
+ ```
39
+
40
+ ## Auto-Selection
41
+
42
+ ```
43
+ change.type=code
44
+ → delivery-workflow
45
+ + hexagonal-development (arch.pattern=hexagonal or layered)
46
+ + interface-first-development (change.scope=interface)
47
+ → finalize (after completion)
48
+
49
+ change.type=ai-feature
50
+ → framework-selection (always first)
51
+ + rag-development (retrieval pipeline present)
52
+ + observability (ai.complexity≥pipeline)
53
+ + evaluation (quality measurement needed)
54
+ + human-in-the-loop (action.risk=irreversible)
55
+ + agent-orchestration (ai.complexity=multi-agent)
56
+
57
+ change.type=explicit
58
+ → /version /security-audit /principle-audit /ai-token-optimize
59
+ /coverage /test-runner /finalize
60
+ ```
61
+
62
+ ## Composition
63
+
64
+ ```
65
+ finalize = test-runner + coverage + docs-sync + delivery-workflow(commit)
66
+ ```
67
+
68
+ ## Dependency Order
69
+
70
+ Apply required skills before dependent skills. Detect `requires:` in each SKILL.md frontmatter and resolve in dependency order before execution.
71
+
72
+ ---
73
+
74
+ ## Skills
75
+
76
+ ### delivery-workflow
77
+ > Enforce the full delivery cycle for every implementation task. Covers coding, testing, coverage, commit rules, and auto-commit on completion. This skill MUST be followed for all code changes.
78
+
79
+ **Sequence**
80
+
81
+ implement → run tests → fix failures → repeat until pass → add/update tests for changed behavior → rerun → commit by purpose
82
+
83
+ **Rules**
84
+ <constraints>
85
+ - every code change requires test run
86
+ - new behavior requires new tests
87
+ - changed behavior requires updated tests
88
+ - commit only when all tests pass
89
+ - never mix purposes in one commit
90
+ - auto-commit when work is complete
91
+ </constraints>
92
+
93
+ **Commit Format**
94
+
95
+ ```
96
+ format: <type>: <imperative summary, ≤72 chars>
97
+ types: feat=new feature | fix=bug fix | refactor=no behavior change | test=test change | docs=doc change | chore=build/config/deps
98
+ forbidden: vague summaries (update, fix issues, changes)
99
+ ```
100
+
101
+ **Done**
102
+ <criteria>
103
+ all tests pass + tests exist for changed behavior + commits separated by purpose
104
+ </criteria>
105
+
106
+ ---
107
+
108
+ ### hexagonal-development
109
+ > Detect and enforce layered architecture boundaries. Use when the project separates concerns into layers and changes touch layer boundaries.
110
+
111
+ **Sequence**
112
+
113
+ detect project layer structure → apply change flow inside-out
114
+
115
+ **Change Flow**
116
+
117
+ domain/business rule → inbound contract → outbound contract → infrastructure adapter → presentation mapping
118
+
119
+ **Rules**
120
+ <constraints>
121
+ - detect existing layer naming, do not rename/restructure unless requested
122
+ - domain layer: zero deps on infrastructure or presentation
123
+ - infrastructure types must not leak into domain or contract layers
124
+ - explicit mapping between infrastructure models and domain models
125
+ - presentation layer: thin, delegates to use-cases
126
+ - deps always point inward: outer→inner, never reverse
127
+ </constraints>
128
+
129
+ ---
130
+
131
+ ### interface-first-development
132
+ > Define contracts before implementations. Use when adding or changing abstractions, service boundaries, or cross-layer dependencies.
133
+
134
+ **Sequence**
135
+
136
+ detect project's abstraction mechanism → define/update contract first → implement after contract stable → wire via DI/config → update external boundaries only for surface changes → test contract behavior
137
+
138
+ **Rules**
139
+ <constraints>
140
+ - infrastructure types must not appear in contract signatures
141
+ - function signatures: minimal, intention-revealing
142
+ - prefer extending existing contracts over ad-hoc cross-layer deps
143
+ - one contract = one responsibility
144
+ </constraints>
145
+
146
+ ---
147
+
148
+ ### test-runner
149
+ > Detect the project's test runner and execute the full test suite with coverage reporting. Fail fast and fix on failure.
150
+
151
+ **Sequence**
152
+
153
+ detect test framework from project → run full suite → on failure: classify(code bug|test bug) → fix → rerun → repeat until pass → summarize
154
+
155
+ **Output Format**
156
+
157
+ ```
158
+ Tests:total=N passed=N failed=N skipped=N Coverage:N% Duration:Xs
159
+ ```
160
+
161
+ **Rules**
162
+ <constraints>
163
+ - tests must be independently runnable, no order dependency
164
+ - mock only external I/O boundaries
165
+ </constraints>
166
+
167
+ ---
168
+
169
+ ### coverage
170
+ > Analyze test coverage and drive it to 80%+ by writing missing tests. Detects the project's test runner automatically.
171
+
172
+ **Sequence**
173
+
174
+ detect coverage tool → measure → identify uncovered code → write tests → remeasure → repeat until ≥80%
175
+
176
+ **Priority**
177
+
178
+ core business logic → service/use-case → infrastructure/integration → entry points
179
+
180
+ **Test Strategy**
181
+
182
+ happy path + boundary values + error paths + all conditional branches
183
+
184
+ **Exclusions**
185
+
186
+ entry-point bootstrap | auto-generated files | config/env files | type-definition-only files
187
+
188
+ **Done**
189
+ <criteria>
190
+ coverage ≥80% + all tests pass
191
+ </criteria>
192
+
193
+ ---
194
+
195
+ ### finalize
196
+ > Post-implementation pipeline — run tests, enforce 80% coverage, sync docs, then commit atomically. Run after every feature or fix.
197
+
198
+ **Sequence**
199
+
200
+ test(detect→run→fix→pass) → coverage(measure→write tests→≥80%) → docs-sync(detect drift→update) → commit(by purpose, type: summary)
201
+
202
+ **Output Format**
203
+
204
+ ```
205
+ Tests:total=N passed=N failed=N Coverage:N% Docs:[files] Commits:[hash:msg]
206
+ ```
207
+
208
+ **Done**
209
+ <criteria>
210
+ all tests pass + coverage ≥80% + docs synced + commits created
211
+ </criteria>
212
+
213
+ ---
214
+
215
+ ### docs-sync
216
+ > Detect documentation drift from recent code changes and synchronize docs to match the current codebase.
217
+
218
+ **Sequence**
219
+
220
+ scan project docs → identify changed code → map changes to affected docs → update docs → validate structure
221
+
222
+ **Change-to-Doc Mapping**
223
+
224
+ - new public API/module → API docs, architecture overview
225
+ - public interface change → API docs, usage examples
226
+ - config change → config guide, env examples
227
+ - schema change → data model docs
228
+ - dependency change → install guide
229
+ - architecture change → architecture docs
230
+
231
+ **Rules**
232
+ <constraints>
233
+ - code is source of truth: docs follow code
234
+ - add sections for new topics
235
+ - remove docs for deleted features
236
+ - fix broken internal links
237
+ - sync TOC with actual headings
238
+ - remove duplicate content
239
+ </constraints>
240
+
241
+ ---
242
+
243
+ ### security-audit
244
+ > Comprehensive security review — secrets exposure, dependency vulnerabilities, code injection risks, and infrastructure config.
245
+
246
+ **Scan Targets**
247
+
248
+ 1. **secrets**: VCS history + source files for hardcoded credentials + verify secret/key/log files excluded from VCS
249
+ 2. **deps**: run project's vulnerability scanner
250
+ 3. **code**: injection(query,command,template) + path traversal + missing input validation at boundaries + error exposure(stack traces,internal paths) + credential logging
251
+ 4. **infra**: unnecessary port exposure + default/weak credentials + secrets not via env vars
252
+
253
+ **Severity**
254
+ <criteria>
255
+ HIGH(secret exposure, injection) → fix immediately
256
+ MEDIUM(vulnerable dep, error exposure) → fix this cycle
257
+ LOW(potential risk, best-practice violation) → next cycle
258
+ </criteria>
259
+
260
+ **Action**
261
+
262
+ fix HIGH issues directly when possible
263
+
264
+ ---
265
+
266
+ ### version
267
+ > Manage semantic versioning — auto-detect version bump type from recent commits, update version files, write CHANGELOG, and create a git tag.
268
+
269
+ **Bump Rules**
270
+
271
+ BREAKING CHANGE→MAJOR(X+1.0.0) | feat→MINOR(X.Y+1.0) | fix,refactor,perf→PATCH(X.Y.Z+1) | test,docs,chore→no change
272
+
273
+ **Sequence**
274
+
275
+ detect current version(tags→version files→CHANGELOG) → determine bump(arg or auto from commits) → update all version files → write CHANGELOG(Added/Changed/Fixed/Removed) → commit + tag
276
+
277
+ **Usage**
278
+
279
+ ```
280
+ /version (auto) | /version patch | /version minor | /version major
281
+ ```
282
+
283
+ ---
284
+
285
+ ### ai-token-optimize
286
+ > Optimize AI-consumed code and data for token efficiency — reduce token usage while preserving semantic fidelity. Applies to prompts, tool outputs, and inter-agent messages.
287
+
288
+ **Scope**
289
+
290
+ - **include**: AI-consumed data (prompts, tool returns, agent messages, AI-parsed structures, LLM context)
291
+ - **exclude**: human-facing data (docs, tests, config, schema)
292
+
293
+ **Techniques**
294
+
295
+ 1. **legend**: define all abbreviations once at prompt start; reuse without re-definition — prefer abbreviations already present in model training data (domain-standard codes require no definition)
296
+ 2. **compact k:v**: verbose structured labels → short key:value pairs, pipe or comma-separated
297
+ 3. **tabular**: repeated-structure collections → typed header with column list once, then value rows only
298
+ 4. **numeric notation**: express numbers as `{digit_count:value}` to prevent tokenizer fragmentation on large or precise values
299
+ 5. **structural tags**: lightweight semantic markup for boundaries instead of deep nesting or verbose prose
300
+ 6. **placement**: identity and critical directives at top, supporting data in middle, output schema at bottom — mitigates attention degradation in long contexts
301
+
302
+ **Sequence**
303
+
304
+ scan AI-consumed targets → identify repetition and verbosity → apply techniques → verify AI can parse output → run tests → commit per module
305
+
306
+ **Rules**
307
+ <constraints>
308
+ - apply only to AI-consumed data — never to human-facing content
309
+ - verify after each technique: AI must parse output correctly
310
+ - legend abbreviations must be unambiguous within their scope
311
+ - tabular format requires consistent column order across all rows
312
+ - placement order: legend → identity/directives → data → output schema
313
+ </constraints>
314
+
315
+ **Done**
316
+ <criteria>
317
+ labels compressed + collections tabular + numerics notation-formatted + critical info at top + output schema at bottom + tests pass
318
+ </criteria>
319
+
320
+ ---
321
+
322
+ ### principle-audit
323
+ > Audit the codebase for violations of the project's core principles — detect unintended system-imposed constraints that contradict the project's stated goals.
324
+
325
+ **Sequence**
326
+
327
+ find project principles(docs, config) → scan for violations → classify(allowed vs violation) → report + fix
328
+
329
+ **Violation Types**
330
+
331
+ 1. **unintended constraints**: system blocks behavior without business rule
332
+ 2. **layer boundary**: deps in forbidden direction, logic in wrong layer
333
+ 3. **consistency**: same-purpose logic in conflicting ways, naming/error-handling mismatch
334
+ 4. **hardcoded assumptions**: values that should be configurable, env-specific assumptions
335
+
336
+ **Distinguish**
337
+
338
+ - allowed: status as info | config-based threshold | domain rule rejection
339
+ - violation: status blocks execution | hardcoded threshold | infra-layer business decision
340
+
341
+ **Severity**
342
+ <criteria>
343
+ CRITICAL(direct violation, immediate impact) → fix now
344
+ WARNING(violation, currently inactive) → fix this cycle
345
+ INFO(potential risk) → comment/TODO
346
+ </criteria>
347
+
348
+ **Report**
349
+
350
+ per violation: file:line + description + related principle + fix recommendation
351
+ fix CRITICAL immediately → run tests
352
+
353
+ ---
354
+
355
+ ### framework-selection
356
+ > Choose the right tool, library, or architecture for the task — minimal complexity for the requirement.
357
+
358
+ **Sequence**
359
+
360
+ classify problem complexity → detect what the project already uses → match to the lowest sufficient tier → record rationale
361
+
362
+ **Complexity Tiers**
363
+
364
+ ```
365
+ single call → no framework
366
+ pipeline → composable steps, minimal orchestration
367
+ stateful workflow → explicit state, resumability
368
+ multi-agent → routing, delegation, parallelism
369
+ ```
370
+
371
+ **Rules**
372
+ <constraints>
373
+ - detect existing project tools before proposing new ones
374
+ - start at the lowest tier that satisfies the stated requirement
375
+ - escalate only when the lower tier cannot meet a requirement
376
+ - switching tiers mid-project requires explicit justification
377
+ </constraints>
378
+
379
+ **Done**
380
+ <criteria>
381
+ chosen approach matches complexity tier + existing conventions respected + rationale recorded
382
+ </criteria>
383
+
384
+ ---
385
+
386
+ ### rag-development
387
+ > Implement Retrieval-Augmented Generation pipelines — ingestion, chunking, embedding, retrieval, and generation.
388
+
389
+ **Sequence**
390
+
391
+ ingest → chunk → embed → store → retrieve → rerank → generate
392
+
393
+ **Rules**
394
+ <constraints>
395
+ - preserve source metadata (origin, section, date) through all stages
396
+ - chunk boundaries must respect semantic units
397
+ - embedding model must be identical at index time and query time
398
+ - retrieval store must match the data scale
399
+ - retrieve candidates before filtering by relevance — never pass unfiltered results to generation
400
+ - generation output must attribute retrieved sources
401
+ </constraints>
402
+
403
+ **Done**
404
+ <criteria>
405
+ all stages present + metadata preserved + embedding model consistent + sources attributed in output
406
+ </criteria>
407
+
408
+ ---
409
+
410
+ ### observability
411
+ > Instrument AI workflows with tracing, logging, and monitoring to enable debugging, auditing, and performance analysis.
412
+
413
+ **Sequence**
414
+
415
+ identify instrumentation boundaries → add spans → attach metadata → verify no gaps
416
+
417
+ **Boundaries**
418
+
419
+ ```
420
+ entry points → user input, external triggers
421
+ model calls → inputs, outputs, latency, token counts
422
+ tool calls → name, inputs, outputs, errors
423
+ inter-agent msgs → sender, receiver, content, timing
424
+ state transitions → before/after snapshot
425
+ ```
426
+
427
+ **Rules**
428
+ <constraints>
429
+ - every AI model call must produce a trace entry
430
+ - token counts must be extracted from the model API response metadata, not estimated or hardcoded — never use response length or character count as a token proxy
431
+ - propagate trace context across service boundaries
432
+ - attach a correlation ID to every trace
433
+ - structured output only — no free-form strings
434
+ - no secrets, PII, or credentials in traces
435
+ </constraints>
436
+
437
+ **Done**
438
+ <criteria>
439
+ all model calls traced + tool calls recorded + correlation IDs present + no secrets in traces
440
+ </criteria>
441
+
442
+ ---
443
+
444
+ ### evaluation
445
+ > Build evaluation pipelines for AI outputs — create datasets, write evaluators, and measure quality systematically.
446
+
447
+ **Sequence**
448
+
449
+ collect dataset → write evaluators → run baseline → change system → rerun → compare delta → iterate
450
+
451
+ **Dataset Types**
452
+
453
+ ```
454
+ final response → input → expected output
455
+ step-level → input → expected intermediate step
456
+ trajectory → input → expected sequence of steps
457
+ ```
458
+
459
+ **Evaluator Types**
460
+
461
+ ```
462
+ code evaluator → deterministic check (exact match, schema, format)
463
+ LLM-as-judge → semantic check (correctness, tone, safety)
464
+ human evaluator → gold standard for ambiguous criteria
465
+ ```
466
+
467
+ **Rules**
468
+ <constraints>
469
+ - prefer code evaluators for measurable criteria
470
+ - every evaluator must return a score and a reason
471
+ - judge model must differ from the model being evaluated
472
+ - evaluators must produce consistent output for the same input
473
+ - record a baseline before any system change
474
+ </constraints>
475
+
476
+ **Done**
477
+ <criteria>
478
+ dataset covers representative inputs + each evaluator returns score+reason + baseline recorded + regression detectable
479
+ </criteria>
480
+
481
+ ---
482
+
483
+ ### human-in-the-loop
484
+ > Insert human approval, review, or correction checkpoints into AI workflows — interrupt, wait, resume safely.
485
+
486
+ **Sequence**
487
+
488
+ reach checkpoint → serialize state → emit review request → halt → human acts → restore state → resume
489
+
490
+ **Interrupt Triggers**
491
+
492
+ ```
493
+ irreversible actions → destructive, external, financial
494
+ low confidence → below an explicit threshold
495
+ high-cost ambiguity → wrong assumption cannot be easily undone
496
+ compliance gate → policy or sign-off required
497
+ limit approaching → resource or cost ceiling about to be exceeded
498
+ ```
499
+
500
+ **Escalation Tiers**
501
+
502
+ ```
503
+ soft → surface suggestion, continue unless rejected
504
+ hard → halt until explicit approval
505
+ stop → halt and require human restart
506
+ ```
507
+
508
+ **Rules**
509
+ <constraints>
510
+ - state at interrupt must be fully serializable
511
+ - resume path must be idempotent — no duplicated side effects
512
+ - review payload must include: pending action, context, options
513
+ - rejected actions must be recorded with reason
514
+ - never auto-resume on timeout without an explicit policy
515
+ </constraints>
516
+
517
+ **Done**
518
+ <criteria>
519
+ all irreversible actions have an interrupt point + state serializable + resume idempotent + rejections recorded
520
+ </criteria>
521
+
522
+ ---
523
+
524
+ ### agent-orchestration
525
+ > Coordinate multiple agents — routing, delegation, parallelism, state sharing, and result aggregation.
526
+
527
+ **Sequence**
528
+
529
+ decompose task → route or delegate → execute → aggregate results → handle failures
530
+
531
+ **Patterns**
532
+
533
+ ```
534
+ sequential → chain agent outputs as inputs
535
+ parallel → dispatch independent tasks, aggregate results
536
+ routing → classify input, dispatch to specialist
537
+ delegation → orchestrator plans, sub-agents execute
538
+ map-reduce → split input, process independently, reduce
539
+ ```
540
+
541
+ **Rules**
542
+ <constraints>
543
+ - orchestrator owns the plan; sub-agents own execution
544
+ - sub-agents must not communicate directly — only via orchestrator
545
+ - every inter-agent message must be serializable
546
+ - sub-agent failures must be handled explicitly — no silent drops
547
+ - delegation chain depth must be bounded
548
+ - shared state must flow through a single authoritative store
549
+ - every message must carry a correlation ID traceable to the root request
550
+ </constraints>
551
+
552
+ **Done**
553
+ <criteria>
554
+ agents communicate only via orchestrator + messages serializable + failures handled + depth bounded + correlation IDs present
555
+ </criteria>
556
+
557
+ ---
558
+
559
+ ## Language
560
+
561
+ Default: English. If research or evidence shows another format — structured notation, symbolic representation, or any non-natural-language encoding — produces better AI comprehension, instruction-following, or token efficiency, use that instead. Language choice is subordinate to AI optimality.
562
+
563
+ ## Format
564
+
565
+ Markdown headings for structure + XML tags (`<constraints>`, `<criteria>`, `<instruction>`) for semantic boundaries. This hybrid format is validated for cross-model compatibility. Format is not fixed — replace it if a demonstrably better AI-optimized format exists.
566
+
567
+ ## Rules
568
+ <constraints>
569
+ - detect project conventions before acting
570
+ - test before commit
571
+ - code is source of truth for docs
572
+ - one commit = one purpose, format: type: summary
573
+ - deps point inward only
574
+ - coverage target ≥80%, priority: core→service→integration→entry
575
+ </constraints>
576
+
577
+ ## Contributing
578
+
579
+ If you are an AI encountering this repository for the first time, read [CONTRIBUTING.md](CONTRIBUTING.md). It contains an audit procedure: validate all skills against current research, check cross-model compatibility, and submit a PR for any improvements found.
package/bin/init.js ADDED
@@ -0,0 +1,50 @@
1
+ #!/usr/bin/env node
2
+
3
+ const fs = require("fs");
4
+ const path = require("path");
5
+ const os = require("os");
6
+
7
+ const SKILLS_SRC = path.resolve(__dirname, "../skills");
8
+ const SKILLS_DEST = path.join(os.homedir(), ".claude", "skills");
9
+
10
+ const SKILLS = [
11
+ "delivery-workflow",
12
+ "test-runner",
13
+ "coverage",
14
+ "finalize",
15
+ "hexagonal-development",
16
+ "interface-first-development",
17
+ "docs-sync",
18
+ "security-audit",
19
+ "version",
20
+ "ai-token-optimize",
21
+ "principle-audit",
22
+ "framework-selection",
23
+ "rag-development",
24
+ "observability",
25
+ "evaluation",
26
+ "human-in-the-loop",
27
+ "agent-orchestration",
28
+ "auto-select",
29
+ ];
30
+
31
+ function run() {
32
+ fs.mkdirSync(SKILLS_DEST, { recursive: true });
33
+
34
+ let installed = 0;
35
+ for (const skill of SKILLS) {
36
+ const src = path.join(SKILLS_SRC, skill, "SKILL.md");
37
+ if (!fs.existsSync(src)) {
38
+ console.warn(`⚠ skill not found: ${skill}`);
39
+ continue;
40
+ }
41
+ const destDir = path.join(SKILLS_DEST, skill);
42
+ fs.mkdirSync(destDir, { recursive: true });
43
+ fs.copyFileSync(src, path.join(destDir, "SKILL.md"));
44
+ installed++;
45
+ }
46
+
47
+ console.log(`✓ Installed ${installed} skills to ${SKILLS_DEST}`);
48
+ }
49
+
50
+ run();
package/package.json ADDED
@@ -0,0 +1,25 @@
1
+ {
2
+ "name": "ai-skill-interface",
3
+ "version": "1.4.0",
4
+ "description": "Abstract skill interfaces for AI — delivery, testing, architecture, security, and more. Skills define WHAT; AI decides HOW.",
5
+ "keywords": ["ai", "claude", "skills", "llm", "prompt", "engineering", "interface", "abstract"],
6
+ "license": "MIT",
7
+ "bin": {
8
+ "ai-skill-interface": "./bin/init.js"
9
+ },
10
+ "files": [
11
+ "skills/",
12
+ "bin/",
13
+ "README.md"
14
+ ],
15
+ "scripts": {
16
+ "test": "node test/init.test.js"
17
+ },
18
+ "engines": {
19
+ "node": ">=14"
20
+ },
21
+ "repository": {
22
+ "type": "git",
23
+ "url": "https://github.com/jaemyeong-hwnag/common-ai-skill.git"
24
+ }
25
+ }
@@ -0,0 +1,37 @@
1
+ ---
2
+ name: agent-orchestration
3
+ description: Coordinate multiple agents — routing, delegation, parallelism, state sharing, and result aggregation.
4
+ requires: [framework-selection]
5
+ ---
6
+
7
+ ## Sequence
8
+
9
+ decompose task → route or delegate → execute → aggregate results → handle failures
10
+
11
+ ## Patterns
12
+
13
+ ```
14
+ sequential → chain agent outputs as inputs
15
+ parallel → dispatch independent tasks, aggregate results
16
+ routing → classify input, dispatch to specialist
17
+ delegation → orchestrator plans, sub-agents execute
18
+ map-reduce → split input, process independently, reduce
19
+ ```
20
+
21
+ ## Rules
22
+
23
+ <constraints>
24
+ - orchestrator owns the plan; sub-agents own execution
25
+ - sub-agents must not communicate directly — only via orchestrator
26
+ - every inter-agent message must be serializable
27
+ - sub-agent failures must be handled explicitly — no silent drops
28
+ - delegation chain depth must be bounded
29
+ - shared state must flow through a single authoritative store
30
+ - every message must carry a correlation ID traceable to the root request
31
+ </constraints>
32
+
33
+ ## Done
34
+
35
+ <criteria>
36
+ agents communicate only via orchestrator + messages serializable + failures handled + depth bounded + correlation IDs present
37
+ </criteria>