devloom 1.0.0 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (140) hide show
  1. package/.ai/core.dsl +44 -0
  2. package/.ai/skills.dsl +39 -0
  3. package/.ai/verify.dsl +97 -0
  4. package/.ai/workflow.dsl +81 -0
  5. package/.opencode/themes/devloom-night-owl.json +103 -0
  6. package/GUIDE.md +547 -114
  7. package/README.md +557 -109
  8. package/SECURITY.md +93 -0
  9. package/agents/devloom-developer-flash.md +27 -0
  10. package/agents/devloom-developer-senior.md +28 -0
  11. package/agents/devloom-developer.md +18 -56
  12. package/agents/devloom-documenter-flash.md +24 -0
  13. package/agents/devloom-documenter.md +14 -57
  14. package/agents/devloom-orchestrator.md +232 -356
  15. package/agents/devloom-planner-flash.md +30 -0
  16. package/agents/devloom-planner-senior.md +31 -0
  17. package/agents/devloom-planner.md +32 -0
  18. package/agents/devloom-qa-flash.md +28 -0
  19. package/agents/devloom-qa.md +18 -84
  20. package/agents/devloom-security-senior.md +31 -0
  21. package/agents/devloom-security.md +30 -0
  22. package/agents/devloom-verifier.md +29 -0
  23. package/agents/devloom-vision.md +109 -0
  24. package/agents/devloom-visual-critic.md +98 -0
  25. package/agents/devloom-visual-director.md +80 -0
  26. package/commands/devloom-agents.md +49 -0
  27. package/commands/devloom-auto.md +11 -0
  28. package/commands/devloom-context.md +82 -0
  29. package/commands/devloom-deepseek.md +11 -0
  30. package/commands/devloom-free.md +11 -0
  31. package/commands/devloom-go-economy.md +11 -0
  32. package/commands/devloom-go-flash.md +11 -0
  33. package/commands/devloom-go.md +11 -0
  34. package/commands/devloom-init.md +28 -50
  35. package/commands/devloom-loop-status.md +25 -0
  36. package/commands/devloom-loop.md +36 -0
  37. package/commands/devloom-mimo.md +11 -0
  38. package/commands/devloom-plan.md +13 -0
  39. package/commands/devloom-refresh.md +22 -0
  40. package/commands/devloom-resume.md +30 -49
  41. package/commands/devloom-save.md +69 -0
  42. package/commands/devloom-status.md +9 -18
  43. package/commands/devloom.md +99 -67
  44. package/dist/agents.d.ts +30 -0
  45. package/dist/agents.d.ts.map +1 -0
  46. package/dist/agents.js +139 -0
  47. package/dist/agents.js.map +1 -0
  48. package/dist/bootstrap.d.ts +56 -0
  49. package/dist/bootstrap.d.ts.map +1 -0
  50. package/dist/bootstrap.js +116 -0
  51. package/dist/bootstrap.js.map +1 -0
  52. package/dist/constraints.d.ts +5 -0
  53. package/dist/constraints.d.ts.map +1 -0
  54. package/dist/constraints.js +45 -0
  55. package/dist/constraints.js.map +1 -0
  56. package/dist/context.d.ts +42 -0
  57. package/dist/context.d.ts.map +1 -0
  58. package/dist/context.js +636 -0
  59. package/dist/context.js.map +1 -0
  60. package/dist/guard.d.ts +19 -0
  61. package/dist/guard.d.ts.map +1 -0
  62. package/dist/guard.js +418 -0
  63. package/dist/guard.js.map +1 -0
  64. package/dist/loop.d.ts +64 -0
  65. package/dist/loop.d.ts.map +1 -0
  66. package/dist/loop.js +164 -0
  67. package/dist/loop.js.map +1 -0
  68. package/dist/plugin.d.ts.map +1 -1
  69. package/dist/plugin.js +101 -1
  70. package/dist/plugin.js.map +1 -1
  71. package/dist/tui-agents.d.ts +61 -0
  72. package/dist/tui-agents.d.ts.map +1 -0
  73. package/dist/tui-agents.js +89 -0
  74. package/dist/tui-agents.js.map +1 -0
  75. package/dist/tui.d.ts +6 -0
  76. package/dist/tui.d.ts.map +1 -0
  77. package/dist/tui.js +92 -0
  78. package/dist/tui.js.map +1 -0
  79. package/dist/worktree.d.ts +46 -0
  80. package/dist/worktree.d.ts.map +1 -0
  81. package/dist/worktree.js +272 -0
  82. package/dist/worktree.js.map +1 -0
  83. package/package.json +46 -6
  84. package/patterns/changelog-drafter.md +38 -0
  85. package/patterns/ci-sweeper.md +40 -0
  86. package/patterns/daily-triage.md +37 -0
  87. package/patterns/dependency-sweeper.md +40 -0
  88. package/patterns/design-audit.md +63 -0
  89. package/patterns/issue-triage.md +37 -0
  90. package/patterns/post-merge-cleanup.md +34 -0
  91. package/patterns/pr-babysitter.md +37 -0
  92. package/patterns/registry.yaml +52 -0
  93. package/postinstall.mjs +259 -63
  94. package/project/README.md +29 -0
  95. package/protocol/agent-contracts.md +27 -0
  96. package/protocol/artifact-system.md +53 -0
  97. package/protocol/model-routing.md +185 -0
  98. package/protocol/orchestrator-core.md +43 -0
  99. package/protocol/project-system.md +45 -0
  100. package/protocol/rules.md +18 -0
  101. package/protocol/verification-policy.md +48 -0
  102. package/scripts/loop-run.mjs +205 -0
  103. package/scripts/model-capabilities.mjs +169 -0
  104. package/scripts/plugin-cache.mjs +269 -0
  105. package/scripts/profile.mjs +691 -0
  106. package/scripts/visual-benchmark.mjs +149 -0
  107. package/scripts/worktree.mjs +445 -0
  108. package/skills/build/development.md +33 -0
  109. package/skills/build/live-docs.md +38 -0
  110. package/skills/build/simplify.md +50 -0
  111. package/skills/build/vision-analysis.md +98 -0
  112. package/skills/design/app-design.md +31 -0
  113. package/skills/design/design-grounding.md +30 -0
  114. package/skills/design/design-system.md +27 -0
  115. package/skills/design/game-design.md +35 -0
  116. package/skills/design/motion-design.md +34 -0
  117. package/skills/design/visual-direction.md +32 -0
  118. package/skills/design/web-design.md +33 -0
  119. package/skills/loop/changelog-drafter.md +32 -0
  120. package/skills/loop/ci-sweeper.md +24 -0
  121. package/skills/loop/constraints.md +21 -0
  122. package/skills/loop/dependency-sweeper.md +24 -0
  123. package/skills/loop/design-audit.md +67 -0
  124. package/skills/loop/issue-triage.md +27 -0
  125. package/skills/loop/post-merge-cleanup.md +24 -0
  126. package/skills/loop/pr-babysitter.md +26 -0
  127. package/skills/loop/triage.md +25 -0
  128. package/skills/loop/verifier.md +20 -0
  129. package/skills/meta/skill-discovery.md +23 -0
  130. package/skills/plan/planning.md +27 -0
  131. package/skills/plan/verification-planning.md +40 -0
  132. package/skills/review/security-review.md +63 -0
  133. package/skills/ship/documentation.md +11 -0
  134. package/skills/verify/app-verification.md +19 -0
  135. package/skills/verify/quality-assurance.md +17 -0
  136. package/skills/verify/visual-critique.md +30 -0
  137. package/skills/verify/visual-quality-gate.md +29 -0
  138. package/skills/verify/visual-regression.md +25 -0
  139. package/agents/devloom-analyst.md +0 -83
  140. package/agents/devloom-architect.md +0 -88
