/** * What the harness last prompted each agent about * (specs/2026-10-02-harness-owned-routing.md §4). * * A `[FOLLOW-UP TKT-187]` or `[DECISION D-12]` prompt names the ticket / * decision / work item the agent should answer about. When the agent then * runs `reply ""` with no ids, the reply follows that reference rather * than whichever work item happens to be the newest running one (an * unrelated cron item put Owen's TKT-187 delivery top-level, 2026-10-02). * * In-memory: a restart forgets it, and the resolver falls back to the turn * origin — the prompts also print the exact command with the reference. * * @module services/orc/agent-prompt-reference.service */ /** A reference an agent's reply can name (see reply-destination-resolver). */ export interface ReplyReference { /** chat-v2 message id the agent is answering */ messageId?: string; /** Request ticket (`TKT-187`) or project ticket (`CE-7`) */ ticket?: string; /** Work item id */ workItemId?: string; /** Owner decision id (`D-12`) */ decisionId?: string; } /** A recorded prompt reference. */ export interface PromptReference { reference: ReplyReference; /** The prompt's tag (`[FOLLOW-UP TKT-187]`, `[DECISION D-12]`): it counts only while the last delivered message carries it */ marker?: string; /** Epoch ms the prompt was delivered */ at: number; } /** * Whether a reference names anything. * * @param ref - Reference * @returns True when at least one id is set */ export declare function hasReference(ref: ReplyReference | undefined | null): ref is ReplyReference; /** * Per-agent registry of the last harness prompt's reference. */ export declare class AgentPromptReferenceService { private readonly now; private static instance; private readonly refs; /** * @param now - Clock (tests) */ constructor(now?: () => number); /** @returns The process-wide instance */ static getInstance(): AgentPromptReferenceService; /** Reset the singleton (tests). */ static resetInstance(): void; /** * Record that the harness just prompted `session` about `reference`. * * Call only after the prompt was delivered. * * @param session - Agent session * @param reference - What the prompt was about * @param marker - The prompt's tag (`[FOLLOW-UP TKT-187]`) */ note(session: string, reference: ReplyReference, marker?: string): void; /** * The agent's last prompt reference while it is fresh. * * @param session - Agent session * @returns The reference, or undefined (none / expired) */ get(session: string): PromptReference | undefined; /** * Forget the agent's reference (it was answered). * * @param session - Agent session */ clear(session: string): void; } //# sourceMappingURL=agent-prompt-reference.service.d.ts.map