CI / build (push) Has been cancelled
7 memory files covering: - audit-bug-patterns: recurring status.py bug patterns - vram-model-matching: three-tier model prefix matching - dashboard-security: .state priority, CORS removal, register-guards - state-machine-workflow: legal transitions and approval gates - testing-conventions: pytest patterns and helpers - audit-process: report conventions and batch processing - framework-architecture: enforcement layers and key files
1.3 KiB
1.3 KiB
Framework architecture — key files and enforcement layers
Three enforcement layers (in order of strength)
- Harness pre-edit hook (
--can-edit) — blocks edits before they happen. opencode plugin atplugins/automaton-guard/. - Git pre-commit hook (
scripts/git-hooks/pre-commit) — blocks commits when no task in edit-allowed phase. Works for ALL harnesses. - Prompt-based rules (ALLOWED/FORBIDDEN sections) — advisory only.
Key files
scripts/status.py(~1430 lines) — core enforcement: phase transitions, approvals, can-edit, scope-check, audit, claim/releasescripts/vram_detect.py(~700 lines) — VRAM detection and model context lookupautomaton/dashboard/core/task.py— dashboard state inference (.statefirst, artifacts fallback)automaton/dashboard/ui/app.py— HTTP server with security headers
NON_ARTIFACT_FILES
Files that should NOT be treated as phase artifacts:
.state, .state.tmp, .state.lock, .state.approvals, .state.implementer, .state.lastedit, VRAM_CONFIG.md, PARENT_SPEC.md, REVIEW.md
Stale-task mechanism
.state.lastedit file touched by --can-edit on ALLOWED. Falls back to .state mtime if .state.lastedit doesn't exist. 30-minute threshold. --touch resets the timer.