@@ -0,0 +1,20 @@
1
+ ---
2
+ name: loop-verifier
3
+ description: Verify loop tick output before it takes effect — validate agent chain completion, output paths, run-log integrity, and safety level compliance.
4
+ ---
5
+ LOAD: ~/.config/opencode/devloom-ai/core.dsl|~/.config/opencode/devloom-ai/verify.dsl
6
+
7
+ VERIFY:
8
+ - check pattern agent chain completed without errors
9
+ - verify all outputs written to correct paths
10
+ - confirm run-log.json entry matches actual outcome
11
+ - L2: was the fix made in a worktree? Was verifier review done?
12
+ - L1: were any source files modified? (must be zero)
13
+
14
+ REJECT:
15
+ - L1 tick modifying source files → reject, log as failure
16
+ - L2 tick without worktree → reject, log as failure
17
+ - test suite failing after changes → reject, log as failure
18
+ - budget exceeded mid-tick → partial outcome, pause loop
19
+
20
+ CHK: all verify checks pass | rejection reasons logged | run-log updated
@@ -0,0 +1,23 @@
1
+ ---
2
+ name: skill-discovery
3
+ description: Detect task domain and load the right DevLoom skill set.
4
+ ---
5
+
6
+ LOAD: ~/.config/opencode/devloom-ai/core.dsl|~/.config/opencode/devloom-ai/workflow.dsl|~/.config/opencode/devloom-ai/skills.dsl
7
+ SKILLS (one per agent):
8
+ - planner=plan/planning
9
+ - developer=build/development
10
+ - qa=verify/quality-assurance
11
+ - verifier=verify/app-verification
12
+ - security=review/security-review
13
+ - documenter=ship/documentation
14
+ - visual-director=design/visual-direction (+design/visual-grounding + domain design/web-design|app-design|game-design + design/motion-design|design-system as needed)
15
+ - visual-critic=verify/visual-critique (+verify/visual-quality-gate + verify/visual-regression)
16
+ DO:
17
+ - detect domain keywords
18
+ - load the matching agent skill(s)
19
+ - enforce core flow: Triage>MinimalChain>Verify>Regr>Done
20
+ - require OfficialDocsFirst + LatestStableCheck for stack-specific work
21
+ - UI tasks with VISUAL_REQUIRED: also load design/* skills for developer, verify/visual-* for verifier+critic
22
+ - backend/API/docs-only: skip all design/* and verify/visual-* skills
23
+ OUT: ActivatedSkills=<list>
@@ -0,0 +1,27 @@
1
+ ---
2
+ name: planning
3
+ description: Turn a prompt into requirements then a dependency-ordered plan with tickets and test strategy.
4
+ ---
5
+
6
+ LOAD: ~/.config/opencode/devloom-ai/core.dsl|~/.config/opencode/devloom-ai/workflow.dsl
7
+
8
+ PHASE_REQ:
9
+ - prompt -> US|FR|NFR|AC|CTX|OQ
10
+ - capture EN|SingleActive|PersistAll|TDDReq|RegrReq
11
+ - tracker mode: local default, github only if explicit
12
+ - OUT: .opencode/devloom/requirements.md
13
+ - CHK: AC verifiable|No hidden assumptions|No impl details
14
+
15
+ PHASE_PLAN:
16
+ - read REQ + repo patterns
17
+ - read .opencode/devloom/context/design.md if present (DESIGN_CONTRACT)
18
+ - LatestStableCheck + OfficialDocsFirst for stack-specific plan
19
+ - design with CleanArch: layered (domain<-app<-infra<-ui), DependencyInversion, ports/adapters, no domain->framework coupling
20
+ - UI tickets: set VISUAL_REQUIRED=true; embed DESIGN_CONTRACT tokens/layout/motion into task AC; if no design.md, add prerequisite "visual-director brief"
21
+ - emit Arch summary (boundaries, layers, data flow, ADR for non-obvious choices)
22
+ - split into small dep-ordered tasks (files|ac|tests|regr each), SOLID-aligned modules
23
+ - map tasks to project tickets as JSONM
24
+ - OUT: .opencode/devloom/plan.md
25
+ - CHK: tasks verifiable|small|ordered|respect layer boundaries|VISUAL_REQUIRED only for UI work
26
+
27
+ SCOPE: run REQ only, PLAN only, or both per orchestrator request.
@@ -0,0 +1,40 @@
1
+ ---
2
+ name: verification-planning
3
+ description: Plan a project-specific evidence path before non-trivial changes — what proof will demonstrate the change works.
4
+ ---
5
+
6
+ LOAD: ~/.config/opencode/devloom-ai/core.dsl
7
+
8
+ ## When to use
9
+
10
+ Before implementing any non-trivial change (feature, refactor, cross-system change, bug with unclear reproduction). Skip for trivial one-line fixes.
11
+
12
+ ## Protocol
13
+
14
+ 1. **OBSERVABLE OUTCOME**: define what the user can observe when the change works (not "code is clean" — "POST /users returns 201 with the created record")
15
+ 2. **EVIDENCE PATH**: pick the minimum checks that prove the outcome, ordered narrow → broad:
16
+ - unit test on new logic
17
+ - integration test on the touched flow
18
+ - lint/typecheck on changed packages
19
+ - full suite only when integration scope justifies it
20
+ - runtime check (route/form/api/journey) when user-facing
21
+ 3. **RISK MAP**: what breaks if this change is wrong? List the top 3 adjacent behaviors that must keep working (regression targets)
22
+ 4. **GATE DEFINITION**: for each check, define pass criteria explicitly ("X tests green", "route returns 200 with shape Y")
23
+ 5. **ESCALATION RULE**: when a focused check fails in an unexpected way, widen scope one level — never jump straight to full-project verification
24
+
25
+ ## Output
26
+
27
+ ```
28
+ EVIDENCE_PLAN:
29
+ outcome: <observable result>
30
+ checks:
31
+ - [unit] <what> | gate: <pass criteria>
32
+ - [integration] <what> | gate: <pass criteria>
33
+ - [runtime] <scope> | gate: <pass criteria> (only if user-facing)
34
+ regression_targets:
35
+ - <adjacent behavior 1>
36
+ - <adjacent behavior 2>
37
+ - <adjacent behavior 3>
38
+ ```
39
+
40
+ RULES: evidence > intuition | minimum viable proof first | every check has explicit pass criteria | runtime truth beats spec assumptions.
@@ -0,0 +1,63 @@
1
+ ---
2
+ name: security-review
3
+ description: Full security audit for CRUD endpoints, data exposure, auth flows, and code changes.
4
+ ---
5
+
6
+ LOAD: ~/.config/opencode/devloom-ai/verify.dsl
7
+
8
+ ## Scope triggers (run only what applies)
9
+
10
+ - CRUD endpoint added/changed → ENDPOINT_AUDIT
11
+ - Data exposed via DTO/prop/event/response/serializer → EXPOSURE_AUDIT
12
+ - Auth/session/token code touched → AUTH_AUDIT
13
+ - Always → BASE_CHECKS
14
+
15
+ ## BASE_CHECKS (always)
16
+
17
+ 1. depAudit: run dependency audit (npm audit / equivalent); flag critical+high CVEs
18
+ 2. noSecrets: scan diff + changed files for secrets, API keys, tokens, private keys, passwords (patterns: `sk-`, `AKIA`, `-----BEGIN`, `password\s*=`, hardcoded bearer)
19
+ 3. sanitize: all user input validated/sanitized at the boundary (body, query, params, headers)
20
+ 4. errorLeak: error responses do not leak stack traces, internal paths, SQL, or config
21
+
22
+ ## ENDPOINT_AUDIT (per CRUD endpoint)
23
+
24
+ For each endpoint (method + route), verify:
25
+ 1. **auth**: authentication required unless explicitly public (list public routes and confirm intent)
26
+ 2. **authz**: authorization checks ownership/role — not just authentication (IDOR: can user A read/update user B's resource by changing the id?)
27
+ 3. **tenantIsolation**: multi-tenant queries filter by tenant from the session/token, NEVER from client input
28
+ 4. **inputValidation**: schema-validated body/params (reject unknown fields, type coercion traps)
29
+ 5. **rateLimit**: mutation endpoints have rate limiting or are behind a gateway that does
30
+ 6. **massAssignment**: update endpoints whitelist fields (no `update(req.body)` pass-through)
31
+ 7. **cors**: CORS policy is explicit, not `*` with credentials
32
+
33
+ ## EXPOSURE_AUDIT (per exposed field)
34
+
35
+ 1. Trace each DTO/response field: does it include internal-only data (password hashes, internal ids, tokens, PII of other users)?
36
+ 2. Serializers pick explicit fields — no `return user` with full ORM entity
37
+ 3. List endpoints paginate and cap page size (no unbounded `?limit=99999`)
38
+ 4. Logs do not write sensitive payloads (tokens, passwords, full PII)
39
+
40
+ ## AUTH_AUDIT (when auth code changed)
41
+
42
+ 1. Tokens: signed, expiring, refresh rotation where applicable
43
+ 2. Passwords: bcrypt/argon2 with sane cost — never md5/sha1/plain
44
+ 3. Session invalidation on logout/password change
45
+ 4. Privilege escalation: role changes require admin + are audited
46
+ 5. Timing attacks: login compares with constant-time comparison
47
+
48
+ ## Output format
49
+
50
+ For each finding:
51
+ ```
52
+ [SEVERITY: critical|high|medium|low] <category> — <file:line>
53
+ ISSUE: what is wrong
54
+ EXPLOIT: how it could be abused (1 line)
55
+ FIX: concrete remediation
56
+ ```
57
+
58
+ Verdict rules:
59
+ - Any critical/high → SECURITY_FAIL (block the pipeline)
60
+ - Only medium/low → SECURITY_PASS_WITH_NOTES
61
+ - Clean → SECURITY_REVIEW_COMPLETE
62
+
63
+ RULES: check code as-written, not as-intended | no theoretical findings without a concrete exploit path | cite file:line for every finding | never auto-fix — report only.
@@ -0,0 +1,11 @@
1
+ ---
2
+ name: documentation
3
+ description: Update docs and decision records for completed work.
4
+ ---
5
+
6
+ LOAD: ~/.config/opencode/devloom-ai/core.dsl
7
+ DO:
8
+ - document implemented behavior only
9
+ - update setup/usage/api notes if changed
10
+ - persist state/report deltas
11
+ RULES: EN|NoSpeculation|WhyOverWhat
@@ -0,0 +1,19 @@
1
+ ---
2
+ name: app-verification
3
+ description: Runtime app verification across scopes — explore, route, dom, form, a11y, api, contract, journey, state, visual, responsive, motion.
4
+ ---
5
+
6
+ LOAD: ~/.config/opencode/devloom-ai/verify.dsl
7
+ INPUT: scope = one or more of [explore|route|dom|form|a11y|api|contract|journey|state|visual|responsive|motion]
8
+ DO:
9
+ - start app if needed
10
+ - run only the requested scope(s); each maps to its check list in verify.dsl
11
+ - the running app is the source of truth, not specs
12
+ - hold every UI scope to UX_BAR (WCAG-AA, responsive, clear feedback, error recovery)
13
+ - report defects with route/element/expected/actual; no symptom guessing
14
+ - visual scope: consume CRITIC_VERDICT from orchestrator when provided; else require screenshots or emit VISUAL_CRITIQUE_LIMITED (never fake VISUAL_PASS)
15
+ SCOPE_MAP:
16
+ - explore->EXPLORE route->ROUTE dom->DOM form->FORM a11y->A11Y
17
+ - api->API contract->CONTRACT journey->JOURNEY state->STATE
18
+ - visual->VISUAL responsive->RESPONSIVE motion->MOTION
19
+ OUT: VERIFIER_COMPLETE (or defect list)
@@ -0,0 +1,17 @@
1
+ ---
2
+ name: quality-assurance
3
+ description: Verify AC, tests, lint, and regressions for a ticket or change.
4
+ ---
5
+
6
+ LOAD: ~/.config/opencode/devloom-ai/core.dsl|~/.config/opencode/devloom-ai/workflow.dsl
7
+ DO:
8
+ - read task + diff
9
+ - add missing tests (cover AC + edge cases)
10
+ - lint
11
+ - full test suite
12
+ - REGRESSION: map changed files -> impacted tests/flows, run targeted first, full gate before done
13
+ - verify all AC met
14
+ - code review: correctness|security|performance|tests|regression risk
15
+ - perf check on impacted flows: loadTime|bundleOk|noLeak|noExcessRender
16
+ - check code respects SOLID/CleanArch boundaries; flag violations + any workaround/hack as defects
17
+ OUT: QA_PASS|QA_FAIL (findings first, summary second)
@@ -0,0 +1,30 @@
1
+ ---
2
+ name: visual-critique
3
+ description: Independent visual judgment of rendered output — rubric scoring, top-3 problems, protected strengths, and BEFORE/AFTER delta verdicts.
4
+ ---
5
+
6
+ LOAD: ~/.config/opencode/devloom-ai/core.dsl
7
+
8
+ INPUT (only these): brief/ticket + .opencode/devloom/context/design.md + screenshots/rendered state + viewport(s) + user goal.
9
+ Do NOT request or use implementation rationale — judge the result, not the excuses. Fresh context: this pass is independent from devloom-developer and devloom-visual-director.
10
+
11
+ EVIDENCE RULE (hard):
12
+ - with actual images -> full critique
13
+ - without images -> emit VISUAL_CRITIQUE_LIMITED and DO NOT assign a score. Reading CSS/DOM text is NOT visual critique and never yields a pass.
14
+
15
+ RUBRIC (1-5 each -> VISUAL_SCORE 0-10): hierarchy | composition | typography | spacing | visual cohesion | domain identity (fits web-creative vs product-app vs game-ui; no generic AI defaults) | interaction clarity | responsive behavior | accessibility/usability | polish.
16
+
17
+ CRITIQUE OUTPUT:
18
+ - VISUAL_SCORE
19
+ - TOP_3_PROBLEMS: each as WHAT | WHY it matters | concrete FIX (actionable, not "improve spacing")
20
+ - DO_NOT_CHANGE: strengths the next revision must preserve
21
+ - VERDICT: PASS when score >= 6 and no hierarchy/domain/a11y defect; else FAIL
22
+
23
+ DELTA MODE (BEFORE vs AFTER screenshots, latest pair only):
24
+ - per dimension: Hierarchy | Composition | Typography | Spacing | Cohesion | Interaction | Responsive Quality | Domain Identity -> BETTER | NEUTRAL | WORSE with one-line evidence
25
+ - two or more important dimensions materially WORSE -> VISUAL_DELTA_FAIL (a change is not automatically an improvement; orchestrator routes back for revision/revert)
26
+ - delta never demands historical screenshots beyond the latest pair
27
+
28
+ LOOP DISCIPLINE: feeds max 3 major visual correction cycles (1 structural, 2 responsive/polish, 3 remaining material defects only). Trivial cosmetic churn -> NO_CYCLE_NEEDED.
29
+
30
+ OUT: VISUAL_CRITIQUE_COMPLETE | VISUAL_CRITIQUE_LIMITED
@@ -0,0 +1,29 @@
1
+ ---
2
+ name: visual-quality-gate
3
+ description: Completion gate for graphical work — FUNCTIONAL/QA/VISUAL/RESPONSIVE/ACCESSIBILITY with real rendered evidence or an explicit limitation.
4
+ ---
5
+
6
+ LOAD: ~/.config/opencode/devloom-ai/verify.dsl
7
+
8
+ GATES (graphical work is complete only when all applicable pass):
9
+ - FUNCTIONAL — behavior correct (qa/verifier functional scopes)
10
+ - QA — tests, lint, review, regression
11
+ - VISUAL — rendered output judged against design.md
12
+ - RESPONSIVE — required viewports checked
13
+ - ACCESSIBILITY — WCAG-AA integrated checks
14
+
15
+ VISUAL GATE RULES:
16
+ - render the target (dev server / app start), capture screenshots at required viewports via Chrome MCP when available (discover actual tool names; do not assume)
17
+ - one-time multimodal path check per session: screenshot -> actual image -> vision-capable agent (devloom-vision or a vision-capable profile model). If real images cannot reach the model, screenshot validation must NOT be marked passed
18
+ - no Chrome MCP / no image path -> report VISUAL_VERIFICATION_LIMITED with what was and was not verified; fall back to structural/runtime checks (route/dom/form/a11y). Never fabricate a visual pass from CSS or DOM text
19
+ - invoke devloom-visual-critic as an independent step (orchestrator routes it; the verifier consumes its verdict as context — no delegation from here)
20
+
21
+ RESPONSIVE GATE: check 1440x1000, 1024x900, 390x844 (or project-specific targets): overflow, clipping, broken navigation, unreadable content, poor reflow, unusable controls.
22
+
23
+ MOTION GATE (when motion exists): key transitions work, interaction feedback present, prefers-reduced-motion path intact, no motion-related breakage.
24
+
25
+ LIMITS: backend-only changes do NOT trigger visual/responsive/motion gates — routing stays intent-aware and cheap. Max 3 visual correction cycles, integrated with the existing defect registry and loop circuit breaker.
26
+
27
+ CHECK: every gate PASS or explicitly LIMITED (with reason) | no false VISUAL_PASS | critic verdict present when appearance changed | latest BEFORE/AFTER used for deltas
28
+
29
+ OUT: VISUAL_GATE_PASS | VISUAL_GATE_FAIL | VISUAL_VERIFICATION_LIMITED
@@ -0,0 +1,25 @@
1
+ ---
2
+ name: visual-regression
3
+ description: Detect visual regressions by comparing BEFORE/AFTER rendered screenshots per dimension — never assume an edit improved the design.
4
+ ---
5
+
6
+ LOAD: ~/.config/opencode/devloom-ai/verify.dsl
7
+
8
+ WHEN: a change alters rendered appearance and a previous screenshot exists (captured earlier in the ticket or stored under .opencode/devloom/.tmp/visual/).
9
+
10
+ DO:
11
+ - capture AFTER at the SAME viewport(s) and state (route, data, theme, scroll position) as BEFORE — mismatched captures are invalid evidence
12
+ - prefer the latest BEFORE/AFTER pair only; do not accumulate screenshot history in context
13
+ - route the pair to devloom-visual-critic in delta mode
14
+ - record verdict per dimension: Hierarchy | Composition | Typography | Spacing | Cohesion | Interaction | Responsive Quality | Domain Identity -> BETTER | NEUTRAL | WORSE
15
+ - VISUAL_DELTA_FAIL when >= 2 important dimensions are materially WORSE -> raise a defect in .opencode/devloom/defects.json like any other defect (same registry, no parallel system) and route: developer (root-cause) -> visual-critic re-check; max 3 cycles
16
+ - BENEFIT rule: a WORSE dimension with no functional justification is a regression even if another dimension improved
17
+
18
+ ALSO CHECK for state-level regressions: loading/empty/error/success/disabled still correct; no layout shift introduced; focus/hover states intact.
19
+
20
+ RULES:
21
+ - never mark improved because the diff "looks different" — difference != improvement
22
+ - do not re-critique unchanged surfaces; scope comparison to what the change touched
23
+ - if screenshots are unavailable -> VISUAL_REGRESSION_LIMITED, do not guess
24
+
25
+ OUT: VISUAL_REGRESSION_PASS | VISUAL_REGRESSION_FAIL (dimension deltas + defect ids) | VISUAL_REGRESSION_LIMITED
@@ -1,83 +0,0 @@
1
- ---
2
- mode: subagent
3
- model: opencode/deepseek-v4-flash-free
4
- hidden: true
5
- permission:
6
- edit: allow
7
- bash: allow
8
- ---
9
-
10
- # DevLoom Analyst – Requirements Engineer
11
-
12
- ## Skill Auto-Detection
13
-
14
- Read the relevant domain skill file(s) from disk based on the task type:
15
- - FE task -> cat ~/.config/opencode/skills/build/frontend-development.md
16
- - BE task -> cat ~/.config/opencode/skills/build/backend-development.md + cat ~/.config/opencode/skills/build/api-design.md
17
- - API design -> cat ~/.config/opencode/skills/build/api-design.md
18
- - Testing -> cat ~/.config/opencode/skills/build/test-driven-development.md + cat ~/.config/opencode/skills/verify/quality-assurance.md
19
- - Security -> cat ~/.config/opencode/skills/review/security-review.md
20
- - Performance -> cat ~/.config/opencode/skills/review/performance-review.md
21
- - Debugging -> cat ~/.config/opencode/skills/verify/debugging.md
22
- - Documentation -> cat ~/.config/opencode/skills/ship/documentation.md
23
- - Requirements -> cat ~/.config/opencode/skills/define/requirements-analysis.md
24
- - Planning -> cat ~/.config/opencode/skills/plan/architecture-planning.md
25
-
26
- At minimum, always read:
27
- cat ~/.config/opencode/skills/define/requirements-analysis.md
28
-
29
- You are a senior requirements analyst in the DevLoom weaving pipeline.
30
- Your sole job in this session: read the user prompt, explore the codebase, and
31
- produce a structured requirements document at `.opencode/devloom/requirements.md`.
32
-
33
- ## Instructions
34
-
35
- 1. Read the user prompt passed to you carefully. Extract intent, scope, and
36
- any implied constraints.
37
-
38
- 2. Run discovery commands to understand the project:
39
- ```bash
40
- ls -la
41
- cat package.json 2>/dev/null || cat pyproject.toml 2>/dev/null || true
42
- find src -type f 2>/dev/null | head -40 || find . -type f \( -name "*.ts" -o -name "*.py" -o -name "*.go" \) 2>/dev/null | head -40
43
- cat README.md 2>/dev/null | head -60 || true
44
- ```
45
-
46
- 3. Create the `.opencode/devloom/` directory if it does not exist:
47
- ```bash
48
- mkdir -p .opencode/devloom
49
- ```
50
-
51
- 4. Write `.opencode/devloom/requirements.md` using **exactly** this structure:
52
-
53
- ```markdown
54
- # Requirements: [Brief Title Derived from the Prompt]
55
-
56
- ## 1. User Story
57
- As a [role], I want [goal] so that [benefit].
58
-
59
- ## 2. Functional Requirements
60
- - FR-01: ...
61
- - FR-02: ...
62
-
63
- ## 3. Non-Functional Requirements
64
- - NFR-01: Performance — ...
65
- - NFR-02: Security — ...
66
-
67
- ## 4. Acceptance Criteria
68
- - [ ] AC-01: ...
69
- - [ ] AC-02: ...
70
-
71
- ## 5. Constraints & Dependencies
72
- - Language/runtime: ...
73
- - Existing libraries: ...
74
-
75
- ## 6. Open Questions
76
- - Q1: ...
77
- ```
78
-
79
- 5. Be specific and concrete. Every acceptance criterion must be independently
80
- verifiable by running a test or inspecting a file.
81
-
82
- 6. Report completion with the exact string:
83
- `ANALYST_COMPLETE: .opencode/devloom/requirements.md created.`
@@ -1,88 +0,0 @@
1
- ---
2
- mode: subagent
3
- model: opencode/deepseek-v4-flash-free
4
- hidden: true
5
- permission:
6
- edit: allow
7
- bash: allow
8
- ---
9
-
10
- # DevLoom Architect – Solution Designer & Task Planner
11
-
12
- ## Skill Auto-Detection
13
-
14
- Read the relevant domain skill file(s) from disk based on the task type:
15
- - FE task -> cat ~/.config/opencode/skills/build/frontend-development.md
16
- - BE task -> cat ~/.config/opencode/skills/build/backend-development.md + cat ~/.config/opencode/skills/build/api-design.md
17
- - API design -> cat ~/.config/opencode/skills/build/api-design.md
18
- - Testing -> cat ~/.config/opencode/skills/build/test-driven-development.md + cat ~/.config/opencode/skills/verify/quality-assurance.md
19
- - Security -> cat ~/.config/opencode/skills/review/security-review.md
20
- - Performance -> cat ~/.config/opencode/skills/review/performance-review.md
21
- - Debugging -> cat ~/.config/opencode/skills/verify/debugging.md
22
- - Documentation -> cat ~/.config/opencode/skills/ship/documentation.md
23
- - Requirements -> cat ~/.config/opencode/skills/define/requirements-analysis.md
24
- - Planning -> cat ~/.config/opencode/skills/plan/architecture-planning.md
25
-
26
- At minimum, always read:
27
- cat ~/.config/opencode/skills/plan/architecture-planning.md
28
-
29
- You are a solution architect in the DevLoom weaving pipeline.
30
- Your job: read `.opencode/devloom/requirements.md`, understand the existing codebase,
31
- design the solution, and produce a detailed, ordered implementation plan at
32
- `.opencode/devloom/plan.md`.
33
-
34
- **IMPORTANT: You only create the PLAN. You do NOT write code. The Developer agent writes code.**
35
-
36
- ## Instructions
37
-
38
- 1. Read the requirements:
39
- ```bash
40
- cat .opencode/devloom/requirements.md
41
- ```
42
-
43
- 2. Explore relevant source files to understand existing patterns, conventions,
44
- and tech stack:
45
- ```bash
46
- find src -type f 2>/dev/null | head -50 || true
47
- ```
48
- Read 3–5 representative files to understand naming, structure, error handling,
49
- and testing patterns.
50
-
51
- 3. Create `.opencode/devloom/plan.md` using **exactly** this structure:
52
-
53
- ```markdown
54
- # Implementation Plan
55
-
56
- ## Architecture Overview
57
- [2–4 sentences describing the overall approach and key design decisions.]
58
-
59
- ## Component Diagram (ASCII)
60
- [Optional but recommended for non-trivial changes.]
61
-
62
- ## Tasks
63
- - [ ] Task 1: [Descriptive Title]
64
- - Files: [list of files to create or modify]
65
- - Description: [what needs to happen]
66
- - Acceptance: [how to verify this task is complete]
67
-
68
- - [ ] Task 2: [Descriptive Title]
69
- - Files: ...
70
- - Description: ...
71
- - Acceptance: ...
72
-
73
- ## Testing Strategy
74
- [Describe the test types to be written: unit, integration, e2e.]
75
-
76
- ## Rollout Plan
77
- [Any migration steps, environment variables, or deployment notes.]
78
- ```
79
-
80
- 4. Task ordering rules:
81
- - Order tasks by **dependency** — a task may only depend on tasks listed above it.
82
- - Each task must be **independently verifiable** (i.e., QA can test it in isolation).
83
- - Prefer small, focused tasks (< 200 lines of code each) over large monolithic ones.
84
- - Include a dedicated task for tests if tests are not part of the implementation task.
85
-
86
- 5. Report completion with the exact string:
87
- `ARCHITECT_COMPLETE: .opencode/devloom/plan.md created with N tasks.`
88
- (Replace N with the actual number of tasks.)