import { ScorerTypes, ScorerConfig, ScorerDefaults, ModelType, OutputType, InputType, ChainPollTemplate, ScorerResponse, BaseScorerVersionResponse, DeleteScorerResponse } from '../types/scorer.types'; import { StepType } from '../types/logging/step.types'; /** * Service class for scorer operations. */ export declare class Scorers { private client; private ensureClient; /** * Lists scorers with optional filtering and built-in pagination. * @param options - (Optional) The filtering options. * @param options.name - (Optional) Filter by a single scorer name. * @param options.names - (Optional) Filter by multiple scorer names. * @param options.types - (Optional) Filter by scorer types. * @returns A promise that resolves to an array of scorers. */ list(options?: { name?: string; names?: string[]; types?: ScorerTypes[]; }): Promise; /** * Lists scorers by label with built-in pagination. * @param labels - Labels to search for. * @param strict - When false, also matches by scorer name as fallback. Defaults to false. * @returns A promise that resolves to an array of scorers. */ listByLabels(labels: string[], strict?: boolean): Promise; /** * Lists scorers by ID with built-in pagination. * @param ids - Scorer IDs to search for. * @returns A promise that resolves to an array of scorers. */ listByIds(ids: string[]): Promise; /** * Gets a specific scorer version. * @param scorerId - The unique identifier of the scorer. * @param version - The version number to retrieve. * @returns A promise that resolves to the scorer version. */ getScorerVersion(scorerId: string, version: number): Promise; /** * Creates a new scorer. * @param options - The scorer creation options. * @param options.name - The name of the scorer. * @param options.scorerType - The type of the scorer. * @param options.description - (Optional) A description for the scorer. * @param options.tags - (Optional) Tags to associate with the scorer. * @param options.defaults - (Optional) Default settings for the scorer. * @param options.modelType - (Optional) The model type for the scorer. * @param options.defaultVersionId - (Optional) The default version ID for the scorer. * @param options.scoreableNodeTypes - (Optional) The node types that can be scored. * @param options.outputType - (Optional) The output type for the scorer. * @param options.inputType - (Optional) The input type for the scorer. * @returns A promise that resolves to the created scorer. */ create(options: { name: string; scorerType: ScorerTypes; description?: string; tags?: string[]; defaults?: ScorerDefaults; modelType?: ModelType; defaultVersionId?: string; scoreableNodeTypes?: StepType[]; outputType?: OutputType; inputType?: InputType; groundTruth?: boolean; }): Promise; /** * Creates a new LLM scorer version. * @param options - The LLM scorer version creation options. * @param options.scorerId - The unique identifier of the scorer. * @param options.instructions - (Optional) Instructions for the LLM scorer. * @param options.chainPollTemplate - (Optional) Chain poll template configuration. * @param options.userPrompt - (Optional) User prompt for the LLM scorer. * @param options.cotEnabled - (Optional) Whether chain-of-thought is enabled. * @param options.modelName - (Optional) The model name to use. * @param options.numJudges - (Optional) The number of judges for consensus. * @returns A promise that resolves to the created scorer version. */ createLlmScorerVersion(options: { scorerId: string; instructions?: string; chainPollTemplate?: ChainPollTemplate; userPrompt?: string; cotEnabled?: boolean; modelName?: string; numJudges?: number; }): Promise; /** * Creates a code-based scorer version. * @param scorerId - The unique identifier of the scorer. * @param codeContent - The Python code content for the scorer. * @param validationResult - (Optional) The validation result JSON string. * @returns A promise that resolves to the created scorer version. */ createCodeScorerVersion(scorerId: string, codeContent: string, validationResult?: string): Promise; /** * Deletes a scorer by ID. * @param scorerId - The unique identifier of the scorer to delete. * @returns A promise that resolves to a response containing a success message. */ delete(scorerId: string): Promise; } /** * Service class for run scorer settings. */ export declare class ScorerSettings { private client; private ensureClient; /** * Creates run scorer settings. * @param options - The run scorer settings options. * @param options.projectId - The unique identifier of the project. * @param options.runId - The unique identifier of the run or experiment. * @param options.scorers - The array of scorer configurations. * @returns A promise that resolves when the settings are created. */ create(options: { projectId: string; runId: string; scorers: ScorerConfig[]; }): Promise; }