UNPKG

@code-yeongyu/senpi

Version:

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

37 lines • 1.78 kB
import type { ResourceDiagnostic } from "./diagnostics.ts"; export interface ContextFile { path: string; content: string; /** * "user" for the user's own standing instructions (the agent-dir file and the home-directory file); * absent means a project file. The prompt ranks user instructions above its default working style. */ scope?: "user"; } /** Preserve the public array API while returning diagnostics to the owning mode. */ export type ContextFiles = ContextFile[] & { readonly diagnostics: ResourceDiagnostic[]; }; /** Size limits for AGENTS.md / CLAUDE.md context files, which ride along on every model request. */ export interface ContextFileLimits { maxBytesPerFile?: number; maxTotalBytes?: number; /** * The global (user-scope) context file to load instead of the agent-dir probe (senpi#5567). * Honored from the user's own settings only (`SettingsManager.getGlobalContextFilePath`); a * project's settings never set it. A leading `~` is expanded; a relative path resolves against * the agent dir, like other paths in global settings; a directory runs the same candidate probe * as the agent dir. Unset or blank keeps the agent-dir file. A path that is set but missing, * unreadable, a special file, or a directory with no candidate falls back to the agent-dir probe * and reports one warning diagnostic instead of erroring. */ globalPath?: string; } export declare const DEFAULT_CONTEXT_FILE_MAX_BYTES: number; export declare const DEFAULT_CONTEXT_FILES_MAX_TOTAL_BYTES: number; export declare function loadProjectContextFiles(options: { cwd: string; agentDir: string; homeDir?: string; } & ContextFileLimits): ContextFiles; //# sourceMappingURL=context-files.d.ts.map