Commit Graph

483 Commits

Author SHA1 Message Date
copybot[bot] 0b519027e5 copybot: live paper feed [skip ci] 2026-07-06 06:50:06 +00:00
copybot[bot] 558d43f28c copybot: live paper feed [skip ci] 2026-07-06 06:47:58 +00:00
copybot[bot] 8905d77e6d copybot: live paper feed [skip ci] 2026-07-06 06:45:53 +00:00
copybot[bot] 946a443789 copybot: live paper feed [skip ci] 2026-07-06 06:41:43 +00:00
copybot[bot] 6caf9af514 copybot: live paper feed [skip ci] 2026-07-06 06:14:37 +00:00
copybot[bot] b559e457f1 copybot: live paper feed [skip ci] 2026-07-06 06:12:30 +00:00
copybot[bot] e7a1ae6321 copybot: live paper feed [skip ci] 2026-07-06 05:14:02 +00:00
jaxperro bf15d5199e deploy: auto-sync the Alchemy webhook address list to the follow set
live/sync_webhook.py diffs copybot.paper.json's wallets against the
push-mode webhook's address list (Notify API) and patches add/remove;
wired into deploy_bot.sh. Needs alchemy_notify_token in the gitignored
config.json (dashboard -> Webhooks -> Auth token); skips politely
without it — the 5-min backstop poll covers the gap at poll-speed lag.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-06 01:12:18 -04:00
jaxperro e59ccde834 README: push mode is live (Alchemy webhook + heartbeat + backstop); redeploy-vs-rebuild gotcha
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-06 01:06:10 -04:00
copybot[bot] b61ac7ca9b copybot: live paper feed [skip ci] 2026-07-06 05:01:36 +00:00
jaxperro e2fbb08140 railway: pin NIXPACKS builder (new default builder ignored nixpacks.toml -> no git in image)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-06 01:00:53 -04:00
jaxperro 234a892119 railway: pin start command to host/start.sh (config-as-code)
The copybot service's custom start command was 'bash start.sh' — a relic
of the scratchpad folder it was first deployed from; builds from the repo
root have no root start.sh, so image rebuilds crashed and Railway kept
serving the years-old image (which is also why start.sh changes never
took effect via redeploy). railway.json now pins the start command;
nixpacks.toml's default no longer points at the retired webhook_receiver.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-06 00:53:42 -04:00
jaxperro c6f5f5888f railway: .railwayignore — keep secrets/cache out of the build image
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-06 00:41:06 -04:00
copybot[bot] 48e31f44aa copybot: live paper feed [skip ci] 2026-07-06 04:39:17 +00:00
copybot[bot] f597a41f5c copybot: live paper feed [skip ci] 2026-07-06 04:36:59 +00:00
copybot[bot] fe7bccbabf copybot: live paper feed [skip ci] 2026-07-06 04:33:16 +00:00
copybot[bot] c914d86d0f copybot: live paper feed [skip ci] 2026-07-06 04:28:49 +00:00
copybot[bot] 55b47fd849 copybot: live paper feed [skip ci] 2026-07-06 04:22:39 +00:00
copybot[bot] f69bc1fb9d copybot: live paper feed [skip ci] 2026-07-06 04:18:23 +00:00
copybot[bot] 7e54ad26e6 copybot: live paper feed [skip ci] 2026-07-06 04:16:15 +00:00
jaxperro 0c7ee62ed7 copybot: push mode — Alchemy webhook + heartbeat + backstop poll
Setting ALCHEMY_SIGNING_KEY on the worker switches start.sh to webhook
mode: instant copies on POST /alchemy (signature-verified), a 60s
housekeeping heartbeat (settle, feed, summary), and a full backstop poll
every 5 min so a dropped push costs minutes, not a silent miss. Webhook
mode now baselines at boot and publishes an initial feed like poll mode.
No signing key -> classic 60s poll, unchanged.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-06 00:07:23 -04:00
copybot[bot] 104534eef0 copybot: live paper feed [skip ci] 2026-07-06 03:59:13 +00:00
jaxperro bda859a046 copybot state: backfill sold-leg P&L for the one pre-fix mirror-sell
Kruto2027 'Chidekh vs. Janvier O/U 22.5', sold 2026-07-05 11:48 — ten
hours before the sold-leg ledger existed. Reconstructed from the feed's
git history (realized/cash deltas between commits 34476dc and 2ef0e19,
the only open position in that window): net proceeds $53.15, whole-bet
pnl +$11.84.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-05 23:57:59 -04:00
copybot[bot] cc58aa9245 copybot: live paper feed [skip ci] 2026-07-06 03:53:44 +00:00
jaxperro d3d7d11c14 README: full refresh for handoff — cheat-sheet, current sizing, trust layer, rolling backtest
Operating cheat-sheet (add/remove live wallets, backtest, promote, logs,
deploys, digest, real-money); 8am schedule; follow set points at
copybot.paper.json as source of truth; diagram gains trust.py + rolling
replay; sizing docs reflect the their-bet ceiling (cap/reserve retired);
auto p80 floors; gotcha 9 (endDate rewrites + invalidate deletion);
research numbers updated to the trusted-row era.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-05 23:53:05 -04:00
copybot[bot] 99546f791e copybot: live paper feed [skip ci] 2026-07-06 03:47:17 +00:00
jaxperro 6d2fb0f34b copybot: their-bet stake ceiling replaces stake cap + banked reserve (parity with backtest)
stake = class % of equity (drawdown-braked), capped at the signal's own
position size so far (OPEN caps at their fill, ADDs grow with their
position). No sweep, no $250 pin — fills stay within size the market
demonstrably absorbed from the signal itself.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-05 23:45:56 -04:00
jaxperro 1b8f48eda3 backtest: drop banking/stake-cap; stakes capped at the followed wallet's own bet
cur_stake = class % of equity (drawdown-braked), then min(their stake):
a copy is never bigger than what the wallet actually bet. No reserve
sweep, no $250 pin — the their-bet ceiling is the liquidity bound now
(fills stay within size the market demonstrably absorbed).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-05 23:41:59 -04:00
copybot[bot] 6f88849f85 copybot: live paper feed [skip ci] 2026-07-06 03:37:04 +00:00
jaxperro 64b56c0818 copybot: follow-set update (deploy_bot.sh) 2026-07-05 23:36:25 -04:00
jaxperro 2d2d3aa097 backtest: add ArbTrader as third whale (30d replay: 74W-1L, +$21k)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-05 23:35:12 -04:00
jaxperro abeb74a6f7 add ArbTrader to follow 2026-07-05 23:33:03 -04:00
copybot[bot] 2a933d2687 copybot: live paper feed [skip ci] 2026-07-06 03:28:26 +00:00
copybot[bot] af10d121b7 copybot: live paper feed [skip ci] 2026-07-06 03:24:11 +00:00
copybot[bot] 4c6c7239b4 copybot: live paper feed [skip ci] 2026-07-06 03:19:56 +00:00
copybot[bot] f8a45ebe0c copybot: live paper feed [skip ci] 2026-07-06 03:13:34 +00:00
copybot[bot] cbe62f7bea copybot: live paper feed [skip ci] 2026-07-06 03:11:26 +00:00
jaxperro 6f8fdb7aff copybot: follow-set update (deploy_bot.sh) 2026-07-05 23:10:53 -04:00
jaxperro 4190455436 copybot: compact follow config + auto floors + one-command deploy
config format matches backtest.json — one entry per wallet:
  wallets: [{wallet, name, class: volume|whale, floor?}]
