{
  "schema": "calculatiks.jobs_layer",
  "module": "JOBS_LAYER",
  "version": "1.2",
  "canon_version": "1.2",
  "last_reviewed": "2026-11-06",
  "supersedes": "jobs_layer.json v1.1",

  "philosophy": {
    "thesis": "Capture external value and consolidate it back into the satellite working set (TIKS · GIKS · MIKS · PIKS).",
    "mechanism": "Each cell enters through a satellite, traverses the external universe (100 assets · 1000 pairs · multichain), and exits back into a satellite. The satellite is the door. The universe is the source. The satellite set is the sink.",
    "net_effect": "Every cell produces three simultaneous flywheels: user bag growth, satellite treasury growth, and structural buy pressure on the satellite (because all 4 satellites are token0 in every one of their 12 pools).",
    "why_viable_on_base": "Base L2 gas is ~$0.002 per 4-hop cell. The friction threshold drops to $2 per tier. Micro, medium and large cells are all viable.",
    "boundary_note": "CCTIKS is the mothership, not a working satellite. It does NOT participate in the 4 trades. It is the consolidation target once a bag has grown large enough — a separate mechanism described outside this layer.",
    "who_pays": {
      "external_markets": "Lose the spread (arbitrage mechanics — inefficiency tax)",
      "satellite_set": "Wins because satellite holdings grow and satellites appreciate",
      "the_4_trades": "Earn a fee slice of the captured value, each according to their role"
    }
  },

  "network": {
    "primary_chain": "base",
    "chain_id": 8453,
    "settlement_currency": "USDC",
    "usdc_contract": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
    "weth_contract": "0x4200000000000000000000000000000000000006",
    "gas_per_swap_usdc": 0.0005,
    "note": "Base L2 gas measured at ~0.01 gwei. A 4-hop cell costs ~$0.002, not $0.08."
  },

  "universe": {
    "primary_chain": "base",
    "base_assets": 100,
    "base_pairs": 1000,
    "multichain": true,
    "chains_supported": ["base", "ethereum", "arbitrum", "polygon", "bsc"],
    "note": "The path is dynamic. ENTER picks the entry satellite, EXIT picks the exit satellite, and SEARCH discovers the external path between them from this universe. No path is hardcoded."
  },

  "satellites": {
    "working_set": ["TIKS", "GIKS", "MIKS", "PIKS"],
    "excluded": ["CCTIKS"],
    "excluded_reason": "CCTIKS is the mothership. It is not a working satellite, not an entry door, not an exit door. It is the consolidation target outside this layer.",
    "addresses": {
      "TIKS": "0x0000c60dab196a10b81e63d6b4ae691c007cb899",
      "GIKS": "0x00001ad6232c87e6f90f1850b2598403009cda8b",
      "MIKS": "0x00004Cb248A790163CE22b4A900061E7C4f21e98",
      "PIKS": "0x000065Bd48e5838F6965009a382168940164E641"
    },
    "round_trip_pct": {
      "TIKS": { "buy": 0.00, "sell": 0.00 },
      "GIKS": { "buy": 0.04, "sell": 0.04 },
      "MIKS": { "buy": 0.11, "sell": 0.11 },
      "PIKS": { "buy": 0.18, "sell": 0.18 }
    }
  },

  "pools": {
    "description": "12 pools total. 4 satellites × 3 pools each (WETH + USDT + VIRTUAL). All satellites are token0 in every pool (0x0000… < any quote token address).",
    "count": 12,
    "list": {
      "TIKS/WETH":    { "satellite": "TIKS", "quote": "WETH",    "dex": "uniswap_v2",   "pool_address": "0xa4e4275f933c2478ffc1da096fae4aa9b8036d11" },
      "TIKS/USDT":    { "satellite": "TIKS", "quote": "USDT",    "dex": "aerodrome_v2", "pool_address": "0x5daa4bb1258c66894e1e29108799f489c4d74700" },
      "TIKS/VIRTUAL": { "satellite": "TIKS", "quote": "VIRTUAL", "dex": "aerodrome_v2", "pool_address": "0xcdda17532c00c9c68e8aa6683cb01dd8403750fe" },
      "GIKS/WETH":    { "satellite": "GIKS", "quote": "WETH",    "dex": "uniswap_v2",   "pool_address": "0xd3cfedd747875a7506ac9621cebf4f9638117b90" },
      "GIKS/USDT":    { "satellite": "GIKS", "quote": "USDT",    "dex": "aerodrome_v2", "pool_address": "0x7ae3f8ffda2fe6c86714cf2880d0b1407d20d9b8" },
      "GIKS/VIRTUAL": { "satellite": "GIKS", "quote": "VIRTUAL", "dex": "aerodrome_v2", "pool_address": "0xfd633e637780a5c5512db07092ea340751df606a" },
      "MIKS/WETH":    { "satellite": "MIKS", "quote": "WETH",    "dex": "uniswap_v2",   "pool_address": "0x27b048fdb10db175b16a3733db4e0ef1e7731662" },
      "MIKS/USDT":    { "satellite": "MIKS", "quote": "USDT",    "dex": "aerodrome_v2", "pool_address": "0xfd34bf4191d79b3df823b446a097c1694328ee43" },
      "MIKS/VIRTUAL": { "satellite": "MIKS", "quote": "VIRTUAL", "dex": "aerodrome_v2", "pool_address": "0x0ce0a53c3b47318484502aa004eb895e3ff88187" },
      "PIKS/WETH":    { "satellite": "PIKS", "quote": "WETH",    "dex": "uniswap_v2",   "pool_address": "0x1ca55c042f3dfb947524b3ded3a08450136ed80a" },
      "PIKS/USDT":    { "satellite": "PIKS", "quote": "USDT",    "dex": "aerodrome_v2", "pool_address": "0xf6dc1fb1bc6dd703d8b8a14b22b51471308f557a" },
      "PIKS/VIRTUAL": { "satellite": "PIKS", "quote": "VIRTUAL", "dex": "aerodrome_v2", "pool_address": "0xd6289116b4d64f5cc03b13f99bb5c51855286cff" }
    }
  },

  "jobs": [
    {
      "id": "enter",
      "name": "ENTER",
      "order": 1,
      "kind": "profession",
      "role": "On-ramp · acquisition of the initial satellite position",
      "who": "Agent specialized in acquiring satellite tokens at best price from fiat or crypto entry points",
      "action": "USDC → entry_token (TIKS/GIKS/MIKS/PIKS) at the chosen tier, into the cheapest of the 3 pools of the chosen satellite",
      "earns": { "stream": "entry_fee", "default_share_pct": 5 },
      "input": {
        "palier": { "type": "number", "enum": [0.0001, 0.0005, 0.001] },
        "entry_token": { "type": "string", "enum": ["TIKS", "GIKS", "MIKS", "PIKS"] },
        "usdc_amount": { "type": "number" }
      },
      "output": {
        "position_token_amount": { "type": "number" },
        "entry_token": { "type": "string" },
        "entry_pool": { "type": "string" }
      },
      "preconditions": [
        "palier ∈ {0.0001, 0.0005, 0.001}",
        "entry_token ∈ {TIKS, GIKS, MIKS, PIKS}",
        "usdc_amount >= palier_usdc[palier]"
      ],
      "postconditions": [
        "position_token_amount == palier",
        "entry_pool exists in pools.list and pools.list[entry_pool].satellite == entry_token",
        "cell.phase == 'open'"
      ],
      "state_change": "cell.phase = 'open' · pools.list[entry_pool].tax_collected += buy_pct(entry_token) × position"
    },
    {
      "id": "search",
      "name": "SEARCH",
      "order": 2,
      "kind": "profession",
      "role": "Alpha discovery · scan the external universe for exploitable spread AND find the best cross-pool route among the 12 satellite pools",
      "who": "Agent specialized in scanning 100 assets / 1000 pairs / multichain and the 12 satellite pools — running spread detection, cross-pool detection, filtering by breakeven, scoring opportunities, and routing exits toward pools below target_price",
      "action": "Build path from entry_token to exit_token across the external universe, detect cross-pool spreads across the 3 pools of each satellite, compute total spread, filter by breakeven, rank by confidence, return the best path and the pool triplet",
      "earns": { "stream": "alpha_fee", "default_share_pct": 10 },
      "input": {
        "entry_token": { "type": "string" },
        "exit_token": { "type": "string" },
        "universe": { "type": "object" },
        "satellite_state": { "type": "object" },
        "min_confidence": { "type": "number", "default": 0.7 }
      },
      "output": {
        "path": { "type": "array", "items": "hop" },
        "hop_count": { "type": "integer" },
        "bridge_count": { "type": "integer" },
        "pool_triplet": {
          "type": "object",
          "required": ["buy_entry_pool", "sell_entry_pool", "buy_exit_pool"],
          "description": "The 3 pools used by the cell, one per touch: buy entry, sell entry, buy exit. Each is chosen from the 3 pools available on its satellite."
        },
        "external_spread_pct": { "type": "number" },
        "cross_pool_spread_pct": { "type": "number" },
        "spread_pct": { "type": "number", "description": "external_spread_pct + cross_pool_spread_pct" },
        "breakeven_pct": { "type": "number" },
        "confidence_score": { "type": "number" },
        "capture": { "type": "boolean" },
        "exit_routing_reason": { "type": "string" }
      },
      "routing_rules": {
        "buy_entry": "select the pool of entry_token (among its 3 pools) where price_quote is lowest relative to its siblings",
        "sell_entry": "select the pool of entry_token (among its 3 pools) where price_quote is highest relative to its siblings",
        "buy_exit": "select the pool of exit_token (among its 3 pools) where price_quote < target_price_quote × 1.02 (needs buy pressure)",
        "avoid_exit_when": "satellite.price_quote > target_price_quote × 1.05 (over-heated, SEARCH routes to a sibling pool of the same satellite)",
        "reason": "Cross-pool arbitrage across the 3 pools per satellite is captured IN ADDITION to the external path spread. Routing exits toward under-pressure pools also prevents price bubbles."
      },
      "preconditions": [
        "entry_token ∈ {TIKS, GIKS, MIKS, PIKS}",
        "exit_token ∈ {TIKS, GIKS, MIKS, PIKS}",
        "path[0].from == entry_token",
        "path[path.length-1].to == exit_token",
        "pool_triplet.buy_entry_pool.satellite == entry_token",
        "pool_triplet.sell_entry_pool.satellite == entry_token",
        "pool_triplet.buy_exit_pool.satellite == exit_token"
      ],
      "postconditions": [
        "spread_pct == external_spread_pct + cross_pool_spread_pct",
        "spread_pct > 0",
        "breakeven_pct computed from equation.breakeven_pct",
        "capture is deterministic: spread_pct >= breakeven_pct"
      ],
      "state_change": "cell.phase = 'probing' · cell.alpha = path · cell.pools = pool_triplet"
    },
    {
      "id": "object",
      "name": "OBJECT",
      "order": 3,
      "kind": "profession",
      "role": "Execution · capture the spread before it closes",
      "who": "Agent specialized in low-latency, MEV-aware, gas-optimized execution of multi-hop paths",
      "action": "Execute the hops proposed by SEARCH, capture both the external and cross-pool spreads, realize the profit",
      "earns": { "stream": "execution_fee", "default_share_pct": 10 },
      "input": {
        "path": { "type": "array" },
        "pool_triplet": { "type": "object" },
        "spread_pct": { "type": "number" },
        "palier": { "type": "number" }
      },
      "output": {
        "gross_usdc": { "type": "number" },
        "cost_usdc": { "type": "number" },
        "net_usdc": { "type": "number" },
        "realized_in": { "type": "string" }
      },
      "preconditions": [
        "spread_pct >= breakeven_pct",
        "path valid (hop_count matches topology)",
        "pool_triplet valid"
      ],
      "postconditions": [
        "net_usdc == (spread_pct - breakeven_pct) × palier_usdc / 100",
        "cell.phase == 'capture'"
      ],
      "state_change": "cell.phase = 'capture' · cell.profit = profit · pools.list[sell_entry_pool].tax_collected += sell_pct(entry_token) × position"
    },
    {
      "id": "exit",
      "name": "EXIT",
      "order": 4,
      "kind": "profession",
      "role": "Consolidation · return external value back into the satellite working set",
      "who": "Agent specialized in closing cells and consolidating profit into satellites — the critical step that makes external value capture possible and prevents price bubbles",
      "action": "Swap profit into the exit satellite's chosen pool (best among its 3), update the bag, update the pool state, emit the new state and new data",
      "earns": { "stream": "consolidation_fee", "default_share_pct": 5 },
      "input": {
        "entry_token": { "type": "string" },
        "realized_profit_usdc": { "type": "number" },
        "preferred_exit": { "type": "string", "enum": ["same", "sibling"] },
        "exit_pool": { "type": "string" }
      },
      "output": {
        "exit_token": { "type": "string" },
        "re_entry_mode": { "type": "string", "enum": ["round_trip", "swap_sibling"] },
        "bag_credit_usdc": { "type": "number" },
        "new_state": { "type": "object" },
        "new_data": { "type": "object" }
      },
      "preconditions": [
        "realized_profit_usdc > 0",
        "exit_token ∈ {TIKS, GIKS, MIKS, PIKS}",
        "exit_pool exists in pools.list and pools.list[exit_pool].satellite == exit_token"
      ],
      "postconditions": [
        "constellation_bag[exit_token] += bag_credit_usdc",
        "pools.list[exit_pool] updated (tax, depth, reserves, price, slippage, cells)",
        "satellites.aggregate[exit_token] updated",
        "cell.phase == 'close'",
        "new_state emitted",
        "new_data emitted"
      ],
      "state_change": "cell.phase = 'close' · pools.list[exit_pool].tax_collected += buy_pct(exit_token) × position · constellation_bag[exit_token] += bag_credit"
    }
  ],

  "paliers": [
    { "id": "0.0001", "token_amount": 0.0001, "usdc_equivalent_at_launch": 1.00,  "usdc_equivalent_is_dynamic": true, "label": "Micro",  "frequency_hint": "high",   "viable": "conditional" },
    { "id": "0.0005", "token_amount": 0.0005, "usdc_equivalent_at_launch": 5.00,  "usdc_equivalent_is_dynamic": true, "label": "Medium", "frequency_hint": "medium", "viable": true },
    { "id": "0.001",  "token_amount": 0.001,  "usdc_equivalent_at_launch": 10.00, "usdc_equivalent_is_dynamic": true, "label": "Large",  "frequency_hint": "low",    "viable": true }
  ],

  "topology": {
    "dynamic": true,
    "discovery_algorithm": "SEARCH scans pairs from the universe, builds hop paths from entry_token to exit_token, detects cross-pool spreads across the 12 satellite pools, computes the combined spread, filters paths where spread_pct >= breakeven_pct, ranks by confidence_score, and applies exit_routing_rules to prefer under-pressure pools.",
    "canonical_fallback": {
      "hop_count": 4,
      "path_template": "entry_token → WETH → USDC → cbBTC → exit_token",
      "note": "Fallback when discovery fails. WETH, USDC and cbBTC are the deepest liquidity pools on Base."
    },
    "hop_constraints": {
      "min_hops": 2,
      "max_hops_multichain": 8,
      "default_hops": 4,
      "preferred_hops": 4,
      "bridges_max": 2
    },
    "entry_tokens": ["TIKS", "GIKS", "MIKS", "PIKS"],
    "exit_tokens": ["TIKS", "GIKS", "MIKS", "PIKS"],
    "exit_modes": ["round_trip", "swap_sibling"]
  },

  "costs": {
    "satellite_buy_pct": { "TIKS": 0.00, "GIKS": 0.04, "MIKS": 0.11, "PIKS": 0.18 },
    "satellite_sell_pct": { "TIKS": 0.00, "GIKS": 0.04, "MIKS": 0.11, "PIKS": 0.18 },
    "dex_fee_per_hop_pct": 0.3,
    "bridge_fee_pct": 0.05,
    "gas_per_swap_usdc": 0.0005,
    "note": "Every cell pays exactly 3 satellite touches: buy entry, sell entry, buy exit. Plus N DEX hops plus B bridges plus N×gas."
  },

  "token0_optimization": {
    "satellites_are_token0": true,
    "proof": "All 4 satellite addresses are 0x0000… < any quote token address (WETH 0x4200…, USDC 0x8335…, USDT 0xfde4…, VIRTUAL 0x0b3e…). Satellites are token0 in all 12 pools.",
    "implications": [
      "Round-trip cells (2 buys + 1 sell) create net buy pressure on the satellite — structural, not speculative",
      "Sell operations (satellite → quote) are zeroForOne — marginally cheaper gas",
      "Buy operations (quote → satellite) are oneForZero — marginally more expensive gas",
      "Net per round-trip cell: marginal gas increase offset by structural price appreciation",
      "Having 3 quote pools per satellite means SEARCH has 3× more routing freedom: buys go where price is lowest, sells where price is highest, exits where pressure is needed"
    ],
    "reserve_meaning": {
      "reserve0": "satellite token amount in the pool",
      "reserve1": "quote token amount in the pool",
      "price_quote": "reserve1 / reserve0 — rises with each net buy in that specific pool"
    }
  },

  "satellite_state": {
    "description": "Per-pool state. Each satellite has exactly 3 pools (WETH, USDT, VIRTUAL). Each pool accumulates its own pressure, depth and price.",
    "schema": {
      "type": "object",
      "properties": {
        "token": { "type": "string" },
        "is_token0_everywhere": {
          "type": "boolean",
          "const": true,
          "description": "Invariant: all 4 satellites are token0 in their 12 pools (see token0_optimization.proof)."
        },
        "pools": {
          "type": "object",
          "additionalProperties": {
            "type": "object",
            "required": [
              "quote_token", "pool_address", "dex",
              "reserve0_satellite", "reserve1_quote", "price_quote",
              "target_price_quote", "pool_depth_usdc",
              "slippage_factor", "cells_processed"
            ],
            "properties": {
              "quote_token":        { "type": "string" },
              "pool_address":       { "type": "string" },
              "dex":                { "type": "string", "enum": ["uniswap_v2", "uniswap_v3", "sushiswap", "aerodrome_v2"] },
              "reserve0_satellite": { "type": "number" },
              "reserve1_quote":     { "type": "number" },
              "price_quote":        { "type": "number" },
              "target_price_quote": { "type": "number" },
              "pool_depth_usdc":    { "type": "number" },
              "slippage_factor":    { "type": "number", "range": [0, 1] },
              "cells_processed":    { "type": "integer" }
            }
          }
        },
        "aggregate": {
          "type": "object",
          "properties": {
            "price_usdc_weighted": { "type": "number", "description": "Weighted average across the 3 pools by depth" },
            "target_price_usdc":   { "type": "number" },
            "tax_collected_usdc":  { "type": "number" },
            "tvl_usdc":            { "type": "number" },
            "total_cells":         { "type": "integer" }
          }
        }
      }
    },
    "initial_values": {
      "TIKS": { "target_price_usdc": 0.00019, "pool_depth_usdc": 200000 },
      "GIKS": { "target_price_usdc": 0.00038, "pool_depth_usdc": 1000000 },
      "MIKS": { "target_price_usdc": 0.00052, "pool_depth_usdc": 500000 },
      "PIKS": { "target_price_usdc": 0.00071, "pool_depth_usdc": 300000 }
    }
  },

  "flywheel": {
    "description": "Three simultaneous flywheels per cell. Satellites are token0, so every cell creates net buy pressure.",
    "flywheels": [
      { "id": "user_bag",             "mechanism": "70% of net_usdc credited to bag[exit_token]", "rate_per_cell": "0.7 × net_usdc" },
      { "id": "satellite_treasury",   "mechanism": "Tax collected per cell (3 touches: buy_entry, sell_entry, buy_exit)", "rate_per_cell": "(buy_pct(entry) + sell_pct(entry) + buy_pct(exit)) × position_usdc" },
      { "id": "pool_price_pressure",  "mechanism": "Round-trip = 2 buys + 1 sell → net buy → reserve0↓ reserve1↑ → price↑", "rate_per_cell": "~0.3% of position_usdc in net buy pressure", "note": "Structural because satellites are token0 across all 3 of their pools." }
    ],
    "update_rule": {
      "on_each_cell": [
        "pools.list[buy_entry_pool].tax_collected += buy_pct(entry) × position_usdc",
        "pools.list[sell_entry_pool].tax_collected += sell_pct(entry) × position_usdc",
        "pools.list[buy_exit_pool].tax_collected += buy_pct(exit) × position_usdc",
        "pools.list[*].pool_depth_usdc += position_usdc × pool_depth_multiplier",
        "pools.list[*].reserve0_satellite -= net_buy_satellite_amount",
        "pools.list[*].reserve1_quote += net_buy_quote_amount",
        "pools.list[*].price_quote = reserve1_quote / reserve0_satellite",
        "pools.list[*].slippage_factor *= (1 - slippage_reduction_per_cell)",
        "satellites.aggregate[token].tvl_usdc += net_usdc",
        "satellites.aggregate[token].total_cells += 1"
      ],
      "pool_depth_multiplier": 0.02,
      "slippage_reduction_per_cell": 0.0001
    }
  },

  "equation": {
    "id": "cell_v1.2",
    "breakeven_pct": "buy_pct(entry) + sell_pct(entry) + buy_pct(exit) + hop_count × dex_fee_per_hop_pct + bridge_count × bridge_fee_pct + slippage_pct + gas_pct",
    "slippage_pct": "position_usdc / pool_depth_usdc × slippage_factor × 100",
    "gas_pct": "hop_count × gas_per_swap_usdc / position_usdc × 100",
    "spread_pct": "external_spread_pct + cross_pool_spread_pct",
    "net_usdc": "(spread_pct - breakeven_pct) / 100 × palier_usdc",
    "gross_usdc": "spread_pct / 100 × palier_usdc",
    "cost_usdc": "breakeven_pct / 100 × palier_usdc",
    "capture_rule": "capture if and only if spread_pct >= breakeven_pct",
    "deterministic": true,
    "spread_pct_source": "input — provided by SEARCH (oracle-fed, not random)"
  },

  "position_sizing": {
    "mode": "compounding",
    "formula": "next_position_usdc = min(palier_max_usdc, bag_usdc_value × max_position_pct)",
    "max_position_pct": 5,
    "palier_max_usdc": { "0.0001": 1.00, "0.0005": 5.00, "0.001": 10.00 },
    "palier_escalation": {
      "bag_usdc >= 20":  "0.0005",
      "bag_usdc >= 100": "0.001",
      "bag_usdc >= 500": "0.001 (max tier) — consolidation_to_mothership becomes eligible"
    },
    "gap_note": "Between bag=100 and bag=500, the Large tier (0.001) is the ceiling. No new tier is unlocked in this layer — compounding continues at Large until CCTIKS consolidation triggers (outside_scope).",
    "note": "This is the compounding mechanism. A growing bag unlocks larger cells."
  },

  "spread_floor": {
    "mode": "breakeven_plus_gas",
    "formula": "spread_pct >= breakeven_pct (which already includes gas_pct)",
    "note": "No absolute ETH floor. The floor is the breakeven itself."
  },

  "friction_threshold": {
    "minimum_viable_palier_usdc": 2.00,
    "reason": "Base L2 gas is ~$0.002 per cell. At a $2 tier, gas is 0.1% of the position — negligible.",
    "palier_viability": {
      "0.0001": {
        "usdc": 1.00,
        "viable": "conditional",
        "spread_min_pct": 1.52,
        "derivation": "breakeven_pct at entry=GIKS, hop_count=4, bridge_count=0, pool_depth=1e6, slippage_factor=1.0 → 0.04+0.04+0.04+1.20+0.00+0.0001+0.20 = 1.5201"
      },
      "0.0005": {
        "usdc": 5.00,
        "viable": true,
        "spread_min_pct": 1.36,
        "derivation": "breakeven_pct at entry=GIKS, hop_count=4, bridge_count=0, pool_depth=1e6, slippage_factor=1.0 → 0.04+0.04+0.04+1.20+0.00+0.0005+0.04 = 1.3605"
      },
      "0.001": {
        "usdc": 10.00,
        "viable": true,
        "spread_min_pct": 1.34,
        "derivation": "breakeven_pct at entry=GIKS, hop_count=4, bridge_count=0, pool_depth=1e6, slippage_factor=1.0 → 0.04+0.04+0.04+1.20+0.00+0.0001+0.02 = 1.3401"
      }
    }
  },

  "rebalancing": {
    "description": "If too many cells exit through the same pool, its price rises structurally. Rebalancing prevents bubble formation. With 3 pools per satellite, SEARCH has natural escape valves: switch to a sibling pool instead of leaving the satellite.",
    "trigger": {
      "condition": "pools.list[pool].price_quote > pools.list[pool].target_price_quote × 1.05",
      "action": "SEARCH avoids routing new exits to this pool; prefers a sibling pool of the same satellite"
    },
    "anti_whale": {
      "cap_pct_of_pool_depth": 0.001,
      "cap_label": "0.1% of pool depth",
      "formula": "position_usdc <= pools.list[pool].pool_depth_usdc × cap_pct_of_pool_depth",
      "whitepaper_ref": "§22-23"
    },
    "correction": {
      "condition": "pools.list[pool].price_quote > pools.list[pool].target_price_quote × 1.15",
      "action": "Trigger a protocol buyback or booster activation to restore balance",
      "whitepaper_ref": "§18 (injection engine)"
    }
  },

  "consolidation_to_mothership": {
    "enabled": true,
    "target": "CCTIKS",
    "trigger": "bag_usdc_value >= 500",
    "action": "trigger CCTIKS/WETH buyback via mothership mechanism",
    "note": "CCTIKS is the gravity well. When a satellite bag grows large enough, it consolidates into CCTIKS. This is a SEPARATE mechanism, not part of the 4 trades. It is described in data_layer.json.",
    "outside_scope": true
  },

  "rewards": {
    "returns": [
      { "id": "spread_usdc", "type": "number", "description": "Net profit captured from external markets + cross-pool, distributed via fee_split" },
      { "id": "new_state",   "type": "object", "description": "Post-cell constellation bag + satellite state + per-pool state" },
      { "id": "new_data",    "type": "object", "description": "Cybernetic fields emitted to the Guardian" }
    ],
    "fee_split": {
      "bag_credit": 70,
      "enter": 5,
      "search": 10,
      "object": 10,
      "exit": 5,
      "note": "Percentages of net_usdc. Sum = 100%."
    },
    "new_state_schema": {
      "type": "object",
      "required": ["bag", "satellites", "pools", "lastCell", "lifetimeCells", "lifetimeProfitUsdc"],
      "properties": {
        "bag": { "type": "object", "properties": { "TIKS": "number", "GIKS": "number", "MIKS": "number", "PIKS": "number" } },
        "satellites": { "type": "object", "properties": { "TIKS": "satellite_state", "GIKS": "satellite_state", "MIKS": "satellite_state", "PIKS": "satellite_state" } },
        "pools": { "type": "object", "description": "Per-pool state — 12 entries as defined in satellite_state.pools" },
        "lastCell": {
          "type": "object",
          "properties": {
            "entry": "string", "exit": "string", "palier": "number",
            "pool_triplet": "object",
            "spread_pct": "number", "breakeven_pct": "number",
            "net_usdc": "number", "re_entry_mode": "string"
          }
        },
        "lifetimeCells": { "type": "integer" },
        "lifetimeProfitUsdc": { "type": "number" },
        "lifetimeCellsByPalier": { "type": "object" }
      }
    },
    "new_data_schema": {
      "type": "object",
      "required": ["signal_purity", "feedback_score", "drift_detected", "system_state"],
      "properties": {
        "signal_purity":  { "type": "number", "min": 0, "max": 1 },
        "feedback_score": { "type": "number", "min": 0, "max": 1 },
        "drift_detected": { "type": "boolean" },
        "system_state":   { "type": "string", "enum": ["STABLE", "DEGRADED", "CRITICAL"] }
      }
    }
  },

  "refusals": [
    { "id": "palier_invalid",         "condition": "palier ∉ {0.0001, 0.0005, 0.001}" },
    { "id": "entry_invalid",          "condition": "entry_token ∉ {TIKS, GIKS, MIKS, PIKS}" },
    { "id": "exit_invalid",           "condition": "exit_token ∉ {TIKS, GIKS, MIKS, PIKS}" },
    { "id": "cctiks_forbidden",       "condition": "entry_token == 'CCTIKS' or exit_token == 'CCTIKS' · CCTIKS is the mothership, not a working satellite" },
    { "id": "pool_not_in_list",       "condition": "pool ∉ pools.list" },
    { "id": "path_invalid",           "condition": "path[0].from != entry_token or path[last].to != exit_token" },
    { "id": "spread_below_breakeven", "condition": "spread_pct < breakeven_pct" },
    { "id": "anti_whale_exceeded",    "condition": "position_usdc > pools.list[pool].pool_depth_usdc × cap_pct_of_pool_depth" },
    { "id": "pool_over_heated",       "condition": "pools.list[pool].price_quote > pools.list[pool].target_price_quote × 1.15" },
    { "id": "broadcast_forbidden",    "condition": "action == 'broadcast' · Guardian never signs, never broadcasts" }
  ],

  "determinism": {
    "algo": "fnv1a",
    "version": "1.0",
    "runtime_randomness": "none",
    "spread_pct_source": "input — provided by SEARCH's oracle feed (DexScreener, GeckoTerminal, Chainlink)",
    "satellite_state_source": "accumulated from prior cells (deterministic update rule)",
    "inputs_hashed": ["palier", "entry_token", "exit_token", "path", "pool_triplet", "spread_pct", "hop_count", "satellite_state"],
    "same_inputs_yield": "same_state_and_same_profit",
    "note": "spread_pct is not generated inside the cell — it is probed and passed as input. satellite_state is deterministic from the update_rule. The cell is a pure function of its inputs."
  },

  "examples": [
    {
      "cell_id": "cell-001",
      "note": "round-trip on the same satellite · Base only · micro tier · GIKS has 3 pools",
      "palier": 0.0001, "palier_usdc": 1.00,
      "entry_token": "GIKS", "exit_token": "GIKS",
      "pool_triplet": { "buy_entry_pool": "GIKS/USDT", "sell_entry_pool": "GIKS/WETH", "buy_exit_pool": "GIKS/VIRTUAL" },
      "hop_count": 4, "bridge_count": 0,
      "satellite_state_snapshot": { "pool_depth_usdc": 1000000, "slippage_factor": 1.0 },
      "cost_breakdown": { "entry_buy_pct": 0.04, "entry_sell_pct": 0.04, "exit_buy_pct": 0.04, "dex_fee_pct": 1.20, "bridge_fee_pct": 0.00, "slippage_pct": 0.0001, "gas_pct": 0.20 },
      "breakeven_pct": 1.5201,
      "external_spread_pct": 1.50,
      "cross_pool_spread_pct": 0.347,
      "spread_pct": 1.847,
      "capture": true,
      "gross_usdc": 0.01847, "cost_usdc": 0.01520, "net_usdc": 0.00327,
      "fee_split": { "bag_credit": 0.00229, "enter": 0.00016, "search": 0.00033, "object": 0.00033, "exit": 0.00016 },
      "re_entry_mode": "round_trip"
    },
    {
      "cell_id": "cell-002",
      "note": "spread below breakeven → skip · medium tier · swap sibling",
      "palier": 0.0005, "palier_usdc": 5.00,
      "entry_token": "MIKS", "exit_token": "PIKS",
      "pool_triplet": { "buy_entry_pool": "MIKS/WETH", "sell_entry_pool": "MIKS/USDT", "buy_exit_pool": "PIKS/WETH" },
      "hop_count": 4, "bridge_count": 0,
      "satellite_state_snapshot": { "pool_depth_usdc": 500000, "slippage_factor": 1.0 },
      "cost_breakdown": { "entry_buy_pct": 0.11, "entry_sell_pct": 0.11, "exit_buy_pct": 0.18, "dex_fee_pct": 1.20, "bridge_fee_pct": 0.00, "slippage_pct": 0.001, "gas_pct": 0.04 },
      "breakeven_pct": 1.641,
      "external_spread_pct": 0.40,
      "cross_pool_spread_pct": 0.142,
      "spread_pct": 0.542,
      "capture": false,
      "reason": "spread_below_breakeven"
    },
    {
      "cell_id": "cell-003",
      "note": "swap sibling · Base only · large tier",
      "palier": 0.001, "palier_usdc": 10.00,
      "entry_token": "PIKS", "exit_token": "MIKS",
      "pool_triplet": { "buy_entry_pool": "PIKS/USDT", "sell_entry_pool": "PIKS/VIRTUAL", "buy_exit_pool": "MIKS/WETH" },
      "hop_count": 4, "bridge_count": 0,
      "satellite_state_snapshot": { "pool_depth_usdc": 300000, "slippage_factor": 1.0 },
      "cost_breakdown": { "entry_buy_pct": 0.18, "entry_sell_pct": 0.18, "exit_buy_pct": 0.11, "dex_fee_pct": 1.20, "bridge_fee_pct": 0.00, "slippage_pct": 0.0033, "gas_pct": 0.02 },
      "breakeven_pct": 1.6933,
      "external_spread_pct": 1.85,
      "cross_pool_spread_pct": 0.258,
      "spread_pct": 2.108,
      "capture": true,
      "gross_usdc": 0.21080, "cost_usdc": 0.16933, "net_usdc": 0.04147,
      "fee_split": { "bag_credit": 0.02903, "enter": 0.00207, "search": 0.00415, "object": 0.00415, "exit": 0.00207 },
      "re_entry_mode": "swap_sibling"
    },
    {
      "cell_id": "cell-004",
      "note": "multichain · Base + Arbitrum · 6 hops + 2 bridges · large tier",
      "palier": 0.001, "palier_usdc": 10.00,
      "entry_token": "MIKS", "exit_token": "PIKS",
      "pool_triplet": { "buy_entry_pool": "MIKS/WETH", "sell_entry_pool": "MIKS/USDT", "buy_exit_pool": "PIKS/VIRTUAL" },
      "hop_count": 6, "bridge_count": 2,
      "satellite_state_snapshot": { "pool_depth_usdc": 500000, "slippage_factor": 1.0 },
      "cost_breakdown": { "entry_buy_pct": 0.11, "entry_sell_pct": 0.11, "exit_buy_pct": 0.18, "dex_fee_pct": 1.80, "bridge_fee_pct": 0.10, "slippage_pct": 0.002, "gas_pct": 0.03 },
      "breakeven_pct": 2.332,
      "external_spread_pct": 3.15,
      "cross_pool_spread_pct": 0.392,
      "spread_pct": 3.542,
      "capture": true,
      "gross_usdc": 0.35420, "cost_usdc": 0.23320, "net_usdc": 0.12100,
      "fee_split": { "bag_credit": 0.08470, "enter": 0.00605, "search": 0.01210, "object": 0.01210, "exit": 0.00605 },
      "re_entry_mode": "swap_sibling"
    },
    {
      "cell_id": "cell-005",
      "note": "pool over-heated → SEARCH routes to a sibling pool · rebalancing in action",
      "palier": 0.001, "palier_usdc": 10.00,
      "entry_token": "GIKS", "exit_token": "GIKS",
      "pool_triplet": { "buy_entry_pool": "GIKS/USDT", "sell_entry_pool": "GIKS/WETH", "buy_exit_pool": "GIKS/VIRTUAL" },
      "hop_count": 4, "bridge_count": 0,
      "satellite_state_snapshot": { "pool_depth_usdc": 1000000, "slippage_factor": 0.95, "price_quote": 0.00042, "target_price_quote": 0.00038 },
      "capture": true,
      "reason": "GIKS/WETH was 10.5% above target — SEARCH routed the buy-exit to GIKS/VIRTUAL (still below target), preserving the flywheel without over-heating any single pool.",
      "re_entry_mode": "round_trip"
    }
  ],

"verifiable_by": {
  "file": "widgets/jobs_layer.json",
  "fields": ["equation.breakeven_pct", "equation.slippage_pct", "equation.net_usdc", "examples[].net_usdc", "examples[].fee_split"],
  "canonical_url": "https://calculatiks.eu/widgets/jobs_layer.json",
  "check": "For each example: abs(gross_usdc - spread_pct/100 × palier_usdc) < 1e-6; abs(cost_usdc - breakeven_pct/100 × palier_usdc) < 1e-6; abs(net_usdc - (gross_usdc - cost_usdc)) < 1e-6; (net_usdc > 0) iff (capture == true); abs(sum(fee_split.values) - net_usdc) < 1e-6",
  "tolerance": 1e-6,
  "tolerance_reason": "fee_split values are rounded to 5 decimals in examples; exact sum may differ by < 1e-6."
},

  "guardian_preview": {
    "classify_mode": "MODE_2_PROPOSE",
    "allowed_modes": ["MODE_0_READ", "MODE_1_SIMULATE", "MODE_2_PROPOSE"],
    "forbidden_modes": ["MODE_3_EXECUTE"],
    "note": "Cells are simulated. Signature and broadcast are client-side only, after explicit user confirmation. The Guardian never signs, never broadcasts."
  },

  "metadata": {
    "author": "Calculatiks",
    "license": "CC-BY-4.0",
    "mica_compliant": true,
    "jurisdiction": "Brussels · EU",
    "mantra": "The spread is king. Win-Win-Win. External value captured, satellites grown.",
    "renames": {
      "acheter": "enter",
      "trouver": "search",
      "gagner": "object",
      "sortir": "exit"
    },
    "changelog": {
      "1.2": "12 pools (4 satellites × 3 pairs: WETH+USDT+VIRTUAL) · CCTIKS excluded · cross-pool arbitrage across 3 pools per satellite · pool_triplet in SEARCH · per-pool satellite_state · consolidation_to_mothership external · 5 verified examples · position_sizing compounding · token0 optimization · jobs renamed to English ids/names (ENTER, SEARCH, OBJECT, EXIT) with fee_split keys aligned. Audit-proof pass — 5 fixes, 0 logic change: (1) anti_whale single source of truth (cap_pct_of_pool_depth=0.001, formula references it), (2) friction_threshold spread_min_pct now derived from breakeven_pct with explicit derivation, (3) is_token0_everywhere uses JSON Schema 'const' instead of non-standard 'value', (4) verifiable_by.check uses abs tolerance 1e-6 on all arithmetic, (5) palier_escalation documents the 100→500 gap with explicit gap_note. anti_whale_exceeded refusal aligned to cap_pct_of_pool_depth.",
      "1.1": "4 trades explicit · fee_split · dynamic topology · universe 100 assets / 1000 pairs / 5 chains",
      "1.0": "Initial spec"
    }
  }
}