@sallmarta/eye-hate-agent 1.0.2 → 1.0.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (74) hide show
  1. package/README.md +56 -304
  2. package/bin/eha.js +203 -118
  3. package/docs/templates/project-docs-template/index.md +208 -0
  4. package/docs/templates/project-docs-template/technical-guidelines/index.md +81 -0
  5. package/docs/templates/reusable-prompts/00-project-docs-bootstrap.md +40 -0
  6. package/docs/{vibes → templates}/reusable-prompts/00-project-docs-parity.md +4 -6
  7. package/docs/{vibes → templates}/reusable-prompts/00-project-docs-refresh.md +11 -11
  8. package/docs/{vibes → templates}/reusable-prompts/01-sdd-execute.md +1 -1
  9. package/docs/{vibes → templates}/reusable-prompts/02-sdd-discuss.md +3 -3
  10. package/{.agents/rules/agent.md → docs/templates/rules/agent-rules.md} +7 -12
  11. package/docs/{vibes → templates}/skills/api-design/SKILL.md +14 -25
  12. package/docs/{vibes/skills/full-verification → templates/skills/code-audit}/SKILL.md +36 -54
  13. package/docs/templates/skills/db-schema-design/SKILL.md +120 -0
  14. package/docs/templates/skills/devops-ci-cd/SKILL.md +99 -0
  15. package/docs/templates/skills/observability/SKILL.md +99 -0
  16. package/docs/{vibes/skills/parity → templates/skills/parity-audit}/SKILL.md +26 -52
  17. package/docs/templates/skills/refactor/SKILL.md +100 -0
  18. package/docs/templates/skills/security-audit/SKILL.md +149 -0
  19. package/docs/{vibes/skills/analysis → templates/skills/system-analysis}/SKILL.md +19 -41
  20. package/docs/{vibes/skills/test-authoring → templates/skills/system-tester}/SKILL.md +28 -46
  21. package/docs/templates/skills/ui-ux-design/SKILL.md +102 -0
  22. package/docs/templates/skills/wireframing/SKILL.md +88 -0
  23. package/package.json +4 -6
  24. package/src/engine/index.js +9 -12
  25. package/src/engine/install.js +67 -165
  26. package/src/engine/runtime-adapters.js +266 -50
  27. package/src/engine/skill-registry.js +72 -0
  28. package/src/engine/state.js +29 -7
  29. package/src/engine/workflow-registry.js +14 -23
  30. package/.claude/commands/eha/README.md +0 -3
  31. package/.claude/commands/eha/eha-bootstrap.md +0 -9
  32. package/.claude/commands/eha/eha-discuss.md +0 -9
  33. package/.claude/commands/eha/eha-execute.md +0 -9
  34. package/.claude/commands/eha/eha-parity.md +0 -9
  35. package/.claude/commands/eha/eha-refresh.md +0 -9
  36. package/.claude/commands/eha/eha-verify.md +0 -9
  37. package/.claude/rules/agent-rules.md +0 -64
  38. package/.github/instructions/agent-rules.instructions.md +0 -63
  39. package/.github/instructions/eha-workflows.instructions.md +0 -21
  40. package/docs/eyehateagent-contract.md +0 -475
  41. package/docs/eyehateagent-maintenance.md +0 -103
  42. package/docs/project-docs/changelog.md +0 -299
  43. package/docs/project-docs/foundation/architecture.md +0 -117
  44. package/docs/project-docs/foundation/status.md +0 -32
  45. package/docs/project-docs/foundation/workflow.md +0 -63
  46. package/docs/project-docs/index.md +0 -20
  47. package/docs/project-docs/testing.md +0 -73
  48. package/docs/vibes/project-docs-template/foundation/architecture.md +0 -79
  49. package/docs/vibes/project-docs-template/foundation/changelog.md +0 -53
  50. package/docs/vibes/project-docs-template/foundation/feature-inventory.md +0 -46
  51. package/docs/vibes/project-docs-template/foundation/phases.md +0 -60
  52. package/docs/vibes/project-docs-template/foundation/prd.md +0 -69
  53. package/docs/vibes/project-docs-template/foundation/status.md +0 -57
  54. package/docs/vibes/project-docs-template/foundation/workflow.md +0 -59
  55. package/docs/vibes/project-docs-template/getting-started.md +0 -52
  56. package/docs/vibes/project-docs-template/index.md +0 -66
  57. package/docs/vibes/project-docs-template/operations/ci-cd.md +0 -56
  58. package/docs/vibes/project-docs-template/operations/compliance.md +0 -46
  59. package/docs/vibes/project-docs-template/operations/governance.md +0 -46
  60. package/docs/vibes/project-docs-template/operations/observability.md +0 -53
  61. package/docs/vibes/project-docs-template/operations/production-runbook.md +0 -62
  62. package/docs/vibes/project-docs-template/operations/security.md +0 -49
  63. package/docs/vibes/project-docs-template/technical/api-contract.md +0 -49
  64. package/docs/vibes/project-docs-template/technical/database.md +0 -59
  65. package/docs/vibes/project-docs-template/technical/error-handling.md +0 -54
  66. package/docs/vibes/project-docs-template/technical/internationalization.md +0 -46
  67. package/docs/vibes/project-docs-template/technical/testing.md +0 -57
  68. package/docs/vibes/project-docs-template/technical/ui-ux.md +0 -68
  69. package/docs/vibes/project-docs-template/technical-guidelines/index.md +0 -52
  70. package/docs/vibes/reusable-prompts/00-project-docs-bootstrap.md +0 -59
  71. package/docs/vibes/skills/code-audit/SKILL.md +0 -170
  72. package/docs/vibes/skills/project-elevation/SKILL.md +0 -157
  73. package/docs/vibes/skills/test-authoring/references/patterns.md +0 -116
  74. package/docs/vibes/skills/test-authoring/references/test-types.md +0 -52
