import { KnowledgeGraph } from '../../contracts/graph.js'; import type { ContextSessionDiagnostics } from '../../contracts/context-session.js'; import { type PromptRunnerUsage } from '../prompt-runner.js'; import { type BenchmarkPromptArtifacts, type BenchmarkPromptTokenSource } from './runner.js'; export interface BenchmarkQuestionResult { id?: string; description?: string; question: string; query_tokens: number; effective_query_tokens?: number; reused_context_tokens?: number; session_diagnostics?: ContextSessionDiagnostics; reduction: number; expected_labels: string[]; matched_expected_labels: string[]; missing_expected_labels: string[]; total_tokens?: number | null; prompt_tokens_estimated?: number; prompt_token_source?: BenchmarkPromptTokenSource; usage?: PromptRunnerUsage | null; answer_text?: string | null; elapsed_ms?: number; artifacts?: BenchmarkPromptArtifacts; } export interface BenchmarkQuestionSpec { id?: string; description?: string; question: string; expected_labels?: string[]; } export type BenchmarkQuestionInput = string | BenchmarkQuestionSpec; export interface BenchmarkMissingExpectedLabels { question: string; labels: string[]; } export interface BenchmarkQuestionEvaluation { question: string; result: BenchmarkQuestionResult | null; expected_label_count: number; matched_expected_label_count: number; missing_expected_labels: BenchmarkMissingExpectedLabels | null; } export declare function normalizeExpectedLabel(label: string): string; export declare function normalizeBenchmarkQuestion(question: BenchmarkQuestionInput): BenchmarkQuestionSpec; export declare function loadBenchmarkQuestions(questionsPath: string): BenchmarkQuestionSpec[]; export declare function querySubgraphTokens(graph: KnowledgeGraph, question: string, depth?: number): number; export declare function evaluateBenchmarkQuestion(graph: KnowledgeGraph, question: BenchmarkQuestionInput, corpusTokens: number, depth?: number): BenchmarkQuestionEvaluation;