◎ OS PUB Apache 2.0 ← All specifications

P220 — AIEP — Counterfactual Branch Pruning Engine

Applicant: Neil Grassby Classification: Patent Application — Confidential Priority: Claims priority from GB2519711.2 filed 20 November 2025 Architecture Layer: AIEP Phase 2 Support Layer


Framework Context

[0001] This specification operates within an AIEP environment as defined in GB2519711.2 and GB2519798.9. The present specification defines the counterfactual branch management and computational efficiency subsystem of the Phase-2 AIEP simulation architecture, addressing the problem of unbounded branch proliferation in multi-hypothesis counterfactual reasoning.


Field of the Invention

[0002] The present invention relates to computational resource management systems for counterfactual simulation architectures in evidence-bound artificial intelligence.

[0003] More particularly, the invention relates to a system that evaluates the informational value of active counterfactual simulation branches and prunes low-value branches before full execution, releasing compute resources for higher-priority branches and canonical timeline reasoning.


Background

[0004] The Counterfactual Timeline Engine (P203) may generate many simultaneous branches during multi-hypothesis reasoning. Without a pruning mechanism, the number of active branches grows unboundedly, consuming computational resources disproportionate to their informational value.

[0005] Effective branch pruning must: evaluate branch value before full simulation completes; prune branches that are provably dominated by other branches; maintain sufficient branch diversity to avoid premature convergence; and preserve a record of pruned branches for audit purposes.


Summary of the Invention

[0006] The invention provides a Counterfactual Branch Pruning Engine (CBPE) that evaluates active simulation branches using a multi-criterion branch value score comprising: divergence potential (estimated maximum divergence from canonical timeline); evidence alignment (fraction of branch events consistent with admitted evidence); goal relevance (alignment with active goal states); and novelty contribution (informational distance from other active branches).

[0007] Branches whose branch value score falls below the configured pruning threshold are terminated and their branch records admitted to the AIEP evidence ledger as pruning records. The CBPE enforces a configurable maximum active branch count, always pruning the lowest-scoring branches when the count is exceeded.


ASCII Architecture

Active Counterfactual Branches (P203)
           |
           v
+------------------------------------------+
| Counterfactual Branch Pruning Engine     |
|                                          |
|  Branch Value Scorer:                   |
|    - Divergence Potential               |
|    - Evidence Alignment                 |
|    - Goal Relevance                     |
|    - Novelty Contribution               |
|                                          |
|  Pruning Decision:                      |
|    score < threshold → prune            |
+-------------------+----------------------+
                    |
           KEEP           PRUNE
             |               |
             v               v
      Continues        Pruning Record
      Simulation       (admitted to ledger)

Detailed Description

[0008] Branch Value Scoring. The branch value score V is computed as: V = w1 * divergence_potential + w2 * evidence_alignment + w3 * goal_relevance + w4 * novelty_contribution. Default weights: w1=0.30, w2=0.25, w3=0.30, w4=0.15.

[0009] Divergence Potential Estimation. Divergence potential is estimated from the first N events of the branch simulation, projecting the expected divergence trajectory assuming continuation. Branches that diverge only minimally from the canonical timeline contribute little to reasoning diversity and are prime pruning candidates.

[0010] Evidence Alignment Check. A partially simulated branch whose events are predominantly contradicted by admitted evidence artefacts is unlikely to contribute valid causal candidates. Such branches are penalised heavily on the evidence alignment dimension.

[0011] Novelty Contribution. To prevent premature convergence to similar branches, the CBPE measures the informational distance between branches. When multiple active branches are structurally similar, the lowest-scoring similar branches are pruned to maintain branch diversity.

[0012] Pruning Record. Each pruned branch produces a pruning record admitted to the ledger containing: the branch_id; the pruning decision timestamp; the final branch value score; and the reason code. Pruning records enable audit of the branch selection process and retrospective analysis of pruning decisions.


Technical Effect

[0013] The invention provides evidence-grounded, multi-criterion pruning of counterfactual simulation branches to prevent unbounded branch proliferation while preserving reasoning diversity. By evaluating branch value before full simulation completes, compute resources are released for higher-priority branches and canonical timeline reasoning. By measuring novelty contribution and penalising structurally similar branches, the engine prevents premature convergence. By recording all pruning decisions as immutable evidence artefacts, the engine provides full audit coverage of branch selection.


Claims

  1. A computer-implemented method for counterfactual branch pruning, the method comprising: (a) receiving a set of active counterfactual simulation branches from a Counterfactual Timeline Engine; (b) computing a branch value score for each active branch as a weighted sum comprising: divergence potential estimated from the first N simulation events, evidence alignment score, goal relevance score against the active GoalVector, and novelty contribution measured as informational distance from other active branches; (c) identifying branches whose branch value score falls below a configured pruning threshold and terminating those branches; (d) enforcing a configurable maximum active branch count by pruning the lowest-scoring branches when the count is exceeded; and (e) admitting an immutable pruning record to the AIEP evidence ledger for each pruned branch, comprising the branch identifier, pruning timestamp, final score, and reason code.

  2. The method of claim 1, wherein novelty contribution scoring penalises structurally similar branches to preserve branch diversity and prevent premature convergence.

  3. The method of claim 1, wherein branches whose evidence alignment dimension falls below a minimum threshold are eligible for priority pruning regardless of other score components.

  4. The method of claim 1, wherein the component weights of the branch value formula are adjustable via the active governance policy.

  5. The method of claim 1, wherein pruning records retained in the evidence ledger are accessible for retrospective analysis of which simulation branches were explored during a reasoning session.

  6. A Counterfactual Branch Pruning Engine comprising: one or more processors; memory storing a branch registry, branch value scorer, and pruning record buffer; wherein the processors are configured to execute the method of claim 1.

  7. A non-transitory computer-readable medium storing instructions that, when executed by a processor, implement the method of claim 1.


Abstract

A counterfactual branch pruning engine for evidence-bound artificial intelligence evaluates active simulation branches using a multi-criterion branch value score combining divergence potential, evidence alignment, goal relevance, and novelty contribution. Branches falling below a configured pruning threshold or exceeding a configurable maximum active branch count are terminated, with pruning records admitted to the AIEP evidence ledger. Novelty scoring preserves branch diversity to prevent premature convergence in multi-hypothesis counterfactual reasoning.

Dependencies