# Professional Trader Desk + FinanceManager bridge

Use this pattern when the user wants JARVIS/Crypto_Agent to move from negative paper-bot variants toward a professional trader workflow and later Hyperliquid tiny-live/full autonomy.

## User-facing framing

- Be direct as a trader/risk manager: more data sources (CoinGecko, chart analysis, TradingView community, Hyperliquid OI/funding) do not automatically create edge.
- If current strategies are negative, say so plainly and do not relabel them as live-ready.
- When the user treats the Hyperliquid wallet as written-off risk capital, it permits tiny-live experimentation after gates, not uncontrolled gambling.
- Target progression: `Trader Desk Shadow -> Final Tiny-Live Preflight -> Tiny Live Autonomy -> Controlled/Full Autonomy`.

## Trader Desk v1 shape

Build a read-only decision layer that turns market context into structured trade plans:

```text
Coin
Direction: long / short / none
Action: no_trade / watch_shadow / tiny_live_candidate
Score
Setup
Entry zone
Stop loss
TP1 / TP2 / trailing management
Risk/reward
Evidence
Blockers
Preflight required
```

Inputs to combine:

```text
Hyperliquid price, funding, premium, OI, spread, depth/impact
Chart/trend/momentum/volatility/regime context
CoinGecko fundamentals
TradingView/community context as research-only sentiment
Own paper/live journal evidence
Tiny-live mandate and risk limits
```

Safety invariant for the desk itself:

```text
live_order_allowed=false
mainnet_signed_action=false
execution_allowed=false
```

A `tiny_live_candidate` is a candidate, not an order. The runtime must still pass final preflight and re-check every bot-side gate.

## FinanceManager bridge pattern

The user expects Trader Desk visibility in FinanceManager. Export a sanitized bridge snapshot before building dashboard UI:

```text
/home/agent/jarvis_runtime/finance-system/crypto_trader/trader_desk_latest.json
/home/agent/jarvis_runtime/finance-system/crypto_trader/trader_desk_latest.md
```

Recommended schema:

```text
finance_crypto_trader_desk_bridge.v1
```

Each FinanceManager `trade_intent` should include:

```text
intent_id
portfolio_id=hyperliquid-usdc-derivatives
source_engine=jarvis_trader_desk_v1
strategy_id=trader_desk_multi_signal_v1
coin / side / signal / mode
entry_zone / stop_loss / take_profit
confidence_score / evidence / blockers
requires_preflight=true for candidates
execution_allowed=false
dashboard_executes_orders=false
live_order_allowed=false
mainnet_signed_action=false
```

Dashboard buttons may write approval/audit decisions only. FinanceManager must never call Hyperliquid exchange APIs or sign orders.

## Verification checklist

- Unit-test high-quality long -> `tiny_live_candidate` while still `execution_allowed=false`.
- Unit-test hard blockers -> `no_trade`.
- Unit-test shorts are `watch_shadow` when tiny-live mandate is long-only.
- Unit-test Finance bridge snapshot and Markdown export.
- Run full tests plus `py_compile`/`compileall`.
- Smoke export to the Finance runtime path and verify JSON exists, schema matches, intent count > 0, and all execution/live/signed flags are false.

## Next increments

1. FinanceManager API/Vue page reads the bridge snapshot and renders Trader Desk cards.
2. Trader Desk Shadow Runner journals all plans/outcomes per tick.
3. Tiny-live runtime consumes only candidate intents and still runs final preflight/reconcile/stop/risk gates.
