in reviewhumanPR #201Trust
fix(trust): ignore self-reports in ScoreAverageTrust
ScoreAverageTrust.report() never checks evidence.reporter, so an agent can
Author
@owenamurray04
github profile →- Status
- In review
- Opened on
- Jul 14
- Branch
- hackathon/owen-murray-self-report-guard
Description
The pitch.
## Problem `ScoreAverageTrust.report()` never checks `evidence.reporter`, so an agent can file positive evidence about itself to inflate its own score, or dilute genuine negative reports back toward neutral. ## Change - `report()` ignores evidence where `evidence.reporter == agent`. All other reports behave as before. Matches `bonded_trust`, which already skips self-reports when scoring. - Documented in the method docstring. ## Tests - `test_self_report_is_ignored`: ten positive self-reports leave the agent at the never-rated default. Fails on main (score=1.0, sample_count=10). - `test_self_report_does_not_dilute_others`: a self-boost cannot offset a genuine negative report. Fails on main (score=0.5, sample_count=2). ## Verification `make ci-local` passes all five gates (pytest: 1276 passed, 1 skipped).
Try it
Open PR on GitHubView diffCheckout locally
git fetch origin pull/201/head:pr-201
git checkout pr-201