Skip to main content

@arizeai/phoenix-evals provides evaluator building blocks for TypeScript workflows. It includes LLM-based evaluators, code-based evaluators, prompt templating helpers, and compatibility points for Phoenix experiments.

Install#

@arizeai/phoenix-evals depends on model adapters from the AI SDK ecosystem. Install the package plus at least one provider adapter for the models you plan to use.

Common Setups#

You can also pair it with Phoenix experiments:

Runtime Expectations#

  • Node.js 22.12+ (required by AI SDK v7, which is ESM-only)
  • an AI SDK v7-compatible provider package such as @ai-sdk/openai (v4+)
  • credentials required by your chosen provider

Minimal Example#

Docs And Source In node_modules#

After install, a coding agent can inspect the installed package directly:

The bundled docs cover evaluator creation, LLM evaluators, classification metrics, templates, classification, and Phoenix integration.

Where To Start#

Source Layout#

  • src/index.ts re-exports the package surface you usually import from @arizeai/phoenix-evals
  • src/llm/ contains classification helpers and built-in LLM evaluator factories
  • src/code/ contains deterministic classification-metric evaluators (precision, recall, F-beta)
  • src/helpers/ contains createEvaluator and evaluation-result helpers
  • src/template/ contains formatTemplate and getTemplateVariables
  • src/types/ contains shared evaluator and prompt types