import { LLMService } from "../../core/llm/services/llm.service"; import { RubricVerdict } from "./retrieval-eval.types"; export declare const RUBRIC_JUDGE_PROMPT = "\nYou are grading one answer produced by a retrieval-augmented assistant.\n\nYou are given the user's question, a rubric stating what a correct answer MUST\nassert, the answer that was produced, and how many pieces of required evidence\nthe answer cited.\n\nDecide ONE thing: does the answer satisfy the rubric?\n\nJudge only against the rubric. Do not reward length, tone, formatting or\nconfidence. An answer that is well written but does not assert what the rubric\nrequires has failed. An answer that asserts what the rubric requires in plain\nlanguage has passed, even if it is terse.\n\nWhen the answer FAILS, classify why, choosing exactly one:\n\n- evidence-not-retrieved: the answer could not have been written because the\n required material never reached it. Typically the citation count is zero.\n- retrieved-but-unused: the required material was cited or is clearly present,\n and the answer still does not assert what the rubric requires.\n- contradicted-source: the answer asserts something that conflicts with the\n material it cites.\n- hedged-without-answering: the answer declines, defers, or describes what it\n would need, instead of answering.\n\nBe strict and be consistent. Your explanation must be one sentence naming the\nspecific rubric requirement that was met or missed.\n"; /** * Grades one answer against its rubric. * * A judging failure degrades to a FAILED verdict for that question rather than * killing the sweep — the graceful-degradation rule in 06-llm-calls.md rule 8, * applied deliberately: an ungraded question must never silently count as a pass. * * ATTRIBUTION EXCEPTION (06-llm-calls.md rule 5). `tokenUsageType` and * `metadata` are set, but `relationshipId` / `relationshipType` are deliberately * absent: a sweep grades the harness itself, so there is no tenant entity whose * spend this is. LLMService skips usage persistence unless BOTH are set, which * is the intended outcome here — eval spend must not land on a customer's * ledger. The call is still fully identifiable in dumps and telemetry through * metadata.agentName / metadata.nodeName. */ export declare class RubricJudgeService { private readonly llmService; private readonly logger; constructor(llmService: LLMService); judge(params: { question: string; rubric: string; answer: string; evidenceCited: number; }): Promise; } //# sourceMappingURL=rubric-judge.service.d.ts.map