TonyTrade.net

Home / Safety design

Safety design: three layers between the AI and your orders

This page answers: what happens if the AI says something wrong, the app is closed, your key is stolen, or you want to stop right now. It also says what this design can't do.

The AI writes plans, fixed rules check them, stops sit on the exchange, and keys never leave your device. If one layer fails, the others are still there.

Three layers

  1. The AI only writes plans. Plans have a fixed format: market, side, size, entry, stop-loss, take-profit, adding rules, expiry. The AI never calls the exchange and never gets your keys.
  2. The rule engine checks. Fixed code that looks only at numbers. It lets a plan through only if it's within what you allowed. Anything outside pops up and waits for you to confirm.
  3. The executor places the order. It places the stop-loss and take-profit on the exchange at the same time. A position whose stop can't be placed is not opened.

Details of each step: How it works.

Limits you set

You set these limits and the app enforces them. The AI can't change them, and follow-up suggestions can't go past them.

LimitWhat happens when it's reached
Maximum size per tradePlans above it don't run automatically. They wait for you
Maximum size per coinAll positions in one coin together can't exceed it
Total position limitAcross all exchanges and all coins
Maximum leverageA futures plan can't use more than this
Maximum daily lossNo new positions for the rest of the day, and you get an alert
Coin whitelistCoins not on the list are not traded
Maximum orders per dayStops a faulty strategy from placing orders again and again

Start with small limits. At first you can keep the automatic range very narrow, so most actions need your confirmation, and widen it once you're used to it.

Stops sit on the exchange

Each time a position opens, its stop is placed on the exchange at the same time, as the exchange's own conditional or TP/SL order. That means:

  • If your computer shuts down, the network drops or the app crashes, the stop still works on the exchange.
  • If the stop can't be placed (for example, the exchange rejects it), the position is not opened.
  • When the app opens again, it reconciles with the exchange first. Positions, open orders and records must match before strategies run again.
Keep in mind: once triggered, a stop fills at the market. In a violent market with thin depth, the fill can be much worse than the trigger. Placing the stop on the exchange solves "is there protection at all". It does not fix the fill price. See Wicks: what they are and how to handle them and Why stop-losses should sit on the exchange.

Keys: no withdrawal permission, stored only on your device

  • Only two permissions: read and trade. If the app finds withdrawal permission on a key, it refuses to use it and asks you to make a new one.
  • Keys are encrypted in your operating system's keychain (Keychain on Mac, Credential Manager on Windows) and never uploaded to any server.
  • The AI never gets your keys. The model provider receives only the chat and market data.

Without withdrawal permission, a stolen key can't move your coins out. But the thief could still place bad trades with it, so also bind an IP whitelist and keep funds in a sub-account. How to do this on each exchange: API key setup and the API key permissions guide.

Stop-all button

There is a stop-all button on both the computer and the phone. When you press it:

  • All strategies stop at once. No new positions, no more follow-ups.
  • You choose whether to also close all positions and cancel all open orders.
  • If you don't cancel orders, stops already on the exchange stay there and keep protecting your positions.

Your phone connects to TonyTrade on your own computer. If the computer is offline, the phone can't send the stop-all command. In that case, act directly in the exchange's app.

What this design can't do

  • It can't make you money or keep you from losing. The rules only limit how big and how fast losses can be.
  • It can't make a stop fill at the trigger. Wicks and dried-up liquidity cause slippage.
  • It can't stop you from setting limits too high, or confirming something you shouldn't.
  • It can't prevent exchange outages, maintenance, disconnections or API changes.
  • It can't protect a computer that already has malware. Keep your system updated and don't install software from unknown sources.

The full risk notice is at Risk notice. Other questions: FAQ.