@@ -0,0 +1,40 @@
1
+ # Project Docs Bootstrap Reusable Prompt
2
+
3
+ Generate the **initial project documentation set** for a repository.
4
+ You must dynamically adjust your behavior based on the current state of the repository.
5
+
6
+ ## Step 1: State & Complexity Detection (The Adaptive Taxonomy)
7
+ Before writing any documents, analyze the workspace to determine its state (Zero Docs vs. Unclear Docs vs. Mature Docs) and its complexity.
8
+
9
+ Based on the repository's complexity, you MUST recommend one of the following **Taxonomy Tiers**:
10
+
11
+ 1. **Tier 1: Lite Profile**
12
+ - *Target:* Small scripts, micro-libraries, single-component repos.
13
+ - *Files Generated:* `index.md`, `getting-started.md`, `foundation/prd.md`, `foundation/architecture.md`, `foundation/status.md`.
14
+ 2. **Tier 2: Standard Profile**
15
+ - *Target:* Typical web applications, APIs, standard services.
16
+ - *Files Generated:* Everything in Tier 1 PLUS `development/testing.md`, `development/database.md`, `development/ui-ux.md`, `development/api-contract.md`, `operations/ci-cd.md`.
17
+ 3. **Tier 3: Enterprise Profile**
18
+ - *Target:* Large-scale platforms, regulated systems, monorepos.
19
+ - *Files Generated:* Everything in Tier 2 PLUS `operations/governance.md`, `operations/security-compliance.md` (merged), `operations/observability-error-handling.md` (merged), `operations/production-runbook.md`, `development/internationalization.md`, `foundation/phases.md` (merged phases + feature inventory), `foundation/changelog.md`.
20
+
21
+ **STOP AND ASK:** Present your analysis of the repo's complexity and ask the user: *"Which Taxonomy Tier should I generate?"* Do not proceed until the user approves a tier.
22
+
23
+ ## Step 2: Document Generation
24
+ Once the user approves a tier, strictly follow the 4-layer file structure (`foundation/`, `operations/`, `development/`, `technical-guidelines/`).
25
+
26
+ ### Required Behavior
27
+ 1. **Dynamic Generation from Registry:** You MUST read the master registry file `docs/templates/project-docs-template/index.md` to obtain the universal stable headings schema and the unique domain-specific headings for each document type within the approved tier. Generate each document dynamically using this structural mapping.
28
+ 2. Create project-specific truth in `docs/project-docs/`, not in the reusable prompt output itself.
29
+ 3. Do not invent details. Mark uncertain facts as `TBD` or `Assumption`.
30
+ 4. If reverse-engineering from code, explicitly state "Inferred from codebase" in the generated document until the user confirms it.
31
+ 5. **DO NOT generate files outside the approved tier.**
32
+
33
+ ## Final Pass
34
+ Before finishing, check that:
35
+ 1. No files are generated in the root of `project-docs/` except `index.md` and `getting-started.md`. Everything else must be in its respective subfolder.
36
+ 2. `foundation/architecture.md` and `development/testing.md` do not conflict.
37
+ 3. The generated documents strictly match the approved Taxonomy Tier and structural definitions cataloged in the master registry.
38
+
39
+ ## Inputs
40
+ Use the project brief, codebase, and constraints provided below to begin your Phase 1 analysis.
@@ -1,7 +1,5 @@
1
1
  # Project Docs Parity Reusable Prompt
2
2
 
3
- Read `docs/eyehateagent-contract.md` first.
4
-
5
3
  Audit the repository for **documentation-system drift**.
6
4
 
7
5
  ## Goal
@@ -18,8 +16,8 @@ Check at least these areas when present:
18
16
  - relevant code, tests, configs, or runtime-facing artifacts when a finding depends on current implementation behavior or source-of-truth ownership
19
17
  - clearly named reference or archive folders such as `docs-legacy/`, `docs-old/`, `archive/`, or `reference/`
20
18
  - platform instruction surfaces (mirrored rule files)
21
- - `docs/vibes/skills/`
22
- - `docs/vibes/reusable-prompts/`
19
+ - `docs/templates/skills/`
20
+ - `docs/templates/reusable-prompts/`
23
21
  - workflow docs and handoff docs
24
22
 
25
23
  ### High-Value Drift Categories
@@ -40,11 +38,11 @@ Check at least these areas when present:
40
38
  ## Required Behavior
41
39
 
42
40
  1. Use project docs as the primary source of truth for documentation ownership and doc-to-doc drift unless the repository explicitly states otherwise.
43
- 2. Treat `docs/eyehateagent-contract.md` as the ownership map.
41
+ 2. Use the EHA Project Doc Rules above as the ownership map.
44
42
  3. Treat `docs/project-docs/index.md` and `docs/project-docs/technical-guidelines/index.md` as the authoritative inventories for optional regular docs and guideline docs when present.
45
43
  4. Treat clearly named reference or archive folders such as `docs-legacy/`, `docs-old/`, `archive/`, or `reference/` as migration input only, not as owner-doc paths.
