import type { PortableTool } from "../portable-tool.js";
/** A single instruction file entry. */
export interface InstructionFileInfo {
    filename: string;
    path: string;
    size: number;
    updatedAt: string;
}
/** Full instruction file (with content). */
export interface InstructionFileContent extends InstructionFileInfo {
    content: string;
}
/** Deps injected by the host runtime for instructions CRUD. */
export interface InstructionsToolDeps {
    /** List all instruction files for a project (recursive). */
    list(projectId: string): InstructionFileInfo[];
    /** Read a single instruction file. Returns null if not found. */
    read(projectId: string, filename: string): InstructionFileContent | null;
    /** Write (create or overwrite) an instruction file. */
    write(projectId: string, filename: string, content: string): InstructionFileContent;
    /** Remove an instruction file. Returns true if deleted. */
    remove(projectId: string, filename: string): boolean;
}
export declare const INSTRUCTIONS_TOOL_NAME: "instructions";
export type InstructionsAction = "list" | "read" | "write" | "edit" | "delete";
export interface InstructionsToolParams {
    action: InstructionsAction;
    project_id: string;
    filename?: string;
    content?: string;
    old_text?: string;
    new_text?: string;
}
export declare const INSTRUCTIONS_TOOL_SCHEMA: {
    readonly type: "object";
    readonly properties: {
        readonly action: {
            readonly type: "string";
            readonly enum: readonly ["list", "read", "write", "edit", "delete"];
            readonly description: "Operation: list all files, read a file, write (create/overwrite), edit (partial replace), or delete a file.";
        };
        readonly project_id: {
            readonly type: "string";
            readonly description: "Project ID. Use \"default\" for the default project.";
        };
        readonly filename: {
            readonly type: "string";
            readonly description: "Instruction file name ending in .md (e.g. \"code-style.md\"). Required for read/write/delete. Sub-paths like \"testing/unit-test.md\" are supported.";
        };
        readonly content: {
            readonly type: "string";
            readonly description: "Markdown content for the instruction file. Required for write action.";
        };
        readonly old_text: {
            readonly type: "string";
            readonly description: "Required for edit action: the exact existing text to find and replace (must appear exactly once).";
        };
        readonly new_text: {
            readonly type: "string";
            readonly description: "Required for edit action: the replacement text.";
        };
    };
    readonly required: readonly ["action", "project_id"];
};
export declare function createInstructionsTool(deps: InstructionsToolDeps): PortableTool<InstructionsToolParams>;
