probo icon indicating copy to clipboard operation
probo copied to clipboard

Rework evidence agent into structured assessor

Open SachaProbo opened this issue 5 months ago • 0 comments

Replace the free-text evidence describer with an assessor that emits a structured assessment (status plus rationale) so downstream code can act on the verdict instead of parsing prose.

Rename the evidencedescriber package and worker to evidenceassessor and introduce a dedicated EvidenceAssessment coredata model backed by an assessment status enum. Split the schema changes into focused migrations and scope the FAILED transition to the status columns so unrelated evidence fields are left untouched.

Realign the surrounding configuration and wiring: rename the config to EvidenceAssessmentConfig, update probod aliases and builders, add a Thinking budget to the LLM agent config, and extract an OutputType.DecorateEnum helper. Bind jsonRawMessageOrNull through driver.Valuer so raw JSON assessments persist cleanly.


Summary by cubic

Replaced the free-text evidence describer with a structured assessor that outputs a JSON assessment and explicit status. Added an EvidenceAssessment model and updated the worker, services, and configs so downstream code can act on verdicts without parsing prose.

Coredata +336 -173

  • Added assessment JSONB and EvidenceAssessmentStatus; renamed description_* to assessment_* via 3 migrations.
  • New helpers: Evidence.SetAssessment, GetAssessment, and SetAssessmentFailed; added driver.Valuer for raw JSON nulls.
  • Renamed loaders/reset to assessment; switched to EvidenceFileID.

Service +303 -198

  • Introduced pkg/evidenceassessor and evidence-assessment worker; removed pkg/evidencedescriber.
  • Persist JSON assessment and derive Description from Summary; failure only touches status columns.
  • Added OutputType.DecorateEnum and enforced enum for confidence; added Thinking budget to LLMAgentConfig.
  • Updated wiring and configs to EvidenceAssessmentConfig; adjusted services to EvidenceFileID and new statuses.

Tests +145 -8

  • Added assessment round‑trip and status enum tests; schema decoration test for confidence.
  • Updated builder tests to the new assessor.

GraphQL API +2 -2

  • Switched console evidence type to use EvidenceFileID.

Other +58 -58

  • Bumped GitHub Actions pins (runner, Docker, Helm, cosign, upload/download‑artifact, setup‑node) with no functional changes.

Written for commit 75a131e5fb066931e84ea546ef733ba106824de5. Summary will update on new commits.

Review in cubic

SachaProbo avatar Jun 16 '26 14:06 SachaProbo