46
44
  5. When evaluating legacy material, classify it by the durable concern it governs rather than by its legacy name or path. Treat names such as `epic`, `milestone`, `roadmap`, `protocol`, `procedure`, `policy`, or `standard` as hints only.
47
- 6. Report likely mappings when content points to an active owner even if naming differs, such as phased-planning content that should map to `foundation/phases/` or technical-rule content that should map to `technical-guidelines/`.
45
+ 6. Report likely mappings when content points to an active owner even if naming differs, such as phased-planning content that should map to `foundation/phases.md` or technical-rule content that should map to `technical-guidelines/`.
48
46
  7. Distinguish between:
49
47
  - true contradiction
50
48
  - stale summary
@@ -1,7 +1,5 @@
1
1
  # Project Docs Refresh Reusable Prompt
2
2
 
3
- Read `docs/eyehateagent-contract.md` first.
4
-
5
3
  Refresh the existing project documentation after a change in scope, stack, workflow, architecture, testing policy, or product behavior.
6
4
 
7
5
  ## Goal
@@ -11,7 +9,7 @@ Update **only the docs that own the changed information** while keeping the docu
11
9
  ## Required Behavior
12
10
 
13
11
  1. Read the current project docs before editing anything.
14
- 2. Use `docs/eyehateagent-contract.md` to identify which files own the changed information.
12
+ 2. Use the EHA Project Doc Rules above to identify which files own the changed information.
15
13
  3. Read `docs/project-docs/index.md` and `docs/project-docs/technical-guidelines/index.md` when present and treat them as the authoritative inventories for optional docs and guideline docs.
16
14
  4. When clearly named reference or archive folders such as `docs-legacy/`, `docs-old/`, `archive/`, or `reference/` exist, read them as migration input only and do not treat them as owner-doc paths.
17
15
  5. Update only the affected docs and any documents that summarize them.
@@ -45,19 +43,21 @@ Update **only the docs that own the changed information** while keeping the docu
45
43
 
46
44
  ## Ownership Examples
47
45
 
48
- - stack or dependency changes → `foundation/architecture.md`, `technical/testing.md`
49
- - feature scope changes → `foundation/prd.md`, `foundation/feature-inventory.md`, `foundation/status.md`
46
+ - stack or dependency changes → `foundation/architecture.md`, `development/testing.md`
47
+ - feature scope changes → `foundation/prd.md`, `foundation/status.md`
50
48
  - detailed requirements or acceptance changes → `foundation/prd.md`, `foundation/status.md`
51
- - workflow or roadmap changes → `foundation/status.md`, `foundation/phases/index.md`, workflow docs if present
52
- - validation / CI changes → `technical/testing.md`, `getting-started.md`
53
- - production environment, rollout, rollback, or smoke-check changes → `operations/production-runbook.md`, `foundation/architecture.md`, `technical/testing.md`
49
+ - workflow or roadmap changes → `foundation/status.md`, `foundation/phases.md`, workflow docs if present
50
+ - validation / CI changes → `development/testing.md`, `getting-started.md`
51
+ - production environment, rollout, rollback, or smoke-check changes → `operations/production-runbook.md`, `foundation/architecture.md`, `development/testing.md`
54
52
  - API or integration changes → relevant API / integration docs plus `foundation/architecture.md`
53
+ - security or compliance changes → `operations/security-compliance.md`
54
+ - observability, logging, or error-handling changes → `operations/observability-error-handling.md`
55
55
  - optional or conditional doc inventory changes → `docs/project-docs/index.md` plus the affected optional owner docs
56
56
  - cross-cutting technical conventions or implementation rules → relevant `technical-guidelines/*.md`, `technical-guidelines/index.md`, and any summarizing core docs that reference them
57
57
  - documentation-system migration from legacy docs → active owner docs under `docs/project-docs/` first, with `docs-legacy/`, `docs-old/`, or other clearly named archive/reference folders used only as source material
58
- - semantic legacy-name normalization → map legacy names by content, for example `epic` or `roadmap` material to `foundation/phases/` and `protocol` or `standard` material to `technical-guidelines/` when their governed concern matches those owners
58
+ - semantic legacy-name normalization → map legacy names by content, for example `epic` or `roadmap` material to `foundation/phases.md` and `protocol` or `standard` material to `technical-guidelines/` when their governed concern matches those owners
59
59
  - legacy technical-guidance promotion → `docs/project-docs/technical-guidelines/*.md`, `technical-guidelines/index.md`, and any summarizing core docs that now depend on those active guidelines
60
- - legacy phased-planning promotion → `docs/project-docs/foundation/phases/index.md`, the relevant phase or epic docs, `foundation/status.md`, and `docs/project-docs/index.md`
60
+ - legacy phased-planning promotion → `docs/project-docs/foundation/phases.md`, `foundation/status.md`, and `docs/project-docs/index.md`
61
61
 
62
62
  ## Output Contract
63
63
 
@@ -72,7 +72,7 @@ Your result should state:
72
72
 
73
73
  Before finishing, check that:
74
74
 
75
- 1. the updated docs still match the contract in `docs/eyehateagent-contract.md`
75
+ 1. the updated docs still match the EHA Project Doc Rules above
76
76
  2. platform instruction surfaces and skills would now read the correct project-specific truth
77
77
  3. no stale summary remains in `foundation/status.md`, `docs/project-docs/index.md`, `technical-guidelines/index.md`, or other index docs
78
78
 
@@ -31,4 +31,4 @@ Translate a newly updated project specification into tested, working code by fol
31
31
  - The user's prompt requesting the execution of a feature.
32
32
  - `docs/project-docs/foundation/prd.md`
33
33
  - `docs/project-docs/foundation/architecture.md`
34
- - `docs/project-docs/technical/testing.md`
34
+ - `docs/project-docs/development/testing.md`
@@ -12,7 +12,7 @@ Act as a Senior Engineer / Agile Product Manager to help the user brainstorm and
12
12
  - API shapes and payload structures.
13
13
  - UI/UX constraints or responsive layouts.
14
14
  - Data model changes (new tables, columns, relations).
15
- 3. **Draft the Spec:** Once the user answers your questions and you reach an agreement, output a drafted, markdown-formatted snippet that is ready to be injected into the specific target documents (e.g., `foundation/prd.md`, `foundation/architecture.md`, `technical/api-contract.md`).
15
+ 3. **Draft the Spec:** Once the user answers your questions and you reach an agreement, output a drafted, markdown-formatted snippet that is ready to be injected into the specific target documents (e.g., `foundation/prd.md`, `foundation/architecture.md`, `development/api-contract.md`).
16
16
  4. **Final Approval:** Ask the user: "Should I execute the SDD workflow (`01-sdd-execute.md`) with these specifications?"
17
17
 
18
18
  ## Output Contract
@@ -23,5 +23,5 @@ Act as a Senior Engineer / Agile Product Manager to help the user brainstorm and
23
23
  ## Inputs
24
24
 
25
25
  - The user's rough feature idea or concept.
26
- - `docs/project-docs/foundation/prd.md` (to understand current scope)
27
- - `docs/project-docs/foundation/architecture.md` (to understand current stack constraints)
26
+ - Read `docs/project-docs/foundation/prd.md` if it exists (to understand current scope).
27
+ - Read `docs/project-docs/foundation/architecture.md` if it exists (to understand current stack constraints).
@@ -1,11 +1,3 @@
1
- ---
2
- trigger: always_on
3
- ---
4
-
5
- ---
6
- description: "Lean always-on rules for guardrails, context, intake, verification, and doc sync."
7
- ---
8
-
9
1
  # Agent Rules
10
2
 
11
3
  ## 1. Guardrails & Approach
@@ -22,7 +14,10 @@ Protect the prompt prefix cache and manage context-window capacity to preserve t
22
14
 
23
15
  - **2.1** Keep always-on context small. Keep rules generic and leave project-specific facts in project docs under `docs/project-docs/`.
24
16
  - **2.2** Read the smallest owning doc that resolves the decision rather than scanning the entire repository.
25
- - **2.3** **Prefix Stability (Gemini):** Never reorder tool definitions, system instructions, or serialized schemas mid-session — the implicit prefix cache requires a byte-identical prompt prefix for the 90% cached-token discount. Do not inject dynamic content (timestamps, session IDs, reordered JSON keys) before or between stable blocks. Append all per-turn dynamic data after the stable prefix. If cache-hit rates drop unexpectedly, suspect non-deterministic serialization or framework-injected metadata before other causes.
17
+ - **2.3** **Agent-Specific Cache Strategies:**
18
+ - **Claude (Prefix & Lookback Integrity):** Cache reads cost 90% less but require a byte-identical prefix in tools -> system -> messages order. Never reorder, add, or remove tool definitions mid-session. Never inject dynamic content (timestamps, per-request IDs) into the system prompt. In heavy agentic loops, be aware of the ~20-block lookback window; explicitly request the user to perform a minor conversational interaction to prevent silent cache misses.
19
+ - **Antigravity (Prefix Stability):** Never reorder tool definitions, system instructions, or serialized schemas mid-session. The implicit prefix cache requires a byte-identical prompt prefix for the 90% cached-token discount. Append all per-turn dynamic data after the stable prefix. If cache-hit rates drop unexpectedly, suspect non-deterministic serialization.
20
+ - **Copilot (Context Efficiency):** Under usage-based billing, cached tokens still cost AI Credits — keep instruction files and session context lean rather than exhaustive. Prefer explicit context (`#file`, `#selection`) over broad implicit context. Start a fresh session or use `/clear` when switching to an unrelated task to prevent context clutter.
26
21
  - **2.4** **Session Continuity (No Dynamic Compaction):** Never modify, compact, or delete prior chat turns mid-session—this destroys the hardware prefix cache. If context reaches ~65% capacity, compile a comprehensive session-handoff.md to `active-repo/memories/session/session-handoff.md` (overwriting any previous handoff, and ensure `active-repo/memories/session/` is added to `.gitignore` if created). The handoff must contain a full, detailed summary of the active conversation's progress, decisions, and open threads, strictly redact all sensitive information (such as API keys, passwords, credentials, or PII), and incorporate any user-provided compaction arguments as next-session focus areas. Prompt the user to run `/clear` or open a new session with this file loaded, providing a copy-pasteable short prompt (e.g., "Resume session from memories/session/session-handoff.md") to load the handoff instantly.
27
22
 
28
23
  ## 3. Intake & Scope Alignment
@@ -37,7 +32,7 @@ Structure incoming requests before acting to reduce rework and catch ambiguity e
37
32
  5. Treat a user-provided list as full scope unless the user changes it.
38
33
  6. Confirm if the plan could materially change scope, output, or direction.
39
34
  7. Then proceed.
