Skip to content

feat(ops): add signal freshness SLOs and alertable audit events #40

Description

@JSONbored

Parent: #32

Goal

Prevent stale data from silently degrading recommendations.

Requirements

  • Define freshness SLOs for registry snapshots, scoring model snapshots, GitHub totals, repo segments, contributor decision packs, bounty data, and signal snapshots.
  • Add audit events when data becomes stale, degraded, blocked, or repaired.
  • Surface stale/degraded state in readiness, sync status, MCP outputs, and decision packs.
  • Avoid noisy public GitHub output.

Acceptance Criteria

  • /v1/readiness distinguishes service health from signal freshness.
  • MCP responses explain when recommendations are stale or degraded.
  • Internal jobs can detect and enqueue repair for stale signals.
  • Audit events are structured and secret-safe.

Testing Requirements

This issue must preserve the repo's CI gate:

  • npm run test:ci must pass.
  • Global coverage must remain at or above 95% for lines, statements, functions, and branches.
  • Add or update tests for every new branch, fallback path, sanitizer rule, and regression.
  • Add invariant/property-style tests when behavior depends on sorting, gating, public/private boundaries, scoring, queue pressure, or source-upload safety.
  • Public GitHub output must be tested against forbidden language: wallet, hotkey, raw trust score, payout, reward estimate, farming, private reviewability, and public score estimate.

Required Test Scenarios

  • Fresh state.
  • Stale registry.
  • Stale decision pack.
  • Degraded repo segment.
  • Repair queued.
  • Audit event redaction.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions