Conflict & Entropy

Contradictions are inevitable. The conflict system detects, tracks, and helps resolve them while monitoring overall knowledge consistency.

How Conflicts Are Detected

At L3, every new claim is checked against existing memories using a three-stage process:

  1. Vector similarity — cosine similarity ≥ 0.85 with same subject
  2. Keyword overlap — matching subject + predicate combinations
  3. Semantic check — LLM-based contradiction detection for ambiguous cases

Conflict Lifecycle

New claim arrives
  │
  ├─ No conflict found → store normally
  │
  └─ Conflict detected
       │
       ├─ Old claim → tier changes to CHALLENGED
       ├─ New claim → stored at computed tier
       ├─ Both get conflictGroup link
       ├─ Entropy increases
       │
       └─ Resolution:
            ├─ Manual: epistemic_resolve (keep old/new/both)
            ├─ Auto: conflictAutoResolve=true → higher confidence wins
            └─ Timeout: unresolved conflicts generate health alerts

System Entropy

Entropy measures the overall contradiction density in the knowledge base:

E = challenged_count / total_count

Entropy levels:

LevelRangeStatusAction
🟢 Healthy0.00–0.05NormalNo action needed
🟡 Warning0.05–0.15ElevatedReview challenged claims
🔴 Critical> 0.15DangerousPipeline may halt new stores

Resolution Strategies

Manual Resolution

{
  "tool": "epistemic_resolve",
  "input": {
    "conflictId": "conflict_abc123",
    "keep": "new"  // "old" | "new" | "both"
  }
}

Auto-Resolution

When conflictAutoResolve: true, the system automatically:

  1. Compares confidence scores of conflicting claims
  2. Keeps the higher-confidence claim
  3. Revokes the lower-confidence claim
  4. Logs the resolution in the audit trail

Conflict Groups

Related contradictions are linked via conflictGroup IDs. This allows:

  • epistemic_diff to show all claims in a conflict group
  • epistemic_explain to trace the conflict history
  • Batch resolution of related contradictions