.agents/skills/change-proposal/SKILL.md
Present proposed code changes visually before implementing. Use when the user says "show me options", "compare approaches", "what should we do", or when multiple approaches exist, changes span multiple files, or architecture decisions need before/after comparison.
npx skillsauth add epicenterhq/epicenter change-proposalInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
When proposing non-trivial changes, make your reasoning visible before acting. The user should see what will change, why, and what alternatives were considered—before a single file is edited.
Follow writing-voice for prose sections.
For trivial changes (typo fix, single-line edit, obvious bug), skip this and just do it.
Show what specific code will change. Use fenced diff blocks with file paths.
--- a/workspace.ts
+++ b/workspace.svelte.ts
@@ createWorkspaceState()
- let client = buildWorkspaceClient();
+ let client = $state(buildWorkspaceClient());
return {
get current() { return client; },
- async reset() {
- await client.clearLocalData();
- await client.dispose();
- client = buildWorkspaceClient();
+ async reset(options?: { key?: Uint8Array }) {
+ await client.dispose();
+ client = buildWorkspaceClient(options);
},
};
Rules:
Show how components relate before and after the change. Use the characters from progress-summary: ┌ ┐ └ ┘ ─ │ ├ ┤ ┬ ┴ ┼ ▼ ▲ ──→ ←──
Before:
auth ──signOut()──→ workspace.reset() ──→ internally rebuilds
│ (self-manages lifecycle)
├── clearLocalData()
├── dispose()
└── client = build()
After:
auth ──signOut()──→ workspace.current.dispose()
setWorkspaceClient(build())
│
workspace is a reactive slot ← auth owns lifecycle
When to use which diagram type:
When multiple approaches exist, present them as a table with clear trade-off dimensions.
A: Self-managed B: Slot + builder C: Auth owns state
─────────────── ───────────────── ──────────────────
Who holds $state? workspace workspace auth
Who decides wipe? workspace auth (explicit) auth (explicit)
Circular deps? same as today same as today WORSE
God module risk? workspace neither auth
Rules:
For non-trivial changes, present in this order:
| Change scope | What to show | | --- | --- | | 1 file | Just the diff, no diagram | | 2–5 files | Diff of the hardest file + one diagram showing relationships | | 5+ files | Full proposal: comparison table, diagrams, diffs for hardest 2–3 files | | Architecture decision | Comparison table mandatory, even if only 2 options | | Competing approaches | All three tools: diagram per approach, diff per approach, comparison table |
workspace.tscurrently self-manages its lifecycle. I'd split it: workspace becomes a reactive slot + builder, auth owns the lifecycle decisions.writes reads auth ──────────────────► workspace.svelte.ts ◄──── consumers builds, sets let client = $state() .current decides wipe set(newClient) via $effect--- a/workspace.ts (createWorkspaceState) +++ b/workspace.svelte.ts - let client = buildWorkspaceClient(); + let client = $state(buildWorkspaceClient());Trade-off: auth gains 10 lines of explicit lifecycle code, workspace loses its god-object methods. Net simpler because lifecycle decisions are visible at the call site.
Should I proceed with this, or keep workspace self-managed?
I'll refactor workspace.ts to use a slot pattern and move lifecycle management to auth.svelte.ts. This involves changing how the client is created and disposed, updating the state management to use $state, and modifying the reset function to accept an optional key parameter. The consumers will use $effect to automatically rebind when the workspace changes.
The bad version describes changes in prose. The good version shows them.
documentation
Yjs CRDT patterns, shared types (Y.Map, Y.Array, Y.Text), conflict resolution, and document storage. Use when the user mentions Yjs, Y.Doc, CRDTs, collaborative editing, or when handling shared types, implementing real-time sync, or optimizing document storage.
tools
Voice and tone rules for all written content—prose, UI text, tooltips, error messages. Use when the user says "fix the tone", "rewrite this", "sounds like AI", "sounds corporate", or when writing any user-facing text, landing pages, product copy, or open-source documentation.
tools
Workspace API patterns for defineTable, defineKv, versioning, migrations, data access (CRUD + observation), withActions, and extension ordering. Use when the user mentions workspace, defineTable, defineKv, createWorkspace, withActions, withExtension, defineQuery, defineMutation, connectWorkspace, or when defining schemas, reading/writing table data, observing changes, writing migrations, chaining extensions, or attaching actions to a workspace client.
documentation
Standard workflow for implementing features with specs and planning documents. Use when the user says "start a new feature", "how should I plan this", "what's the process", or when starting implementation, planning work, or working on any non-trivial task.