normalize_follow_config expands it into the legacy watchlist/watch/
floors/classes structures (old-format configs like config.live.json
pass through untouched). Volume wallets without an explicit floor get
an auto p80 derived from the data-api at boot (the worker has no cache),
logged and published in the feed. live/deploy_bot.sh = validate ->
preview -> commit -> push -> railway redeploy -> confirm boot.

Promotion workflow: prove a wallet in backtest.json, copy the same
entry into copybot.paper.json, run deploy_bot.sh.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-05 23:10:51 -04:00
copybot[bot] bf2495b58b copybot: live paper feed [skip ci] 2026-07-06 03:09:39 +00:00
copybot[bot] a2349f8865 copybot: live paper feed [skip ci] 2026-07-06 02:44:29 +00:00
jaxperro cb4a33279a sharps feed: all-time trusted stats (every bet); bot feed: wallet classes
* validate_timing.display_stats adds all_win/all_won/all_lost/all_pnl —
  the wallet's record and own P&L over EVERY resolved bet ever cached,
  trusted rows only, deduped one-per-market (feeds the dashboard's new
  All-Time columns); consensus temp table now built before the pool
* copybot write_feed adds classes {name: volume|whale} so the dashboard
  can badge whale-class wallets

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-05 22:43:56 -04:00
jaxperro 4792235582 backtest: interchangeable wallets + rolling window (live/backtest.json)
portfolio.py now replays ANY wallet set over a rolling N-day window
(default 30) instead of the hardcoded four-from-June-1:

