What discovery invariants prevent cold-start bias in federated agent networks?

**Date of Record:** 2026 October 27 **Scope:** Applies when a new agent joins a federated discovery network with no prior reputation, history, or peer connections, and must discover trustworthy peers or resources without being systematically deprioritized due to lack of history. Does not apply to established agents with history, or to strictly permissioned networks where cold-start is not possible.

Core Distinction

The separation between **reputation-weighted discovery** (ranking is dominated by peers with long history, ignoring new entrants) and **cold-start-aware discovery** (new entrants are given equal consideration through uncertainty quantification, explicit exploration, or stake-based trust). Relying solely on reputation creates the **Cold-Start Exclusion**: new agents can never bootstrap, because they are always ranked below established agents, even if their recommendations would be superior.

What Was Observed

In federated discovery architectures, failing to handle cold-start bias produces three primary failure modes:

  1. **Monopoly Lock-In:** Early agents dominate the network's trust graph, and no new agent can break in, even with superior resources.
  2. **Exploration Collapse:** The discovery algorithm always exploits existing high-reputation peers, never exploring new ones, causing the network to stagnate.
  3. **Sybil Resistance Overcorrection:** To prevent Sybils, the algorithm requires stake for participation, but this also prevents legitimate new agents from bootstrapping.

Recorded Elements

  1. **`cold_start_uncertainty_bonus`:** A bonus applied to new agents' rankings based on their uncertainty band, allowing exploration while capping their maximum influence until reputation accrues.
  2. **`stake_weighted_trust`:** For stake-based networks, the new agent's trust is initialized at a level proportional to their stake, but capped to prevent stake-only Sybil attacks.
  3. **`exploration_budget_ratio`:** The fraction of discovery slots reserved for cold-start agents, ensuring new entrants get exposure.
  4. **`cold_start_graduation_predicate`:** The exact criterion (e.g., N successful transactions) after which the agent graduates from cold-start status to full reputation weighting.

Condition of Validity

* **Applies when:** The discovery algorithm uses reputation-weighted ranking, new agents must be able to bootstrap, and the network must resist Sybil attacks simultaneously. * **Does not apply when:** The network is strictly permissioned (new agents must be invited), or the discovery algorithm does not depend on reputation.

Decision Boundary

  1. **Is the querying agent itself new (cold-start)?** If yes, its recommendations should be tagged as `NEW_AGENT` and weighted accordingly.
  2. **Is the discovered peer new (cold-start)?** If yes, apply the `cold_start_uncertainty_bonus` and reserve part of the `exploration_budget_ratio` for it.
  3. **Has the new agent met the `cold_start_graduation_predicate`?** If yes, promote to full reputation weighting. If no, keep the uncertainty bonus and exploration reserve active.
  4. **Conversely, when can a network skip cold-start handling?** Only when the network is strictly permissioned (no new agents), or the network's Sybil resistance is enforced by an external mechanism (e.g., identity verification) that makes cold-start irrelevant.

Operational Effect

  1. **Bootstrap Enablement:** Allows new agents to gain exposure and build reputation over time.
  2. **Exploration Preservation:** Prevents the network from converging on a small set of established agents, preserving diversity.
  3. **Sybil Resistance:** Caps new agents' influence while they build history, preventing stake-based or identity-based Sybil attacks.
from dataclasses import dataclass
from enum import Enum, auto
import hashlib
import json

class ColdStartVerdict(Enum):
    ESTABLISHED_AGENT = auto()
    COLD_START_AGENT_EXPLORE = auto()
    COLD_START_AGENT_EXCLUDED = auto()

@dataclass(frozen=True)
class AgentProfile:
    agent_id: str
    successful_transactions: int
    stake_amount: int
    uncertainty_band: float

@dataclass(frozen=True)
class ColdStartPolicy:
    graduation_threshold: int
    min_stake_for_inclusion: int
    exploration_budget_ratio: float

@dataclass(frozen=True)
class ColdStartManifest:
    verdict: ColdStartVerdict
    exploration_weight: float
    directive: str
    manifest_digest: str

class ColdStartDiscoveryGuard:
    @staticmethod
    def _hash(data: str) -> str:
        return hashlib.sha256(data.encode("utf-8")).hexdigest()

    @classmethod
    def evaluate_agent(
        cls, agent: AgentProfile, policy: ColdStartPolicy
    ) -> ColdStartManifest:
        
        # Gate 1: Established agent
        if agent.successful_transactions >= policy.graduation_threshold:
            digest = cls._hash(json.dumps({
                "agent": agent.agent_id,
                "transactions": str(agent.successful_transactions),
                "status": "ESTABLISHED"
            }, sort_keys=True))
            return ColdStartManifest(
                verdict=ColdStartVerdict.ESTABLISHED_AGENT,
                exploration_weight=0.0,
                directive="PROCEED: Agent is established with full reputation weighting.",
                manifest_digest=digest
            )

        # Gate 2: Insufficient stake
        if agent.stake_amount < policy.min_stake_for_inclusion:
            return ColdStartManifest(
                verdict=ColdStartVerdict.COLD_START_AGENT_EXCLUDED,
                exploration_weight=0.0,
                directive=f"HALT: Cold-start agent with insufficient stake ({agent.stake_amount} < {policy.min_stake_for_inclusion}).",
                manifest_digest=cls._hash(f"INSUFFICIENT_STAKE:{agent.agent_id}")
            )

        # Gate 3: Cold-start with exploration
        digest = cls._hash(json.dumps({
            "agent": agent.agent_id,
            "transactions": str(agent.successful_transactions),
            "stake": str(agent.stake_amount),
            "uncertainty": f"{agent.uncertainty_band:.3f}"
        }, sort_keys=True))
        
        return ColdStartManifest(
            verdict=ColdStartVerdict.COLD_START_AGENT_EXPLORE,
            exploration_weight=policy.exploration_budget_ratio,
            directive=f"PROCEED: Cold-start agent included with {policy.exploration_budget_ratio:.0%} exploration weight.",
            manifest_digest=digest
        )