self-evolving-workflow 0.0.0-stage → 0.1.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.
- package/LICENSE +27 -0
- package/README.md +195 -2
- package/dist/agent-memory-prompts.d.ts +13 -0
- package/dist/agent-memory-prompts.js +55 -0
- package/dist/cli.d.ts +2 -0
- package/dist/cli.js +6 -0
- package/dist/closeout.d.ts +105 -0
- package/dist/closeout.js +473 -0
- package/dist/code.d.ts +39 -0
- package/dist/code.js +124 -0
- package/dist/codex-memory.d.ts +24 -0
- package/dist/codex-memory.js +217 -0
- package/dist/common.d.ts +16 -0
- package/dist/common.js +52 -0
- package/dist/context-envelope.d.ts +59 -0
- package/dist/context-envelope.js +23 -0
- package/dist/host-adapters.d.ts +34 -0
- package/dist/host-adapters.js +151 -0
- package/dist/http.d.ts +3 -0
- package/dist/http.js +90 -0
- package/dist/index.d.ts +16 -0
- package/dist/index.js +13 -0
- package/dist/knowledge-cli.d.ts +198 -0
- package/dist/knowledge-cli.js +761 -0
- package/dist/knowledge-reads.d.ts +72 -0
- package/dist/knowledge-reads.js +201 -0
- package/dist/memory-config.d.ts +44 -0
- package/dist/memory-config.js +204 -0
- package/dist/memory-evidence.d.ts +13 -0
- package/dist/memory-evidence.js +40 -0
- package/dist/memory-history.d.ts +46 -0
- package/dist/memory-history.js +432 -0
- package/dist/memory.d.ts +96 -0
- package/dist/memory.js +362 -0
- package/dist/retrospective.d.ts +57 -0
- package/dist/retrospective.js +240 -0
- package/dist/search.d.ts +36 -0
- package/dist/search.js +112 -0
- package/dist/skill-addition.d.ts +25 -0
- package/dist/skill-addition.js +89 -0
- package/dist/skill-design.d.ts +96 -0
- package/dist/skill-design.js +226 -0
- package/dist/skill-replay.d.ts +55 -0
- package/dist/skill-replay.js +448 -0
- package/dist/skill-route.d.ts +30 -0
- package/dist/skill-route.js +75 -0
- package/dist/transcript-evidence.d.ts +3 -0
- package/dist/transcript-evidence.js +58 -0
- package/dist/upstream/chunker.d.ts +24 -0
- package/dist/upstream/chunker.js +96 -0
- package/dist/upstream/file-protocol.d.ts +45 -0
- package/dist/upstream/file-protocol.js +117 -0
- package/dist/upstream/frontmatter.d.ts +47 -0
- package/dist/upstream/frontmatter.js +86 -0
- package/dist/upstream/graph-search.d.ts +33 -0
- package/dist/upstream/graph-search.js +67 -0
- package/dist/upstream/l1-extraction.d.ts +26 -0
- package/dist/upstream/l1-extraction.js +405 -0
- package/dist/upstream/llm.d.ts +8 -0
- package/dist/upstream/llm.js +1 -0
- package/dist/upstream/merge.d.ts +50 -0
- package/dist/upstream/merge.js +153 -0
- package/dist/upstream/prompts.d.ts +53 -0
- package/dist/upstream/prompts.js +181 -0
- package/dist/upstream/search-utils.d.ts +34 -0
- package/dist/upstream/search-utils.js +55 -0
- package/dist/upstream/slug.d.ts +26 -0
- package/dist/upstream/slug.js +103 -0
- package/dist/upstream/template.d.ts +29 -0
- package/dist/upstream/template.js +80 -0
- package/dist/upstream/tokenize.d.ts +4 -0
- package/dist/upstream/tokenize.js +29 -0
- package/dist/wiki-change.d.ts +76 -0
- package/dist/wiki-change.js +299 -0
- package/dist/wiki-entry.d.ts +26 -0
- package/dist/wiki-entry.js +93 -0
- package/dist/wiki-ingest.d.ts +12 -0
- package/dist/wiki-ingest.js +126 -0
- package/dist/wiki-migration.d.ts +16 -0
- package/dist/wiki-migration.js +268 -0
- package/dist/wiki-tokens.d.ts +1 -0
- package/dist/wiki-tokens.js +46 -0
- package/dist/wiki.d.ts +103 -0
- package/dist/wiki.js +330 -0
- package/dist/workflow-cli.d.ts +2 -0
- package/dist/workflow-cli.js +319 -0
- package/dist/workflow-install.d.ts +37 -0
- package/dist/workflow-install.js +148 -0
- package/dist/workflow-knowledge.d.ts +18 -0
- package/dist/workflow-knowledge.js +32 -0
- package/dist/workflow-mcp.d.ts +2 -0
- package/dist/workflow-mcp.js +137 -0
- package/dist/workflow-names.d.ts +4 -0
- package/dist/workflow-names.js +31 -0
- package/dist/workflow-runtime.d.ts +735 -0
- package/dist/workflow-runtime.js +747 -0
- package/dist/workflow-skills.d.ts +48 -0
- package/dist/workflow-skills.js +141 -0
- package/docs/images/impeccable-skill.png +0 -0
- package/docs/images/workflow-overview.png +0 -0
- package/docs/images/workflow-skills.png +0 -0
- package/package.json +77 -4
- package/skills/ew-impeccable/LICENSE +191 -0
- package/skills/ew-impeccable/NOTICE.md +19 -0
- package/skills/ew-impeccable/SKILL.md +91 -0
- package/skills/ew-impeccable/UPSTREAM.md +23 -0
- package/skills/ew-impeccable/reference/adapt.md +314 -0
- package/skills/ew-impeccable/reference/adapt.native.md +60 -0
- package/skills/ew-impeccable/reference/android.md +46 -0
- package/skills/ew-impeccable/reference/animate.md +91 -0
- package/skills/ew-impeccable/reference/audit.md +138 -0
- package/skills/ew-impeccable/reference/audit.native.md +141 -0
- package/skills/ew-impeccable/reference/bolder.md +35 -0
- package/skills/ew-impeccable/reference/clarify.md +96 -0
- package/skills/ew-impeccable/reference/colorize.md +88 -0
- package/skills/ew-impeccable/reference/craft-floor.md +44 -0
- package/skills/ew-impeccable/reference/craft.md +5 -0
- package/skills/ew-impeccable/reference/critique.md +808 -0
- package/skills/ew-impeccable/reference/degraded/asset-producer.md +36 -0
- package/skills/ew-impeccable/reference/degraded/documenter.md +23 -0
- package/skills/ew-impeccable/reference/degraded/finish-reviewer.md +72 -0
- package/skills/ew-impeccable/reference/degraded/manual-edit-applier.md +91 -0
- package/skills/ew-impeccable/reference/delight.md +72 -0
- package/skills/ew-impeccable/reference/distill.md +113 -0
- package/skills/ew-impeccable/reference/doctor.md +56 -0
- package/skills/ew-impeccable/reference/document.md +418 -0
- package/skills/ew-impeccable/reference/extract.md +68 -0
- package/skills/ew-impeccable/reference/harden.md +338 -0
- package/skills/ew-impeccable/reference/hooks.md +113 -0
- package/skills/ew-impeccable/reference/init.md +133 -0
- package/skills/ew-impeccable/reference/ios.md +51 -0
- package/skills/ew-impeccable/reference/layout.md +86 -0
- package/skills/ew-impeccable/reference/live-setup.md +102 -0
- package/skills/ew-impeccable/reference/live.md +326 -0
- package/skills/ew-impeccable/reference/new-work.md +209 -0
- package/skills/ew-impeccable/reference/onboard.md +236 -0
- package/skills/ew-impeccable/reference/operate.md +61 -0
- package/skills/ew-impeccable/reference/optimize.md +260 -0
- package/skills/ew-impeccable/reference/overdrive.md +127 -0
- package/skills/ew-impeccable/reference/polish.md +105 -0
- package/skills/ew-impeccable/reference/quieter.md +101 -0
- package/skills/ew-impeccable/reference/routing.md +20 -0
- package/skills/ew-impeccable/reference/shape.md +59 -0
- package/skills/ew-impeccable/reference/typeset.md +82 -0
- package/skills/ew-impeccable/reference/visualize.md +46 -0
- package/skills/ew-impeccable/scripts/build-phase.mjs +1022 -0
- package/skills/ew-impeccable/scripts/command-metadata.json +94 -0
- package/skills/ew-impeccable/scripts/comp-diff.mjs +391 -0
- package/skills/ew-impeccable/scripts/comp-spec.mjs +513 -0
- package/skills/ew-impeccable/scripts/concept-seed.mjs +814 -0
- package/skills/ew-impeccable/scripts/context-signals.mjs +325 -0
- package/skills/ew-impeccable/scripts/context.mjs +1521 -0
- package/skills/ew-impeccable/scripts/critique-storage.mjs +473 -0
- package/skills/ew-impeccable/scripts/data/font-index-failures.json +121 -0
- package/skills/ew-impeccable/scripts/data/font-index.json +1 -0
- package/skills/ew-impeccable/scripts/detect-csp.mjs +246 -0
- package/skills/ew-impeccable/scripts/detect.mjs +30 -0
- package/skills/ew-impeccable/scripts/detector/browser/injected/index.mjs +2580 -0
- package/skills/ew-impeccable/scripts/detector/cli/main.mjs +498 -0
- package/skills/ew-impeccable/scripts/detector/design-system.mjs +1311 -0
- package/skills/ew-impeccable/scripts/detector/detect-antipatterns-browser.js +9486 -0
- package/skills/ew-impeccable/scripts/detector/detect-antipatterns.mjs +51 -0
- package/skills/ew-impeccable/scripts/detector/engines/browser/detect-url.mjs +434 -0
- package/skills/ew-impeccable/scripts/detector/engines/regex/detect-text.mjs +1439 -0
- package/skills/ew-impeccable/scripts/detector/engines/static-html/css-cascade.mjs +1242 -0
- package/skills/ew-impeccable/scripts/detector/engines/static-html/detect-html.mjs +263 -0
- package/skills/ew-impeccable/scripts/detector/engines/visual/screenshot-contrast.mjs +189 -0
- package/skills/ew-impeccable/scripts/detector/findings.mjs +23 -0
- package/skills/ew-impeccable/scripts/detector/node/file-system.mjs +225 -0
- package/skills/ew-impeccable/scripts/detector/profile/profiler.mjs +166 -0
- package/skills/ew-impeccable/scripts/detector/registry/antipatterns.mjs +636 -0
- package/skills/ew-impeccable/scripts/detector/rules/checks.mjs +5750 -0
- package/skills/ew-impeccable/scripts/detector/shared/color.mjs +596 -0
- package/skills/ew-impeccable/scripts/detector/shared/constants.mjs +127 -0
- package/skills/ew-impeccable/scripts/detector/shared/fonts.mjs +30 -0
- package/skills/ew-impeccable/scripts/detector/shared/inline-ignores.mjs +148 -0
- package/skills/ew-impeccable/scripts/detector/shared/page.mjs +7 -0
- package/skills/ew-impeccable/scripts/detector/vendor/MDN-DATA-LICENSE +116 -0
- package/skills/ew-impeccable/scripts/detector/vendor/THIRD_PARTY_LICENSES.md +227 -0
- package/skills/ew-impeccable/scripts/detector/vendor/static-html-parser.build-entry.txt +11 -0
- package/skills/ew-impeccable/scripts/detector/vendor/static-html-parser.bundle.mjs +9121 -0
- package/skills/ew-impeccable/scripts/doctor.mjs +330 -0
- package/skills/ew-impeccable/scripts/embed-prompt.mjs +166 -0
- package/skills/ew-impeccable/scripts/font-match.mjs +457 -0
- package/skills/ew-impeccable/scripts/generate-image.mjs +447 -0
- package/skills/ew-impeccable/scripts/hook-admin.mjs +829 -0
- package/skills/ew-impeccable/scripts/hook-before-edit.mjs +538 -0
- package/skills/ew-impeccable/scripts/hook-lib.mjs +2493 -0
- package/skills/ew-impeccable/scripts/hook.mjs +79 -0
- package/skills/ew-impeccable/scripts/lib/artifact-schema.mjs +93 -0
- package/skills/ew-impeccable/scripts/lib/composition-catalog.mjs +200 -0
- package/skills/ew-impeccable/scripts/lib/concept-catalog.mjs +395 -0
- package/skills/ew-impeccable/scripts/lib/design-parser.mjs +880 -0
- package/skills/ew-impeccable/scripts/lib/font-fingerprint.mjs +564 -0
- package/skills/ew-impeccable/scripts/lib/font-index.mjs +130 -0
- package/skills/ew-impeccable/scripts/lib/hero-checks.mjs +246 -0
- package/skills/ew-impeccable/scripts/lib/image-metrics.mjs +306 -0
- package/skills/ew-impeccable/scripts/lib/impeccable-config.mjs +640 -0
- package/skills/ew-impeccable/scripts/lib/impeccable-paths.mjs +137 -0
- package/skills/ew-impeccable/scripts/lib/is-generated.mjs +72 -0
- package/skills/ew-impeccable/scripts/lib/live-path-globs.mjs +37 -0
- package/skills/ew-impeccable/scripts/lib/open-system-browser.mjs +26 -0
- package/skills/ew-impeccable/scripts/lib/png.mjs +281 -0
- package/skills/ew-impeccable/scripts/lib/provider.mjs +5 -0
- package/skills/ew-impeccable/scripts/lib/raster.mjs +194 -0
- package/skills/ew-impeccable/scripts/lib/roll-selection.mjs +369 -0
- package/skills/ew-impeccable/scripts/lib/staleness-deep.mjs +491 -0
- package/skills/ew-impeccable/scripts/lib/staleness-notice.mjs +169 -0
- package/skills/ew-impeccable/scripts/lib/staleness.mjs +532 -0
- package/skills/ew-impeccable/scripts/lib/surface-briefs.mjs +149 -0
- package/skills/ew-impeccable/scripts/lib/target-args.mjs +42 -0
- package/skills/ew-impeccable/scripts/lib/target-slug.mjs +33 -0
- package/skills/ew-impeccable/scripts/lib/template-extensions.mjs +146 -0
- package/skills/ew-impeccable/scripts/live/accept-css.mjs +617 -0
- package/skills/ew-impeccable/scripts/live/accept-verify.mjs +60 -0
- package/skills/ew-impeccable/scripts/live/browser-script-parts.mjs +84 -0
- package/skills/ew-impeccable/scripts/live/completion.mjs +28 -0
- package/skills/ew-impeccable/scripts/live/event-validation.mjs +199 -0
- package/skills/ew-impeccable/scripts/live/frameworks/astro.mjs +47 -0
- package/skills/ew-impeccable/scripts/live/frameworks/detect-utils.mjs +73 -0
- package/skills/ew-impeccable/scripts/live/frameworks/index.mjs +143 -0
- package/skills/ew-impeccable/scripts/live/frameworks/journal.mjs +197 -0
- package/skills/ew-impeccable/scripts/live/frameworks/nextjs.mjs +49 -0
- package/skills/ew-impeccable/scripts/live/frameworks/nuxt.mjs +161 -0
- package/skills/ew-impeccable/scripts/live/frameworks/script-src.mjs +17 -0
- package/skills/ew-impeccable/scripts/live/frameworks/static-html.mjs +26 -0
- package/skills/ew-impeccable/scripts/live/frameworks/sveltekit.mjs +71 -0
- package/skills/ew-impeccable/scripts/live/frameworks/tag-strategy.mjs +247 -0
- package/skills/ew-impeccable/scripts/live/frameworks/tanstack-start.mjs +70 -0
- package/skills/ew-impeccable/scripts/live/frameworks/vite-generic.mjs +42 -0
- package/skills/ew-impeccable/scripts/live/generation-preflight.mjs +149 -0
- package/skills/ew-impeccable/scripts/live/insert-ui.mjs +458 -0
- package/skills/ew-impeccable/scripts/live/instructions.mjs +142 -0
- package/skills/ew-impeccable/scripts/live/manual-apply.mjs +939 -0
- package/skills/ew-impeccable/scripts/live/manual-edit-routes.mjs +357 -0
- package/skills/ew-impeccable/scripts/live/manual-edits-buffer.mjs +152 -0
- package/skills/ew-impeccable/scripts/live/poll-lanes.mjs +14 -0
- package/skills/ew-impeccable/scripts/live/project-ignores.mjs +139 -0
- package/skills/ew-impeccable/scripts/live/roots.mjs +508 -0
- package/skills/ew-impeccable/scripts/live/session-store.mjs +563 -0
- package/skills/ew-impeccable/scripts/live/source-lock.mjs +105 -0
- package/skills/ew-impeccable/scripts/live/source-search.mjs +105 -0
- package/skills/ew-impeccable/scripts/live/svelte-ast.mjs +969 -0
- package/skills/ew-impeccable/scripts/live/svelte-component.mjs +1366 -0
- package/skills/ew-impeccable/scripts/live/sveltekit-adapter.mjs +304 -0
- package/skills/ew-impeccable/scripts/live/tanstack-adapter.mjs +259 -0
- package/skills/ew-impeccable/scripts/live/ui-surfaces.mjs +75 -0
- package/skills/ew-impeccable/scripts/live/vocabulary.mjs +171 -0
- package/skills/ew-impeccable/scripts/live-accept.mjs +938 -0
- package/skills/ew-impeccable/scripts/live-browser-dom.js +167 -0
- package/skills/ew-impeccable/scripts/live-browser-ignores.js +242 -0
- package/skills/ew-impeccable/scripts/live-browser-session.js +144 -0
- package/skills/ew-impeccable/scripts/live-browser.js +12851 -0
- package/skills/ew-impeccable/scripts/live-commit-manual-edits.mjs +1200 -0
- package/skills/ew-impeccable/scripts/live-complete.mjs +107 -0
- package/skills/ew-impeccable/scripts/live-copy-edit-agent.mjs +800 -0
- package/skills/ew-impeccable/scripts/live-discard-manual-edits.mjs +51 -0
- package/skills/ew-impeccable/scripts/live-inject.mjs +463 -0
- package/skills/ew-impeccable/scripts/live-insert.mjs +292 -0
- package/skills/ew-impeccable/scripts/live-manual-edit-evidence.mjs +368 -0
- package/skills/ew-impeccable/scripts/live-poll.mjs +430 -0
- package/skills/ew-impeccable/scripts/live-resume.mjs +123 -0
- package/skills/ew-impeccable/scripts/live-server.mjs +1698 -0
- package/skills/ew-impeccable/scripts/live-status.mjs +71 -0
- package/skills/ew-impeccable/scripts/live-target.mjs +30 -0
- package/skills/ew-impeccable/scripts/live-wrap.mjs +927 -0
- package/skills/ew-impeccable/scripts/live.mjs +334 -0
- package/skills/ew-impeccable/scripts/modern-screenshot.umd.js +14 -0
- package/skills/ew-impeccable/scripts/palette.mjs +628 -0
- package/skills/ew-impeccable/scripts/pin.mjs +352 -0
- package/skills/ew-impeccable/scripts/serve-question.mjs +1783 -0
- package/skills/ew-impeccable/scripts/surface-brief.mjs +74 -0
- package/skills/ew-knowledge/SKILL.md +35 -0
- package/skills/ew-knowledge/references/closeout-protocol.md +68 -0
- package/skills/ew-knowledge/references/knowledge-route.md +73 -0
- package/skills/ew-knowledge/references/wiki-maintenance.md +27 -0
- package/skills/ew-odyssey/SKILL.md +106 -0
- package/skills/ew-odyssey/references/audit-artifacts.md +7 -0
- package/skills/ew-odyssey/references/odyssey-base.md +104 -0
- package/skills/ew-odyssey/references/odyssey-debug.md +264 -0
- package/skills/ew-odyssey/references/odyssey-defensive.md +351 -0
- package/skills/ew-odyssey/references/odyssey-improve.md +230 -0
- package/skills/ew-odyssey/references/odyssey-planex.md +294 -0
- package/skills/ew-odyssey/references/odyssey-review.md +233 -0
- package/skills/ew-odyssey/references/odyssey-security.md +231 -0
- package/skills/ew-odyssey/references/odyssey-ui.md +232 -0
- package/skills/ew-odyssey/references/prepare/odyssey-debug.md +102 -0
- package/skills/ew-odyssey/references/prepare/odyssey-defensive.md +117 -0
- package/skills/ew-odyssey/references/prepare/odyssey-improve.md +95 -0
- package/skills/ew-odyssey/references/prepare/odyssey-planex.md +105 -0
- package/skills/ew-odyssey/references/prepare/odyssey-review.md +105 -0
- package/skills/ew-odyssey/references/prepare/odyssey-security.md +91 -0
- package/skills/ew-odyssey/references/prepare/odyssey-ui.md +88 -0
- package/skills/ew-odyssey/references/runtime-adapters.md +31 -0
- package/skills/ew-orchestrate/SKILL.md +89 -0
- package/skills/ew-orchestrate/references/auto-policy.md +66 -0
- package/skills/ew-orchestrate/references/boundary-grill.md +51 -0
- package/skills/ew-orchestrate/references/companion-route.md +40 -0
- package/skills/ew-orchestrate/references/ew-orchestrate.md +44 -0
- package/skills/ew-orchestrate/references/goal.md +51 -0
- package/skills/ew-orchestrate/references/orchestrator-run-loop.md +33 -0
- package/skills/ew-orchestrate/references/planning.md +54 -0
- package/skills/ew-orchestrate/steps/ew-analyze/SKILL.md +70 -0
- package/skills/ew-orchestrate/steps/ew-analyze/references/issue-gaps-analyze.md +24 -0
- package/skills/ew-orchestrate/steps/ew-analyze/references/prepare.md +8 -0
- package/skills/ew-orchestrate/steps/ew-analyze/references/workflow.md +138 -0
- package/skills/ew-orchestrate/steps/ew-auto-test/SKILL.md +80 -0
- package/skills/ew-orchestrate/steps/ew-auto-test/references/prepare.md +23 -0
- package/skills/ew-orchestrate/steps/ew-auto-test/references/workflow.md +31 -0
- package/skills/ew-orchestrate/steps/ew-blueprint/SKILL.md +122 -0
- package/skills/ew-orchestrate/steps/ew-blueprint/references/prepare.md +21 -0
- package/skills/ew-orchestrate/steps/ew-blueprint/references/workflow.md +28 -0
- package/skills/ew-orchestrate/steps/ew-brainstorm/SKILL.md +49 -0
- package/skills/ew-orchestrate/steps/ew-companion/SKILL.md +50 -0
- package/skills/ew-orchestrate/steps/ew-debug/SKILL.md +85 -0
- package/skills/ew-orchestrate/steps/ew-debug/references/prepare.md +27 -0
- package/skills/ew-orchestrate/steps/ew-debug/references/workflow.md +31 -0
- package/skills/ew-orchestrate/steps/ew-execute/SKILL.md +74 -0
- package/skills/ew-orchestrate/steps/ew-execute/references/prepare.md +27 -0
- package/skills/ew-orchestrate/steps/ew-execute/references/workflow.md +87 -0
- package/skills/ew-orchestrate/steps/ew-grill/SKILL.md +62 -0
- package/skills/ew-orchestrate/steps/ew-grill/references/prepare.md +26 -0
- package/skills/ew-orchestrate/steps/ew-grill/references/workflow.md +31 -0
- package/skills/ew-orchestrate/steps/ew-init/SKILL.md +56 -0
- package/skills/ew-orchestrate/steps/ew-init/references/prepare.md +25 -0
- package/skills/ew-orchestrate/steps/ew-init/references/workflow.md +28 -0
- package/skills/ew-orchestrate/steps/ew-plan/SKILL.md +131 -0
- package/skills/ew-orchestrate/steps/ew-plan/references/prepare.md +8 -0
- package/skills/ew-orchestrate/steps/ew-plan/references/tdd.md +53 -0
- package/skills/ew-orchestrate/steps/ew-plan/references/workflow.md +100 -0
- package/skills/ew-orchestrate/steps/ew-retrospective/SKILL.md +68 -0
- package/skills/ew-orchestrate/steps/ew-retrospective/references/prepare.md +18 -0
- package/skills/ew-orchestrate/steps/ew-retrospective/references/workflow.md +34 -0
- package/skills/ew-orchestrate/steps/ew-review/SKILL.md +45 -0
- package/skills/ew-orchestrate/steps/ew-review/references/prepare.md +17 -0
- package/skills/ew-orchestrate/steps/ew-review/references/workflow.md +116 -0
- package/skills/ew-orchestrate/steps/ew-roadmap/SKILL.md +62 -0
- package/skills/ew-orchestrate/steps/ew-roadmap/references/prepare.md +27 -0
- package/skills/ew-orchestrate/steps/ew-roadmap/references/workflow.md +28 -0
- package/skills/ew-orchestrate/steps/ew-test/SKILL.md +99 -0
- package/skills/ew-orchestrate/steps/ew-test/references/prepare.md +23 -0
- package/skills/ew-orchestrate/steps/ew-test/references/workflow.md +23 -0
- package/skills/ew-orchestrate/steps/ew-verify/SKILL.md +73 -0
- package/skills/ew-orchestrate/steps/ew-verify/references/prepare.md +21 -0
- package/skills/ew-orchestrate/steps/ew-verify/references/workflow.md +29 -0
- package/skills/ew-skill-design/SKILL.md +30 -0
- package/skills/ew-skill-design/references/package-contract.md +40 -0
- package/skills/ew-skill-design/references/validation.md +21 -0
- package/skills/team-swarm/SKILL.md +68 -0
- package/skills/team-swarm/references/mcp-coordination.md +14 -0
- package/skills/team-swarm/roles/analyst/role.md +181 -0
- package/skills/team-swarm/roles/ant/role.md +149 -0
- package/skills/team-swarm/roles/coordinator/commands/converge.md +112 -0
- package/skills/team-swarm/roles/coordinator/commands/init-swarm.md +136 -0
- package/skills/team-swarm/roles/coordinator/commands/iterate.md +171 -0
- package/skills/team-swarm/roles/coordinator/role.md +170 -0
- package/skills/team-swarm/roles/scorer/role.md +150 -0
- package/skills/team-swarm/scripts/aco.py +646 -0
- package/skills/team-swarm/scripts/pheromone.py +144 -0
- package/skills/team-swarm/scripts/scoring.py +111 -0
- package/skills/team-swarm/scripts/test_aco.py +606 -0
- package/skills/team-swarm/specs/ant-output-schema.md +127 -0
- package/skills/team-swarm/specs/convergence-criteria.md +108 -0
- package/skills/team-swarm/specs/pheromone-schema.md +125 -0
- package/skills/team-swarm/specs/swarm-config-template.json +71 -0
- package/skills/team-swarm/specs/swarm-protocol.md +119 -0
- package/skills/workflow-evolve/SKILL.md +64 -0
- package/skills/workflow-evolve/references/agy-gate.md +27 -0
- package/skills/workflow-evolve/references/auto-loop.md +23 -0
- package/skills/workflow-evolve/references/history-review.md +15 -0
- package/skills/workflow-evolve/scripts/codex-memory-replay.mjs +86 -0
- package/skills/workflow-evolve/scripts/codex-replay.mjs +1 -0
- package/skills/workflow-evolve/scripts/evolve-loop.mjs +260 -0
- package/skills/workflow-evolve/scripts/memory-codex-mcp.mjs +124 -0
- package/workflows/index.json +33 -0
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ew-odyssey-planex
|
|
3
|
+
description: "Odyssey planex mode — single requirement delivery loop through acceptance criteria definition, task planning, execution, verification, and fix iteration until all criteria pass"
|
|
4
|
+
argument-hint: "<requirement> [--template feature|bugfix|refactor|migration|api-endpoint] [--method auto|agent|<cli>] [--skip-verify] [--skip-generalize] [--max-iterations N] [-y] [-c]"
|
|
5
|
+
contract:
|
|
6
|
+
contract_version: 2.1
|
|
7
|
+
produces:
|
|
8
|
+
- path: outputs/session.json
|
|
9
|
+
kind: session
|
|
10
|
+
schema: session/1.0
|
|
11
|
+
role: primary
|
|
12
|
+
alias: planex-session
|
|
13
|
+
required: true
|
|
14
|
+
- path: outputs/evidence.ndjson
|
|
15
|
+
kind: evidence
|
|
16
|
+
schema: evidence/1.0
|
|
17
|
+
role: evidence
|
|
18
|
+
alias: planex-evidence
|
|
19
|
+
required: false
|
|
20
|
+
- path: outputs/understanding.md
|
|
21
|
+
kind: understanding
|
|
22
|
+
schema: understanding/1.0
|
|
23
|
+
role: primary
|
|
24
|
+
alias: planex-understanding
|
|
25
|
+
required: false
|
|
26
|
+
goal: true
|
|
27
|
+
---
|
|
28
|
+
|
|
29
|
+
# Pre-task Thinking: odyssey-planex
|
|
30
|
+
|
|
31
|
+
## Purpose
|
|
32
|
+
|
|
33
|
+
Odyssey planex is a full requirement delivery cycle: requirement intake → acceptance criteria derivation → task planning → execution (agent or CLI) → verification → fix iteration → generalization → discovery → knowledge persistence. Unlike standalone `ew-plan` + `ew-execute` (which handle planning and execution separately), odyssey-planex owns the entire loop from requirement to all acceptance criteria passing, including iterative fix cycles and pattern generalization.
|
|
34
|
+
|
|
35
|
+
## Input Interpretation
|
|
36
|
+
|
|
37
|
+
Entry modes:
|
|
38
|
+
|
|
39
|
+
| Mode | Trigger | Requirement source |
|
|
40
|
+
|------|---------|-------------------|
|
|
41
|
+
| standalone | requirement description in `<intent>` | Parse requirement directly |
|
|
42
|
+
| template | `--template <name>` | Apply predefined criteria pattern (feature, bugfix, refactor, migration, api-endpoint) |
|
|
43
|
+
| continuation | `-c` | Resume via latest session, jump to `current_state` |
|
|
44
|
+
|
|
45
|
+
Template criteria patterns:
|
|
46
|
+
|
|
47
|
+
| Template | Criteria pattern | Use case |
|
|
48
|
+
|----------|-----------------|----------|
|
|
49
|
+
| `feature` | User story acceptance + boundary tests + UI verification | New feature |
|
|
50
|
+
| `bugfix` | Regression tests + root cause confirmation + boundary coverage | Bug fix |
|
|
51
|
+
| `refactor` | Behavior preservation + performance baseline + API compatibility | Refactoring |
|
|
52
|
+
| `migration` | Data consistency + rollback verification + performance comparison | Data/API migration |
|
|
53
|
+
| `api-endpoint` | Request/response contract + error handling + permission checks | API development |
|
|
54
|
+
|
|
55
|
+
Execution method is configurable at S_EXECUTE via interactive confirmation or `--method`:
|
|
56
|
+
|
|
57
|
+
| Method | Resolution |
|
|
58
|
+
|--------|-----------|
|
|
59
|
+
| `auto` | Domain routing — frontend/backend/general mapped to configured tools |
|
|
60
|
+
| `agent` | All tasks executed by Agent |
|
|
61
|
+
| `<cli-name>` | All tasks dispatched to specific CLI tool |
|
|
62
|
+
|
|
63
|
+
## Required Context
|
|
64
|
+
|
|
65
|
+
Satisfy the Knowledge Gate (`AGENTS.md`) before searching code:
|
|
66
|
+
|
|
67
|
+
- Wiki & Memory (first): Run MCP `wiki_context` / `memory_search` + `wiki_reference` / `memory_get`, or CLI `evolve context "<requirement keywords>" --session <session> --include-memory --reads "<run_dir>/knowledge-reads.json"` (plus `evolve wiki get <id> --resolved --reads ... --from-search ...`) for `coding` and `review` scope.
|
|
68
|
+
- Code graph (after Knowledge Gate): `evolve code search "<requirement keywords>"` → module boundaries, integration points.
|
|
69
|
+
- CLI tools: `the Codex or Agy executables available to the host` → available executors for task dispatch.
|
|
70
|
+
|
|
71
|
+
When prior planex sessions of the same scope exist, check their acceptance criteria and plan to avoid duplicating work or re-implementing already-delivered features.
|
|
72
|
+
|
|
73
|
+
## Run Artifact Metadata
|
|
74
|
+
|
|
75
|
+
Attach `kind`, `schema`, `role`, and `alias` from `produces` to top-level `_meta` in `outputs/session.json`, the first JSON record in `outputs/evidence.ndjson`, and YAML frontmatter in `outputs/understanding.md` (`current_state: "END"` before `evolve run complete`).
|
|
76
|
+
|
|
77
|
+
## Boundaries and Invariants
|
|
78
|
+
|
|
79
|
+
- **State chain:** `S_INTAKE → S_PLAN → S_EXECUTE → S_VERIFY → S_FIX → [back-half]` with FIX↔VERIFY loop until all criteria pass.
|
|
80
|
+
- **Acceptance criteria are sacred** — once confirmed at S_INTAKE, criteria cannot be silently dropped or weakened. All must reach `passed` (or `deferred` at max iteration with user consent).
|
|
81
|
+
- **Max iterations** (default 3) prevents infinite FIX↔VERIFY loops. When exceeded: Normal → structured user prompt (continue/lower bar/accept) | `-y` → `deferred`, proceed S_RECORD.
|
|
82
|
+
- **Max 3 retries per task** — first attempt normal → retry with simplified self-contained prompt → switch to a joined subagent (see [runtime adapters](../runtime-adapters.md)) → all 3 fail → mark `blocked`, continue remaining. NEVER exceed 3 attempts.
|
|
83
|
+
- **Replan preserves criteria** — when S_VERIFY routes back to S_PLAN (fundamental plan flaw), `acceptance_criteria[]` statuses are preserved; only `plan.tasks[]` are regenerated. Passed criteria retain `passed`; failed criteria reset to `pending`.
|
|
84
|
+
- **Evidence append-only** — evidence.ndjson entries are immutable observations; modifying or deleting them is forbidden.
|
|
85
|
+
- **Phase goal tracking** — mark each goal done/failed before transition; no silent skips.
|
|
86
|
+
- **Generalize is mandatory** unless `skip_generalize == true`; prior-phase convergence is NOT a valid skip reason.
|
|
87
|
+
- **Fix scope:** fixes target diagnosed gaps in specific failed criteria, not re-implementation. Targeted code fix, not wholesale rewrite.
|
|
88
|
+
- **In scope:** Single requirement delivery loop. **Out of scope:** Multi-requirement orchestration → `/ew-orchestrate` (`ew-plan`) | Deep debugging → `--mode debug` | Code review → `--mode review` | UI optimization → `--mode ui`.
|
|
89
|
+
|
|
90
|
+
## Risk Checklist
|
|
91
|
+
|
|
92
|
+
- Are acceptance criteria testable and each assigned a `verify_method` (test|grep|cli-review|manual)? Vague criteria like "works well" cannot be verified.
|
|
93
|
+
- Is the plan decomposition complete — every criterion mapped to at least one task? Unmapped criteria will never be satisfied.
|
|
94
|
+
- Was execution method confirmed (or defaulted with `-y`) before task dispatch? Dispatching without confirmed config wastes cycles on wrong executors.
|
|
95
|
+
- Did each task respect the 3-retry hard limit? Exceeding 3 attempts on a single task is forbidden — mark `blocked` and continue.
|
|
96
|
+
- At S_VERIFY, was every criterion verified by its declared method? Switching methods silently (e.g., skipping `test` and using `grep` instead) undermines verification integrity.
|
|
97
|
+
- On replan (S_VERIFY → S_PLAN), were passed criteria preserved? Regenerating the entire criteria set loses confirmed progress.
|
|
98
|
+
- Are all 3 generalization layers (syntax/semantic/structural) attempted? A single-layer quick grep does NOT satisfy the thoroughness floor.
|
|
99
|
+
- Is every discovery hit individually classified with a reason? Blanket "pre-existing" skips are forbidden.
|
|
100
|
+
|
|
101
|
+
## Gate Intent
|
|
102
|
+
|
|
103
|
+
- `criteria-defined`: acceptance criteria are derived from the requirement (≥1 criterion in `acceptance_criteria[]`), each with a testable `criterion` statement and assigned `verify_method` (test|grep|cli-review|manual). Criteria are confirmed by user or auto-derived with deferred confirmation under `-y`. Goal G1 is marked.
|
|
104
|
+
- `all-criteria-passed`: every `acceptance_criteria[].status == passed` with recorded evidence and `passed_at` timestamp, verified by the declared `verify_method`. Iterations are logged in `iterations[]`. If max iterations exceeded, criteria may be `deferred` only with explicit user consent (or `-y` auto-accept). Goal G4 is marked.
|
|
105
|
+
- `plan-executed`: all plan tasks are executed (status `completed`) or explicitly `blocked` after 3 retries with logged evidence. Per-task execution evidence is recorded. Post-execution validation (convergence, existence, substance, anti-patterns) is completed unless `--skip-verify`. Goal G3 is marked.
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ew-odyssey-review
|
|
3
|
+
description: "Odyssey review mode — multi-dimensional deep code review through archaeology, exploration, 4-dimension audit, exhaustive severity-tiered fix, and zero-residual confirmation, producing review"
|
|
4
|
+
argument-hint: "<target: file|dir|HEAD|staged|phase#|PR#> [--skip-fix] [--skip-generalize] [-y] [-c]"
|
|
5
|
+
contract:
|
|
6
|
+
contract_version: 2.1
|
|
7
|
+
produces:
|
|
8
|
+
- path: outputs/session.json
|
|
9
|
+
kind: session
|
|
10
|
+
schema: session/1.0
|
|
11
|
+
role: primary
|
|
12
|
+
alias: review-session
|
|
13
|
+
required: true
|
|
14
|
+
- path: outputs/evidence.ndjson
|
|
15
|
+
kind: evidence
|
|
16
|
+
schema: evidence/1.0
|
|
17
|
+
role: evidence
|
|
18
|
+
alias: review-evidence
|
|
19
|
+
required: false
|
|
20
|
+
- path: outputs/understanding.md
|
|
21
|
+
kind: understanding
|
|
22
|
+
schema: understanding/1.0
|
|
23
|
+
role: primary
|
|
24
|
+
alias: review-understanding
|
|
25
|
+
required: false
|
|
26
|
+
- path: outputs/explore.json
|
|
27
|
+
kind: exploration
|
|
28
|
+
schema: exploration/1.0
|
|
29
|
+
role: evidence
|
|
30
|
+
alias: review-explore
|
|
31
|
+
required: false
|
|
32
|
+
goal: true
|
|
33
|
+
---
|
|
34
|
+
|
|
35
|
+
# Pre-task Thinking: odyssey-review
|
|
36
|
+
|
|
37
|
+
## Purpose
|
|
38
|
+
|
|
39
|
+
Odyssey review is a full-lifecycle code review cycle: target intake → archaeology → code exploration → multi-dimensional review audit → exhaustive severity-tiered fix → zero-residual confirmation → generalization → discovery → knowledge persistence. Unlike standalone code review (which produces only findings), odyssey-review carries through to fix ALL findings by severity, confirm zero residual, generalize patterns project-wide, and persist learnings.
|
|
40
|
+
|
|
41
|
+
## Input Interpretation
|
|
42
|
+
|
|
43
|
+
Entry modes:
|
|
44
|
+
|
|
45
|
+
| Mode | Trigger | Target source |
|
|
46
|
+
|------|---------|---------------|
|
|
47
|
+
| file/dir | file or directory path in `<intent>` | Review those files directly |
|
|
48
|
+
| diff | `HEAD` or `staged` in `<intent>` | `git diff HEAD` or `git diff --staged` |
|
|
49
|
+
| session/run | session/run ID or commit range in `<intent>` | Evolve Run artifacts / `git diff <base>..<head>` |
|
|
50
|
+
| PR | PR number in `<intent>` | `git diff main...HEAD` |
|
|
51
|
+
| continuation | `-c` | Resume via latest session, jump to `current_state` |
|
|
52
|
+
|
|
53
|
+
Target resolution table:
|
|
54
|
+
|
|
55
|
+
| Input | Resolution |
|
|
56
|
+
|-------|-----------|
|
|
57
|
+
| File/dir path | Review those files |
|
|
58
|
+
| `HEAD` / `staged` | `git diff HEAD` / `git diff --staged` |
|
|
59
|
+
| Session/Run ID or commit range | Evolve Run artifacts / `git diff <base>..<head>` |
|
|
60
|
+
| PR number | `git diff main...HEAD` |
|
|
61
|
+
|
|
62
|
+
## Required Context
|
|
63
|
+
|
|
64
|
+
Satisfy the Knowledge Gate (`AGENTS.md`) before searching code:
|
|
65
|
+
|
|
66
|
+
- Wiki & Memory (first): Run MCP `wiki_context` / `memory_search` + `wiki_reference` / `memory_get`, or CLI `evolve context "<target keywords>" --session <session> --include-memory --reads "<run_dir>/knowledge-reads.json"` (plus `evolve wiki get <id> --resolved --reads ... --from-search ...`) for `review` and `coding` scope.
|
|
67
|
+
- Code graph (after Knowledge Gate): `evolve code search "<target keywords>"` → module boundaries, ownership.
|
|
68
|
+
|
|
69
|
+
When prior review artifacts of the same scope exist, check their findings first to avoid re-reviewing already-addressed patterns.
|
|
70
|
+
|
|
71
|
+
## Run Artifact Metadata
|
|
72
|
+
|
|
73
|
+
Attach `kind`, `schema`, `role`, and `alias` from `produces` to top-level `_meta` in `outputs/session.json` and `outputs/explore.json`, the first JSON record in `outputs/evidence.ndjson`, and YAML frontmatter in `outputs/understanding.md` (`current_state: "END"` before `evolve run complete`).
|
|
74
|
+
|
|
75
|
+
## Boundaries and Invariants
|
|
76
|
+
|
|
77
|
+
- **State chain:** `S_INTAKE → S_ARCHAEOLOGY → S_EXPLORE → S_REVIEW → S_FIX → S_CONFIRM → [back-half]`
|
|
78
|
+
- **Zero-residual applies** — fix ALL findings within fix_threshold (default: all severity levels). No partial-tier advancement.
|
|
79
|
+
- **Evidence append-only** — evidence.ndjson entries are immutable observations; modifying or deleting them is forbidden.
|
|
80
|
+
- **Phase goal tracking** — mark each goal done/failed before transition; no silent skips.
|
|
81
|
+
- **4-dimension mandatory** — all dimensions (correctness, security, performance, architecture) must be reviewed. Zero dimensions reviewed is BLOCKED.
|
|
82
|
+
- **Exhaustive fix by severity** — descend through [critical, high, medium, low], each tier fully addressed before advancing. Blanket "pre-existing" classification forbidden; each finding must be individually assessed.
|
|
83
|
+
- **max_fix_rounds = 5** — hard limit on fix retry rounds. After 5 rounds with remaining > 0, escalate to user or classify as deferred.
|
|
84
|
+
- **Test evidence reuse across S_FIX/S_CONFIRM** — a per-tier commit invalidates only tests covering the committed changes; unchanged passing results carry forward, and S_CONFIRM reruns only invalidated targets plus the modified-area re-review. Never rerun the full matrix merely because a tier advanced.
|
|
85
|
+
- **Generalize is mandatory** unless `skip_generalize == true`; prior-phase convergence is NOT a valid skip reason.
|
|
86
|
+
- **Fix scope:** source code modifications during fix phase are in-scope but MUST be committed per tier. Session artifacts target `{run_dir}/outputs/` only.
|
|
87
|
+
- **In scope:** Multi-dimensional deep review → exhaustive fix → generalize. **Out of scope:** Root cause debug → `--mode debug` | Feature implementation → `--mode planex` | UI visual optimization → `--mode ui`.
|
|
88
|
+
|
|
89
|
+
## Risk Checklist
|
|
90
|
+
|
|
91
|
+
- Are all 4 review dimensions (correctness, security, performance, architecture) covered? Missing a dimension leaves an entire class of findings undetected.
|
|
92
|
+
- Is every finding backed by file, line, and description evidence? Vague findings without location are not actionable.
|
|
93
|
+
- Did you descend severity tiers in order (critical → high → medium → low)? Skipping tiers leaves high-severity issues unfixed.
|
|
94
|
+
- Is every finding in a tier either fixed or individually classified with a reason? Blanket "pre-existing" skips are forbidden.
|
|
95
|
+
- Have fix rounds exceeded 5? Stop and escalate — do not continue fixing indefinitely.
|
|
96
|
+
- Are archaeology/explore results properly logged even on partial failure (W003/W006)? Missing evidence must be flagged, not silently omitted.
|
|
97
|
+
- Is every discovery hit individually classified with a reason? Blanket skips are forbidden.
|
|
98
|
+
- Are all 3 generalization layers (syntax/semantic/structural) attempted? A single-layer quick grep does NOT satisfy the thoroughness floor.
|
|
99
|
+
- Did the zero-residual confirmation actually re-review modified areas? A pass-through without re-review does not satisfy the CONFIRM gate.
|
|
100
|
+
|
|
101
|
+
## Gate Intent
|
|
102
|
+
|
|
103
|
+
- `discovery-complete`: archaeology and/or exploration phases have logged evidence, understanding.md §2-§3 are updated, and explore goal (G2) is marked. Log W003 on partial archaeology failure or W006 when no CLI exploration executor is available, and record what was covered.
|
|
104
|
+
- `all-dimensions-reviewed`: all 4 dimension agents (correctness, security, performance, architecture) have completed, findings are merged into review_result with severity classification, evidence phase=review is logged, and understanding.md §4 severity matrix is written. G1 is marked. Zero dimensions reviewed is BLOCKED (W002 partial with at least 1 dimension is allowed).
|
|
105
|
+
- `zero-remaining`: exhaustive fix has been applied tier-by-tier, `remaining_actionable == 0` (or all remaining individually classified as deferred after 5-round escalation), tests covering the modified areas pass (reusing still-valid live-run results from S_FIX rounds when nothing they cover changed since; rerunning only invalidated targets), CLI re-review confirms no new findings, confirmation is written, understanding.md §5 is updated, and G3 is marked. `needs_rework` routes back to FIX. Skippable only when `skip_fix == true`.
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ew-odyssey-security
|
|
3
|
+
description: "Odyssey security mode — read-only tiered security audit (OWASP Top 10, dependency supply chain, secrets, CI/CD, STRIDE, git history) producing severity matrix report with file:line evidence."
|
|
4
|
+
argument-hint: "<target> [--tier quick|standard|deep] [--skip-generalize] [-y] [-c]"
|
|
5
|
+
contract:
|
|
6
|
+
contract_version: 2.1
|
|
7
|
+
produces:
|
|
8
|
+
- path: outputs/session.json
|
|
9
|
+
kind: security-audit-result
|
|
10
|
+
schema: security-audit-result/1.0
|
|
11
|
+
role: primary
|
|
12
|
+
alias: security-session
|
|
13
|
+
required: true
|
|
14
|
+
- path: outputs/evidence.ndjson
|
|
15
|
+
kind: evidence
|
|
16
|
+
schema: evidence/1.0
|
|
17
|
+
role: evidence
|
|
18
|
+
alias: security-evidence
|
|
19
|
+
required: true
|
|
20
|
+
- path: outputs/understanding.md
|
|
21
|
+
kind: security-report
|
|
22
|
+
schema: security-report/1.0
|
|
23
|
+
role: primary
|
|
24
|
+
alias: security-understanding
|
|
25
|
+
required: true
|
|
26
|
+
goal: true
|
|
27
|
+
---
|
|
28
|
+
|
|
29
|
+
# Pre-task Thinking: odyssey-security
|
|
30
|
+
|
|
31
|
+
## Purpose
|
|
32
|
+
|
|
33
|
+
Odyssey security performs a systematic read-only security audit of a target module or project. It covers OWASP Top 10, dependency supply chain, secrets detection, CI/CD pipeline review, STRIDE threat modeling, and git history archaeology — tiered by depth (quick/standard/deep). Unlike other Odyssey modes, security is strictly read-only: it produces a severity matrix report with file:line evidence and remediation suggestions, but NEVER modifies source code. Before starting, establish the target scope, audit tier, and entry points.
|
|
34
|
+
|
|
35
|
+
## Input Interpretation
|
|
36
|
+
|
|
37
|
+
Target resolution determines what gets audited:
|
|
38
|
+
|
|
39
|
+
| Input | Resolution |
|
|
40
|
+
|-------|-----------|
|
|
41
|
+
| Module/dir path | Audit that module |
|
|
42
|
+
| Project root (default) | Full project scan |
|
|
43
|
+
| `HEAD` / `staged` | Review changes in diff for security issues |
|
|
44
|
+
|
|
45
|
+
Tier selection (default: `standard`):
|
|
46
|
+
|
|
47
|
+
| Tier | OWASP | Dependencies | Secrets | CI/CD | STRIDE | Git History |
|
|
48
|
+
|------|-------|-------------|---------|-------|--------|-------------|
|
|
49
|
+
| quick | ✓ | ✓ | — | — | — | — |
|
|
50
|
+
| standard | ✓ | ✓ | ✓ | ✓ | — | — |
|
|
51
|
+
| deep | ✓ | ✓ | ✓ | ✓ | ✓ | ✓ |
|
|
52
|
+
|
|
53
|
+
## Required Context
|
|
54
|
+
|
|
55
|
+
Satisfy the Knowledge Gate (`AGENTS.md`) before searching code:
|
|
56
|
+
|
|
57
|
+
- Wiki & Memory (first): Run MCP `wiki_context` / `memory_search` + `wiki_reference` / `memory_get`, or CLI `evolve context "<target keywords>" --session <session> --include-memory --reads "<run_dir>/knowledge-reads.json"` (plus `evolve wiki get <id> --resolved --reads ... --from-search ...`) for `debug` and `coding` scope.
|
|
58
|
+
- Code graph (after Knowledge Gate): `evolve code search "<target keywords>"` → module boundaries, trust zones.
|
|
59
|
+
|
|
60
|
+
When prior security audit sessions of the same target exist, check their findings first to avoid re-reporting already-documented issues.
|
|
61
|
+
|
|
62
|
+
Use [read-only audit artifacts](../audit-artifacts.md) for the checkpoint and output metadata.
|
|
63
|
+
|
|
64
|
+
## Boundaries and Invariants
|
|
65
|
+
|
|
66
|
+
- **Read-only** — NEVER modify source code, configuration, dependencies, or CI/CD files during audit. Security audit produces reports only. All file writes target `{run_dir}/outputs/` exclusively.
|
|
67
|
+
- **Findings require file:line evidence** — every finding MUST reference a specific file:line location and include the vulnerable code pattern. No vague or category-only findings.
|
|
68
|
+
- **Severity NEVER downgraded without justification** — if a finding matches a known OWASP category, its severity follows OWASP guidance. Downgrading requires documented rationale (e.g., compensating control exists).
|
|
69
|
+
- **Tier coverage is mandatory** — all scan phases required by the selected tier MUST complete. NEVER skip a tier-required phase silently; failures are logged as W00x warnings.
|
|
70
|
+
- **False positive marking requires evidence** — marking a finding as false positive MUST include the compensating control or code path that prevents exploitation. NEVER dismiss findings without counter-evidence.
|
|
71
|
+
- **Secrets are never logged** — if secrets are discovered, report their location (file:line) and type but NEVER include the actual secret value in the report output.
|
|
72
|
+
- **No fix loop** — this mode has NO S_FIX or S_CONFIRM states. Findings are reported with remediation suggestions; actual fixes route to `--mode improve` or `--mode debug`.
|
|
73
|
+
- **Evidence append-only** — evidence.ndjson entries are immutable observations; modifying or deleting them is forbidden.
|
|
74
|
+
- **Generalize is mandatory** unless `skip_generalize == true`; prior-phase convergence is NOT a valid skip reason.
|
|
75
|
+
|
|
76
|
+
## Risk Checklist
|
|
77
|
+
|
|
78
|
+
- Is every finding anchored to `file:line` with severity, category, description, and remediation? Unanchored findings are not actionable.
|
|
79
|
+
- Were all tier-required scan phases attempted? Missing phases mean incomplete coverage.
|
|
80
|
+
- Are OWASP category severities preserved without unjustified downgrades?
|
|
81
|
+
- Are false positive dismissals backed by compensating-control evidence?
|
|
82
|
+
- Were discovered secrets reported by location only, never by value?
|
|
83
|
+
- Did the audit remain strictly read-only? Any source modification is a violation.
|
|
84
|
+
- Is every discovery hit individually classified with a reason? Blanket skips are forbidden.
|
|
85
|
+
- Are all 3 generalization layers (syntax/semantic/structural) attempted? A single-layer quick grep does NOT satisfy the thoroughness floor.
|
|
86
|
+
|
|
87
|
+
## Gate Intent
|
|
88
|
+
|
|
89
|
+
- `recon-complete`: tech stack detected, entry points identified, auth/authz modules listed, data flow mapped. Evidence phase=recon logged. Understanding.md §2 updated. Cannot scan without entry points and data flow baseline.
|
|
90
|
+
- `scan-complete`: all tier-required scan phases completed (OWASP + dependencies for quick; + secrets + CI/CD for standard; + STRIDE + git history for deep). Evidence phase=scan logged per phase. Findings merged into severity matrix. Understanding.md §3-§4 updated. Tier-required phase not attempted is BLOCKED (W001/W002 partial from tool failure is a warning).
|
|
91
|
+
- `report-produced`: severity matrix with file:line references and remediation for every finding. Summary statistics computed. Understanding.md §5 (full report) written. Session.json `audit_result` populated.
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ew-odyssey-ui
|
|
3
|
+
description: "6-dimension visual experience audit with divergent exploration — survey design context, audit visual/interaction/a11y/responsive/motion/edge dimensions, diverge for polish+delight, fix, verify,"
|
|
4
|
+
argument-hint: "<target> [--dimensions <list>] [--skip-fix] [--skip-generalize] [-y] [-c]"
|
|
5
|
+
contract:
|
|
6
|
+
contract_version: 2.1
|
|
7
|
+
produces:
|
|
8
|
+
- path: outputs/session.json
|
|
9
|
+
kind: session
|
|
10
|
+
schema: session/1.0
|
|
11
|
+
role: primary
|
|
12
|
+
alias: ui-session
|
|
13
|
+
required: true
|
|
14
|
+
- path: outputs/evidence.ndjson
|
|
15
|
+
kind: evidence
|
|
16
|
+
schema: evidence/1.0
|
|
17
|
+
role: evidence
|
|
18
|
+
alias: ui-evidence
|
|
19
|
+
required: false
|
|
20
|
+
- path: outputs/understanding.md
|
|
21
|
+
kind: understanding
|
|
22
|
+
schema: understanding/1.0
|
|
23
|
+
role: primary
|
|
24
|
+
alias: ui-understanding
|
|
25
|
+
required: false
|
|
26
|
+
goal: true
|
|
27
|
+
---
|
|
28
|
+
|
|
29
|
+
# Pre-task Thinking: odyssey-ui
|
|
30
|
+
|
|
31
|
+
## Purpose
|
|
32
|
+
|
|
33
|
+
Odyssey UI performs a full-lifecycle visual experience optimization cycle: survey design context → 6-dimension audit (visual hierarchy, interaction states, accessibility, responsiveness, micro-interactions, edge cases) → divergent exploration for polish and delight ideas → exhaustive fix → verify → generalize to sibling components → persist learnings. Unlike a standalone review or audit, odyssey-ui goes beyond defect fixing to explore what would make the UI delightful, then carries through to fix, verify, generalize, and persist.
|
|
34
|
+
|
|
35
|
+
## Input Interpretation
|
|
36
|
+
|
|
37
|
+
Target resolution determines what gets audited:
|
|
38
|
+
|
|
39
|
+
| Input | Resolution |
|
|
40
|
+
|-------|-----------|
|
|
41
|
+
| Component path | Audit component |
|
|
42
|
+
| Page/route | Audit page |
|
|
43
|
+
| `staged` / `HEAD` | Diff UI changes |
|
|
44
|
+
| Feature area | Resolve to components/pages |
|
|
45
|
+
|
|
46
|
+
The six dimensions (default all, overridable via `--dimensions`): visual_hierarchy, interaction_states, accessibility, responsiveness, micro_interactions, edge_cases. Each dimension has a distinct focus area (see Dimensions table in workflow file).
|
|
47
|
+
|
|
48
|
+
## Required Context
|
|
49
|
+
|
|
50
|
+
Satisfy the Knowledge Gate (`AGENTS.md`) before searching code:
|
|
51
|
+
|
|
52
|
+
- Wiki & Memory (first): Run MCP `wiki_context` / `memory_search` + `wiki_reference` / `memory_get`, or CLI `evolve context "<target keywords>" --session <session> --include-memory --reads "<run_dir>/knowledge-reads.json"` (plus `evolve wiki get <id> --resolved --reads ... --from-search ...`) for `ui` and `coding` scope.
|
|
53
|
+
- Code graph (after Knowledge Gate): `evolve code search "<target keywords>"` → component hierarchy, design system structure.
|
|
54
|
+
- Design system scan: scan for design tokens, CSS variables, theme imports at survey phase — these inform the audit baseline.
|
|
55
|
+
|
|
56
|
+
When prior UI sessions of the same target exist, check their audit results and diverge ideas first to avoid re-auditing already-addressed dimensions.
|
|
57
|
+
|
|
58
|
+
## Run Artifact Metadata
|
|
59
|
+
|
|
60
|
+
Attach `kind`, `schema`, `role`, and `alias` from `produces` to top-level `_meta` in `outputs/session.json`, the first JSON record in `outputs/evidence.ndjson`, and YAML frontmatter in `outputs/understanding.md` (`current_state: "END"` before `evolve run complete`).
|
|
61
|
+
|
|
62
|
+
## Boundaries and Invariants
|
|
63
|
+
|
|
64
|
+
- **Browser is truth** — the rendered visual output in the browser is the authoritative source of UI quality; code-level analysis alone is insufficient for visual/interaction judgment.
|
|
65
|
+
- **Diverge before converge** — the DIVERGE phase explicitly generates ideas beyond the audit defects. Polish (shadows, transitions, hover, feedback, skeleton loading) and delight (motion design, progressive disclosure, smart defaults, celebratory feedback) are separate from fixing audit findings.
|
|
66
|
+
- **Decision gate narrow scope** — ONLY these qualify as decisions requiring user input: brand/style direction requiring human creative judgment | layout restructuring that significantly changes user flow | requires new design tokens or breaking component API. Everything else is actionable without user escalation.
|
|
67
|
+
- **All dimensions mandatory** — all 6 dimensions (or `--dimensions` subset) must be audited with independent agents. Zero dimensions reviewed is BLOCKED, not a warning.
|
|
68
|
+
- **Priority-ordered fixing** — findings and ideas are fixed by priority tier (critical → high → medium → low + high-impact ideas). No partial-tier advancement.
|
|
69
|
+
- **Evidence append-only** — evidence.ndjson entries are immutable observations; modifying or deleting them is forbidden.
|
|
70
|
+
- **Fix scope** — source code modifications during fix phase are in-scope but MUST be committed per action. Session artifacts target `{run_dir}/outputs/` only.
|
|
71
|
+
- **Generalize is mandatory** unless `skip_generalize == true`; prior-phase convergence is NOT a valid skip reason.
|
|
72
|
+
|
|
73
|
+
## Risk Checklist
|
|
74
|
+
|
|
75
|
+
- Is every audit finding anchored to `file:line` with severity, dimension, description, and suggestion? Unanchored findings are not actionable.
|
|
76
|
+
- Were all 6 dimensions (or `--dimensions` subset) audited with independent agents? Missing dimensions mean incomplete coverage.
|
|
77
|
+
- Did the DIVERGE phase go beyond fixing defects — did it explore polish and delight opportunities separately? Diverge that only restates audit findings is insufficient.
|
|
78
|
+
- Are the 2 diverge agents (Polish + Delight) returning distinct categories? Overlapping outputs indicate the agents were not properly scoped.
|
|
79
|
+
- After consolidation, is the priority list sorted by severity × impact × effort? Unsorted lists lead to suboptimal fix ordering.
|
|
80
|
+
- Is every discovery hit individually classified with a reason? Blanket "pre-existing" skips are forbidden.
|
|
81
|
+
- Are all 3 generalization layers (syntax/semantic/structural) attempted? A single-layer quick grep does NOT satisfy the thoroughness floor.
|
|
82
|
+
- Does the decision gate only escalate brand/style/layout/token decisions? Over-escalation slows the cycle; under-escalation risks unwanted visual changes.
|
|
83
|
+
|
|
84
|
+
## Gate Intent
|
|
85
|
+
|
|
86
|
+
- `all-dimensions-audited`: all 6 dimensions (or `--dimensions` subset) completed audit with structured findings (`[{title, severity, file, line, description, suggestion, dimension}]`), merged into severity matrix, and evidence phase=audit logged for each. Zero dimensions reviewed is BLOCKED (W002 partial coverage from agent failure is a warning, not a block).
|
|
87
|
+
- `diverge-explored`: both Polish and Delight agents completed, returning distinct `[{idea, category, impact, effort, description, inspiration}]` entries. CLI-assisted analysis completed. All outputs consolidated with audit findings into a prioritized list (severity × impact × effort). Evidence phase=diverge logged. Understanding.md §4 written.
|
|
88
|
+
- `zero-remaining-verified`: all prioritized findings and ideas are either fixed and verified, individually classified with justification (issue created / decision recorded), or legitimately skipped via `--skip-fix` flag. Tests pass (lint, unit, visual regression). Confirmation written. No unaddressed actionable findings remain. Understanding.md §5 updated. `needs_rework` routes back to FIX.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Odyssey Host Runtime Adapters
|
|
2
|
+
|
|
3
|
+
Mode workflows describe host-neutral capabilities (parallel agents, structured user prompts, progress tracking, heartbeats). Map them to the active host runtime below:
|
|
4
|
+
|
|
5
|
+
## 1. Parallel Subagents & Batch Scans
|
|
6
|
+
|
|
7
|
+
| Capability | Antigravity | Codex |
|
|
8
|
+
|---|---|---|
|
|
9
|
+
| Parallel review / audit / archaeology / generalization scan | `invoke_subagent` (parallel), `swarm`, or `run_workflow` | `spawn_agent` / `spawn_agents_on_csv` + `wait_agent` |
|
|
10
|
+
| Lifecycle rule | **Always join, complete, or cancel every spawned subagent before advancing or ending scope** | Collect all batch CSV/agent outputs before merging |
|
|
11
|
+
| Cross-angle CLI verification | `evolve delegate "<prompt>" --to codex\|agy --mode analysis\|write` (pass `--session <id> --run <run>` only with `--to codex`) | Same (`evolve delegate` binds Run MCP with `--to codex`) |
|
|
12
|
+
|
|
13
|
+
## 2. Structured User Prompts
|
|
14
|
+
|
|
15
|
+
- When a workflow specifies **structured prompt** at a non-`-y` decision gate: use `ask_question` in Antigravity, or `request_user_input` in Codex.
|
|
16
|
+
- When `-y` (`auto_confirm: true`) is active, follow each mode's `-y` Decision Points table and record skipped human choices as `deferred`.
|
|
17
|
+
|
|
18
|
+
## 3. Progress Mirroring & Heartbeats
|
|
19
|
+
|
|
20
|
+
- **`phase_goals[]` in `outputs/session.json`** is the single authoritative campaign progress record.
|
|
21
|
+
- Mirror `phase_goals[]` updates via the host's native progress tracker when available (`update_plan` in Codex; Antigravity hosts respect native `/goal` state and never re-emit `/goal` prose or recreate cleared UI state).
|
|
22
|
+
- **Optional `--heartbeat`**: update `session.json.updated_at` on each phase transition (if >15 min stalls occur, increment `stale_count`; Antigravity `schedule` is used only when the user explicitly requests a recurring timer).
|
|
23
|
+
|
|
24
|
+
## 4. Run Artifact Metadata & Sealing
|
|
25
|
+
|
|
26
|
+
- Every mode stores artifacts exclusively under `{run_dir}/outputs/` (or workspace source files in mutable fix phases).
|
|
27
|
+
- Attach matching `kind`, `schema`, `role`, and `alias` from `references/prepare/odyssey-<mode>.md` to:
|
|
28
|
+
- Top-level `_meta` in JSON outputs (`session.json`, plus `explore.json` or `anchors.json`)
|
|
29
|
+
- First record's `_meta` in `evidence.ndjson` (append-only NDJSON lines thereafter)
|
|
30
|
+
- YAML frontmatter in `understanding.md`
|
|
31
|
+
- Set `current_state = "END"` in `outputs/session.json` before sealing atomically via `evolve run complete <run_id> --session <session_id> --actor <actor> --expected-orchestration-revision <rev> --expected-run-revision <run_rev> --summary "<summary>"`.
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ew-orchestrate
|
|
3
|
+
description: Route, initialize, brainstorm, grill, blueprint, roadmap, analyze, plan, execute, verify, test, debug, review, retrospect and recover work over one canonical Session/Run chain
|
|
4
|
+
argument-hint: <intent> [--goal <goal>] [--auto] [--resume <session-id>] [-y] [-c] [--amend]
|
|
5
|
+
session-mode: run
|
|
6
|
+
contract:
|
|
7
|
+
discovery: self-described
|
|
8
|
+
consumes: []
|
|
9
|
+
produces: []
|
|
10
|
+
version: 0.7.1
|
|
11
|
+
---
|
|
12
|
+
|
|
13
|
+
<deferred_reading>
|
|
14
|
+
- [Chain catalog](references/ew-orchestrate.md) — initial intent classification, cold-start fallback, and step thresholds.
|
|
15
|
+
- [Planning and chain creation](references/planning.md) — Session chain creation, readonly status short-circuit, and decomposition.
|
|
16
|
+
- [Automatic & goal policy](references/auto-policy.md) — `--auto` and `--goal` long-chain stage mapping, decision gates, and retry guards.
|
|
17
|
+
- [Goal amendment](references/goal.md) — `--amend` pending-tail change protocol.
|
|
18
|
+
- [Run loop and recovery](references/orchestrator-run-loop.md) — fenced `evolve` CLI dispatch, MCP/CLI reads, and recovery.
|
|
19
|
+
- [Companion route](references/companion-route.md) — bounded `ew-companion` fast path.
|
|
20
|
+
- Steps (loaded when dispatched): [ew-companion](steps/ew-companion/SKILL.md), [ew-init](steps/ew-init/SKILL.md), [ew-brainstorm](steps/ew-brainstorm/SKILL.md), [ew-grill](steps/ew-grill/SKILL.md), [ew-blueprint](steps/ew-blueprint/SKILL.md), [ew-roadmap](steps/ew-roadmap/SKILL.md), [ew-analyze](steps/ew-analyze/SKILL.md), [ew-plan](steps/ew-plan/SKILL.md), [ew-execute](steps/ew-execute/SKILL.md), [ew-verify](steps/ew-verify/SKILL.md), [ew-test](steps/ew-test/SKILL.md), [ew-auto-test](steps/ew-auto-test/SKILL.md), [ew-review](steps/ew-review/SKILL.md), [ew-debug](steps/ew-debug/SKILL.md), [ew-retrospective](steps/ew-retrospective/SKILL.md).
|
|
21
|
+
</deferred_reading>
|
|
22
|
+
|
|
23
|
+
<purpose>
|
|
24
|
+
Route a user intent to the lightest sufficient execution path. For durable multi-step or verifiable edit work, open one canonical topic Session (`evolve session open`) and drive it through the shared Run loop (`orchestrator-run-loop.md`). Standalone knowledge governance, closeout harvesting, Wiki publication, and legacy migration route to `ew-knowledge` (`evolve workflows show knowledge`).
|
|
25
|
+
</purpose>
|
|
26
|
+
|
|
27
|
+
## Routing Boundaries
|
|
28
|
+
|
|
29
|
+
<goal_long_chain>
|
|
30
|
+
`--goal <goal>` selects long-chain mode. Read `references/auto-policy.md` (and `references/goal.md` when `--amend` is present) to derive `boundary_contract` and observable `goals` persisted on `evolve session open` (`--boundary-contract`, `--goals`, `--goal-mode`, `--auto`), binding `post-goal-audit` before `session complete`. Child steps under `steps/` remain steps of this Session rather than standalone Skill invocations.
|
|
31
|
+
</goal_long_chain>
|
|
32
|
+
|
|
33
|
+
<companion_route>
|
|
34
|
+
Any bounded, mechanically clear task that **modifies workspace files or runs state-changing verification** with a single focus and no typed handoff uses `references/companion-route.md` (`ew-companion` on the canonical Session/Run lifecycle), escalating to `ew-analyze`/`ew-plan`/`ew-execute`/`ew-verify`/`ew-review` if scope expands or self-check fails. Pure read-only Q&A or status/CLI queries exit via `END` without opening a Session.
|
|
35
|
+
</companion_route>
|
|
36
|
+
|
|
37
|
+
## Public Flags & Host Mapping
|
|
38
|
+
|
|
39
|
+
- `-y` — auto-confirm low-risk classification and proposals; NEVER bypasses high risk, confidence < 60, ambiguity requiring user input, failed gates, or drift escalation (and NEVER authorizes Wiki publication).
|
|
40
|
+
- `-c` — continue the unique live compatible Session (ask if 0 or >1 match).
|
|
41
|
+
- `--resume <session-id>` — resume exact Session via `evolve session status` / `evolve run brief`.
|
|
42
|
+
- `--auto` — sets `policy.auto_mode` (`continuation.authority = automatic`) with bounded retries (`--retry-max`) and recovery policy (`auto-policy.md`).
|
|
43
|
+
- `--goal <goal>` — durable outcome-driven chain (`--goal-mode`, `auto-policy.md`).
|
|
44
|
+
- `--amend` — amend live Session goal (`references/goal.md`, appends `CHG-NNN`).
|
|
45
|
+
- **Host capabilities**: map subagent/parallel steps to the host's native tools (`invoke_subagent` / `swarm` / `run_workflow` in Antigravity, joining or cancelling all spawned subagents; `spawn_agent` / `wait_agent` in Codex), user prompts to `ask_question` / `request_user_input`, web search to `search_web`, and browser acceptance to `browser` subagent / Playwright / Chrome DevTools.
|
|
46
|
+
|
|
47
|
+
<invariants>
|
|
48
|
+
1. **One chain** — one canonical Session/Run protocol; no executor-specific Session types.
|
|
49
|
+
2. **Session before execution** — `evolve session open` precedes allocating any step Run (except read-only `END` queries or pre-Git bootstrap).
|
|
50
|
+
3. **Creator owns decomposition** — Evolve persists `boundary_contract` and outcome `goals` on the Session; downstream steps consume without overwriting.
|
|
51
|
+
4. **Runtime owns mutation** — never edit SQLite/protocol state directly or bypass fenced CLI/MCP commands.
|
|
52
|
+
5. **Coordinator proposal & gate discipline** — chain updates follow Run `report.md` `next` (`chain-proposal/1.0`, validated at Run completion) and fenced `evolve session chain insert|replace|skip` + `evolve run decide`. Decision-gate thresholds (`CONFIDENCE_SCORE < 60`, `REGROUND_HALT`) are enforced by the coordinator alongside Runtime `--confidence` / `--target-step` validation.
|
|
53
|
+
6. **Verdict advances** — advance execution steps only via fenced `evolve run complete ... --verdict done|done_with_concerns`, and decision steps via fenced `evolve run decide` (exact CLI syntax in `orchestrator-run-loop.md`).
|
|
54
|
+
7. **Historical similarity is read-only** — never selects a Session or binds outputs.
|
|
55
|
+
8. **Auto is bounded** — `-y` never skips high risk, low confidence, ambiguity, failed gates, or drift halts.
|
|
56
|
+
9. **Running means continue** — when `continuation.authority` is `automatic`, execute the next action and re-read the receipt in the same turn without ending on soft warnings.
|
|
57
|
+
</invariants>
|
|
58
|
+
|
|
59
|
+
<state_machine>
|
|
60
|
+
```text
|
|
61
|
+
S_PARSE:
|
|
62
|
+
-> S_AMEND WHEN --amend (follow references/goal.md)
|
|
63
|
+
-> S_CONTINUE WHEN --resume <id> OR -c (resolve live Session; stuck/blocked Run -> S_RECOVER)
|
|
64
|
+
-> S_CLASSIFY WHEN intent present (follow references/ew-orchestrate.md + planning.md)
|
|
65
|
+
-> S_FALLBACK OTHERWISE (ask for intent / disambiguation)
|
|
66
|
+
|
|
67
|
+
S_CLASSIFY:
|
|
68
|
+
-> S_RUN_LOOP WHEN existing compatible open Session found (or `status` read-only short-circuit)
|
|
69
|
+
-> END WHEN pure read-only Q&A or info lookup modifying no files
|
|
70
|
+
-> S_COMPANION WHEN single-focus change/check needs no typed handoff or decision gate (references/companion-route.md)
|
|
71
|
+
-> S_DECOMPOSE -> S_CREATE WHEN multi-step/broad (>=3 modules or cross-package or >=2 open scope/constraint/DoD questions)
|
|
72
|
+
-> S_CREATE WHEN narrow/single-step chain needing typed artifact/gate
|
|
73
|
+
-> S_FALLBACK WHEN confidence < 60
|
|
74
|
+
|
|
75
|
+
S_CREATE -> S_RUN_LOOP WHEN -y AND risk != high AND confidence >= 60 (else S_CONFIRM)
|
|
76
|
+
S_CONFIRM -> S_RUN_LOOP (confirmed) | S_CLASSIFY (revised) | END (cancelled)
|
|
77
|
+
S_COMPANION -> END (verified) | S_CLASSIFY (scope expands / self-check fails)
|
|
78
|
+
```
|
|
79
|
+
</state_machine>
|
|
80
|
+
|
|
81
|
+
<task_tracking>
|
|
82
|
+
Keep any host UI plan mirrored (never authoritative over SQLite Session state): initialize steps after `session open`, mark `in_progress` on `run next`, `completed` on `run complete`, and record failure reason on `run transition failed`.
|
|
83
|
+
</task_tracking>
|
|
84
|
+
|
|
85
|
+
<success_criteria>
|
|
86
|
+
- Classification is auditable (`ew-orchestrate.md`) and Session exists before step execution.
|
|
87
|
+
- Steps execute via `run next`, seal via `run complete`, decide via `run decide`, and recover via `run check` / `run brief` / `run transition`.
|
|
88
|
+
- Chain amendments use fenced `session chain insert|replace|skip`; post-session closeout and Wiki governance hand off to `ew-knowledge`.
|
|
89
|
+
</success_criteria>
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
# Automatic & Goal Long-Chain Policy
|
|
2
|
+
|
|
3
|
+
本文件定义 `--auto` 与 `--goal` 闭环长链的 **阶段映射(Stage Mapping)**、**建链规则(Build Rules)** 与 **决策门评估(Decision Gates)**。具体 fenced CLI 语法见 [执行循环](orchestrator-run-loop.md),Goal 变更协议见 [goal.md](goal.md)。
|
|
4
|
+
|
|
5
|
+
## Execution Authority Invariants
|
|
6
|
+
|
|
7
|
+
1. 首次变更前通过 `evolve capabilities` 确认运行时能力,之后严格沿 `Evolve mutation receipt` 刷新 `orchestration_revision`(Run 目标操作另需 `run_revision`)。
|
|
8
|
+
2. 全程固定同一 `actor_id`(同时传给 `--participant` 与 `--actor`);每次重试同一请求复用原 `--request-id`,修订冲突先读 `evolve session status`。
|
|
9
|
+
3. 在 `session open` 时显式持久化 `--boundary-contract`、`--goals` 与 `--auto` / `--goal-mode` 策略(`Session.policy.auto_mode` 控制 `continuation.authority = "automatic"`);未设置 `--auto` 时需按 `S_CONFIRM` 与每步人工节点推进。
|
|
10
|
+
4. 禁止绕过 `evolve session` / `evolve run` 命令行直接修改状态;Run 封存后不可变,失败重试须通过 `evolve run transition ... failed`(触发 `--retry-max` 计数)后再经 `evolve run next` 派发。
|
|
11
|
+
|
|
12
|
+
## Stage Mapping
|
|
13
|
+
|
|
14
|
+
| Stage | Skill / 节点配置 | Decision after | 适用条件 |
|
|
15
|
+
| --- | --- | --- | --- |
|
|
16
|
+
| init | `ew-init "{intent}"` | — | 项目未初始化或需存量接入引导时 |
|
|
17
|
+
| grill | `ew-grill "{intent}"` | — | 需要压测假设或对齐术语时 |
|
|
18
|
+
| brainstorm | `ew-brainstorm "{intent}"` | — | 开放探索阶段 |
|
|
19
|
+
| blueprint | `ew-blueprint "{intent}"` | — | 需要正式规格文档包时 |
|
|
20
|
+
| roadmap | `ew-roadmap "{intent}"` | — | 多 Session 拆解证据 |
|
|
21
|
+
| analyze-macro | `ew-analyze "{intent}"` | `post-analyze-scope` | 宏分析路由门 |
|
|
22
|
+
| analyze | `ew-analyze --session {session}` | — | 分析阶段 |
|
|
23
|
+
| plan | `ew-plan --session {session}` | — | 规划阶段 |
|
|
24
|
+
| execute | `ew-execute --session {session}` | `post-execute` | 执行阶段 |
|
|
25
|
+
| verify | `ew-verify --session {session}` | — | 需要结构与约束覆盖验证时(前置 `plan` + `execute`) |
|
|
26
|
+
| test | `ew-test --session {session}` | — | 需要 UAT / `--frontend-verify` 验收时 |
|
|
27
|
+
| auto-test | `ew-auto-test --session {session}` | — | 需要分层自动化测试生成与收敛时 |
|
|
28
|
+
| review | `ew-review --session {session} [--tier quick]` | `post-review` | 审查阶段(quick 模式加 `--tier quick`) |
|
|
29
|
+
| debug | `ew-debug "{intent}"` | — | 链内出现失败需要根因诊断时 |
|
|
30
|
+
| retrospective | `ew-retrospective --session {session}` | — | 阶段收尾多视角复盘时 |
|
|
31
|
+
| goal-audit | `--decision-only` | `post-goal-audit` | 存在 `goals` 分解时 |
|
|
32
|
+
| session-complete | `--decision-only` | `post-execution` | 长链终端核验节点 |
|
|
33
|
+
| debug-escalate | `--decision-only` | `post-debug-escalate` | 调试升级阻断节点 |
|
|
34
|
+
|
|
35
|
+
> **说明**:`{session}` 与 `{intent}` 占位符由 Runtime 在 `evolve run next` 派发 `run.task.args` 时自动展开;`--decision-only` 节点仅需 `--step-id` 与 `--decision-ref`,不绑定 Skill 包。
|
|
36
|
+
|
|
37
|
+
## Build Rules(按顺序应用)
|
|
38
|
+
|
|
39
|
+
1. **Wiki 约束预检**: 建链前执行 `evolve context` 读取项目约束(旧知识目录通过 `evolve knowledge import` 预览并导入,禁止直接读写)。
|
|
40
|
+
2. **起点与过滤**: 从当前最新状态起步,跳过已有 sealed artifact 的阶段,并确认 `ew-verify` 等硬契约上游已满足。
|
|
41
|
+
3. **决策门、重试上限与审计插入**:
|
|
42
|
+
- 附带在可运行步骤上的门禁通过 `evolve session chain insert ... --decision-ref "<gate>" --retry-max 3` 绑定;独立核验节点使用 `--decision-only --decision-ref "<gate>" --step-id <id>`。
|
|
43
|
+
- 存在 `goals` 分解时:在末个产出阶段后插入 `--decision-only --decision-ref post-goal-audit`;每执行 `>= 3` 步插入 `--decision-only --decision-ref post-reground`。
|
|
44
|
+
- 链尾以 `--decision-only --decision-ref post-execution`(需 `run decide proceed`)收尾,再调用 `evolve session complete`。
|
|
45
|
+
4. **参数与契约校验**: 建链前用 `evolve skills validate <command>` 校验所有步骤(且新增/修改的 Skill 必须已提交进 Git `HEAD`)。
|
|
46
|
+
5. **`scope_verdict` 门控(宏分析起点)**: `large` 保留多模块分解并向 `ew-plan` 传 `--session {session}`;`unknown` 由 `post-analyze-scope` 决策或询问用户纠正(`-y` 不猜测)。
|
|
47
|
+
|
|
48
|
+
## Decision Gate 评估与回退规范
|
|
49
|
+
|
|
50
|
+
| 类型 | `decision_ref` | 评估动作 | 检查输入 |
|
|
51
|
+
| --- | --- | --- | --- |
|
|
52
|
+
| quality-gate | `post-execute` | 评估执行与自检 | `outputs/execution.json`, `outputs/self-check.json` |
|
|
53
|
+
| quality-gate | `post-review` | 评估审查结论 | `outputs/review.json` |
|
|
54
|
+
| goal-gate | `post-goal-audit` | 对照 `goals[].done_when` 核验未完成目标 | `Session.goals` + Run 证据 |
|
|
55
|
+
| scope-gate | `post-analyze-scope` | 判定范围路由 | `outputs/findings.json` (`scope_verdict`) |
|
|
56
|
+
| reground-gate | `post-reground` | 核验累积产出是否偏离 `intent` / `boundary_contract` | `Session.boundary_contract` + handoffs |
|
|
57
|
+
| structural | `post-execution` | 终态核验(全部 Run sealed + chain 终结) | Session 全量状态 |
|
|
58
|
+
| structural | `post-debug-escalate` | 始终 `escalate` 阻断推进 | — |
|
|
59
|
+
|
|
60
|
+
### Evaluator Verdict 与回退约定
|
|
61
|
+
|
|
62
|
+
- **`proceed` / `fix` / `escalate`**:决策评价包含 `CONFIDENCE_SCORE`(`0–100`);调用 `evolve run decide <gate> --verdict <verdict> --confidence <score> [--target-step <step-id>] --summary "<evidence>"`:
|
|
63
|
+
- Runtime 在 `auto_mode` 下遇到 `confidence < 60` 且无明确 `--evidence` 时会拒绝 `proceed`;
|
|
64
|
+
- 判定 `fix` 需要重跑上游执行/规划步骤时,**必须显式传入 `--target-step <step-id>`**(从 `--decision-only` 节点返回 `fix` 时为必填),Runtime 会把目标步骤至决策门间的步骤重开为 `pending`;若需新增修复步骤(如 `ew-debug` / `ew-plan --gaps`),先通过 `evolve session chain insert` 插链再判定 `proceed` 或重开步骤;
|
|
65
|
+
- `reground-gate` 判定严重漂移且置信度 `>= 60` 时,作为协调器强制停机策略(`REGROUND_HALT`,`-y` 不可跳过)立即传入 `--verdict escalate` 暂停并上报用户。
|
|
66
|
+
- **`post-execution`**:核验全部 Run 已 sealed 且无悬空门禁后,提交 `--verdict proceed`,再用最新 `orchestration_revision` 调用 `evolve session complete`。
|