Evaluators#

Evaluators: people, simulated users, metrics, LLM judges, panels and hybrids.

Simulated users, metric evaluators, LLM and VLM judges and their API clients, panels, hybrid escalation, verbal steering, people.

Classes#

Evaluator()

Base class: evaluate(query) -> Feedback.

CallbackEvaluator(fn[, name, human])

Wrap a function query -> Feedback (custom GUIs, web services, experiments).

MetricEvaluator(problem, metric[, name, ...])

Deterministic evaluator from a numeric criterion (computational aesthetics, KPIs).

RecordingEvaluator(inner)

Pass-through that records every query–answer pair (for replays and audits).

ReplayEvaluator(feedbacks[, name])

Answer queries from a recorded list (deterministic re-runs and tests).

SimulatedUser(problem[, target, noise, ...])

A user model with a hidden target.

LLMJudge(client[, problem, goal, criteria, ...])

An LLM/VLM acting as the evaluator of an IEC session.

MockJudgeClient([scorer, score_on, noise, ...])

Scorer-driven fake LLM.

AnthropicClient([model, api_key, ...])

Claude through the Anthropic Messages API.

OpenAIClient([model, api_key, base_url, ...])

OpenAI Chat Completions (and compatible endpoints through base_url).

GeminiClient([model, api_key, base_url, ...])

Google Gemini generateContent with inline PNG data and JSON responses.

OllamaClient([model, base_url, temperature])

A local model served by Ollama (http://localhost:11434).

CachedClient(inner[, path])

Disk cache in front of any client: identical requests are answered from file.

Panel(members[, weights, method, name])

Ask several evaluators and aggregate.

PersonaPanel(client, personas, *[, problem, ...])

A panel of LLM judges sharing one client but differing in persona.

EscalationEvaluator(ai, human, *[, policy, ...])

Answer with an AI evaluator; escalate uncertain queries to a person.

HumanProxy()

Stands for a person in an event-driven front end: raises NeedsHuman.

ConsoleEvaluator([problem, image_size, ...])

Terminal front end: saves the gallery as a PNG and reads the answer from input().

VerbalSteering(problem[, client, step, ...])

Convert comments into unit-cube directions.

Functions#

feedback_from_scores(query, scores, evaluator, *)

Answer query from perceived scores {id: score in [0, 1]}.

make_crowd(problem[, n, spread, ...])

Heterogeneous simulated users whose targets scatter around a common one.

make_client([provider, model, cache])

Create a client: make_client("anthropic", "claude-haiku-5-5", cache=".cache").

kendall_w(rank_matrix)

Kendall's coefficient of concordance of m rankers × n items (ranks 1..n).

disagreement(query, a, b)

Protocol-aware disagreement in [0, 1] between two answers to query.