CtrlK
BlogDocsLog inGet started
Tessl Logo

the-trace-execution-path

Trace a behavior, event, or request path through the Stave codebase. Use when the request asks "where does this happen", "execution path", "call flow", "흐름 추적", "어디서 처리돼", or needs the exact producer -> bridge -> consumer chain.

68

Quality

83%

Does it follow best practices?

Impact

No eval scenarios have been run

SecuritybySnyk

Passed

No known issues

SKILL.md
Quality
Evals
Security

The Trace Execution Path

Trace forward and backward across boundaries.

Workflow

  1. Identify the user-facing trigger or event name.
  2. Find the producer.
  3. Cross the nearest contract boundary:
    • renderer → preload
    • preload → main IPC
    • IPC → provider runtime
    • provider event → Zod validation → replay → UI
  4. Confirm the consumer and any replay or persistence path.
  5. Check tests that mention the same type, event, or function.

Stave Contract Boundaries (common crossings)

BoundaryFiles to confirm
Renderer → preloadsrc/types/window-api.d.ts, electron/preload.ts
Preload → main IPCelectron/main/ipc/*.ts, strict Zod schemas in electron/main/ipc/schemas.ts
IPC → provider runtimeelectron/providers/claude-sdk-runtime.ts, electron/providers/codex-sdk-runtime.ts, electron/providers/adapter.factory.ts
Provider emit → normalizesrc/lib/providers/provider.types.ts (TS union) + src/lib/providers/schemas.ts (Zod union, strictly validated at parseNormalizedEvent)
Normalized event → UI statesrc/lib/session/provider-event-replay.ts, src/store/app.store.ts consumers, src/components/session/chat-panel-message-parts.tsx
Terminal IPCelectron/main/ipc/terminal.ts, electron/host-service/terminal-runtime.ts, src/components/layout/useTerminalSessionManager.ts

Stave-Specific Guidance

  • For provider-turn questions, start with docs/architecture/conversation-flow.md.
  • For provider output rendering, inspect src/lib/session/provider-event-replay.ts and the chat panel components.
  • When the trace crosses electron/host-service/, remember that async runtime functions (e.g. attachSession) must be awaited before being passed to respond()JSON.stringify(Promise) silently becomes {}.

Output

Return:

  • entrypoint
  • forward path (producer → consumer)
  • reverse path (consumer → producer)
  • contract files crossed
  • likely breakpoints or tests

Avoid

  • describing only one side of a boundary
  • stopping before checking the matching Zod schema or replay consumer
  • conflating TypeScript types with the strict Zod validation at parseNormalizedEvent
Repository
sendbird/stave
Last updated
Created

Is this your skill?

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.