40
- - **3.2** Skip the intake checklist only for trivial single-step edits.
35
+ - **3.2** **Lite Mode (Micro-Tasks):** Skip the 7-step intake checklist and SDD requirements ONLY if the user explicitly triggers Lite Mode (e.g., using a `/lite` slash command, or prefixing their request with "Lite task:") AND the task is a trivial, isolated edit (e.g., typo fix, single UI tweak). For Lite Mode, bypass PRD validation and execute immediately to save time.
41
36
 
42
37
  ## 4. Docs, Verification, and Completion
43
38
 
@@ -58,9 +53,9 @@ Embed the critical behavioral rules from the contract so agents follow them with
58
53
  - **5.2 Decision Precedence:** Resolve routing, conflict, and behavior decisions in this strict order:
59
54
  1. User's requested goal and output.
60
55
  2. User's explicit constraints or preferences.
61
- 3. The active contract (`docs/eyehateagent-contract.md`) and the owning project docs under `docs/project-docs/`.
56
+ 3. The active EHA rules and the owning project docs under `docs/project-docs/`.
62
57
  4. Attached context (skills, notes, or examples) treated as relevance hints unless made mandatory.
63
58
  5. Automatic agent judgment.
64
59
  - **5.3 Failure & Fallback:** If a required project doc is missing, note the gap and create the smallest owning doc that unblocks the task. If code, tests, configs, or runtime-facing artifacts conflict with active docs and authority is unclear, do not guess: surface the conflict, cite the evidence, and ask the user before choosing the fix path.
65
60
  - **5.4 Codebase & Comment Integrity:** Maintain absolute documentation and codebase integrity when making modifications. Preserve all existing comments, docstrings, formatting, and structures that are unrelated to your changes unless explicitly instructed otherwise. Never delete unrelated comments or placeholder code silently.
66
- - **5.5 Completion & Verification:** End each task with the requested output and the narrowest applicable validation from `docs/project-docs/testing.md` (or a structural review with an explicit limitation if no executable check exists). Re-read output for correctness, edge cases, and unexpected side effects before finishing. Include a doc-sync check when ownership changed.
61
+ - **5.5 Completion & Verification:** End each task with the requested output and the narrowest applicable validation from `docs/project-docs/testing.md` (or a structural review with an explicit limitation if no executable check exists). Re-read output for correctness, edge cases, and unexpected side effects before finishing. Include a doc-sync check when ownership changed.
@@ -4,7 +4,7 @@ description: "Project-aware expert-role contract design for APIs, interfaces, re
4
4
  argument-hint: "Describe the boundary, interface, endpoint, message contract, or service behavior to design or review"
5
5
  ---
6
6
 
7
- # Interface & API Contract Design — Project-Aware
7
+ # API Design
8
8
 
9
9
  Produces a **project-aware, expert-level contract design or design review** by reading the repository's project docs first, then applying a reusable method to the current boundary type.
10
10
 
@@ -19,23 +19,18 @@ This skill is intentionally reusable across:
19
19
 
20
20
  It should **not** assume one language, framework, transport, or architecture style until the project docs confirm them.
21
21
 
22
- ---
23
-
24
22
  ## Required Project Inputs
25
23
 
26
24
  | Document | Why it matters |
27
25
  | --- | --- |
28
-
29
26
  | `docs/project-docs/foundation/architecture.md` | Defines stack, architecture boundaries, dependency rules, and integration patterns |
30
27
  | `docs/project-docs/foundation/prd.md` | Clarifies scope, constraints, stakeholders, and non-goals |
31
- | `docs/project-docs/technical/testing.md` | Defines how the contract should be validated |
28
+ | `docs/project-docs/development/testing.md` | Defines how the contract should be validated |
32
29
  | Relevant feature docs, API docs, or guidelines | Provide domain-specific rules, request/response shapes, workflows, and edge cases |
33
30
  | Existing code or contracts in the repo | Show local naming, layering, serialization, validation, and error conventions |
34
31
 
35
32
  If the repository lacks the contract-defining docs needed for the task, call that out and create or update the missing docs instead of inventing local rules in the skill.
36
33
 
37
- ---
38
-
39
34
  ## When To Use
40
35
 
41
36
  Use this skill when designing or reviewing one of these boundary types.
@@ -49,8 +44,6 @@ Use this skill when designing or reviewing one of these boundary types.
49
44
  | Event or message contract | payload schema, producer/consumer expectations, ordering, retry, dead-letter rules |
50
45
  | Module boundary | public interface, dependency direction, allowed imports, extension points |
51
46
 
52
- ---
53
-
54
47
  ## Procedure
55
48
 
56
49
  ### Step 1 — Identify the contract owner
@@ -141,8 +134,6 @@ Examples:
141
134
 
142
135
  The output should fit the repository style and include enough detail to implement safely without locking the repo into one stack-specific pattern that the docs do not support.
143
136
 
144
- ---
145
-
146
137
  ## Output Contract
147
138
 
148
139
  When using this skill, the output should include:
@@ -155,8 +146,6 @@ When using this skill, the output should include:
155
146
  6. verification strategy
156
147
  7. open questions that still require product or architecture decisions
157
148
 
158
- ---
159
-
160
149
  ## Quality Checks
161
150
 
162
151
  Use this checklist when reviewing an existing contract:
@@ -169,8 +158,6 @@ Use this checklist when reviewing an existing contract:
169
158
  - Does the contract create hidden coupling or leak implementation details?
170
159
  - Is there a clear verification strategy in `testing.md`?
