
foojay · 6 min readTesting & code quality
Evaluating Java AI Agents with Harness Evals
Learn how to use Harness Evals to benchmark Java AI agents via HTTP and OpenTelemetry, defining goldens, metrics, and CI gates. The guide shows controller setup, YAML config, and integration with Spring AI or LangChain4j, enabling repeatable, scored evaluations for production reliability.
- Define goldens in JSONL and configure HTTP target for Spring AI agents.
- Use GEval and tool_correctness metrics with an OpenAI judge for correctness.
- Gate CI with --baseline and --fail-under to catch regressions automatically.