Skip to content

Proposal: optional shadow risk preflight before live CLOB submission #5

Description

@MM-sheng

I maintain 404.directory and am looking for a small number of independently operated Polymarket Agents for a seven-day, privacy-safe pilot. This repository is a strong fit because src/trading/executor.py has a concrete live order boundary and app.py still has the numeric market ID, action, and intended size immediately before execute_signal.

Proposed shape:

  1. Default off; no behavior change for existing users.
  2. When DIRECTORY_404_RISK_MODE=shadow, call the public risk preflight with market ID, BUY YES/NO, notional, unattended mode, and caller-observed eligibility immediately before place_market_order.
  3. In shadow mode the order path always continues, including if 404.directory is unavailable.
  4. Persist one random local Agent ID; never transmit wallet data, signing material, prompts, strategy logic, user identity, or order payloads.
  5. Report only a bounded outcome after execution.

The check covers settlement wording, time boundaries, public order-book liquidity/spread, and execution context. It does not forecast, recommend a side, sign, or place an order. Public Python 3.11+ wheel and source are here: https://github.com/MM-sheng/404-directory/releases/tag/v0.10.1

If this shape is welcome, I can submit a focused, tested PR that keeps it optional and starts only in shadow mode. Success for the pilot means normal real workflow calls on more than one UTC day, not synthetic traffic. If it is out of scope, please close this and I will not repeat the request.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions