Class TraceToEvalAdapter

java.lang.Object
com.tnsai.evaluation.bridge.TraceToEvalAdapter

public final class TraceToEvalAdapter extends Object
Converts completed AgentTrace spans into Evaluator.EvaluationInput records.

Extracts the last user message (input) and assistant response (output) from trace observations, along with tool call sequences and latency data.

Since:
0.3.0
  • Constructor Details

    • TraceToEvalAdapter

      public TraceToEvalAdapter()
  • Method Details

    • adapt

      public Evaluator.EvaluationInput adapt(com.tnsai.quality.tracing.AgentTrace trace)
      Converts an AgentTrace to an EvaluationInput.
      Parameters:
      trace - the completed agent trace
      Returns:
      evaluation input, or null if trace has no chat observations