Skip to content

[BUG]: Schema-valid ATIF structured answers disappear from judge evidence #202

Closed

Description

@YMuskrat

What happened?

On main f32c884 (0.5.0), host and standalone-verifier answer extraction accepts only string messages. Harbor 0.24 accepts ATIF messages as arrays of content parts. A valid text-part answer becomes empty judge evidence, or an earlier string message is selected as the final response instead.

Proposed fix

Reuse the existing atif_content_text conversion for agent text, final responses, summaries and final-response references in both implementations. It joins text parts and uses [image]/[audio] markers without exposing media paths. Prepared schema-valid fixtures cover multiple text parts, the last nonempty answer, plain-string/empty controls, media markers and exact host/verifier bundle parity.

Reproduction steps

With the Tier 3 dependencies installed, this runs offline:

from harbor.models.trajectories.trajectory import Trajectory
from skillevaluator.tier3.eval_core.atif_helpers import get_final_response, build_metric_evidence_bundles

trajectory = Trajectory.model_validate({
    "schema_version": "ATIF-v1.7",
    "agent": {"name": "test-agent", "version": "test"},
    "steps": [{
        "step_id": 1, "source": "agent",
        "message": [{"type": "text", "text": "The answer is 4."}],
    }],
}).to_json_dict()
print(repr(get_final_response(trajectory)))
print(build_metric_evidence_bundles(trajectory, "What is 2+2?", ground_truth="4")["accuracy"]["prompt_evidence"])
# Actual: empty final response and empty accuracy evidence.
# Expected: the generated answer is included.

Final-response references and conversation summaries also omit the content. The standalone Harbor verifier duplicates the string-only extraction.

SkillEvaluator version or commit

f32c884 (0.5.0)

Environment

Linux, Python 3.12, Harbor 0.24.0, repository locked dependencies. Offline reproduction; no model calls or credentials required.

Before submitting

Activity

  1. added
    bug
    on Oct 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions