{
  "sources": [
    {
      "url": "https://api.imdnotdead.fun/artifacts/151e0b1b16f90a1384b823bc528d6d1407f7b4bbfcc7966c12119fe483bfd326",
      "quote": "\"code_sha256\": \"4bbf720ff34be09b441e84a7e0c1bf47cba036b5211c4118e44a597f941453db\""
    },
    {
      "url": "https://api.imdnotdead.fun/artifacts/40497298132dcc0ccc9f4c0672031c7eaae00ddcf8cf24983db989feeb3c5ca0",
      "quote": "\"python_version\": \"3.12.3\",\n  \"base_mean_edge\": 102.33197908899267,\n  \"score\": {\n    \"mean_edge\": 108.63974289615767,\n    \"retail_edge\": 136.2713209771645,\n    \"arb_edge\": -27.63157808101933,\n    \"simulations\": 600,\n    \"seed_start\": 1000,\n    \"failures\": 0\n  },"
    },
    {
      "url": "https://raw.githubusercontent.com/danrobinson/prediction-market-challenge/b244530ee2a6247b5f930830eeca9dd950da0e7e/orderbook_pm_challenge/engine.py",
      "quote": "                process.step()\n                probability = process.current_true_probability()\n\n                step_fills = []\n                step_fills.extend(market.execute_arbitrage(probability=probability, step=step))"
    },
    {
      "url": "https://raw.githubusercontent.com/danrobinson/prediction-market-challenge/b244530ee2a6247b5f930830eeca9dd950da0e7e/orderbook_pm_challenge/runner.py",
      "quote": "        spread_ticks=rng.randint(\n            variance.competitor_spread_ticks_min,\n            variance.competitor_spread_ticks_max,\n        ),"
    },
    {
      "url": "https://raw.githubusercontent.com/danrobinson/prediction-market-challenge/b244530ee2a6247b5f930830eeca9dd950da0e7e/orderbook_pm_challenge/market.py",
      "quote": "            edge = fill.quantity * (probability - price) if fill.side is Side.BUY else fill.quantity * (price - probability)"
    },
    {
      "url": "https://raw.githubusercontent.com/danrobinson/prediction-market-challenge/b244530ee2a6247b5f930830eeca9dd950da0e7e/orderbook_pm_challenge/types.py",
      "quote": "    `buy_filled_quantity` and `sell_filled_quantity` are the participant's\n    aggregate filled quantities from the previous step."
    },
    {
      "url": "https://raw.githubusercontent.com/danrobinson/prediction-market-challenge/b244530ee2a6247b5f930830eeca9dd950da0e7e/orderbook_pm_challenge/process.py",
      "quote": "        diffusion_move = self._rng.gauss(0.0, self.config.diffusion_sigma)\n        jump_count = _sample_poisson(self._rng, self.config.jump_intensity)"
    },
    {
      "url": "https://raw.githubusercontent.com/danrobinson/prediction-market-challenge/b244530ee2a6247b5f930830eeca9dd950da0e7e/orderbook_pm_challenge/config.py",
      "quote": "    n_steps: int = 2_000\n    initial_score: float = 0.0\n    diffusion_sigma: float = 0.02"
    },
    {
      "url": "https://raw.githubusercontent.com/danrobinson/prediction-market-challenge/b244530ee2a6247b5f930830eeca9dd950da0e7e/orderbook_pm_challenge/results.py",
      "quote": "    def mean_arb_edge(self) -> float:\n        successes = [result.arb_edge for result in self.simulation_results if not result.failed]\n        return sum(successes) / len(successes) if successes else 0.0"
    },
    {
      "url": "https://raw.githubusercontent.com/danrobinson/prediction-market-challenge/b244530ee2a6247b5f930830eeca9dd950da0e7e/orderbook_pm_challenge/loader.py",
      "quote": "    strategy_cls = getattr(module, \"Strategy\", None)\n    if strategy_cls is None:\n        raise AttributeError(f\"{path} does not define a Strategy class\")"
    },
    {
      "url": "https://raw.githubusercontent.com/danrobinson/prediction-market-challenge/b244530ee2a6247b5f930830eeca9dd950da0e7e/pyproject.toml",
      "quote": "requires-python = \">=3.10\"\ndependencies = []"
    },
    {
      "url": "https://raw.githubusercontent.com/danrobinson/prediction-market-challenge/b244530ee2a6247b5f930830eeca9dd950da0e7e/README.md",
      "quote": "This repository contains a local-first trading challenge built around a single\nFIFO limit order book for a binary `YES` contract."
    }
  ]
}