portfolio-risk-review
Skill23 starsChanged 3 months agoMITView on GitHub
Single-pass holdings analysis for kcn using workspace files and the local fetch chain. Use for portfolio review, position risk ranking, US-HK cross-market read, leverage ETF risk assessment, and one-shot actionable reports based on portfolio.json plus fresh quotes from `clawock analyze-us` / `clawock analyze-hk`.
In this repository14 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- site/llms.txtllms.txt
- daily-deep-briefSkill
- earnings-reviewSkill
- entry-gateSkill
- hk-stock-analysisSkill
- openclaw-tuneSkill
- openclaw-upgradeSkill
- portfolio-swarm-reviewSkill
- scraplingSkill
- serenity-skillSkill
- tavilySkill
- us-stock-analysisSkill
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 2 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 42
Use the returned quote coverage/source warnings to mark stale or unverified holdings.
- Very specific: line 97
Keep core_position, tactical_entry, and risk_rebalance separate.
- Distinctive: line 134
Do not substitute external "best practice" frameworks for the workspace data chain
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Portfolio Risk Review
Single-pass portfolio review. For multi-role analyst framework, use portfolio-swarm-review instead.
Required reads
In this order:
/root/.openclaw/workspace/MEMORY.md— rules, traps, user preferences/root/.openclaw/workspace/portfolio.json— authoritative holdings/root/.openclaw/workspace/memory/theses/*.json— canonical thesis state when present../daily-deep-brief/references/technical-playbooks.md— read before any add / average-down plan/root/.openclaw/workspace/TOOLS.md— data chain reference if anything fails
portfolio.json is the only active/exited list: shares > 0 is held, shares == 0
is exited. There is no hand-maintained summary any more — the one that used to sit
here went 3.5 months without a sync and ended up naming seven held positions as
exited (#1067).
The thesis registry is read-only during a portfolio review. Missing files mean
unknown, not permission to reconstruct a baseline from prior prose. Price moves
may change valuation but cannot by themselves change business, moat, or management.
Fresh data rule
Always refresh quotes before judging the book. Use the workspace scripts.
# US: 7-route fallback, RSI/MA/news/signal, writes back to portfolio.json
/root/.local/bin/clawock analyze-us
/root/.local/bin/clawock analyze-us --no-news # skip news
# HK: Tencent primary + Eastmoney full-batch independent cross-check/fallback → stooq → yfinance
/root/.local/bin/clawock analyze-hk
/root/.local/bin/clawock analyze-hk --no-newsUse the returned quote coverage/source warnings to mark stale or unverified holdings; failure of an unused fallback alone does not invalidate a successful quote. Special trap: 00100 only has Tencent — Tencent down means 00100 is stale.
KR linkage: 07709/07747 are frequently at shares == 0, and SKHY (SK Hynix ADR)
is an independent line — read the KR names off portfolio.json (shares > 0)
rather than assuming any part of the chain is held or dead.
Holdings bucketing
Do not hardcode tickers here — names rotate. Pull the active list from portfolio.json (shares > 0), then bucket by category each run:
| Bucket | What goes in |
| US growth / single-name beta | Active US non-leveraged names (typically aggressive growth) |
| US leverage ETF | Anything in portfolio.json flagged is_leveraged_etf: true (SOXL, RKLX, MSFU, ROBN-class names; rotates over time) |
| US theme / special situation | Regulatory / catalyst-driven (e.g. CRCL ~ GENIUS Act stablecoin) |
| HK lower-beta core | Index / sector ETFs without leverage (currently 03032, 03033) |
| HK single-name | Individual HK equities (currently 00100 AI, 02208 wind) |
| HK leverage ETF | 2x/3x recipes (currently 07226 南方2x恒科) |
The framing is stable; the contents drift. Verify each session against portfolio.json.
Four-lens analysis
Lens A — PnL and position quality
For each active holding:
- gain/loss in $ and %
- distance to breakeven
- thesis status: intact / weakening / broken
- holdable / trim / T-only / cut
Lens B — Cross-market linkage
US side (typically):
- NASDAQ / 纳指夜盘 tone — drives next-day HK tech open
- Specific theme threads (e.g. stablecoin reg for CRCL, space/defense for RKLB)
HK side:
- 恒科指数方向 — primary driver for 03032 / 03033 / 07226
- 南向资金当日净流向 (web search when material)
- Sector policy: 风电 for 02208, AI capex for 00100
Note explicit "supportive / neutral / weak" tag for each chain.
Lens C — Concentration and drawdown risk
- Largest $ loss contributors right now
- Leverage decay risk (any 2x/3x ETF held > 5 trading days?)
- Correlation clusters (e.g. multiple 杠杆 ETF + single high-beta name = one bet)
- One-bad-day worst case for the book
Lens D — Action priority
Sort positions into:
- Hold and watch — thesis intact
- Trim on rebound — thesis weakening but not broken; wait for strength
- T-only — don't add, exit on bounces, no overnight conviction
- Add only on trigger — define the trigger explicitly (price, MA cross, earnings, policy)
Keep core_position, tactical_entry, and risk_rebalance separate. A concentrated
non-leveraged core may remain held while a tactical add is proposed. Registered setups
are suggestions: a self-defined entry states a hypothesis and invalidation price, and
policy-tranche departures are recorded. Loss alone is not evidence of a good entry. For HK, state board lots and use whole-lot multiples; missing
lot_size blocks an add. For US, use integer shares under the current ledger contract.
Output structure
Portfolio snapshot
- 总 US PnL / 总 HK PnL
- 最大盈利位 / 最大亏损位
- 主要风险源 (one line)
Position-by-position
Table format:
| Ticker | Price | PnL ($) | PnL (%) | One-line verdict |
Cross-market read
- US side: tone + key threads
- HK side: 恒科方向 + 南向 + sector policy notes
Top 3 risks (ranked)
Highest to lowest, each with concrete cause.
Action plan
Four buckets from Lens D, with concrete triggers/levels where applicable.
Style rules
- Direct, practical, no academic hedging
- Tie every conclusion to actual holdings (no hypothetical names)
- Respect the user's aggressive style — but call real risk plainly
- Tables for any 3+ data points
- Cite data freshness: "数据: clawock analyze-us / clawock analyze-hk {timestamp}"
- Flag stale legs loudly with ⚠️ before any conclusion drawn from them
- Do not substitute external "best practice" frameworks for the workspace data chain
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

