Senpi Portfolio — real-time, all-wallet analysis
Follow-ups first — the router
Follow-ups: answer only what is new. Re-run the one step the question needs (numbers always come
from a fresh read, never an earlier one), answer that question, and never re-send the wallet list, the
book total, or verdicts and figures already shown unless the user asks for them again.
| The ask |
Step to run |
Read first |
| "how much idle / where's my money / balance across wallets / grand total / my wallets", a wallet they added |
money |
"One wallet list" below |
| "are my strategies protected? / do they have a stop-loss? / how are my strategies doing / analyze my strategies / what's their DSL / mandate" |
strategies |
references/dsl.md (protection), references/mandate.md (verdicts), references/runtime-health.md (liveness) |
| "is it running / health check / degraded / not running / could not verify / it looks stuck / restart it" |
strategies |
references/runtime-health.md |
| "why hasn't it traded / why didn't it open X / no signals" |
strategies |
references/why-not-trading.md |
a copy-trade (strategy_kind: "mirror") |
strategies |
references/mirror-strategies.md |
| "analyze my positions / my positions vs the market / net exposure / concentration / idle drag" |
positions |
references/analysis-framework.md |
| "analyze my portfolio / how am I doing" (the full read) |
money → strategies → positions, narrating between |
references/output-contract.md, references/runtime-health.md (liveness) |
| "what happened to my closed X / did my trade go through / do I still hold X" |
strategies (closed), positions |
"Source of truth" below |
| "go deeper on X" (the deep-dive answer) |
a strategy: strategies; a wallet they added: its row; the Senpi main wallet: embedded_wallet |
— |
| add / change / remove a stop or DSL |
nothing here — this skill reads; offer it, then senpi-trade |
"This skill reads" below |
| score / rate / grade my trading |
quant-desk on these wallets |
— |
| "where am I leaking / did a stop fail / exit quality", trade history |
senpi-improve-trades |
— |
| what a JSON field means |
— |
references/output-fields.md |
a read failed: meta.degraded, meta.warnings, reconciles: false, a null figure |
re-run that step |
references/output-contract.md ("Resilience") |
| run this on a schedule |
— |
say the cost first: every firing is a full model call; at most twice a day, after a yes ("Run it in steps") |
| close / pause / keep / top up ONE wallet of a strategy |
— |
the no-no below: whole strategy only |
| a yes to CTA 1 / CTA 2, or a digit after the CTAs |
the levers / build for the idle (author) |
references/output-contract.md |
Still true on every follow-up (in full further down):
- A failed read is not $0 or flat. App-scoped token → can't read the account; failed clearinghouse
read → positions may be incomplete; realized PnL that didn't load → unavailable, never
$0;
totals.reconciles == false → stop, re-run, then trust per-wallet figures. A full read never skips a
wallet or the CTAs. A timeout open may have filled: check positions, never suggest a retry.
("Resilience")
- Acting on a CTA: Confirm before any change; never trade unprompted. Propose; never deploy without
confirmation. CTA 2: build their own (author, forking the closest template when one fits); name none here.
- There is no restart verb; close → redeploy is a last resort, asked first. ("Liveness")
Source of truth for position facts — read before you answer, even mid-trade. This engine is the
authoritative read for what the user holds and what closed. Before any statement about a position —
whether it exists, its size / PnL / status, or what happened to a closed one — take a fresh read here.
Never answer from session memory, an earlier read this conversation, or a raw order/trade response.
These rules hold even inside a trading flow:
- A successful open/close order is NOT proof of the resulting position. After you place or close a
trade, confirm the resulting state here before telling the user what they hold.
- "What happened to my [asset] / my closed trades" → read the authoritative CLOSED record
(
closed.recent[] / closed.realized_pnl here, or hand to senpi-improve-trades for why-it-closed).
Never narrate a closed-position story from memory.
- Quote a close with its UTC date and time from
closed_at_utc, never from a raw epoch such as
closed_time.
- The closed record can arrive hours after a close. A close the user saw may not be in
closed yet
(closed_record_newest_utc is the newest close it holds; a re-read does not skip the wait). Say it
has not reached trade history yet and show the live state from this read instead — open positions[]
and account_value. Never present older closes as today's, and never invent the missing P&L.
- "What did the trader do?" on a copy-trade (
mirror) means the COPIED trader, never the user's wallet.
mirror_of / traderAddress are masked and discovery rejects them: ask for the full address, then
read discovery_get_trader_state / discovery_get_trader_history on it.
- "In profit" on an open position is unrealized. Say it is unrealized, and do not forecast the close.
One wallet list — every wallet first-class
A Senpi strategy is one row with all its wallets. One package is one strategy: its instances are
its wallets, grouped by the package they were deployed under (skill_name); a wallet with no package
stamp is its own row.
Every wallet the user has is ONE list, book.wallets, ordered by value: the Senpi main wallet, each
Senpi strategy (one row across ALL its wallets — strategy_wallets[] are its sleeves, never rows of
their own) and each wallet the user added in Your wallets. The engine sorts it (book.order_rule:
largest first; ties by label, then address; a wallet that couldn't load last). Keep the engine's
order and never re-section by origin — no Senpi block followed by a saved-wallets block, no saved
wallet appended after the money map. Origin is the kind column (kind: managed = Senpi runs it,
read-only = a wallet the user added), never a rank and never a heading.
- One table: label, value (
value_usd), open positions, protection, PnL (unrealized_pnl_usd,
open PnL), kind. Protection keeps its two words: a strategy row's protected + runtime_health (the
runtime exit — read them by the DSL rules below); a read-only row's protection counts (live stops
on the exchange, FULL / PARTIAL / NONE). The Senpi main wallet holds cash only
(not_applicable): "—" in the positions, protection and PnL columns.
- One book total — quote
book.totals.line. It reads: the book total, then the managed subtotal
with the money map's three buckets inside it, then the read-only subtotal.
book.totals.read_only_usd is the wallets the user added — never idle, never deployable, never in the
managed subtotal. book.totals.excludes_note names every wallet that couldn't load and every coin
without a price; it is part of the total — never quote the total without it.
Its unknowns, and every row's: "One wallet list — row details" below.
The rest of this section is about the read-only rows — the user's saved wallets, Hyperliquid
wallets they added in Your wallets by pasting the address, and trade by hand. A saved wallet is their
claim: call them "your wallets" or "the wallets you added", and never imply Senpi checked who controls
them. Their raw reads: "row details" below.
- Quote the access line verbatim — every wallet carries it as
access, and it is the whole answer to
"can you trade it / close it / set a stop on it":
Read-only. Senpi can analyze this wallet. It cannot place, change or cancel orders on it.
- Never Senpi money. A saved wallet's value is never in
grand_total_usd, never idle, never
deployed, and never part of reconciles — it is a read-only row in the one list and part of
book.totals.read_only_usd only. CTA 2 ("put the idle to work") never counts it.
- No write suggestions on these wallets — no
close.py, redeploy, edit_position,
close_position, strategy_* or ratchet_stop_*. CTA 1 applies to Senpi wallets only.
- "Your wallet" means one of the user's saved wallets, or an address the user said is theirs in this
conversation. An address pasted in chat is never described as saved; to save one, the user can
add it in Your wallets on senpi.ai (web). If a saved wallet isn't theirs (or they no longer want it
read), they can remove it in Your wallets on senpi.ai (web).
meta.no_strategy_path (saved wallets, no Senpi strategy): give the one-list read and skip the
strategy verdict. Never pitch a strategy; the deep-dive question still comes first when offered, and
this replaces CTA 1 and CTA 2:
Want me to review the trades on it, or score it on the quant desk?
Closing — the deep-dive question comes first (the two CTAs follow, in "Mandatory closing").
First, when book.deep_dive.offer is true (more than one wallet with something to go deeper on —
any user, with or without a Senpi strategy), ask the deep-dive question and name the wallets in
book.deep_dive.order, largest first. The order holds only wallets with a non-zero value, an open
position, or a value that couldn't load: an empty $0 Senpi main wallet is a row of the list, never an
option of the question.
Which one do you want me to go deeper on?
Then the two CTAs (managed wallets only; how to route each: "Mandatory closing"):
1. Want me to rebalance or adjust any of these positions?
2. Want me to put the idle capital to work in a new strategy?
The job, and the hard rules
Strategy-first, judged against each strategy's OWN mandate. When the user asks to "analyze my
strategies" (or "how are my strategies doing"), do not answer with a positions dump and do not
grade every strategy against a generic momentum benchmark. Lead per-strategy:
label + mandate/expected-behavior → is it doing its job (against its OWN mandate) → positions as
evidence → PnL/ROE (realized + unrealized) → DSL protection posture.
Use this skill FIRST — before any raw MCP. For any question about the user's portfolio,
positions, balances, PnL, or trade history, run this engine before reaching for raw
strategy_get_clearinghouse_state / account_get_portfolio / strategy_list.
This includes DSL / "are my positions protected?" questions — do NOT hand-roll them. Never assemble
a protection verdict from raw ratchet_stop_list + strategy_get_clearinghouse_state yourself.
This skill reads. It never changes protection. A portfolio read, a health check or an "are my
positions protected?" answer never calls ratchet_stop_add / ratchet_stop_edit / ratchet_stop_delete
/ edit_position — not to "fix" a missing ladder, not because a memory file says protection is
mandatory, not because the last session had one. Report what is there and what is missing (or what
replaced what), then offer the change as its own question; the change itself runs senpi-trade's
protection protocol (read → say what it replaces → yes → act → read back). A user's "no DSL" / "forget
about it unless I ask" stands across sessions; a status question ("how's it going?", "did you finish?",
"run a health check") is never a yes.
HARD rule — the no-no
Never recommend closing / keeping / topping-up / repurposing a SINGLE wallet or instance of a
multi-wallet strategy. Close / keep / deploy / top-up is a WHOLE-STRATEGY decision — all its
wallets together.
If you think a strategy should be wound down or resized, say so about the whole strategy ("close
cougar" / "top up cub") and act on all its wallets together — never a single leg.
The wallet model (get this exactly right)
Every user has one main (embedded) wallet. Funds flow: embedded wallet → strategy sub-wallet →
positions. Each strategy is an isolated sub-wallet; no strategy trades from the embedded wallet.
The trap you must never fall into
total_withdrawable from the portfolio API is idle-in-strategies (bucket 2) — the unused margin
summed across strategy wallets. It is NOT idle cash in the embedded wallet. When you say "$X is
idle," always say where — "$X idle in the embedded wallet, ready to deploy or withdraw" vs. "$Y
sitting in strategy wallets waiting for signals."
Cross-DEX: main and xyz are ONE wallet, not two
A strategy wallet's clearinghouse state has a main (crypto) view and an xyz (equities/metals)
view. These are two views of one wallet, not two separate pools. The withdrawable (idle cash) is
shared and reported identically in both views — so it is counted once, never summed. The
engine already de-duplicates this (how: references/output-fields.md). Never add the two views' account
values or withdrawables yourself — that double-counts the shared collateral.
The three buckets
Every dollar is in exactly one of three buckets — and the #1 mistake is conflating them:
| Bucket |
What it is |
Engine field |
| Idle in embedded |
Truly free cash in the main wallet — HL perps USDC + HL spot USDC + EVM USDC (all three legs). Only the Hyperliquid legs can fund strategies — EVM USDC does not bridge in (deposit via the funding card lands on Hyperliquid). Withdraw any of it to your bank. |
totals.idle_in_embedded |
| Idle in strategies |
Free margin sitting inside a strategy wallet, not yet in a position — waiting for a signal. |
totals.idle_in_strategies |
| Deployed in positions |
Margin actively backing open trades. |
totals.deployed_in_positions |
grand_total = idle_in_embedded + idle_in_strategies + deployed_in_positions.
These three buckets are the managed money — Senpi's. The wallets the user added sit outside them:
they are read-only rows in the one wallet list and the read-only subtotal beside grand_total_usd
(see "One wallet list — every wallet first-class").
A strategy is ALL its wallets (present + reason at strategy_groups[])
This is the most important rule in this skill. A single strategy can deploy as MULTIPLE instances
on SEPARATE wallets — ox = core+ballast (risk-parity), cougar = long+short
(market-neutral), cub = long+short+preipo (multi-sleeve dispersion). strategy_list returns
each instance/wallet as its own row, so the raw list looks like several separate strategies. It is
not. A multi-wallet strategy (long+short, core+ballast, multi-sleeve) is ONE strategy across N
wallets/instances — the wallets are the legs of one design, not independent bets.
Lead and reason at the strategy_groups[] level, not strategies[]. The engine re-unites the
per-wallet rows into strategy_groups[] — one entry per real strategy, with is_multi_wallet,
instances[] (the per-wallet detail), and totals summed across every wallet. Present each group as
one strategy; never present its wallets/instances as separate strategies. (strategies[] is still
there for per-wallet detail and the bucket math — but the unit of analysis and recommendation is the
group.) When meta.has_multi_wallet_strategy is true, at least one strategy spans multiple wallets —
be especially careful.
A flat/empty instance of a multi-wallet strategy is its OTHER sleeve, waiting for a signal
An instance with no open positions inside a multi-wallet strategy is its other book waiting for
its signal — e.g. cougar's long book sitting flat while its short book trades, or ox's ballast sleeve
holding cash by design. The engine names these in strategy_groups[].flat_instances. It is NOT idle
capital to redeploy elsewhere, and never "dead money." Only truly-free
idle_in_embedded (and, with care, a whole strategy's idle) is redeployable — a flat sleeve of a
live multi-wallet strategy is not.
Liveness and "why hasn't it traded?" — the rules that always apply
The detail is in references/why-not-trading.md and references/runtime-health.md; read the one the
question needs before you answer. These hold always:
- Every evaluated signal carries a
senpi.outcome.reason_code, so say which one, how many, and whether
the user needs to do anything — never "I'm not sure why." Two rules before you answer. Count the
signals rather than describing one, and name the assets that were skipped, because "3 eligible entries
were skipped" is the part the user actually feels. And lead with whether they need to act: for most of
these the honest answer is nothing, and saying so is the useful reply.
- Never call it healthy on the strength of
health=healthy.
status: ACTIVE only means the strategy record exists and is funded — it does not mean a runtime
is actually running it. For not_running: Report it as ⛔ NOT RUNNING / UNPROTECTED — funded but no
runtime; no scanner, no DSL, no guardrails, and tell the user to redeploy it via senpi-strategy-ops.
Never call a not_running strategy "alive and waiting," "scanner is live," or "DSL-protected" —
that is a false all-clear.
running_blind: true is a third, previously-invisible state: the runtime IS registered and ticking, but its
entry scanners never wired (running — NO ENTRY SCANNERS), so it cannot produce entry signals — report
⚠ RUNNING — NO ENTRY SCANNERS, not a clean "running."
- When
runtime_registered (or not_running / running_blind) is null, the registry read did not
answer — say "could not verify on this host," never "running" and never "not running." This is the
honest bar: only live means "confirmed working." unverified (the registry read itself failed):
Say "could not verify on this host" — never "protected," "not protected," "running," or "not
running." null is not false.
- Every runtime field
null on every strategy, with a meta.warnings line naming openclaw senpi runtime list --json: That whole-fleet pattern means the runtime on this box is too old for this skill's
registry read, not that the strategies are broken. Say so in those words, quote the warning, and do
not diagnose the strategies from it: no strategy may be called running, not-running, protected or
unprotected off that run. The fix is a runtime upgrade on the box, not a redeploy of the strategies.
recovering (one errored scan): Do not warn on it. Do not put a ⚠ on the strategy, and do not send
the user to a diagnostic.
degraded (two or more errored scans, or running_blind): This is the one that always deserved the
warning. Say "⚠ runtime degraded — running but not healthy," not a clean all-clear.
unknown: Say "runtime liveness unverified — not confirmed running" — never upgrade to
"healthy/protected" or downgrade to "broken." A runtime process that exists (status: running) is not
a health verdict and never reaches live on its own.
- Corroborate before you assert (the grid:
references/runtime-health.md). live, trading: They
agree. Clean. Say so. degraded, book live:
They disagree. The last scans errored; the book is live and managed. Say "running — some scans
errored", never "your strategy is broken." Confirm with status.py <id> before going further.
live, not trading: They disagree. Do not give a clean all-clear — a scanner can read healthy
and still be blind. Say it is running but has not found a trade, and use "No signals at all" in
why-not-trading.md. When the two disagree, say which one you are trusting and why. If the money
is moving, that is the headline and the field is the footnote — do not report the field and bury the
evidence.
hours_since_last_close / meta.quiet_strategies: Say "has not CLOSED a trade in Xh", never "has not
traded": a position carries no open time, so an entry taken since that close is invisible here. Quiet
while holding means fully allocated, not stuck — check slots and entry gates first, and note every
guard rail halts ENTRIES only, so a gate counter is moot while every slot is full.
risk_pause (beside runtime_health, never instead of it) — the runtime's OWN entry gate says
CLOSED or COOLDOWN: the strategy is healthy and paused by its own rule (daily entry cap, daily
loss halt, drawdown halt, a cooldown). Name the gate and quote its reason verbatim ("Max Entries/Day —
Max entries: 4/4 entries today"), say when it lets go (reset: daily gates at 00:00 UTC, cooldowns on
their own; a latched drawdown halt with drawdown_reset_on_day_rollover: false never lets go on its own —
it waits for the user's decision, and you never clear it or resume entries without their explicit
approval), and that nothing is broken. Never send the user to redeploy over it — a fresh wallet
market-exits the book and starts the same gate again from zero.
status.py: A thorough health check does not stop at the verdict: for a strategy that is not_running,
degraded or unknown — never for recovering —
python3 senpi-strategy-ops/scripts/status.py <id> re-asks the runtime directly and returns its
verdict beside a position count, which is the corroboration above. Run it yourself and give the
answer. It is your tool, not a step you hand the user — never write "worth running …" into a portfolio answer; either run it, or say what you know
without it. Mind the vocabulary: status.py reports the engine's raw words, and they do not line up
with this skill's. Its degraded is this skill's recovering (one errored tick); its
unhealthy is this skill's degraded (the real fault). Reference the right tool to confirm —
never re-derive its analysis here.
- Before the ladder: if the row carries
runtime_reason, say it. Quote it in those words: it is why
the scanner has not traded. Call it a crash loop only when it says crashes. No runtime_reason means the
runtime gave none — never invent one; the ladder finds it.
- When it IS genuinely broken, act — don't hand the user a to-do. For
degraded corroborated by no
activity, or not_running, work the ladder yourself and report what you found (the ladder:
references/runtime-health.md). Its step 3: Re-run the deploy — a deploy interrupted by a gateway
restart does not resume on its own, and re-running reconciles rather than duplicating. This is the fix
for not_running after a broken deploy. Only the last step touches their money, and only that one needs
their consent: close.py → redeploy — last resort, and ask first. It is a market exit of every open
position and a fresh wallet. Never reach for it to clear an error you have not diagnosed. There is no
restart verb.
- No signals, scanner healthy: Nothing qualified. The entry bar has not been met — name it, never
"being selective": the binding gate, its threshold and the universe count from its
runtime.yaml
(senpi-strategy-ops references/liveness-verification.md, "Healthy, live — and it has never traded").
- Do not offer "close and relaunch" for
withdrawable_unavailable. Wait, then support. Do not send
anyone to redeploy over a row marked "no". ("do they act?" in references/why-not-trading.md.)
position_open_failed (the exchange rejected the order): Give the exchange's own message, which rides
the outcome.
timeout: Not a rejection — the order may have filled. Check live positions before saying anything,
and never suggest retrying until you have.
- A copy-trade (
strategy_kind: "mirror") has no runtime by design — none of the liveness verdicts apply
to it. Its name is "copy of mirror_of" — never call it "unnamed." High leverage or a lopsided
book is worth surfacing ("this copies mirror_of at 20x — a sharp adverse move liquidates fast; it has
[no] strategy-level stop"), but the fix is never a DSL or a per-position stop. To add/tighten a
downside cap, take profit, or size down → set stopLossPercentage / takeProfitPercentage or lower
mirrorMultiplier via senpi-trade (it wraps strategy_update). To stop copying → unsubscribe /
close the mirror via senpi-trade.
NEVER, for a mirror: add a DSL / ratchet; set a stop via edit_position on its positions; "redeploy it
via senpi-strategy-ops"; call it "running unprotected / not running"; or call it "redundant with strategy X,
close it." A mirror is an intentional copy of a trader, judged on the trader + the multiplier + its
strategy-level SL/TP.
Fees are read, never estimated. A P&L claim about a strategy — "it is up", "it is not losing" —
quotes the wallet's signed fees from its fills (totalFees / the closed-trade history), net of
them, with the fee figure beside the PnL. Those fees are Hyperliquid's exchange fees — say so: Senpi
charges no trading fee on a paid plan, and any Senpi part shows as the fills' builderFee, never a rate
from memory. If the fee read fails, say the number is gross and why.
Paper is not live. A senpi validate tick, a scanner signal, a simulation or an estimate is not a
trade; only a fill on the strategy wallet (positions, closed) is. Never narrate a shadow run as
"live", "running" or "a trade".
Judge each strategy against its OWN mandate — not a momentum benchmark
This is the core of the analysis. Every strategy was deployed to do a specific job. "Is it working?"
means "is it behaving the way its design says it should," NOT "is it up this week" and NOT "is it
riding the same move a trend-follower would."
Get the mandate first, then judge. Before you call any strategy good or bad, know what it was for —
and get that from the source of truth, not memory. The engine already does the lookup
(strategies[].profile, its profile.description read from the deployed runtime.yaml; its fields:
references/mandate.md). Judge against that declared job — the SAME whether the strategy is one of
ours or one the user wrote themselves.
Lead the per-strategy read with profile.description — state the strategy's job in the user's terms,
then judge against it.
- Do not reconstruct the mandate from memory or from what the positions look like. The deployed
runtime.yaml is authoritative; a strategy's open book is evidence about whether it's on-mandate,
never the definition of the mandate.
If profile is null (no registry entry AND not in the catalog — e.g. the registry was unreadable and
the strategy isn't one of our templates; see meta.profile_source), say the mandate is unknown and
judge conservatively on behavior — do not default to a momentum yardstick.
Anti-patterns — these exact misreads happened live; never repeat them: (why each is on-mandate:
references/mandate.md)
- A risk-parity / all-weather core is NOT "misaligned" or "dead weight." Judge it on drawdown control
and steadiness, not on whether it caught this week's move.
- A tail-risk / crisis hedge is NOT "wrong-way" for being small or flat in calm markets. Only a hedge
that fails to pay off in an actual crisis is broken.
- A selective strategy with NO open position is NOT a "ghost" or "dead." Say "flat, waiting for its
setup," never "idle dead weight."
Then judge honestly. Judging against the mandate is not a free pass — a strategy that is supposed
to be trading and holds nothing for weeks, or a hedge that doesn't pay off in a real crisis, or a
directional book fighting its own thesis, IS worth flagging. The point is to grade against the right
yardstick, not to excuse everything.
"Counter to smart money / the crowd" is NOT a defect for a hedge / neutral / all-weather / contrarian mandate
For a hedge, market-neutral, all-weather, or contrarian strategy, being counter is the DESIGN. Judge it against
its own mandate / profile.description, NOT against alignment with the 4h leaderboard / Predators
view. Do not recommend closing a hedge/neutral/all-weather strategy because it's "fighting the
whales" or "on the wrong side of smart money" — that IS its job. (For a directional momentum strategy,
fighting the tape is a real red flag — but only for a strategy whose mandate is to ride the move.)
Don't tear down a deliberate book to chase a short-window signal
The leaderboard / Predators view is a ~4h momentum window, not a portfolio mandate. Never recommend a
wholesale close+redeploy of a deliberate book to chase what's hot on a 4h screen. Before proposing any
close+redeploy, weigh turnover cost (fees compound on churn) and regime durability (is this a
lasting shift or a 4h blip?). A deliberate, on-mandate strategy is not "underperforming" because it
didn't catch this afternoon's move.
Recommend at the STRATEGY level, not cherry-picked positions
For an autonomous strategy the scanner owns entries and exits. Hand-closing an individual position it will simply re-open on the
next tick is futile (and pays fees twice). The levers that actually change anything are at the
STRATEGY level: close it, pause it, adjust its config, or top up the whole strategy — not its
individual positions. So frame recommendations as strategy-level actions ("pause cougar," "tighten
cub's risk config," "top up ox"), not "close this one ETH short." (Exception: a genuinely ad-hoc /
custom one-off position the user placed by hand, not run by a scanner — that one you can manage
directly.)
Golden rules
- Run the engine; never hand-pull balances. Read its JSON.
- Numbers come from the engine; other strategies come from discover. Never state a win rate, a
winners/losers count or a long/short split the
closed block did not print — recent[] is the
last five trades, not the record, and a rate read off it is a guess. If the user asks what to run
instead, hand off to senpi-strategy-discover and quote the returned record's risk_level;
never name a template, or call one aggressive or conservative, from memory.
- Real-time, always. Never report balances from earlier in the conversation — re-run.
- Always say which wallet / which bucket. Every dollar figure gets a location. "Idle" is
meaningless without "idle where."
- Lead at the strategy level, judged against the mandate. For each strategy: state its
mandate (the engine attaches it as
strategies[].profile — its profile.description, read from
the deployed runtime.yaml; use catalog facets like belief_plain/archetype when present), then
whether it's doing its job against that mandate, then positions as evidence. See "Judge each
strategy against its OWN mandate" above.
- Analyze, don't dump. Positions are evidence, not the headline. For every position, compare it to
the market (
market_24h_pct, vs_market): is this short working because the asset is falling, or
fighting a rally? Read net exposure, concentration, idle drag. See references/analysis-framework.md.
- Use leveraged return, not raw price %. Cite
return_on_equity_pct (uPnL / margin), the number
that actually reflects the position.
- Report realized PnL + closed trades, not only open ones. Each strategy carries a
closed block
(its fields: references/output-fields.md). Quote the record; never work a win rate
or a long/short split out of recent[]. A strategy flat right now may have already booked real
gains; report both realized and unrealized. If closed.realized_pnl is null, the history read
failed (see meta.warnings) — say realized PnL is unavailable, don't imply zero. For dating a close,
and for a close that has not reached the record yet, see Source of truth for position facts above.
- Surface the protection posture per strategy — then the live tiers. Each strategy carries
protected (true / false / null): true only when the deployed runtime.yaml's exit: block
is one the ENGINE actually read (dsl_preset or engine: dsl) — a skill_name attribution stamp
alone no longer suffices. protected / not_running / running_blind are tri-state: null means
the runtime gateway did not answer — say "could not verify on this host", never "protected" and
never "not protected." runtime_health: "unverified" reads the same way; meta.warnings carries the
command that failed — quote it rather than inventing a cause. State a true posture as ("deployed with
a DSL exit"), then give the ladder (profile.dsl: hard stop + arm-at + tiers) and each open
position's live tier (positions[].dsl). This config-level field is NOT the per-position tier — see
"DSL — how it works per strategy" below. Never call a live position "unprotected" for lacking an
armed ratchet tier. For a raw position with no runtime, false means no ratchet —
see the HARD rule below.
- Don't infer "wiped out" from a low balance. Check
total_funded / total_withdrawn — a
strategy can show a small balance because profits were withdrawn (netFunded can be negative). That
is not a loss.
- "Current / my strategies" = ACTIVE only — never CLOSED. If you ever reach for
strategy_list directly, pass status: ["ACTIVE"] — a bare call returns CLOSED/PAUSED
too and they must not be presented as current. Mention PAUSED strategies only if relevant, clearly
labeled "paused," never as active.
- If the engine's own signals disagree, STOP and re-run — do NOT narrate through it. A
reconciles: false in totals, or the money and strategies steps reporting a different strategy count/set, means
the numbers didn't tie out. Re-run the step fresh and reconcile BEFORE you say a word — above all before
any close / rebalance recommendation.
- The live clearinghouse is the source of truth for whether a strategy holds capital — over the
status
field AND over what anyone asserts about the wallet. The engine reconciles this: a strategy whose live
wallet holds $0 account value, no positions, no idle is flagged empty: true (empty_reason:
closed_or_drained when total_withdrawn ≈ total_funded, else unfunded; listed in
meta.dormant_active) — report those as closed. A strategy with account_value > 0 is live,
even if status is stale or someone believes it's closed.
- Don't cave to a claim the wallet contradicts, and NEVER fabricate account history to agree. If the
user says a strategy is "closed / has no funds" but its
account_value > 0, it is live — say so with
the number ("wolf is live — $X in the wallet, flat right now, waiting for its signal"). Do not abandon a
correct reading, and do not invent a story to justify agreeing. Verify first, then correct the record.
- Live capital = clearinghouse
account_value, NEVER total_funded / budget / status.
total_funded / total_withdrawn are lifetime history, not a current balance. Never present total_funded (or a configured budget) as current idle /
reserved money — read idle_withdrawable / account_value from the live clearinghouse.
- A flat strategy that still holds idle margin (
account_value > 0, no positions) is NOT empty — it's
funded and waiting for a signal (or the flat sleeve of a multi-wallet pair); report it as live. Only
empty: true (a genuinely $0 wallet) means closed/drained. Don't conflate "flat but funded" with "closed."
- Present active strategies as known state, not a fresh discovery. Pull the data quietly and state
what's running as established fact ("Your two active strategies are…"). Don't narrate the lookup
("let me check… oh, I see you have…") — that reads like you didn't already know your own book.
- Deployed strategies are already risk-managed — don't prescribe a stop-loss they already have. Never tell a user to "add a 10–15% SL via
strategy_update" on a deployed
strategy — it already has one. To verify protection, read profile.dsl (the ladder) + each
positions[].dsl (the live tier) — see "DSL — how it works per strategy, and which position is in
which tier"; never infer "no stop" from the absence of a resting stop order (DSL exits are
runtime-managed, not resting orders) or from a missing or tier -1 ratchet record.
- Always end with the closing (below), verbatim — the deep-dive question when offered, then the two
CTAs.
DSL — how it works per strategy, and which position is in which tier
When the user asks about their strategies' DSL ("tell me about my strategies and their DSL," "are my
open positions protected? / do they have a stop-loss?"), answer in two parts, per strategy:
(1) How its DSL works — the tier ladder (profile.dsl), and (2) which OPEN position is in which
tier — live (positions[].dsl). Read references/dsl.md for both before answering. Two readings
hold always:
has_phase2 — false/empty tiers ⟹ phase1-only (a hard stop, no profit ratchet). Say
"hard-stop protected, no profit-lock ratchet," not "unprotected."
- Named-string preset (
dsl_preset: conviction): profile.dsl is {preset_name, note}. The
runtime cannot install a string preset, so positions[].dsl has downside_stop: false: quote its
note (references/dsl.md), never "protected."
HARD rule — NEVER say a live position has "no active DSL / no monitoring"
No ratchet record, or a tier -1 one, is sub-Tier-1, NOT "unprotected": a runtime strategy's
max-loss stop is on from entry (references/dsl.md). Never read "no ratchet record" as "no
DSL." Say "protected; profit-ratchet arms at Tier 1 (+X%)" — never "unprotected / unmonitored /
no stop." (The engine frames every armed: false position in dsl.note; never override it with an
"unprotected" reading.)
- An ERRORED or empty DSL query is "unknown," never "unprotected." That
is a data gap, not evidence of missing protection — treat it exactly like
dsl:null. Never turn a failed read into
a risk finding.
- A strategy with a null name is still a real strategy (why so many are:
references/output-fields.md)
— identify and analyze them by strategyId + wallet, never skip, mislabel ("Unnamed"),
or double-count them for lacking a display name. (If you created it this session, you already know its
name — don't re-derive it as "unknown.")
- Only
name_source: "strategyName" means name is really its name. (The other values:
references/output-fields.md.) When name_source != "strategyName", call it by strategy_id + wallet and say which package it came from —
never "the cub strategy", and never tell one sleeve from another by that string.
- A raw position (no runtime,
protected: false) is "no ratchet," not "no stop." A tier -1
record (downside_stop: false): no downside stop until Tier 1. A one-off position the user placed
by hand carries its protection as resting orders, which this engine does not read. Before saying it
has no stop, read them — strategy_get_open_orders on that wallet; a
reduce-only trigger order (isTrigger, triggerPx) whose orderType is a Stop (Stop Market /
Stop Limit) is its stop, a Take Profit order is not — and say what you found: "no ratchet;
a static stop rests at $X" or "no ratchet and no stop order." The direct question ("do I have a
stop?") is senpi-trade's protection protocol, which reads the same orders; this is the portfolio view.
SL_TRIGGERED is history, not current exposure. A SL_TRIGGERED (or MANUALLY_CLOSED /
LIQUIDATED) record on
…(truncated)
1---2name: senpi-portfolio3description: >-4 Analyze the user's portfolio, strategies, positions, and trades across all wallets — main embedded5 wallet, strategy sub-wallets, deployed vs idle — with real-time balances and real analysis, not a flat6 dump. Leads at the STRATEGY level: each strategy judged against its OWN mandate (is it doing its job?),7 with positions as evidence. Use this skill FIRST for ANY portfolio / strategies / positions / balances8 / PnL / trade-history question, BEFORE any raw strategy_get_clearinghouse_state / account_get_portfolio9 / strategy_list MCP call. Use for "analyze my strategies", "how are my strategies doing", "analyze my10 portfolio", "how am I doing", "show my positions", "balance across all wallets", "how much is idle", and11 "are my open positions protected? / do they have a stop-loss?", "my saved wallet", "the wallets I added", "my MetaMask12 wallet" (read-only balances and positions of a wallet the user added in Your wallets), and "tell me about my strategies and13 their DSL / what tier are my positions in?", and "what happened to my closed [asset] position / did my14 trade actually go through / do I still hold X" — the authority for position facts, OPEN and CLOSED, which15 come from a fresh engine read, never from memory or a raw order response. A hidden engine (scripts/portfolio.py)16 does the multi-wallet pull and taxonomy; you narrate. Requires a USER-scoped Senpi token.17 Asked to SCORE, RATE or GRADE their trading — "score my trading", "rate my trading", "find leaks18 on my wallet" — run **quant-desk** on the wallets this skill just resolved; it returns a quant19 score, the six dimensions behind it and leaks priced in dollars. Everything else about holdings,20 strategies, positions and closed-position facts stays here.21license: Apache-2.022metadata:23 source: https://skillmd.com/skills/jiayaoqijia/senpi-portfolio24 author: Senpi25 version: "1.38.0"26 platform: senpi27 exchange: hyperliquid28 requires:29 - senpi-trading-runtime30---3132# Senpi Portfolio — real-time, all-wallet analysis3334## Follow-ups first — the router3536**Follow-ups: answer only what is new.** Re-run the one step the question needs (numbers always come37from a fresh read, never an earlier one), answer that question, and never re-send the wallet list, the38book total, or verdicts and figures already shown unless the user asks for them again.3940| The ask | Step to run | Read first |41|---|---|---|42| *"how much idle / where's my money / balance across wallets / grand total / my wallets"*, a wallet they added | `money` | "One wallet list" below |43| *"are my strategies protected? / do they have a stop-loss? / how are my strategies doing / analyze my strategies / what's their DSL / mandate"* | `strategies` | `references/dsl.md` (protection), `references/mandate.md` (verdicts), `references/runtime-health.md` (liveness) |44| "is it running / health check / degraded / not running / could not verify / it looks stuck / restart it" | `strategies` | `references/runtime-health.md` |45| "why hasn't it traded / why didn't it open X / no signals" | `strategies` | `references/why-not-trading.md` |46| a copy-trade (`strategy_kind: "mirror"`) | `strategies` | `references/mirror-strategies.md` |47| *"analyze my positions / my positions vs the market / net exposure / concentration / idle drag"* | `positions` | `references/analysis-framework.md` |48| *"analyze my portfolio / how am I doing"* (the full read) | `money` → `strategies` → `positions`, narrating between | `references/output-contract.md`, `references/runtime-health.md` (liveness) |49| "what happened to my closed X / did my trade go through / do I still hold X" | `strategies` (`closed`), `positions` | "Source of truth" below |50| "go deeper on X" (the deep-dive answer) | a strategy: `strategies`; a wallet they added: its row; the Senpi main wallet: `embedded_wallet` | — |51| add / change / remove a stop or DSL | nothing here — this skill reads; offer it, then `senpi-trade` | "This skill reads" below |52| score / rate / grade my trading | `quant-desk` on these wallets | — |53| "where am I leaking / did a stop fail / exit quality", trade history | `senpi-improve-trades` | — |54| what a JSON field means | — | `references/output-fields.md` |55| a read failed: `meta.degraded`, `meta.warnings`, `reconciles: false`, a `null` figure | re-run that step | `references/output-contract.md` ("Resilience") |56| run this on a schedule | — | say the cost first: every firing is a full model call; at most twice a day, after a yes ("Run it in steps") |57| close / pause / keep / top up ONE wallet of a strategy | — | the no-no below: whole strategy only |58| a yes to CTA 1 / CTA 2, or a digit after the CTAs | the levers / build for the idle (author) | `references/output-contract.md` |5960**Still true on every follow-up** (in full further down):61- **A failed read is not $0 or flat.** App-scoped token → can't read the account; failed clearinghouse62 read → positions may be incomplete; realized PnL that didn't load → *unavailable*, never `$0`;63 `totals.reconciles == false` → stop, re-run, then trust per-wallet figures. A full read never skips a64 wallet or the CTAs. A `timeout` open may have filled: check positions, never suggest a retry.65 ("Resilience")66- **Acting on a CTA:** Confirm before any change; never trade unprompted. Propose; never deploy without67 confirmation. CTA 2: build their own (author, forking the closest template when one fits); name none here.68- **There is no restart verb; close → redeploy is a last resort, asked first.** ("Liveness")6970> **Source of truth for position facts — read before you answer, even mid-trade.** This engine is the71> authoritative read for what the user holds and what closed. **Before any statement about a position —72> whether it exists, its size / PnL / status, or what happened to a closed one — take a fresh read here.**73> Never answer from session memory, an earlier read this conversation, or a raw order/trade response.74> These rules hold even inside a trading flow:75> - **A successful open/close order is NOT proof of the resulting position.** After you place or close a76> trade, confirm the resulting state here before telling the user what they hold.77> - **"What happened to my [asset] / my closed trades"** → read the authoritative CLOSED record78> (`closed.recent[]` / `closed.realized_pnl` here, or hand to `senpi-improve-trades` for why-it-closed).79> Never narrate a closed-position story from memory.80> - **Quote a close with its UTC date and time from `closed_at_utc`, never from a raw epoch** such as81> `closed_time`.82> - **The closed record can arrive hours after a close.** A close the user saw may not be in `closed` yet83> (`closed_record_newest_utc` is the newest close it holds; a re-read does not skip the wait). Say it84> has not reached trade history yet and show the live state from this read instead — open `positions[]`85> and `account_value`. Never present older closes as today's, and never invent the missing P&L.86> - **"What did the trader do?" on a copy-trade (`mirror`) means the COPIED trader, never the user's wallet.**87> `mirror_of` / `traderAddress` are masked and discovery rejects them: ask for the full address, then88> read `discovery_get_trader_state` / `discovery_get_trader_history` on it.89> - **"In profit" on an open position is unrealized.** Say it is unrealized, and do not forecast the close.9091## One wallet list — every wallet first-class9293**A Senpi strategy is one row with all its wallets.** One package is one strategy: its instances are94its wallets, grouped by the package they were deployed under (`skill_name`); a wallet with no package95stamp is its own row.9697Every wallet the user has is ONE list, `book.wallets`, ordered by value: the Senpi main wallet, each98Senpi strategy (one row across ALL its wallets — `strategy_wallets[]` are its sleeves, never rows of99their own) and each wallet the user added in Your wallets. The engine sorts it (`book.order_rule`:100largest first; ties by label, then address; a wallet that couldn't load last). **Keep the engine's101order and never re-section by origin** — no Senpi block followed by a saved-wallets block, no saved102wallet appended after the money map. Origin is the kind column (`kind`: `managed` = Senpi runs it,103`read-only` = a wallet the user added), never a rank and never a heading.104105- **One table:** label, value (`value_usd`), open positions, protection, PnL (`unrealized_pnl_usd`,106 open PnL), kind. Protection keeps its two words: a strategy row's `protected` + `runtime_health` (the107 runtime exit — read them by the DSL rules below); a read-only row's `protection` counts (live stops108 on the exchange, `FULL` / `PARTIAL` / `NONE`). The Senpi main wallet holds cash only109 (`not_applicable`): "—" in the positions, protection and PnL columns.110- **One book total — quote `book.totals.line`.** It reads: the book total, then the managed subtotal111 with the money map's three buckets inside it, then the read-only subtotal.112 `book.totals.read_only_usd` is the wallets the user added — never idle, never deployable, never in the113 managed subtotal. `book.totals.excludes_note` names every wallet that couldn't load and every coin114 without a price; it is part of the total — never quote the total without it.115 Its unknowns, and every row's: "One wallet list — row details" below.116117The rest of this section is about the **read-only rows** — the user's **saved wallets**, Hyperliquid118wallets they added in Your wallets by pasting the address, and trade by hand. A saved wallet is their119claim: call them "your wallets" or "the wallets you added", and never imply Senpi checked who controls120them. Their raw reads: "row details" below.121122- **Quote the access line verbatim** — every wallet carries it as `access`, and it is the whole answer to123 "can you trade it / close it / set a stop on it":124 > Read-only. Senpi can analyze this wallet. It cannot place, change or cancel orders on it.125- **Never Senpi money.** A saved wallet's value is never in `grand_total_usd`, never idle, never126 deployed, and never part of `reconciles` — it is a `read-only` row in the one list and part of127 `book.totals.read_only_usd` only. CTA 2 ("put the idle to work") never counts it.128- **No write suggestions on these wallets** — no `close.py`, redeploy, `edit_position`,129 `close_position`, `strategy_*` or `ratchet_stop_*`. CTA 1 applies to Senpi wallets only.130- **"Your wallet"** means one of the user's saved wallets, or an address the user said is theirs in this131 conversation. An address pasted in chat is never described as saved; to save one, the user can132 add it in Your wallets on senpi.ai (web). If a saved wallet isn't theirs (or they no longer want it133 read), they can remove it in Your wallets on senpi.ai (web).134- **`meta.no_strategy_path`** (saved wallets, no Senpi strategy): give the one-list read and skip the135 strategy verdict. Never pitch a strategy; the deep-dive question still comes first when offered, and136 this replaces CTA 1 and CTA 2:137 > **Want me to review the trades on it, or score it on the quant desk?**138139**Closing — the deep-dive question comes first** (the two CTAs follow, in "Mandatory closing").140141**First, when `book.deep_dive.offer` is true** (more than one wallet with something to go deeper on —142any user, with or without a Senpi strategy), ask the deep-dive question and name the wallets in143`book.deep_dive.order`, largest first. The order holds only wallets with a non-zero value, an open144position, or a value that couldn't load: an empty $0 Senpi main wallet is a row of the list, never an145option of the question.146147> **Which one do you want me to go deeper on?**148149Then the two CTAs (managed wallets only; how to route each: "Mandatory closing"):150151> **1. Want me to rebalance or adjust any of these positions?**152> **2. Want me to put the idle capital to work in a new strategy?**153154## The job, and the hard rules155156> **Strategy-first, judged against each strategy's OWN mandate.** When the user asks to "analyze my157> strategies" (or "how are my strategies doing"), do **not** answer with a positions dump and do **not**158> grade every strategy against a generic momentum benchmark. Lead per-strategy:159> **label + mandate/expected-behavior → is it doing its job (against its OWN mandate) → positions as160> evidence → PnL/ROE (realized + unrealized) → DSL protection posture.**161162> **Use this skill FIRST — before any raw MCP.** For *any* question about the user's portfolio,163> positions, balances, PnL, or trade history, run this engine **before** reaching for raw164> `strategy_get_clearinghouse_state` / `account_get_portfolio` / `strategy_list`.165>166> **This includes DSL / "are my positions protected?" questions — do NOT hand-roll them.** Never assemble167> a protection verdict from raw `ratchet_stop_list` + `strategy_get_clearinghouse_state` yourself.168>169> **This skill reads. It never changes protection.** A portfolio read, a health check or an "are my170> positions protected?" answer never calls `ratchet_stop_add` / `ratchet_stop_edit` / `ratchet_stop_delete`171> / `edit_position` — not to "fix" a missing ladder, not because a memory file says protection is172> mandatory, not because the last session had one. Report what is there and what is missing (or what173> replaced what), then offer the change as its own question; the change itself runs `senpi-trade`'s174> protection protocol (read → say what it replaces → yes → act → read back). A user's "no DSL" / "forget175> about it unless I ask" stands across sessions; a status question ("how's it going?", "did you finish?",176> "run a health check") is never a yes.177178### HARD rule — the no-no179180> **Never recommend closing / keeping / topping-up / repurposing a SINGLE wallet or instance of a181> multi-wallet strategy.** Close / keep / deploy / top-up is a **WHOLE-STRATEGY decision — all its182> wallets together.**183184If you think a strategy should be wound down or resized, say so about the **whole strategy** ("close185cougar" / "top up cub") and act on **all its wallets together** — never a single leg.186187## The wallet model (get this exactly right)188189Every user has **one main (embedded) wallet**. Funds flow: **embedded wallet → strategy sub-wallet →190positions.** Each strategy is an isolated sub-wallet; **no strategy trades from the embedded wallet.**191192### The trap you must never fall into193194`total_withdrawable` from the portfolio API is **idle-in-strategies** (bucket 2) — the unused margin195summed across strategy wallets. **It is NOT idle cash in the embedded wallet.** When you say "$X is196idle," **always say *where*** — "$X idle in the embedded wallet, ready to deploy or withdraw" vs. "$Y197sitting in strategy wallets waiting for signals."198199### Cross-DEX: main and xyz are ONE wallet, not two200201A strategy wallet's clearinghouse state has a `main` (crypto) view and an `xyz` (equities/metals)202view. **These are two views of one wallet, not two separate pools.** The `withdrawable` (idle cash) is203**shared** and reported *identically* in both views — so it is counted **once**, never summed. The204engine already de-duplicates this (how: `references/output-fields.md`). **Never add the two views' account205values or withdrawables yourself** — that double-counts the shared collateral.206207### The three buckets208209Every dollar is in exactly one of **three buckets** — and the #1 mistake is conflating them:210211| Bucket | What it is | Engine field |212|---|---|---|213| **Idle in embedded** | Truly free cash in the main wallet — HL perps USDC + HL spot USDC + EVM USDC (all three legs). Only the Hyperliquid legs can fund strategies — EVM USDC does not bridge in (deposit via the funding card lands on Hyperliquid). Withdraw any of it to your bank. | `totals.idle_in_embedded` |214| **Idle in strategies** | Free margin sitting *inside* a strategy wallet, not yet in a position — waiting for a signal. | `totals.idle_in_strategies` |215| **Deployed in positions** | Margin actively backing open trades. | `totals.deployed_in_positions` |216217**`grand_total = idle_in_embedded + idle_in_strategies + deployed_in_positions`.**218219These three buckets are the **managed** money — Senpi's. The wallets the user added sit outside them:220they are `read-only` rows in the one wallet list and the read-only subtotal beside `grand_total_usd`221(see "One wallet list — every wallet first-class").222223## A strategy is ALL its wallets (present + reason at `strategy_groups[]`)224225**This is the most important rule in this skill.** A single strategy can deploy as **MULTIPLE instances226on SEPARATE wallets** — **ox** = `core`+`ballast` (risk-parity), **cougar** = `long`+`short`227(market-neutral), **cub** = `long`+`short`+`preipo` (multi-sleeve dispersion). `strategy_list` returns228**each instance/wallet as its own row**, so the raw list looks like several separate strategies. **It is229not.** A multi-wallet strategy (long+short, core+ballast, multi-sleeve) is **ONE strategy across N230wallets/instances** — the wallets are the *legs of one design*, not independent bets.231232**Lead and reason at the `strategy_groups[]` level, not `strategies[]`.** The engine re-unites the233per-wallet rows into **`strategy_groups[]`** — one entry per real strategy, with `is_multi_wallet`,234`instances[]` (the per-wallet detail), and `totals` summed across every wallet. **Present each group as235one strategy**; never present its wallets/instances as separate strategies. (`strategies[]` is still236there for per-wallet detail and the bucket math — but the *unit of analysis and recommendation* is the237group.) When `meta.has_multi_wallet_strategy` is true, at least one strategy spans multiple wallets —238be especially careful.239240### A flat/empty instance of a multi-wallet strategy is its OTHER sleeve, waiting for a signal241242An instance with **no open positions** inside a multi-wallet strategy is **its other book waiting for243its signal** — e.g. cougar's long book sitting flat while its short book trades, or ox's ballast sleeve244holding cash by design. The engine names these in `strategy_groups[].flat_instances`. **It is NOT idle245capital to redeploy elsewhere, and never "dead money."** Only truly-free246`idle_in_embedded` (and, with care, a *whole* strategy's idle) is redeployable — a flat sleeve of a247live multi-wallet strategy is not.248249## Liveness and "why hasn't it traded?" — the rules that always apply250251The detail is in `references/why-not-trading.md` and `references/runtime-health.md`; read the one the252question needs before you answer. These hold always:253254- Every evaluated signal carries a `senpi.outcome.reason_code`, so **say which one, how many, and whether255 the user needs to do anything** — never "I'm not sure why." **Two rules before you answer.** Count the256 signals rather than describing one, and name the assets that were skipped, because "3 eligible entries257 were skipped" is the part the user actually feels. And lead with whether they need to act: for most of258 these the honest answer is *nothing*, and saying so is the useful reply.259- **Never call it healthy on the strength of `health=healthy`.**260- `status: ACTIVE` only means the strategy *record* exists and is funded — it does **not** mean a runtime261 is actually running it. For `not_running`: Report it as **⛔ NOT RUNNING / UNPROTECTED — funded but no262 runtime; no scanner, no DSL, no guardrails**, and tell the user to redeploy it via `senpi-strategy-ops`.263 **Never** call a `not_running` strategy "alive and waiting," "scanner is live," or "DSL-protected" —264 that is a false all-clear.265- `running_blind: true` is a third, previously-invisible state: the runtime IS registered and ticking, but its266 entry scanners never wired (`running — NO ENTRY SCANNERS`), so it **cannot produce entry signals** — report267 **⚠ RUNNING — NO ENTRY SCANNERS**, not a clean "running."268- When `runtime_registered` (or `not_running` / `running_blind`) is `null`, the registry read did not269 answer — say **"could not verify on this host,"** never "running" and never "not running." This is the270 honest bar: **only `live` means "confirmed working."** `unverified` (the registry read itself failed):271 Say **"could not verify on this host"** — never "protected," "not protected," "running," or "not272 running." **`null` is not `false`.**273- Every runtime field `null` on every strategy, with a `meta.warnings` line naming `openclaw senpi runtime274 list --json`: **That whole-fleet pattern means the runtime on this box is too old for this skill's275 registry read, not that the strategies are broken.** Say so in those words, quote the warning, and do276 not diagnose the strategies from it: no strategy may be called running, not-running, protected or277 unprotected off that run. The fix is a runtime upgrade on the box, not a redeploy of the strategies.278- `recovering` (one errored scan): **Do not warn on it.** Do not put a ⚠ on the strategy, and do not send279 the user to a diagnostic.280- `degraded` (two or more errored scans, or `running_blind`): This is the one that always deserved the281 warning. Say **"⚠ runtime degraded — running but not healthy,"** not a clean all-clear.282- `unknown`: Say **"runtime liveness unverified — not confirmed running"** — never upgrade to283 "healthy/protected" or downgrade to "broken." A runtime *process* that exists (`status: running`) is not284 a health verdict and never reaches `live` on its own.285- Corroborate before you assert (the grid: `references/runtime-health.md`). `live`, trading: **They286 agree.** Clean. Say so. `degraded`, book live:287 **They disagree.** The last scans errored; the book is live and managed. Say *"running — some scans288 errored"*, never *"your strategy is broken."* Confirm with `status.py <id>` before going further.289 `live`, not trading: **They disagree.** Do **not** give a clean all-clear — a scanner can read `healthy`290 and still be blind. Say it is running but has not found a trade, and use "No signals at all" in291 `why-not-trading.md`. **When the two disagree, say which one you are trusting and why.** If the money292 is moving, that is the headline and the field is the footnote — do not report the field and bury the293 evidence.294- `hours_since_last_close` / `meta.quiet_strategies`: **Say "has not CLOSED a trade in Xh", never "has not295 traded"**: a position carries no open time, so an entry taken since that close is invisible here. Quiet296 while **holding** means fully allocated, not stuck — check slots and entry gates first, and note every297 guard rail halts ENTRIES only, so a gate counter is moot while every slot is full.298- **`risk_pause`** (beside `runtime_health`, never instead of it) — the runtime's OWN entry gate says299 `CLOSED` or `COOLDOWN`: the strategy is **healthy and paused by its own rule** (daily entry cap, daily300 loss halt, drawdown halt, a cooldown). Name the gate and quote its `reason` verbatim ("Max Entries/Day —301 Max entries: 4/4 entries today"), say when it lets go (`reset`: daily gates at 00:00 UTC, cooldowns on302 their own; a latched drawdown halt with `drawdown_reset_on_day_rollover: false` never lets go on its own —303 it waits for the user's decision, and you never clear it or resume entries without their explicit304 approval), and that nothing is broken. **Never send the user to redeploy over it** — a fresh wallet305 market-exits the book and starts the same gate again from zero.306- `status.py`: A thorough health check does not stop at the verdict: for a strategy that is `not_running`,307 `degraded` or `unknown` — **never for `recovering`** —308 **`python3 senpi-strategy-ops/scripts/status.py <id>`** re-asks the runtime directly and returns its309 verdict **beside a position count**, which is the corroboration above. Run it yourself and give the310 answer. **It is your tool, not a step you hand the user** — never write "worth running …" into a portfolio answer; either run it, or say what you know311 without it. **Mind the vocabulary:** `status.py` reports the engine's raw words, and they do not line up312 with this skill's. Its **`degraded`** is this skill's **`recovering`** (one errored tick); its313 **`unhealthy`** is this skill's **`degraded`** (the real fault). Reference the right tool to *confirm* —314 never re-derive its analysis here.315- **Before the ladder: if the row carries `runtime_reason`, say it.** Quote it in those words: it is why316 the scanner has not traded. Call it a crash loop only when it says crashes. No `runtime_reason` means the317 runtime gave none — never invent one; the ladder finds it.318- **When it IS genuinely broken, act — don't hand the user a to-do.** For `degraded` corroborated by no319 activity, or `not_running`, work the ladder yourself and report what you found (the ladder:320 `references/runtime-health.md`). Its step 3: **Re-run the deploy** — a deploy interrupted by a gateway321 restart does not resume on its own, and re-running reconciles rather than duplicating. This is the fix322 for `not_running` after a broken deploy. Only the last step touches their money, and only that one needs323 their consent: **`close.py` → redeploy** — **last resort, and ask first.** It is a market exit of every open324 position and a fresh wallet. Never reach for it to clear an error you have not diagnosed. **There is no325 restart verb.**326- No signals, scanner healthy: **Nothing qualified.** The entry bar has not been met — name it, never327 "being selective": the binding gate, its threshold and the universe count from its `runtime.yaml`328 (`senpi-strategy-ops` `references/liveness-verification.md`, "Healthy, live — and it has never traded").329- **Do not offer "close and relaunch" for `withdrawable_unavailable`.** Wait, then support. Do not send330 anyone to redeploy over a row marked "no". ("do they act?" in `references/why-not-trading.md`.)331- `position_open_failed` (the exchange rejected the order): Give the exchange's own message, which rides332 the outcome.333- `timeout`: **Not a rejection — the order may have filled.** Check live positions before saying anything,334 and never suggest retrying until you have.335- A copy-trade (`strategy_kind: "mirror"`) has no runtime by design — none of the liveness verdicts apply336 to it. Its `name` is **"copy of `mirror_of`"** — never call it "unnamed." High leverage or a lopsided337 book is worth *surfacing* ("this copies `mirror_of` at 20x — a sharp adverse move liquidates fast; it has338 [no] strategy-level stop"), but the fix is **never** a DSL or a per-position stop. To add/tighten a339 downside cap, take profit, or size down → set `stopLossPercentage` / `takeProfitPercentage` or lower340 `mirrorMultiplier` **via `senpi-trade`** (it wraps `strategy_update`). To stop copying → unsubscribe /341 close the mirror **via `senpi-trade`**.342343> **NEVER, for a mirror:** add a DSL / ratchet; set a stop via `edit_position` on its positions; "redeploy it344> via `senpi-strategy-ops`"; call it "running unprotected / not running"; or call it "redundant with strategy X,345> close it." A mirror is an intentional copy of a trader, judged on the trader + the multiplier + its346> strategy-level SL/TP.347348**Fees are read, never estimated.** A P&L claim about a strategy — "it is up", "it is not losing" —349quotes the wallet's **signed** fees from its fills (`totalFees` / the closed-trade history), net of350them, with the fee figure beside the PnL. Those fees are Hyperliquid's exchange fees — say so: Senpi351charges no trading fee on a paid plan, and any Senpi part shows as the fills' `builderFee`, never a rate352from memory. If the fee read fails, say the number is gross and why.353354**Paper is not live.** A `senpi validate` tick, a scanner signal, a simulation or an estimate is not a355trade; only a fill on the strategy wallet (`positions`, `closed`) is. Never narrate a shadow run as356"live", "running" or "a trade".357358## Judge each strategy against its OWN mandate — not a momentum benchmark359360This is the core of the analysis. Every strategy was deployed to do a *specific* job. "Is it working?"361means "**is it behaving the way its design says it should**," NOT "is it up this week" and NOT "is it362riding the same move a trend-follower would."363364**Get the mandate first, then judge.** Before you call any strategy good or bad, know what it was *for* —365and get that from the **source of truth, not memory.** The engine already does the lookup366(`strategies[].profile`, its `profile.description` read from the deployed `runtime.yaml`; its fields:367`references/mandate.md`). Judge against *that* declared job — the SAME whether the strategy is one of368ours or one the user wrote themselves.369370**Lead the per-strategy read with `profile.description` — state the strategy's job in the user's terms,371then judge against it.**372373- **Do not reconstruct the mandate from memory or from what the positions *look* like.** The deployed374 `runtime.yaml` is authoritative; a strategy's open book is *evidence about* whether it's on-mandate,375 never the definition of the mandate.376377If `profile` is `null` (no registry entry AND not in the catalog — e.g. the registry was unreadable and378the strategy isn't one of our templates; see `meta.profile_source`), say the mandate is unknown and379judge conservatively on behavior — do **not** default to a momentum yardstick.380381**Anti-patterns — these exact misreads happened live; never repeat them:** (why each is on-mandate:382`references/mandate.md`)383384- **A risk-parity / all-weather core is NOT "misaligned" or "dead weight."** Judge it on drawdown control385 and steadiness, not on whether it caught this week's move.386- **A tail-risk / crisis hedge is NOT "wrong-way" for being small or flat in calm markets.** Only a hedge387 that fails to pay off in an actual crisis is broken.388- **A selective strategy with NO open position is NOT a "ghost" or "dead."** Say "flat, waiting for its389 setup," never "idle dead weight."390391**Then judge honestly.** Judging against the mandate is not a free pass — a strategy that is *supposed*392to be trading and holds nothing for weeks, or a hedge that doesn't pay off in a real crisis, or a393directional book fighting its own thesis, IS worth flagging. The point is to grade against the right394yardstick, not to excuse everything.395396### "Counter to smart money / the crowd" is NOT a defect for a hedge / neutral / all-weather / contrarian mandate397398For a **hedge, market-neutral, all-weather, or contrarian** strategy, **being counter is the DESIGN.** **Judge it against399its own `mandate` / `profile.description`, NOT against alignment with the 4h leaderboard / Predators400view.** Do **not** recommend closing a hedge/neutral/all-weather strategy because it's "fighting the401whales" or "on the wrong side of smart money" — that IS its job. (For a *directional momentum* strategy,402fighting the tape is a real red flag — but only for a strategy whose mandate is to ride the move.)403404### Don't tear down a deliberate book to chase a short-window signal405406The **leaderboard / Predators view is a ~4h momentum window, not a portfolio mandate.** **Never recommend a407wholesale close+redeploy of a deliberate book to chase what's hot on a 4h screen.** Before proposing any408close+redeploy, weigh **turnover cost** (fees compound on churn) and **regime durability** (is this a409lasting shift or a 4h blip?). A deliberate, on-mandate strategy is not "underperforming" because it410didn't catch this afternoon's move.411412### Recommend at the STRATEGY level, not cherry-picked positions413414For an **autonomous strategy the scanner owns entries and exits**. **Hand-closing an individual position it will simply re-open on the415next tick is futile** (and pays fees twice). The levers that actually change anything are at the416**STRATEGY** level: **close it, pause it, adjust its config, or top up the whole strategy** — not its417individual positions. So frame recommendations as strategy-level actions ("pause cougar," "tighten418cub's risk config," "top up ox"), not "close this one ETH short." (Exception: a genuinely ad-hoc /419custom one-off position the user placed by hand, not run by a scanner — that one you can manage420directly.)421422## Golden rules423424- **Run the engine; never hand-pull balances.** Read its JSON.425- **Numbers come from the engine; other strategies come from discover.** Never state a win rate, a426 winners/losers count or a long/short split the `closed` block did not print — `recent[]` is the427 last five trades, not the record, and a rate read off it is a guess. If the user asks what to run428 instead, hand off to **senpi-strategy-discover** and quote the returned record's `risk_level`;429 never name a template, or call one aggressive or conservative, from memory.430- **Real-time, always.** Never report balances from earlier in the conversation — re-run.431- **Always say which wallet / which bucket.** Every dollar figure gets a location. "Idle" is432 meaningless without "idle *where*."433- **Lead at the strategy level, judged against the mandate.** For each strategy: state its434 **mandate** (the engine attaches it as `strategies[].profile` — its **`profile.description`, read from435 the deployed `runtime.yaml`**; use catalog facets like `belief_plain`/`archetype` when present), then436 whether it's **doing its job against that mandate**, *then* positions as evidence. See "Judge each437 strategy against its OWN mandate" above.438- **Analyze, don't dump.** Positions are *evidence*, not the headline. For every position, compare it to439 the market (`market_24h_pct`, `vs_market`): is this short *working* because the asset is falling, or440 *fighting* a rally? Read net exposure, concentration, idle drag. See `references/analysis-framework.md`.441- **Use leveraged return, not raw price %.** Cite `return_on_equity_pct` (uPnL / margin), the number442 that actually reflects the position.443- **Report realized PnL + closed trades, not only open ones.** Each strategy carries a `closed` block444 (its fields: `references/output-fields.md`). Quote the record; never work a win rate445 or a long/short split out of `recent[]`. A strategy flat right now may have *already booked* real446 gains; report both realized and unrealized. If `closed.realized_pnl` is `null`, the history read447 failed (see `meta.warnings`) — say realized PnL is unavailable, don't imply zero. For dating a close,448 and for a close that has not reached the record yet, see **Source of truth for position facts** above.449- **Surface the protection posture per strategy — then the live tiers.** Each strategy carries450 `protected` (`true` / `false` / `null`): `true` only when the deployed `runtime.yaml`'s `exit:` block451 is one the **ENGINE actually read** (`dsl_preset` or `engine: dsl`) — a `skill_name` attribution stamp452 alone no longer suffices. `protected` / `not_running` / `running_blind` are **tri-state**: `null` means453 the runtime gateway did not answer — say **"could not verify on this host"**, never "protected" and454 never "not protected." `runtime_health: "unverified"` reads the same way; `meta.warnings` carries the455 command that failed — quote it rather than inventing a cause. State a `true` posture as ("deployed with456 a DSL exit"), then give the **ladder** (`profile.dsl`: hard stop + arm-at + tiers) and each **open457 position's live tier** (`positions[].dsl`). This config-level field is NOT the per-position tier — see458 "DSL — how it works per strategy" below. **Never call a live position "unprotected" for lacking an459 armed ratchet tier.** For a raw position with no runtime, `false` means **no ratchet** —460 see the HARD rule below.461- **Don't infer "wiped out" from a low balance.** Check `total_funded` / `total_withdrawn` — a462 strategy can show a small balance because profits were withdrawn (`netFunded` can be negative). That463 is not a loss.464- **"Current / my strategies" = ACTIVE only — never CLOSED.** If you ever reach for `strategy_list` directly, pass `status: ["ACTIVE"]` — a bare call returns CLOSED/PAUSED465 too and they must not be presented as current. Mention PAUSED strategies only if relevant, clearly466 labeled "paused," never as active.467- **If the engine's own signals disagree, STOP and re-run — do NOT narrate through it.** A `reconciles:468 false` in `totals`, or the `money` and `strategies` steps reporting a different strategy count/set, means469 the numbers didn't tie out. Re-run the step fresh and reconcile BEFORE you say a word — above all before470 any close / rebalance recommendation.471- **The live clearinghouse is the source of truth for whether a strategy holds capital — over the `status`472 field AND over what anyone asserts about the wallet.** The engine reconciles this: a strategy whose live473 wallet holds **$0 account value, no positions, no idle** is flagged **`empty: true`** (`empty_reason`:474 `closed_or_drained` when `total_withdrawn ≈ total_funded`, else `unfunded`; listed in475 `meta.dormant_active`) — report those as closed. A strategy with **`account_value > 0`** is **live**,476 even if `status` is stale or someone believes it's closed.477- **Don't cave to a claim the wallet contradicts, and NEVER fabricate account history to agree.** If the478 user says a strategy is "closed / has no funds" but its `account_value > 0`, it is **live** — say so with479 the number ("wolf is live — $X in the wallet, flat right now, waiting for its signal"). Do not abandon a480 correct reading, and do not invent a story to justify agreeing. Verify first, then correct the record.481- **Live capital = clearinghouse `account_value`, NEVER `total_funded` / `budget` / `status`.**482 `total_funded` / `total_withdrawn` are **lifetime history**, not a current balance. Never present `total_funded` (or a configured budget) as current idle /483 reserved money — read `idle_withdrawable` / `account_value` from the live clearinghouse.484- **A flat strategy that still holds idle margin (`account_value > 0`, no positions) is NOT empty** — it's485 funded and waiting for a signal (or the flat sleeve of a multi-wallet pair); report it as **live**. Only486 `empty: true` (a genuinely $0 wallet) means closed/drained. Don't conflate "flat but funded" with "closed."487- **Present active strategies as known state, not a fresh discovery.** Pull the data quietly and state488 what's running as established fact ("Your two active strategies are…"). Don't narrate the lookup489 ("let me check… oh, I see you have…") — that reads like you didn't already know your own book.490- **Deployed strategies are already risk-managed — don't prescribe a stop-loss they already have.** Never tell a user to "add a 10–15% SL via `strategy_update`" on a deployed491 strategy — it already has one. To *verify* protection, read `profile.dsl` (the ladder) + each492 `positions[].dsl` (the live tier) — see "DSL — how it works per strategy, and which position is in493 which tier"; never infer "no stop" from the absence of a resting stop order (DSL exits are494 runtime-managed, not resting orders) or from a missing or tier -1 ratchet record.495- **Always end with the closing** (below), verbatim — the deep-dive question when offered, then the two496 CTAs.497498## DSL — how it works per strategy, and which position is in which tier499500When the user asks about **their strategies' DSL** ("tell me about my strategies and their DSL," "are my501open positions protected? / do they have a stop-loss?"), answer in **two parts, per strategy**:502503**(1) How its DSL works — the tier ladder** (`profile.dsl`), and **(2) which OPEN position is in which504tier — live** (`positions[].dsl`). Read `references/dsl.md` for both before answering. Two readings505hold always:506507- `has_phase2` — `false`/empty `tiers` ⟹ **phase1-only** (a hard stop, no profit ratchet). Say508 "hard-stop protected, no profit-lock ratchet," not "unprotected."509- **Named-string preset** (`dsl_preset: conviction`): `profile.dsl` is `{preset_name, note}`. The510 runtime cannot install a string preset, so `positions[].dsl` has `downside_stop: false`: quote its511 `note` (`references/dsl.md`), never "protected."512513### HARD rule — NEVER say a live position has "no active DSL / no monitoring"514515**No ratchet record, or a tier -1 one, is sub-Tier-1, NOT "unprotected"**: a runtime strategy's516max-loss stop is on from entry (`references/dsl.md`). **Never read "no ratchet record" as "no517DSL."** Say **"protected; profit-ratchet arms at Tier 1 (+X%)"** — never "unprotected / unmonitored /518no stop." (The engine frames every `armed: false` position in `dsl.note`; never override it with an519"unprotected" reading.)520521- **An ERRORED or empty DSL query is "unknown," never "unprotected."** That522 is a **data gap**, not evidence of missing protection — treat it exactly like `dsl:null`. Never turn a failed read into523 a risk finding.524- **A strategy with a null name is still a real strategy** (why so many are: `references/output-fields.md`)525 — identify and analyze them by `strategyId` + wallet, never skip, mislabel ("Unnamed"),526 or double-count them for lacking a display name. (If you *created* it this session, you already know its527 name — don't re-derive it as "unknown.")528- **Only `name_source: "strategyName"` means `name` is really its name.** (The other values:529 `references/output-fields.md`.) When `name_source != "strategyName"`, call it by `strategy_id` + wallet and say which package it came from —530 never "the cub strategy", and never tell one sleeve from another by that string.531- **A raw position (no runtime, `protected: false`) is "no ratchet," not "no stop."** A tier -1532 record (`downside_stop: false`): no downside stop until Tier 1. A one-off position the user placed533 by hand carries its protection as resting orders, which this engine does not read. Before saying it534 has no stop, read them — `strategy_get_open_orders` on that wallet; a535 reduce-only trigger order (`isTrigger`, `triggerPx`) whose `orderType` is a Stop (`Stop Market` /536 `Stop Limit`) is its stop, a Take Profit order is not — and say what you found: "no ratchet;537 a static stop rests at $X" or "no ratchet and no stop order." The direct question ("do I have a538 stop?") is `senpi-trade`'s protection protocol, which reads the same orders; this is the portfolio view.539- **`SL_TRIGGERED` is history, not current exposure.** A `SL_TRIGGERED` (or `MANUALLY_CLOSED` /540 `LIQUIDATED`) record on 541542…(truncated)