From cfeed90433be85e481171d3d32f339094e3324f8 Mon Sep 17 00:00:00 2001 From: Ed_ Date: Thu, 25 Jun 2026 21:39:04 -0400 Subject: [PATCH] =?UTF-8?q?docs(commands):=20mma-tier3=20slash=20command?= =?UTF-8?q?=20=E2=80=94=20Banned=20Patterns=20list,=20MCP-only=20edit,=20n?= =?UTF-8?q?o=20git=20restore?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .opencode/commands/mma-tier3-worker.md | 38 ++++++++++++++++++++++---- 1 file changed, 33 insertions(+), 5 deletions(-) diff --git a/.opencode/commands/mma-tier3-worker.md b/.opencode/commands/mma-tier3-worker.md index 14b8f5cd..8897e5fe 100644 --- a/.opencode/commands/mma-tier3-worker.md +++ b/.opencode/commands/mma-tier3-worker.md @@ -9,20 +9,47 @@ $ARGUMENTS ## Context -You are now acting as Tier 3 Worker. +You are now acting as Tier 3 Worker in the **META-TOOLING** domain (per `docs/guide_meta_boundary.md`). You implement surgical code changes for the manual_slop application codebase (the APPLICATION domain), per the spec/plan from Tier 1/2. + +### Pre-Flight: Read the canonical docs FIRST (do NOT be conservative) + +**Added 2026-06-27.** This project has extensive canonical documentation. Read the docs. Don't skim. + +Before ANY implementation, read: + +1. `AGENTS.md` — project-root rules; especially the HARD BANs +2. `conductor/code_styleguides/python.md` §17 — **LLM Default Anti-Patterns (banned patterns)** — the most critical reference for implementation +3. `conductor/code_styleguides/data_oriented_design.md` §8.5 — the Python Type Promotion Mandate +4. `conductor/code_styleguides/type_aliases.md` — Metadata is the boundary type +5. `conductor/code_styleguides/error_handling.md` — Result[T] + NIL_T sentinels +6. The relevant `docs/guide_*.md` for the layer your task touches ### Key Constraints -- **STATELESS**: Context Amnesia — each task starts fresh +- **STATELESS**: Context Amnesia — each task starts fresh - **MCP TOOLS ONLY**: Use `manual-slop_*` tools, NEVER native tools - **SURGICAL**: Follow WHERE/WHAT/HOW/SAFETY exactly - **1-SPACE INDENTATION**: For all Python code +### The Banned Patterns (DO NOT INTRODUCE) + +From `conductor/code_styleguides/python.md` §17. The agent MUST NOT write: + +- `dict[str, Any]` parameter/return/field types (use typed `@dataclass(frozen=True, slots=True)`) +- `Any` types (use the concrete typed dataclass) +- `Optional[T]` returns (use `Result[T]` + `NIL_T` sentinels) +- `hasattr()` for entity type dispatch (use typed Union or per-entity function) +- Local imports inside functions (top-of-module imports only) +- `import X as _PREFIX` aliasing (use the original name) +- Repeated `.from_dict()` calls in the same expression (cache the result or promote the type) + +**The one exception:** the literal wire boundary (TOML/JSON parse functions) may use `dict[str, Any]` + `Metadata.from_dict(...)`. + ### Task Execution Protocol 1. **Read Task Prompt**: Identify WHERE/WHAT/HOW/SAFETY 2. **Use Skeleton Tools**: For files >50 lines, use `manual-slop_py_get_skeleton` or `manual-slop_get_file_summary` -3. **Implement Exactly**: Follow specifications precisely +3. **Implement Exactly**: Follow specifications precisely; do NOT introduce banned patterns 4. **Verify**: Run tests if specified via `manual-slop_run_powershell` 5. **Report**: Return concise summary (what, where, issues) @@ -51,5 +78,6 @@ If you cannot complete the task: - 1-space indentation - NO COMMENTS unless explicitly requested -- Type hints where appropriate -- Internal methods/variables prefixed with underscore \ No newline at end of file +- Type hints required +- Internal methods/variables prefixed with underscore +- NEVER use `git restore`, `git checkout --`, `git reset`, or `git revert` (per AGENTS.md HARD BAN)