Skip to content

feat: trust scoring engine (spec 12)#38

Merged
DarlingtonDeveloper merged 1 commit into
mainfrom
feat/trust-scoring-engine
Mar 15, 2026
Merged

feat: trust scoring engine (spec 12)#38
DarlingtonDeveloper merged 1 commit into
mainfrom
feat/trust-scoring-engine

Conversation

@DarlingtonDeveloper
Copy link
Copy Markdown
Contributor

Summary

  • Trust scoring engine that computes trust from graph topology at query time — five signals (corroboration, contradiction, source reliability, access reinforcement, freshness) combined via configurable weights
  • Briefing integrationrank() blends importance with trust scores when [trust] is configured (60/40 default split, tunable)
  • HTTP APIGET /trust/:node_id, POST /trust/batch, GET /trust/agents endpoints
  • CLIcortex trust <node-id> and cortex trust --agent <agent-id>
  • Source reliability cache refreshed every auto-linker cycle
  • 14 new tests covering all signals, cache, engine, batch scoring, and determinism

Design

Trust is purely computed, never stored. No schema changes. Opt-in via [trust] in cortex.toml:

[trust]
corroboration_saturation = 3
contradiction_weight = 0.3
access_saturation = 20
freshness_halflife = 90

[trust.weights]
corroboration = 0.30
contradiction = 0.25
source = 0.20
access = 0.15
freshness = 0.10

Test plan

  • cargo test -p cortex-core trust — 14 tests pass
  • cargo build --workspace — clean
  • cargo clippy --workspace — no warnings
  • Manual: enable [trust] in cortex.toml, verify briefing ranking changes
  • Manual: cortex trust <node-id> shows breakdown
  • Manual: GET /trust/:node_id returns JSON score

🤖 Generated with Claude Code

…pec 12)

Trust is derived from five graph signals (corroboration, contradiction,
source reliability, access reinforcement, freshness) rather than
self-reported by writers. Purely additive — opt-in via [trust] in
cortex.toml. Integrates with briefing ranking, HTTP API, and CLI.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@DarlingtonDeveloper DarlingtonDeveloper merged commit 1aa150d into main Mar 15, 2026
2 of 3 checks passed
@DarlingtonDeveloper DarlingtonDeveloper deleted the feat/trust-scoring-engine branch March 15, 2026 18:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant