/**
 * Module: llm/gen/mock
 *
 * Mock LLM generator that uses a static response database for testing and development.
 *
 * === MOCK DATABASE FORMAT (YAML) ===
 *
 * ```yaml
 * responses:
 *   # Comments are supported! Explain which test step uses each entry.
 *   # E.g., # docs/e2e-story-test/basics/reminders.md: Step 1
 *   - message: "hello"
 *     role: "user"
 *     response: "Hi there!"
 *     delayMs: 200
 *     chunkDelayMs: 20
 *   - message: "error text"
 *     role: "tool"
 *     response: "corrected response"
 * ```
 *
 * === ROLE-BASED MATCHING (EXACT ONLY) ===
 *
 * The mock looks at the last *input-like* message in context (no fallback):
 * - role='user' from prompting_msg → matches entries with role='user'
 * - role='tool' from func_result_msg / tellask_result_msg → matches entries with role='tool'
 *
 * Notes:
 * - Context tails may include reminders / transient guides; these are ignored for matching.
 *
 * Matching rules (strict exact matching, NO fallback):
 * 1. Exact: "tool:error text" matches response with message="error text" AND role="tool"
 * 2. Exact: "user:hello" matches response with message="hello" AND role="user"
 * 3. No match: returns fallback response explaining how to add mocks
 *
 * === BENEFITS OF YAML FORMAT ===
 *
 * - Comments: Document which test step uses each entry
 * - Easy cleanup: Identify unused entries by checking test step references
 * - Maintainability: Update comments when tests change, never lose referenced entries
 *
 * === EXAMPLE: TOOL ERROR RECOVERY ===
 *
 * // Turn 1: User asks, LLM makes syntax error
 * # docs/e2e-story-test/reminders.md: User creates reminders
 * - message: "create reminders"
 *   role: "user"
 *   response: "Call the function tool `add_reminder` with {\"content\":\"goals...\"}"
 *
 * // Turn 2: Tool error (func_result_msg with role='tool'), LLM self-corrects
 * # docs/e2e-story-test/reminders.md: Tool syntax error recovery
 * - message: "Error: Invalid args. Use: add_reminder({ content: string, scope?: \"dialog\" | \"task\" | \"agent\" }) (omitting scope means task)."
 *   role: "tool"
 *   response: "Call the function tool `add_reminder` with {\"content\":\"Goals...\",\"scope\":\"task\"}"
 */
import type { Team } from '../../team';
import type { FuncTool } from '../../tool';
import type { ChatMessage, ProviderConfig } from '../client';
import { type LlmBatchResult, type LlmGenerator, type LlmRequestContext, type LlmStreamReceiver, type LlmStreamResult } from '../gen';
export declare class MockGen implements LlmGenerator {
    get apiType(): string;
    private databaseCache;
    private resolveInputForMatching;
    private loadResponseDatabase;
    private responseMatchesContext;
    private normalizeFuncCallArgs;
    private extractLastAssistantSaying;
    private extractCurrentPromptMsgId;
    private buildReplyToolReminderAutoResponse;
    /**
     * Find matching response using EXACT last message only.
     * NO fallback to message-only matching - if exact match fails, return null.
     */
    private findMatchingResponse;
    private makeFallbackResponse;
    genToReceiver(providerConfig: ProviderConfig, agent: Team.Member, systemPrompt: string, _funcTools: FuncTool[], _requestContext: LlmRequestContext, context: ChatMessage[], receiver: LlmStreamReceiver, _genseq: number, abortSignal?: AbortSignal): Promise<LlmStreamResult>;
    genMoreMessages(providerConfig: ProviderConfig, agent: Team.Member, systemPrompt: string, _funcTools: FuncTool[], _requestContext: LlmRequestContext, context: ChatMessage[], genseq: number, abortSignal?: AbortSignal): Promise<LlmBatchResult>;
}
