@agentvault/grok-bridge 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,42 @@
1
+ export interface GrokSpawnOpts {
2
+ /** Defaults to "grok" — resolved from PATH at spawn time, like the launcher
3
+ * script already does for node, so a version-manager switch cannot strand it. */
4
+ grokPath?: string;
5
+ /** Directory holding .claude-plugin/plugin.json + .mcp.json for room__say. */
6
+ pluginDir: string;
7
+ /** The agent's fenced HOME. GROK_HOME is derived as <fenceHome>/.grok. */
8
+ fenceHome: string;
9
+ /** cwd for the agent. MUST NOT be the AV MLS data dir. */
10
+ workspaceDir: string;
11
+ model?: string;
12
+ /** Preferred auth for a daemon: no login state to provision inside the fence
13
+ * and no expiry to re-authenticate. */
14
+ apiKey?: string;
15
+ }
16
+ export interface GrokSpawn {
17
+ command: string;
18
+ args: string[];
19
+ env: NodeJS.ProcessEnv;
20
+ cwd: string;
21
+ }
22
+ export declare function grokSpawnArgs(opts: GrokSpawnOpts): GrokSpawn;
23
+ /**
24
+ * Turn a ChildProcess 'error' into a sentence an operator can act on.
25
+ *
26
+ * Separated from index.ts so it is TESTABLE: index.ts runs main() at module
27
+ * scope, so anything defined there cannot be imported by a test without
28
+ * spawning a real agent. The message text is the whole deliverable here — it
29
+ * must name WHICH binary was missing, WHERE the process looked, and WHAT to
30
+ * set — so it needs to live somewhere assertions can reach.
31
+ */
32
+ export declare function describeSpawnFailure(err: NodeJS.ErrnoException, spawn: GrokSpawn): string;
33
+ /**
34
+ * Child 'exit' after a successful start is fatal UNLESS we are already
35
+ * shutting down. GrokDriver.stop() calls child.kill("SIGTERM"), so a
36
+ * SIGTERM/SIGINT handler that always treats exit as a crash will
37
+ * process.exit(1) and the supervisor will restart us in a loop.
38
+ *
39
+ * null = ignore (intentional stop). string = fatal log body (no prefix).
40
+ */
41
+ export declare function describeChildExit(shuttingDown: boolean, code: number | null, signal: NodeJS.Signals | string | null): string | null;
42
+ //# sourceMappingURL=grok-spawn.d.ts.map
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=index.d.ts.map