IDEXA Family IDEXA Trading Ideas Adexi Codax Sell
IDEXA TRADING
← Back to index
● Retired May 17, 2026

Alpaca Swing Lowvol Bot postmortem · what went wrong

Ran May 7–17, 2026 10 days live Paper trading Retired
TL;DR

Lowvol was an A/B experiment that relaxed Swing's volume filter from 1.5× to 1.1×. The live dashboard showed +$997 realized P&L. But marked-to-market — including 11 open positions Lowvol had accumulated — the bot was actually down ~$2,300 when it was retired.

The realized number wasn't a lie. It was just incomplete. This page exists because we'd rather show the full picture, even when it makes us look worse.

Final realized P&L
after final close
Total trades
over 10 days
Win rate
wins vs losses
Peak leverage
197%
of equity, unintended

Final cumulative P&L

Realized only — open positions excluded
Loading...

What went wrong — three structural bugs

Lowvol was the same swing strategy as the production bot, with one parameter changed: the volume filter dropped from 1.5× to 1.1×. The hypothesis was that the production threshold was too strict and was leaving valid momentum setups on the table. The looser filter would take more trades, and if signal quality held, the bot would make more money.

Signal quality did not hold. But the more important discovery was that the looser filter exposed structural bugs in the shared bot code that the stricter filter had been hiding by accident.

01The looser filter caught a falling knife

Mean reversion trades concentrated in one name. The bot kept re-entering QCOM as it climbed (May 7 +$2,005 win, May 8 +$330 win), then on May 11 entered a third time at $236.38. That entry caught the local top. As QCOM fell to $201.49, the position bled to -$2,791 — a single trade that swamped most of the bot's other winners combined.

This is exactly what looser volume filters do to momentum strategies: they let in marginal setups where the entry signal is real but weaker. Most of the time those still work. Sometimes they don't, and the losses are bigger than the wins because conviction was lower at entry.

02The trailing stop update was broken

When a position rallied past +3% gain, the bot tried to install a tightening trailing stop. The problem: every position already had a stop-loss order outstanding from when the bracket was first placed. Alpaca refused the new stop with insufficient qty available because all shares were already committed.

The bot caught the exception, logged it, and moved on — without canceling the old stop first. The result: NVDA and AAPL, both up significantly, had stale stops from their entry-day prices. The trail never moved. If those positions had reversed, the bot would have given back gains it should have locked in.

Fix (now in production): cancel the existing stop order before submitting the replacement. Wait ~0.75 seconds for Alpaca to release the held quantity. Then submit the new trail.

03No total-exposure check

The bot enforced a per-trade size of $19,759 and a daily limit of 5 trades. It did not check total capital deployed before opening another position. Over 9 days, Lowvol opened 14 trades and only closed 3 cleanly. At its peak, it held 11 open positions worth ~$207,000 — against an equity base of ~$105,000.

The bot had silently leveraged itself to 197% of equity. Alpaca's paper margin allowed it. The strategy didn't ask for it. Nothing in the code prevented it.

Fix (now in production): before any new entry, check capital_deployed / equity. If ≥ 100%, skip new trades regardless of signal quality. A bot can't manage what it doesn't own outright.

What we actually learned

The instinct behind Lowvol — "what if the production bot's filter is too strict?" — wasn't wrong as a question. What was wrong was treating a parameter tweak as a different bet. Lowvol wasn't a different strategy. It was the same strategy with worse settings. When you A/B test a parameter, the worse setting often loses, and you've learned exactly what the original setting was protecting you from.

Three things we'd do differently if we ran the experiment again:

  • Backtest before deploying. Lowvol went live without a backtest. The 1.1× threshold had never been validated against the production 1.5×. We could have caught the falling-knife pattern in 2-year historical data before risking even paper capital.
  • Add a total-exposure check from day one. The 100%-equity guard is now standard in every IDEXA bot. It should have been there in the first one.
  • Look at unrealized P&L, not just realized. The dashboard showed +$997 because we only counted closed trades. A bot that's "winning" with 11 open positions deep underwater isn't winning — it's an iceberg.

The most useful thing this experiment produced wasn't a better strategy. It was a better discipline: measure honestly even when it makes the bot look bad, then publish the measurement. The fixes that came out of Lowvol's collapse — the cancel-then-replace trail logic, the exposure guard, the closed-position logger fix — all went into the production Swing bot. Swing is more robust today because Lowvol failed publicly.

All closed trades

— total
Symbol Entry Exit P&L $ P&L % Closed
Loading trades...