* live/backtest.json: {days, stake_cap_usd, class_pct, wallets:[{wallet,
  name, class}]} — edit to add/remove/swap wallets; seeded with the paper
  bot's current 7-wallet follow set
* class parity with the bot: 'whale' replays EVERY trusted bet at
  class_pct.whale of equity; 'volume' replays conviction bets at
  class_pct.volume, p80 threshold from PRE-window bets only (no peeking)
* outcomes read through trust.py (trusted rows) so any pasted-in wallet
  is scored honestly, not on cache marks
* ad-hoc CLI that leaves the dashboard feed alone:
    python3 portfolio.py --wallets 0xabc,0xdef:whale --days 14 --out /tmp/t.json
* fix: open positions with unknown entry time used to sort at t=0 and
  drain the bankroll before any historical bet ran; they now queue at the
  end (and pre-window entries are excluded)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-05 22:15:37 -04:00
jaxperro e07ff3d305 copybot: sold legs now realize on the bet record, not just cash
Mirror-exits were correct at book level (cash/fees) but invisible per bet:
a fully mirror-sold bet went to 'closed' with pnl null, and a TRIMmed bet
that later resolved subtracted its ORIGINAL cost+fee while ignoring the
sold leg's proceeds — understating whole-bet pnl on the feed.

* _drain_fills links every SELL fill to its bet record
  (sold_shares / sold_proceeds, net of taker fee)
* write_feed: full mirror-sell -> pnl = sold_proceeds − cost − entry fee,
  plus exit_price; dashboard's existing 'mirror-sold with recorded P&L'
  branch picks it up
* settle_resolved: pnl = resolution proceeds + sold leg − original cost −
  entry fee (pos.cost is trim-reduced; bet.cost is the original)

Sandbox-tested: TRIM cash+record, TRIM->WIN whole-bet truth, full EXIT
feed reconcile all agree to the cent.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-05 21:58:06 -04:00
jaxperro 034e128281 copybot: whale class follows ALL trades — no conviction floor
Whale-class wallets bypass min_their_usd and per-wallet floors entirely:
both current whales win ~92% across their ENTIRE book (Stavenson 469-39,
0x4bFb 862-72 all-time trusted; 99.2% last 30d for the whale), so
size-filtering them only costs flow. The 0.95 entry cap stays (execution
guard, validated). Floors removed from the paper config for both.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-05 21:45:45 -04:00
copybot[bot] 58975e515b copybot: live paper feed [skip ci] 2026-07-06 01:43:42 +00:00
copybot[bot] b8f3e5ac2b copybot: live paper feed [skip ci] 2026-07-06 01:37:24 +00:00
copybot[bot] 1e8d62ae73 copybot: live paper feed [skip ci] 2026-07-06 01:31:06 +00:00
jaxperro f8a0f0caee copybot: stop following shisan888
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-05 21:30:28 -04:00
copybot[bot] 09a0b09a83 copybot: live paper feed [skip ci] 2026-07-06 00:22:51 +00:00