256
     Aˆ¾‘äÇò 8à_Ž”!Yþèƒh¹ç¿ä     A0
    CˆÞ�þ\}µœp,ÇlÇ+-‹ùèƒ�7çæ¿ä •   C/**
 * Locating the built browser viewer on disk.
 *
 * The viewer is a static Vite build that ships inside the package, exactly like
 * `schema.sql` and the tree-sitter grammars: emitted into `dist/viewer/`,
 * copied wholesale by `scripts/build-bundle.sh`, packed by
 * `scripts/pack-npm.sh`. So it is found the same way `db/index.ts` finds
 * `schema.sql` â€” relative to `__dirname`, never to `process.cwd()`, which is
 * whatever directory the user happened to be standing in.
 *
 * `dist/viewer`, NOT `dist/ui`: `src/ui/` is the engine's TERMINAL ui and tsc
 * already compiles it to `dist/ui/`. See `ui/vite.config.ts`.
 */
import { VIEWER_PATH_ENV } from './constants';
export { VIEWER_PATH_ENV };
/**
 * The viewer build is missing â€” the package was assembled without it, or the
 * repo was built with `tsc` alone. Carries user-facing remediation rather than
 * a stack trace, because the CLI prints `.message` verbatim.
 */
export declare class ViewerMissingError extends Error {
    constructor(searched: readonly string[]);
}
/**
 * Candidate locations for the viewer, most-specific first.
 *
 * 1. The `CODEGRAPH_VIEWER_PATH` override.
 * 2. `<__dirname>/../viewer` â€” the shipped layout (`dist/ui-server/` â†’
 *    `dist/viewer/`).
 * 3. `<__dirname>/../../dist/viewer` â€” running the TypeScript straight out of
 *    `src/` (vitest, tsx), where `__dirname` is `src/ui-server/`.
 */
export declare function viewerDirCandidates(): string[];
/**
 * Resolve the directory holding the built viewer.
 *
 * @throws {ViewerMissingError} when no candidate contains an `index.html`.
 */
export declare function resolveViewerDir(): string;
//# sourceMappingURL=assets.d.ts.map  %  Eˆé“þC qÀ³m´é_+ËMìÕÿ?èãâç294á¿ä &   E‹      m�AjÃ0E÷:Å�n/ì—vYh!„ö ª4�•Ø#3’BCÈÝûÛ‹B�À#ý÷g¾ÔT•©è)HfÛ£þÝz•�Íìé½‰°¬ÐÑóî{O©‹¥÷$1Ó'SIÀ}€1÷—z2:Ø )ñ5*¹ÎÊ¥Íhq¡®MÕþ£fú*ârˆBNó÷|D;ö;�CH¼ÆaŠ²¡«!|.JÊ4Nµ4SµÞ]¼½³M�Ï,0ÄŒ_ÀEØ'êÙž‚¨ú	Yy§^H”îmæa5Çuëõ†ÚGºÒm²¨)Û\­t¾Àê/0E0“¨œ‹ÊÂlÍÍ4Í¥XÔñ›GÄûØ¿¶ÿ¾L}Lõ`Gó?5ôÐ       GˆÞ�þBä�¬ã�f8Ûf9Yl_Ïèƒmæ›çæ¿ä Õ   G/**
 * Query pool â€” runs CPU-heavy read-tool calls on a pool of worker threads so
 * the shared daemon's main event loop stays free for the MCP transport.
 *
 * Why this exists: see {@link ./query-worker}. One daemon, one event loop, one
 * synchronous SQLite connection serializes every concurrent `codegraph_explore`
 * AND starves the transport (a 10-way wave delivered 0 transport heartbeats in
 * 25s â€” responses can't flush until the whole batch drains, so clients time
 * out). Spreading the dispatch across worker threads (each its own WAL read
 * connection) restores true multi-core parallelism and an idle main loop.
 *
 * Properties:
 *   - lazy growth: one warm worker on construct, grows to `size` on demand, so a
 *     single-agent session pays for one connection and a 10-subagent burst grows
 *     to the core budget.
 *   - crash recovery: a dead worker is respawned and its in-flight call retried
 *     once; a poison call that keeps crashing fails gracefully (never wedges the
 *     pool). A crash budget trips a circuit breaker (`healthy` â†’ false) so the
 *     caller falls back to in-process dispatch instead of thrashing respawns.
 *   - graceful backstop: a call that can't be served within `softTimeoutMs`
 *     resolves with SUCCESS-shaped "busy, retry" guidance â€” never `isError`, so
 *     a momentary overload can't teach the agent to abandon codegraph â€” instead
 *     of hanging past the client's hard timeout.
 */
import type { ToolResult } from './tools';
/**
 * Minimal worker surface the pool drives â€” satisfied by a real `worker_threads`
 * Worker. Abstracted so tests can inject a fake worker and exercise the pool's
 * queue / growth / crash-recovery / backstop logic without spawning threads or
 * needing a built `dist/`.
 */
export interface PoolWorker {
    postMessage(msg: unknown): void;
    terminate(): Promise<number> | void;
    on(event: '