171
160
 
172
- ---
173
-
174
161
  ## Anti-Patterns
175
162
 
176
163
  - Embedding one stack's rules into the skill instead of reading project docs
@@ -180,19 +167,21 @@ Use this checklist when reviewing an existing contract:
180
167
  - Ignoring versioning, compatibility, or migration concerns for externally visible contracts
181
168
  - Over-designing the contract far beyond the current scope in `prd.md`
182
169
 
183
- ---
184
-
185
- ## Natural Prompt Shapes
186
-
187
- - "Design the contract for this API or service boundary."
188
- - "Check whether this endpoint or DTO shape is designed correctly."
189
- - "Define the interface, error contract, and validation rules for this boundary."
190
- - "Review whether this event or repository contract matches the architecture."
170
+ ## Output Contract
191
171
 
192
- ---
172
+ When using this skill, the output should include:
173
+ 1. the boundary type
174
+ 2. the project docs consulted
175
+ 3. the proposed contract shape
176
+ 4. validation and error rules
177
+ 5. ownership and dependency implications
178
+ 6. verification strategy
179
+ 7. open questions that still require product or architecture decisions
193
180
 
194
- ## Example Requests
181
+ ## Neutral Prompt Shape
182
+ `@agent use api-design on [Target Entity/Feature] focusing on [Specific Constraints/Version].`
195
183
 
184
+ ## Example Prompt
196
185
  - "Design the repository contract for this feature"
197
186
  - "Review this controller and DTO boundary"
198
187
  - "Design an event payload for this workflow"
@@ -1,37 +1,32 @@
1
1
  ---
2
- name: full-verification
2
+ name: "code-audit"
3
3
  description: "Project-aware expert-role broad verification that reads project docs first, classifies the verification target, and routes to the best specialist skill for executable or non-executable checks across code, contracts, docs, architecture, quality, security, reliability, and project health."
4
4
  argument-hint: "Describe what should be verified against the contract, project docs, guidelines, code, APIs, architecture, or repository state"
5
5
  ---
6
6
 
7
- # Full Verification — Project-Aware
7
+ # Code Audit
8
8
 
9
9
  Provides an **expert, project-aware broad verification entry point** for requests that ask whether something is correct, consistent, healthy, complete, or aligned with the repository's contract and project docs.
10
10
 
11
11
  This skill is **routing-first**. Its primary job is to identify the dominant verification question and route to the single best specialist skill rather than duplicating every verification procedure itself.
12
12
 
13
- This skill is intentionally **not tied to any single stack or framework**. When executable checks are needed, it should select the correct framework, commands, and conventions from the project's `technical/testing.md`, `foundation/architecture.md`, and local repository patterns.
14
-
15
- ---
13
+ This skill is intentionally **not tied to any single stack or framework**. When executable checks are needed, it should select the correct framework, commands, and conventions from the project's `development/testing.md`, `foundation/architecture.md`, and local repository patterns.
16
14
 
17
15
  ## Required Project Inputs
18
16
 
19
17
  | Document | Why it matters |
20
18
  | --- | --- |
21
- | `docs/eyehateagent-contract.md` | Defines routing, ownership, precedence, and the active skill model |
22
-
23
- | `docs/project-docs/technical/testing.md` | Defines executable and non-executable verification rules, commands, and fallback policy |
24
- | `docs/project-docs/foundation/architecture.md` | Defines boundaries, stack, interfaces, dependency rules, and runtime assumptions |
25
- | `docs/project-docs/foundation/prd.md` | Defines goals, scope, non-goals, and success criteria |
19
+ | EHA Rules | Defines routing, ownership, precedence, and the active skill model |
20
+ | `docs/project-docs/foundation/architecture.md` | Defines boundaries, dependencies, stack choices, and anti-violation rules |
21
+ | `docs/project-docs/development/testing.md` | Defines available validation and evidence strength |
22
+ | `docs/project-docs/foundation/prd.md` | Clarifies scope, non-goals, and project stage |
26
23
  | `docs/project-docs/foundation/status.md` | Defines maturity, roadmap, active workstreams, and readiness context |
27
24
  | Relevant guideline docs under `docs/project-docs/technical-guidelines/` | Define technical standards such as API, logging, database, error-handling, code style, or design patterns |
28
25
  | Relevant code, tests, docs, contracts, and repository artifacts | Provide the actual evidence surfaces to verify against |
29
26
 
30
27
  If required project docs are missing, surface that gap explicitly and limit confidence rather than guessing.
31
28
 
32
- ---
33
-
34
- ## When To Use
29
+ ## When to Use
35
30
 
36
31
  | Trigger | Example request |
37
32
  | --- | --- |
@@ -43,15 +38,12 @@ If required project docs are missing, surface that gap explicitly and limit conf
43
38
 
44
39
  Use a specialist skill directly when the dominant question is already obvious:
45
40
 
46
- - `test-authoring` for executable verification strategy, stack-aware test selection, and test-writing decisions
41
+ - `system-tester` for executable verification strategy, stack-aware test selection, and test-writing decisions
47
42
  - `code-audit` for code correctness, bug, risk, security, and boundary review
48
- - `parity` for repository drift across docs, platform instruction surfaces, skills, prompts, and summaries
49
- - `project-elevation` for forward-looking improvement and readiness planning
50
- - `analysis` for root-cause reasoning, trade-off evaluation, and requirement or decision analysis
43
+ - `parity-audit` for repository drift across docs, platform instruction surfaces, skills, prompts, and summaries
44
+ - `system-analysis` for root-cause reasoning, trade-off evaluation, and requirement or decision analysis
51
45
  - `api-design` for API, schema, interface, or boundary contract design and review
