UNPKG

@code-yeongyu/senpi

Version:

Coding agent CLI with read, bash, edit, write tools and session management

44 lines • 1.6 kB
import type { BrowserEngine } from "../../../core/browser-engine.ts"; import type { ExtensionMode } from "../../../core/extensions/types.ts"; /** * What a tool body running in the tool child may see of its extension context: plain, serializable data only. * No functions, no `ui`, no `sessionManager` - those stay on the server and are reached through host calls. */ export interface ChildToolContext { cwd: string; agentDir: string; mode: ExtensionMode; toolCallId: string; projectTrusted: boolean; sessionId?: string; model?: { provider: string; id: string; }; thinkingLevel?: string; serviceTier?: string; browserEngine?: BrowserEngine; sessionEnv?: Readonly<Record<string, string>>; goalStoreFile?: string; } /** The fields `narrowContext` reads; `ExtensionContext` satisfies it structurally. */ export interface NarrowableContext { readonly cwd: string; readonly agentDir: string; readonly mode: ExtensionMode; readonly model: { readonly provider: string; readonly id: string; } | undefined; readonly thinkingLevel?: string | undefined; readonly serviceTier?: string | undefined; readonly browserEngine?: BrowserEngine | undefined; readonly sessionEnv?: Readonly<Record<string, string>> | undefined; readonly goalStoreFile?: string | undefined; isProjectTrusted(): boolean; } export declare function narrowContext(ctx: NarrowableContext, ids: { sessionId?: string | undefined; toolCallId: string; }): ChildToolContext; //# sourceMappingURL=context.d.ts.map