Chore: remove serena MCP completely; gitea auto-push + test-count conventions

Serena dropped from .mcp.json + .serena/ untracked (unused in practice,
flaky on Unity per CLAUDE.md's own caveat); memory stack is now three
layers. Standing auths recorded in the skill: docs auto-commit + auto-push
main->gitea (origin stays ask-first).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
2026-07-07 22:00:33 -07:00
parent a4b6bb9dfe
commit 7b64c1caa3
6 changed files with 33 additions and 24 deletions
+6 -6
View File
@@ -15,7 +15,7 @@ The spine: **size by blast-radius → ground → (design-review) → plan-gate
2. **Plan-approval gate ★.** Phases up to approval are read-only. Code is written only after the operator approves and you call **`ExitPlanMode`**. Self-policed, not harness-enforced.
3. **Doc + memory bookend ★.** Scan the vault/memory at start; update it at end (incl. CLAUDE.md self-maintenance). Protocol → `CLAUDE.md` Memory section + [`references/memory-protocol.md`](references/memory-protocol.md).
4. **DOTS-correct.** ECS conventions per `CLAUDE.md` + [`references/dots-conventions.md`](references/dots-conventions.md). Any violation found in review is blocking.
5. **Code commits gated; docs commits standing.** Code: offer + propose grouping in the final report; commit only on explicit "commit". **Docs-only changes (vault / CLAUDE.md / skill references) auto-commit at session end** in a logical `Docs:` group — operator standing authorization 2026-07-07. **Never push** unless asked.
5. **Code commits gated; docs commits standing.** Code: offer + propose grouping in the final report; commit only on explicit "commit". **Docs-only changes (vault / CLAUDE.md / skill references) auto-commit at session end** in a logical `Docs:` group — operator standing authorization 2026-07-07. **Push: auto-push `main` to `gitea` after session-end commits** (standing auth 2026-07-07); **`origin` (GitHub) only when asked.**
6. **Operator gates.** Present-forks-don't-auto-decide · no time/effort/deadline estimates · never-silently-defer · tuning-defaults autonomy. See *Operator gates* below.
7. **Path-portable.** Never write machine-specific absolute paths (`/Users/…`, `C:\…`) into the skill, code, docs, or `.mcp.json` — use repo-relative / `${CLAUDE_PROJECT_DIR}`.
@@ -44,13 +44,13 @@ Pick the track from the *surface touched*, never from a minutes estimate.
### Phase 0 — Pre-flight
1. **Foundation check.** `com.unity.entities`/`com.unity.netcode` in `Packages/packages-lock.json`? If **absent**, STOP — point to the one-time setup task (`Docs/dots-setup-task.md`). Never install/scaffold inline.
2. **Unity ready.** `mcpforunity://editor/state``ready_for_tools`. Not ready / no instance → surface, ask operator to focus Unity. Multiple editors → `mcpforunity://instances` + `set_active_instance`. (An unfocused editor throttles to near-idle and breaks Burst recompiles — ask for focus on heavy build/test/Burst sessions.)
3. **Memory stack.** Probe `basic-memory` + `serena`; on failure fall back (obsidian-cli + Glob/Grep) and continue.
3. **Memory stack.** Probe `basic-memory`; on failure fall back (obsidian-cli + Glob/Grep) and continue.
4. **Intake gate.** Unclear scope/surface/output → bundle 24 ambiguities into one `AskUserQuestion`. Specific prompt → skip.
### Phase 1 — Ground (read-only, plan mode)
Declare plan mode: read-only tools only (`Read/Glob/Grep`, MCP resource reads, `unity_reflect`, `unity_docs`, `read_console`, ctx7/find-docs, obsidian-cli reads, `basic-memory`, serena reads). No writes.
Declare plan mode: read-only tools only (`Read/Glob/Grep`, MCP resource reads, `unity_reflect`, `unity_docs`, `read_console`, ctx7/find-docs, obsidian-cli reads, `basic-memory`). No writes.
Run the **Documentation-Protocol scan** (`CLAUDE.md` → vault MoC + latest session log → open DRs/roadmap → `basic-memory` recall on the goal's nouns → native `MEMORY.md`), then ground the work along three lenses: **code/asset graph** (serena `find_symbol`/refs, else Glob/Grep on `Assets/_Project/**/*.cs` + `*.asmdef`; `manage_scene get_hierarchy`; `unity_reflect` for goal types) · **knowledge state** (vault + `basic-memory`; quote locked decisions that constrain the goal) · **live state** (`editor/state`, `read_console` baseline, installed Entities/Netcode versions for ctx7 pinning). For Feature scope, fan this out read-only via the *Ground fan-out* Workflow pattern; for Small, do it inline.
Run the **Documentation-Protocol scan** (`CLAUDE.md` → vault MoC + latest session log → open DRs/roadmap → `basic-memory` recall on the goal's nouns → native `MEMORY.md`), then ground the work along three lenses: **code/asset graph** (Glob/Grep on `Assets/_Project/**/*.cs` + `*.asmdef`; `manage_scene get_hierarchy`; `unity_reflect` for goal types) · **knowledge state** (vault + `basic-memory`; quote locked decisions that constrain the goal) · **live state** (`editor/state`, `read_console` baseline, installed Entities/Netcode versions for ctx7 pinning). For Feature scope, fan this out read-only via the *Ground fan-out* Workflow pattern; for Small, do it inline.
Synthesize a **≤400-word Project Brief**; discard raw dumps. If the goal contradicts a locked vault/`CLAUDE.md` decision, halt and surface.
@@ -74,7 +74,7 @@ The single stateful editor + domain-reload ordering make parallel writes unsafe
### Phase 6 — Verify ladder (definition of done — show evidence, not "done")
NetCodeTestWorld is `internal` and unused here — do NOT prescribe it. Live-driving rules + the server-inject harness → [`references/validation-harness.md`](references/validation-harness.md).
- **L1** — `read_console(types=["error","warning","exception"], include_stacktrace=True)` clean vs the Phase-1 baseline. Burst/source-gen failures surface here, not in a plain build — any new one is a finding.
- **L2** — EditMode tests: plain-Entities `new World → register in SimulationSystemGroup → SortSystems → Update → assert` (`run_tests mode=EditMode`). Extract pure logic to a `*Math.cs` helper and unit-test it (cover swept hit-detection with a tunnelling regression). **Plus one live Play netcode smoke**`execute_code` boot, step ticks, assert **server == client** for the replicated surface (identify worlds by `world.Name == "ServerWorld"/"ClientWorld"`).
- **L2** — EditMode tests: plain-Entities `new World → register in SimulationSystemGroup → SortSystems → Update → assert` (`run_tests mode=EditMode`). In DURABLE docs (DRs/logs/memory) write "suite green (N at the time)" — never stamp absolute counts as standing facts; they drift. Extract pure logic to a `*Math.cs` helper and unit-test it (cover swept hit-detection with a tunnelling regression). **Plus one live Play netcode smoke**`execute_code` boot, step ticks, assert **server == client** for the replicated surface (identify worlds by `world.Name == "ServerWorld"/"ClientWorld"`).
- **L3** (visual/asset work) — screenshot via `execute_code` `ScreenCapture` → Read PNG, **and verify asset *values*** (`shader.GetPropertyType`-guard before `GetColor`/`GetFloat`) — a dark/stylized render masks material bugs.
Loop ≤3 fix iterations per finding; if iteration 3 still fails, halt and surface "I can't resolve X without a decision."
@@ -94,7 +94,7 @@ Per `CLAUDE.md` Memory section + [`references/memory-protocol.md`](references/me
**Reviews**: pre-code <result> · post-impl <result>.
**Next step**: <one concrete next action from the log's Next-session intent>.
```
Then **commit the docs group directly** (standing authorization) and **offer code commits**; code commits only on explicit approval. **Review first** (`git status` + `git diff --stat`); **stage explicit paths — never `git add -A`** (excludes `Library/Temp/obj/Logs/UserSettings`, `.csproj`/`.sln`, scratch screenshots/exports); keep each asset **with its `.meta`** in one commit; one commit per concern; match the repo's message style + the Co-Authored-By trailer; **never push**. Don't auto-loop into a fresh session.
Then **commit the docs group directly** and **push to gitea** (both standing authorizations); **offer code commits** — those only on explicit approval. Report the origin-unpushed count. **Review first** (`git status` + `git diff --stat`); **stage explicit paths — never `git add -A`** (excludes `Library/Temp/obj/Logs/UserSettings`, `.csproj`/`.sln`, scratch screenshots/exports); keep each asset **with its `.meta`** in one commit; one commit per concern; match the repo's message style + the Co-Authored-By trailer; **never push**. Don't auto-loop into a fresh session.
## Workflow orchestration (the parallelism primitive)
@@ -1,6 +1,6 @@
# Memory & Documentation Protocol
How `/dots-dev` reads and writes knowledge. **`CLAUDE.md`'s "Memory — four layers" section is authoritative** for the layer definitions and the which-tool-when routing (in-repo vault · `basic-memory` · `serena` · native `memory/`) — this file does not re-table them; it carries the **session bookends** and the **fallback chain**.
How `/dots-dev` reads and writes knowledge. **`CLAUDE.md`'s "Memory — three layers" section is authoritative** for the layer definitions and the which-tool-when routing (in-repo vault · `basic-memory` · native `memory/`) — this file does not re-table them; it carries the **session bookends** and the **fallback chain**. (serena removed 2026-07-07 — unused + flaky on Unity; C# nav = `Glob`/`Grep`.)
**Cross-machine rule:** anything that must be true on both the Mac and Windows machines goes in the **vault** (`Docs/Vault/`) or **`CLAUDE.md`** (both committed). Native `memory/` is machine-local convenience — never the sole home of a decision or design fact.
@@ -25,8 +25,7 @@ If the operator says "skip the protocol," still write a one-line stub session lo
- **No obsidian-cli configured** → direct `Read`/`Write` on `Docs/Vault/**` (it's plain markdown; Obsidian/basic-memory pick up changes on next index). This is the operative path on a fresh machine.
- **basic-memory down** → obsidian-cli search + `Grep` over the vault.
- **serena C# unavailable / stalls on the Unity solution** → `Glob`/`Grep` (or `claude-context`/LanceDB if it was added as the documented fallback).
## Setup pointer
The vault scaffold, the `basic-memory`/`serena` `.mcp.json` entries (using `${CLAUDE_PROJECT_DIR}`), and `CLAUDE.md` are created by the **one-time project setup task** (`Docs/dots-setup-task.md`), not by this skill. If this skill runs and the vault or memory MCPs are missing, it notes the gap and points to that setup task.
The vault scaffold, the `basic-memory` `.mcp.json` entry, and `CLAUDE.md` are created by the **one-time project setup task** (`Docs/dots-setup-task.md`), not by this skill. If this skill runs and the vault or memory MCPs are missing, it notes the gap and points to that setup task.