52
46
 
53
- ---
54
-
55
47
  ## Procedure
56
48
 
57
49
  ### Step 1 — Identify the verification target
@@ -86,12 +78,11 @@ Prefer the single strongest verification path unless the user explicitly asks fo
86
78
 
87
79
  | Dominant verification question | Route to |
88
80
  | --- | --- |
89
- | How should this be verified, tested, or regression-checked in the current stack? | `test-authoring` |
81
+ | How should this be verified, tested, or regression-checked in the current stack? | `system-tester` |
90
82
  | Is this code correct, safe, consistent, and free of obvious bugs or boundary violations? | `code-audit` |
91
83
  | Does this API or interface contract match the docs, code, and boundary rules? | `api-design` |
92
- | Do the docs, platform instruction surfaces, skills, prompts, and repository artifacts still agree? | `parity` |
93
- | What should improve next, and how healthy or mature is this project at its current stage? | `project-elevation` |
94
- | Do the requirements, trade-offs, design decisions, or explanations hold up? | `analysis` |
84
+ | Do the docs, platform instruction surfaces, skills, prompts, and repository artifacts still agree? | `parity-audit` |
85
+ | Do the requirements, trade-offs, design decisions, or explanations hold up? | `system-analysis` |
95
86
 
96
87
  Example prompt shapes by verification category:
97
88
 
@@ -108,7 +99,7 @@ Example prompt shapes by verification category:
108
99
 
109
100
  When executable validation is required, choose the appropriate framework and commands from project docs and local repo conventions.
110
101
 
111
- Examples of the decision pattern:
102
+ **Examples** of the decision pattern:
112
103
 
113
104
  - Go project -> use the Go testing approach documented in `testing.md`
114
105
  - Python project -> use the Python testing approach documented in `testing.md`
@@ -126,7 +117,20 @@ State:
126
117
  - what evidence and checks should be used
127
118
  - what remains outside the chosen verification path
128
119
 
129
- ---
120
+ ## Quality Check
121
+
122
+ - No finding without evidence from the target artifact
123
+ - No severity inflation
124
+ - No style nitpicks disguised as bugs
125
+ - No architecture complaint without reference to actual project boundaries
126
+ - No recommendation that ignores project stage or available validation
127
+
128
+ ## Anti-Pattern
129
+
130
+ - Calling something dead code without checking workspace usage
131
+ - Calling something a bug without defining the failure condition
132
+ - Criticizing a pattern that the project explicitly chose in `architecture.md`
133
+ - Recommending wide rewrites before testing a local fix or a smaller boundary change
130
134
 
131
135
  ## Output Contract
132
136
 
@@ -141,33 +145,11 @@ When using this skill, the output should include:
141
145
  7. any residual risks or uncovered verification areas
142
146
  8. whether user direction is required before deciding between conflicting docs and implementation
143
147
 
144
- ---
145
-
146
- ## Quality Checks
147
-
148
- - Route to the single best specialist skill unless the user explicitly asks for a broader sweep
149
- - Do not duplicate another skill's full procedure inside this skill
150
- - Do not assume frameworks or commands before checking the project docs
151
- - Keep executable and non-executable verification clearly separated
152
- - State when confidence is limited by missing docs or missing evidence
153
- - Do not assume docs or implementation win when the repository does not define authority for the disputed fact
154
-
155
- ---
156
-
157
- ## Anti-Patterns
158
-
159
- - Treating verification as synonymous with writing tests
160
- - Hardcoding stack-specific frameworks into the skill text
161
- - Routing a docs-drift problem to `code-audit`
162
- - Routing a forward-looking improvement question to `analysis`
163
- - Running a multi-skill sweep by default when one dominant verification path would answer the request
164
- - Claiming the repository passed a check when the relevant evidence or command was never examined
165
-
166
- ---
167
-
168
- ## Example Requests
148
+ ## Neutral Prompt Shape
149
+ `@agent use code-audit on [Target File/Change] focusing on [Specific Risks/Boundaries].`
169
150
 
