19. Configuration

Constants are fixed by the specification. Configuration is per-agent and per-implementation. Both are normative — implementations MUST respect constants and SHOULD use the default configuration values unless the agent’s domain requires otherwise.

19.1 Protocol Constants

ConstantValueNotes
MAX_FRAME_SIZE1,048,576 bytesFrames exceeding this MUST be rejected
HANDSHAKE_TIMEOUT10,000 msInbound identification deadline
HEARTBEAT_INTERVAL5,000 msDefault; configurable per implementation
HEARTBEAT_TIMEOUT15,000 msDefault; configurable per implementation
STATE_SYNC_INTERVAL30,000 msDefault periodic re-broadcast
WAKE_COOLDOWN300,000 msDefault per-peer wake rate limit
PEER_RETENTION300 sStale peer eviction age
DNS-SD_SERVICE_TYPE_sym._tcpService type for Bonjour discovery
DNS-SD_DOMAINlocal.Discovery domain

19.2 Agent Profiles

Each agent type has a pre-built configuration. The profile determines which CMB fields matter most (αf weights), how long signals stay relevant for SVAF evaluation (freshness), and how long remixed CMBs are retained in local storage (retention). New agent types join the mesh by defining their profile — no protocol changes needed.

Freshness and retention are different: freshness controls SVAF temporal drift (how quickly incoming signals become “stale” for evaluation). Retention controls how long the agent’s own remixed CMBs are kept in local storage. Regulated domains (legal, finance, health) MUST set retention according to their compliance requirements.

ProfileBest forFreshnessRetentionNotes
musicMusic, ambience30min24hOld curations irrelevant. Mood changes fast.
codingCoding assistants, dev tools2h7dSession context fades. Weekly patterns useful.
fitnessFitness, health, movement3h30dSedentary patterns need weeks of history.
messagingChat, notifications, social1h7dConversation context is short-lived.
knowledgeNews feeds, research, digests24h30dNews is daily. Trends need monthly context.
legalLegal, compliance, contracts24hPer regulationSet by jurisdiction. May require years or indefinite.
healthHealth monitoring, clinical3hPer regulationClinical records: HIPAA 6yr, GDPR varies. Consult compliance.
financeFinance, trading, compliance2hPer regulationMiFID II: 5yr. SEC: 7yr. Set per jurisdiction.
uniformGeneral purpose, prototyping30min7dGood starting point. Adjust to your domain.

19.3 CAT7 Field Weights (αf)

Per-agent field weights control which CMB fields matter most for each agent type. Higher weight = this field has more influence on SVAF evaluation and remix relevance. The schema is fixed (7 fields). The weights are per-agent.

Agentfocissintmotcompermood
Coding21.51.511.210.8
Music10.80.80.80.81.22
Fitness1.51.511.5112
Knowledge21.51.510.51.50.3
Legal221.5121.50.5
Health1.5211.511.52
Finance221.51220.3

Regulated domains (legal, finance): issue and commitment always high — risks and obligations are non-negotiable. Human-facing domains (music, fitness, health): mood always high — affect drives the experience.Knowledge domains (coding, research): focus always high — subject matter is core.

Custom weights: derive from your domain using these patterns. Implementations SHOULD expose field weights as configuration, not hardcode them.

19.4 SVAF Drift Thresholds

SVAF computes a totalDrift score (0–1) for each incoming memory. Three zones determine acceptance:

ZoneDriftActionDefault
Redundantmax(δf) < TredundantDiscarded — no field carries novel content0.10
Alignedδtotal ≤ TalignedAccepted, full blending0.25
GuardedTaligned < δtotal ≤ TguardedAccepted, attenuated blending0.50
Rejectedδtotal > TguardedDiscarded — irrelevant domain

Defaults work for most agents. Override only with domain-specific reason: tighter thresholds for high-precision domains (legal, health), wider for exploratory domains (research, knowledge).

19.5 Mood vs Memory Thresholds

Mood and memory use different acceptance paths:

SignalGateDefaultWhy
CMB (cmb)SVAF per-field drift0.50 (selective)Full CMB acceptance — domain-specific
Mood fieldExtracted from rejected CMBsAlways deliveredAffect crosses all domain boundaries (Section 9.3)

19.6 Drift Formula

totalDrift = (1 - λ) × fieldDrift + λ × temporalDrift

fieldDrift    = Σ(α_f × δ_f) / Σ(α_f)
temporalDrift = 1 - exp(-age / τ_freshness)
λ             = temporalLambda (default 0.3 = 70% content, 30% time)

At default settings (temporalLambda: 0.3, freshnessSeconds: 1800):

Signal ageTemporal drift contribution
1 minute~0.01 — negligible
30 minutes~0.19 — noticeable
2 hours~0.29 — likely pushes over threshold