/** * A6 renderers — per-harness SessionStart / SessionEnd hook scripts. * * These are the artifacts that WRITE the agent-mediation marker file the server * reads (`telemetry/agent-marker.ts`). They honor that contract exactly: * - one file per session at `~/.skillsmith/agent-markers/.json` * (override via `SKILLSMITH_AGENT_MARKER_DIR`, same knob the server reads); * - atomic write (temp + rename), never a read-modify-write of a shared file; * - required keys `session_id` (non-empty) + `started_at` (epoch-ms), snake_case; * - `agent_session` true, `nudge_origin`/`trigger_id` set by the capped nudge; * - SessionEnd deletes the session's own file (the server's 12h TTL only * backstops a crash). * * Constraints: self-contained POSIX sh, no dependency on the skillsmith CLI (or * any project binary) being on PATH — `jq` is used when present and degraded to * a `sed` extraction otherwise. Every path exits 0: a hook must never fail the * user's session. The session id is sanitized to `[A-Za-z0-9._-]` so it is safe * as both a JSON value and a filename with zero escaping. * * Hooks are generated only for harnesses with a real SessionStart shell hook * ({@link HOOK_HARNESSES}); Hermes has none (spike verified absent) and Windsurf * has no hook system. */ import type { HarnessId } from './types.js'; /** Render the SessionStart hook for a harness (writes the marker + capped nudge). */ export declare function renderSessionStartHook(harness: HarnessId): string; /** Render the SessionEnd hook for a harness (deletes this session's marker). */ export declare function renderSessionEndHook(harness: HarnessId): string; //# sourceMappingURL=hooks.d.ts.map