170
- - "Verify this feature against the project docs, contract, and actual code"
171
- - "Check whether this API matches the docs, code, and guideline standards"
172
- - "Evaluate this project for health, maturity, architecture drift, and consistency"
173
- - "Use the right verification approach for this stack and tell me what to run"
151
+ ## Example Prompt
152
+ - "Audit this service for boundary violations"
153
+ - "Review this change for correctness risks"
154
+ - "Check this module for dead code and duplication"
155
+ - "Audit this workflow implementation for operability gaps"
@@ -0,0 +1,120 @@
1
+ ---
2
+ name: "db-schema-design"
3
+ description: "Project-aware expert-role database schema and modeling design. Reads project docs first, then produces a schema design, migration plan, or query optimization strategy consistent with the current repository constraints."
4
+ argument-hint: "Describe the domain entities, tables, relationships, or queries to design or review"
5
+ ---
6
+
7
+ # Database Schema Design
8
+
9
+ Produces a **project-aware, expert-level database schema design or review** by reading the repository's project docs first, then applying a rigorous data modeling method.
10
+
11
+ This skill is reusable across:
12
+
13
+ - Relational Databases (PostgreSQL, MySQL, Aurora, etc)
14
+ - Document / NoSQL Databases (MongoDB, DynamoDB, etc)
15
+ - In-memory / Cache Models (Redis, Memcache, etc)
16
+ - Event Stores (Kafka, Pulsar, etc)
17
+
18
+ It should **not** assume a specific database engine, ORM, or normalization strategy until the project docs confirm them.
19
+
20
+ ## Required Project Inputs
21
+
22
+ | Document | Why it matters |
23
+ | --- | --- |
24
+ | `docs/project-docs/development/database.md` | Defines the actual database engines, ORMs, migration tools, naming conventions, and constraints. |
25
+ | `docs/project-docs/foundation/architecture.md` | Defines where data logic lives (e.g., repository layer) and integration boundaries. |
26
+ | `docs/project-docs/foundation/prd.md` | Clarifies the feature scale, expected data volume, and access patterns. |
27
+ | `docs/project-docs/development/testing.md` | Defines how data layer code and migrations should be validated. |
28
+
29
+ If the repository lacks the database docs needed for the task, call that out and create or update the missing docs instead of inventing local rules in the skill.
30
+
31
+ ## When to Use
32
+
33
+ Use this skill when designing or reviewing one of these boundary types:
34
+
35
+ | Boundary type | Typical artifacts |
36
+ | --- | --- |
37
+ | Schema Creation | Tables, columns, types, constraints, foreign keys, indexes |
38
+ | Migrations | Up/Down migration scripts, data backfills, zero-downtime strategies |
39
+ | Query Optimization | EXPLAIN plans, index selection, join reduction |
40
+ | Data Modeling | Domain entities, aggregates, document embedding vs referencing |
41
+ | Caching | Cache keys, TTL strategies, eviction policies |
42
+
43
+ ## Procedure
44
+
45
+ ### Step 1 — Identify the Engine and Tools
46
+ Extract from `database.md`:
47
+ - the primary database engine (e.g., Postgres 15)
48
+ - the schema management/migration tool (e.g., Prisma, Flyway, Alembic)
49
+ - the application access pattern (raw SQL vs Query Builder vs ORM)
50
+
51
+ ### Step 2 — Identify the Access Patterns
52
+ Extract from `prd.md` and feature docs:
53
+ - Read/Write ratios (is it write-heavy or read-heavy?)
54
+ - Data volume expectations
55
+ - Latency requirements
56
+ - Multi-tenant data segregation rules (if any)
57
+
58
+ ### Step 3 — Design the Schema Shape
59
+ Design the minimal schema that supports the required behavior.
60
+ Specify:
61
+ - Entity names and relationships (1:1, 1:N, M:N)
62
+ - Strict data types (prefer specific types like `UUID` or `TIMESTAMPTZ` over generic strings if the engine supports it)
63
+ - Constraints (NOT NULL, UNIQUE, CHECK)
64
+ - Primary and Foreign keys
65
+
66
+ ### Step 4 — Define Indexing and Performance Strategies
67
+ Define the indexes required for the access patterns identified in Step 2.
68
+ - Consider composite indexes for multi-column queries.
69
+ - Consider partial/filtered indexes for specific status queries.
70
+ - Avoid over-indexing to protect write performance.
71
+
72
+ ### Step 5 — Design the Migration Plan
73
+ Specify how the schema will be deployed safely:
74
+ - Can this be applied without locking tables?
75
+ - Does it require a multi-phase zero-downtime migration (e.g., Add column -> write to both -> backfill -> drop old column)?
76
+ - How will the rollback (down migration) function?
77
+
78
+ ### Step 6 — Define Verification Requirements
79
+ Use `testing.md` to decide how this will be validated.
80
+ Examples:
81
+ - Schema validation tests
82
+ - Query performance benchmarks
83
+ - Migration dry-run tests
84
+
85
+ ## Quality Check
86
+
87
+ Use this checklist when reviewing an existing schema or PR:
88
+
89
+ - Does the schema follow the project's naming conventions (e.g., snake_case vs camelCase)?
90
+ - Are foreign keys properly enforcing referential integrity?
91
+ - Are appropriate constraints in place to prevent bad data at the database level?
92
+ - Will the migration lock a critical table in production?
93
+ - Is there a clear separation between the database schema and the application's domain model?
94
+
95
+ ## Anti-Pattern
96
+
97
+ - Assuming an ORM is used when the project strictly uses raw SQL.
98
+ - Suggesting a heavy relational model for a project that uses a document database.
99
+ - Proposing migrations that lock large tables (e.g., adding a column with a default value in older Postgres versions) without a zero-downtime strategy.
100
+ - Ignoring data types and using strings for dates, JSON, or booleans.
101
+ - Forgetting to define a rollback strategy for a destructive migration.
102
+
103
+ ## Output Contract
104
+
105
+ When using this skill, the output should include:
106
+
107
+ 1. the database engine and tools being targeted
108
+ 2. the project docs consulted
109
+ 3. the proposed schema / entity model
110
+ 4. indexes and constraints
111
+ 5. the migration strategy and risk assessment
112
+ 6. verification strategy
113
+ 7. open questions regarding data volume or access patterns
114
+
115
+ ## Neutral Prompt Shape
116
+ `@agent use db-schema-design on [Target Feature/Entity] focusing on [Specific Requirement/Database Type].`
117
+
118
+ ## Example Prompt
119
+ - "Design the schema migration for the new order tracking feature."
120
+ - "Optimize the indexing for this query based on read-heavy patterns."