import { ThemeIcon } from "../../../../base/common/themables.js";
import { IOffsetRange, OffsetRange } from "../../../../editor/common/core/offsetRange.js";
import { IRange } from "../../../../editor/common/core/range.js";
import { IChatAgentCommand, IChatAgentData } from "./chatAgents.js";
import { IChatAgentService } from "./chatAgents.service.js";
import { IChatRequestVariableEntry } from "./chatModel.js";
import { IChatSlashData } from "@codingame/monaco-vscode-chat-service-override/vscode/vs/workbench/contrib/chat/common/chatSlashCommands";
import { IChatRequestVariableValue } from "./chatVariables.js";
import { ChatAgentLocation } from "./constants.js";
import { IToolData } from "./languageModelToolsService.js";
import { IChatPromptSlashCommand } from "./promptSyntax/service/types.js";
export interface IParsedChatRequest {
    readonly parts: ReadonlyArray<IParsedChatRequestPart>;
    readonly text: string;
}
export interface IParsedChatRequestPart {
    readonly kind: string;
    readonly range: IOffsetRange;
    readonly editorRange: IRange;
    readonly text: string;
    readonly promptText: string;
}
export declare function getPromptText(request: IParsedChatRequest): {
    message: string;
    diff: number;
};
export declare class ChatRequestTextPart implements IParsedChatRequestPart {
    readonly range: OffsetRange;
    readonly editorRange: IRange;
    readonly text: string;
    static readonly Kind = "text";
    readonly kind = "text";
    constructor(range: OffsetRange, editorRange: IRange, text: string);
    get promptText(): string;
}
export declare const chatVariableLeader = "#";
export declare const chatAgentLeader = "@";
export declare const chatSubcommandLeader = "/";
export declare class ChatRequestToolPart implements IParsedChatRequestPart {
    readonly range: OffsetRange;
    readonly editorRange: IRange;
    readonly toolName: string;
    readonly toolId: string;
    readonly displayName?: string | undefined;
    readonly icon?: IToolData["icon"];
    static readonly Kind = "tool";
    readonly kind = "tool";
    constructor(range: OffsetRange, editorRange: IRange, toolName: string, toolId: string, displayName?: string | undefined, icon?: IToolData["icon"]);
    get text(): string;
    get promptText(): string;
    toVariableEntry(): IChatRequestVariableEntry;
}
export declare class ChatRequestAgentPart implements IParsedChatRequestPart {
    readonly range: OffsetRange;
    readonly editorRange: IRange;
    readonly agent: IChatAgentData;
    static readonly Kind = "agent";
    readonly kind = "agent";
    constructor(range: OffsetRange, editorRange: IRange, agent: IChatAgentData);
    get text(): string;
    get promptText(): string;
}
export declare class ChatRequestAgentSubcommandPart implements IParsedChatRequestPart {
    readonly range: OffsetRange;
    readonly editorRange: IRange;
    readonly command: IChatAgentCommand;
    static readonly Kind = "subcommand";
    readonly kind = "subcommand";
    constructor(range: OffsetRange, editorRange: IRange, command: IChatAgentCommand);
    get text(): string;
    get promptText(): string;
}
export declare class ChatRequestSlashCommandPart implements IParsedChatRequestPart {
    readonly range: OffsetRange;
    readonly editorRange: IRange;
    readonly slashCommand: IChatSlashData;
    static readonly Kind = "slash";
    readonly kind = "slash";
    constructor(range: OffsetRange, editorRange: IRange, slashCommand: IChatSlashData);
    get text(): string;
    get promptText(): string;
}
export declare class ChatRequestSlashPromptPart implements IParsedChatRequestPart {
    readonly range: OffsetRange;
    readonly editorRange: IRange;
    readonly slashPromptCommand: IChatPromptSlashCommand;
    static readonly Kind = "prompt";
    readonly kind = "prompt";
    constructor(range: OffsetRange, editorRange: IRange, slashPromptCommand: IChatPromptSlashCommand);
    get text(): string;
    get promptText(): string;
}
export declare class ChatRequestDynamicVariablePart implements IParsedChatRequestPart {
    readonly range: OffsetRange;
    readonly editorRange: IRange;
    readonly text: string;
    readonly id: string;
    readonly modelDescription: string | undefined;
    readonly data: IChatRequestVariableValue;
    readonly fullName?: string | undefined;
    readonly icon?: ThemeIcon | undefined;
    readonly isFile?: boolean | undefined;
    readonly isDirectory?: boolean | undefined;
    static readonly Kind = "dynamic";
    readonly kind = "dynamic";
    constructor(range: OffsetRange, editorRange: IRange, text: string, id: string, modelDescription: string | undefined, data: IChatRequestVariableValue, fullName?: string | undefined, icon?: ThemeIcon | undefined, isFile?: boolean | undefined, isDirectory?: boolean | undefined);
    get referenceText(): string;
    get promptText(): string;
    toVariableEntry(): IChatRequestVariableEntry;
}
export declare function reviveParsedChatRequest(serialized: IParsedChatRequest): IParsedChatRequest;
export declare function extractAgentAndCommand(parsed: IParsedChatRequest): {
    agentPart: ChatRequestAgentPart | undefined;
    commandPart: ChatRequestAgentSubcommandPart | undefined;
};
export declare function formatChatQuestion(chatAgentService: IChatAgentService, location: ChatAgentLocation, prompt: string, participant?: string | null, command?: string | null): string | undefined;
