Audit Stave multi-file contracts before or during changes. Use when a task touches provider runtime options, IPC payloads, window.api, schemas, NormalizedProviderEvent, replay payloads, or asks for a contract or sync checklist. Trigger on phrases like "ipc", "schema", "runtimeOptions", "window.api", "provider event", "계약", "스키마", "동기화 체크".
76
96%
Does it follow best practices?
Impact
—
No eval scenarios have been run
Passed
No known issues
Treat schema changes as end-to-end runtime changes, not local type edits.
When the task changes a provider or IPC payload, inspect this full chain:
electron/providers/types.tssrc/lib/providers/provider.types.tssrc/lib/providers/schemas.ts — Zod discriminated union for NormalizedProviderEventsrc/types/window-api.d.tselectron/preload.tselectron/main/ipc/schemas.tsDo not assume TypeScript is enough. electron/main/ipc/schemas.ts and src/lib/providers/schemas.ts both use strict Zod — they silently reject extra fields and silently drop unknown event variants at parseNormalizedEvent.
When adding, renaming, or reshaping a normalized event:
src/lib/providers/provider.types.tssrc/lib/providers/schemas.ts (same commit — TS and Zod diverge silently)electron/providers/src/lib/session/provider-event-replay.tsSchema variable names (e.g. StaveExecutionProcessingEventSchema) must mirror the TypeScript literal for easy auditing.
electron/host-service.ts dispatches IPC requests. Async runtime functions (e.g. attachSession, createSession) must be awaited before passing their result to respond(). A bare respond(fn(...)) when fn returns a Promise becomes JSON.stringify(Promise) === "{}" — the renderer sees an empty object with no error.
Changes to executable lookup, runtime env, CLI launch env, or tooling status probes must respect the env-builder contract shared across both adapters. Required check files:
electron/providers/executable-path.tselectron/providers/cli-path-env.tselectron/providers/claude-sdk-runtime.tselectron/providers/codex-sdk-runtime.tselectron/providers/codex-app-server-runtime.tselectron/providers/runtime.tselectron/main/utils/tooling-status.tsA passing claude auth status or codex --version probe is not sufficient — verify the actual turn-start path too. See the-provider-runtime-symmetry for the full symmetry protocol.
electron/main/ipc/schemas.ts.parseNormalizedEvent.respond() without await.If the behavior is meant to be provider-agnostic, inspect both Claude and Codex adapters. Invoke the-provider-runtime-symmetry when the change is adapter-local but the behavior should be shared.
bun run typecheck after contract changesReturn:
e275ad5
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.