UNPKG

@code-yeongyu/senpi

Version:

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

26 lines • 1.38 kB
import type { Api, Context, Model, SimpleStreamOptions } from "@earendil-works/pi-ai"; import { queryWithAuthLane } from "./auth-lane.ts"; import type { SDKMessage } from "./sdk-boundary.ts"; import { type ContinuityObservation } from "./session-observability.ts"; import type { AnthropicSubscriptionProviderSettings } from "./settings.ts"; export type ResidentSessionStreamInput = { model: Model<Api>; context: Context; streamOptions: SimpleStreamOptions; recheckedAccounts?: Set<string>; providerSettings: AnthropicSubscriptionProviderSettings; pinnedAccount?: string; buildOptions: Parameters<typeof queryWithAuthLane>[0]["buildOptions"]; customToolNameToSdk: ReadonlyMap<string, string>; toolWatchNote?: string; onResumeFallback: (error: unknown) => void; onLongContextFallback?: () => void; contextTokens?: () => number; outputReserveTokens?: number; onAttemptStart?: () => void; onContinuityDecision?: (observation: ContinuityObservation) => void; /** Called once per attempt, before dispatch, with whether it re-sends the whole history and that re-send's bytes/4 estimate. */ onDispatchShape?: (coldSeed: boolean, estimatedTokens?: number) => void; }; export declare function residentSessionMessages(input: ResidentSessionStreamInput): AsyncGenerator<SDKMessage>; //# sourceMappingURL=session-stream.d.ts.map