UNPKG

@code-yeongyu/senpi

Version:

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

30 lines • 1.75 kB
import type { ProviderChatModelConfig } from "../../types.ts"; export type CursorCliModelCatalogSettings = { readonly modelCatalogTtlHours?: number; readonly executablePath?: string; }; export type CursorCliModelCatalogDeps = { now: () => number; resolveExecutable: () => string; runProbe: (executable: string, stdoutPath: string, timeoutMs: number) => Promise<void>; makeTemporaryDirectory: (prefix: string) => Promise<string>; readTextFile: (path: string) => Promise<string>; makeDirectory: (path: string) => Promise<void>; writeTextFile: (path: string, contents: string) => Promise<void>; renameFile: (from: string, to: string) => Promise<void>; removeDirectory: (path: string) => Promise<void>; }; type CursorCliModelCatalogDefaultDeps = Omit<CursorCliModelCatalogDeps, "runProbe">; export type ResolveCursorCliModelCatalogOptions = { readonly agentDir: string; readonly settings?: CursorCliModelCatalogSettings; /** The caller owns the probe: it decides the HOME (and therefore the account) `cursor-agent models` runs in. */ readonly deps: Partial<CursorCliModelCatalogDefaultDeps> & Pick<CursorCliModelCatalogDeps, "runProbe">; }; export declare const STATIC_CURSOR_CLI_MODELS: readonly ProviderChatModelConfig[]; /** Parse the complete `cursor-agent models` listing into extension provider entries. */ export declare function parseCursorAgentModelsListing(listing: string): ProviderChatModelConfig[]; /** Resolve a cached or probed catalog, always degrading to the exact offline fallback. */ export declare function resolveCursorCliModelCatalog(options: ResolveCursorCliModelCatalogOptions): Promise<readonly ProviderChatModelConfig[]>; export {}; //# sourceMappingURL=models.d.ts.map