/** Fetches the full diff (patch) of a commit by hash, so a model can inspect an unclear change. */ export type CommitDiffFetcher = (hash: string) => Promise; /** Greps the committed files at a specific commit. Receives the raw tool input and validates it. */ export type CodebaseGrepper = (input: Record) => Promise; export type TranslationRequest = { /** Provider-agnostic system prompt describing how to translate. */ systemPrompt: string; /** The English release notes (plus context) to translate. */ userContent: string; /** Tool the model may call to read a commit's diff when a description is unclear. */ fetchCommitDiff: CommitDiffFetcher; /** Tool the model may call to search the committed code at a commit for more context. */ grepCodebase: CodebaseGrepper; /** Called for every tool the model invokes, before it runs — used for progress logging. */ onToolCall?: (call: { name: string; input: Record; }) => void; }; /** * A translation backend (OpenAI, Claude, ...). Implementations own the provider-specific * request/tool-call loop and expose the same surface so the provider can be swapped via config. */ export interface TranslationModel { /** Human-readable identifier, e.g. "openai:gpt-5.5". Used in logs. */ readonly name: string; /** Runs the translation, resolving `get_commit_diff` / `grep_codebase` tool calls against the request. */ translate(request: TranslationRequest): Promise; } /** The tool the model can call to inspect a commit. Shared shape, translated per provider. */ export declare const COMMIT_DIFF_TOOL: { name: string; description: string; parameters: { type: "object"; properties: { hash: { type: string; description: string; }; }; required: string[]; additionalProperties: boolean; }; }; /** The tool the model can call to search committed source files at a specific commit. */ export declare const GREP_TOOL: { name: string; description: string; parameters: { type: "object"; properties: { pattern: { type: string; description: string; }; commit: { type: string; description: string; }; ignoreCase: { type: string; description: string; }; fixedString: { type: string; description: string; }; wordMatch: { type: string; description: string; }; pathspec: { type: string; description: string; }; }; required: string[]; additionalProperties: boolean; }; }; /** Maximum number of tool-call round trips before we give up, to bound cost and avoid loops. */ export declare const MAX_TOOL_ITERATIONS = 12; //# sourceMappingURL=translation-model.d.ts.map