{"skill":{"slug":"wyckoff-a-share","displayName":"Wyckoff Analysis AShare","summary":"Run Wyckoff master-style analysis from stock codes, holdings (symbol/cost/qty), cash, CSV data, and optional chart images. Use when users want online multi-s...","description":"---\nname: akshare-online-alpha\ndescription: Run Wyckoff master-style analysis from stock codes, holdings (symbol/cost/qty), cash, CSV data, and optional chart images. Use when users want online multi-source data fetching with source switching, strict Beijing-time trading-session checks, fixed system prompt analysis, single-stock analysis, holding rotation, holding add/reduce suggestions, or empty-position cash deployment suggestions.\n---\n\n# Akshare Online Alpha\n\nUse this skill when the user wants Wyckoff-style analysis with online data fetch and source fallback.\n\n## Input Schema\n\nSingle/multi symbol analysis:\n- Inputs: stock code(s), optional CSV, optional chart image, text goals.\n\nPortfolio decision analysis:\n- `holdings` (can be empty): `[股票A+成本+数量, 股票B+成本+数量, ...]`\n- `cash`: available cash amount\n- `candidate` (optional): stock code not currently in holdings\n- Optional CSV/image/text instructions are still supported.\n\nPortfolio example:\n- `holdings = [600519+1450+100, 000001+10.2+3000]`\n- `cash = 80000`\n- `candidate = 300750`\n\n## When To Use / Not Use\n\nUse this skill when at least one condition is true:\n- User provides stock code(s) and asks for current/near-current analysis.\n- User provides holdings + cash + candidate and asks whether to switch positions.\n- User asks whether current holdings should be increased/reduced/kept.\n- User has no holdings and asks how to act with available cash.\n- User asks to combine CSV + online validation.\n- User provides chart image and asks for Wyckoff interpretation.\n\nDo not use this skill when:\n- User only asks for generic Python/chart debugging unrelated to market analysis.\n- User requests purely offline historical analysis with no online data requirement.\n\n## Auto Intent Inference\n\nWhen `holdings/cash/candidate` are provided, do not require the user to say \"switch / add / reduce / empty-position\".\n\nInfer automatically from provided fields:\n- `holdings` non-empty + `candidate` provided: include rotation comparison and per-holding actions.\n- `holdings` non-empty + no `candidate`: provide per-holding add/reduce/hold/exit suggestions.\n- `holdings` empty + `cash` provided: provide empty-position cash deployment suggestion.\n\n## Required Execution Order\n\n1. Validate input and parse structured fields:\n- Determine symbol-only flow or portfolio flow from input fields.\n- CSV (if provided): main source for historical structure.\n- Text instructions: constraints and goals.\n- Image (if provided): supplemental intraday/micro-structure signal.\n- In portfolio flow, parse `holdings/cash/candidate(optional)` before analysis.\n\n2. Resolve current Beijing time before any trading suggestion:\n- Fetch actual current time from tool/system.\n- Convert to `Asia/Shanghai`.\n- Print `当前北京时间：YYYY-MM-DD HH:MM（UTC+8）`.\n- Determine if in A-share continuous auction window.\n\n3. Enforce trading-session rules:\n- If not in tradable session, only provide post-market review/next-day plan/order strategy.\n- Do not output immediate intraday execution commands.\n\n4. Fetch data with online source switching:\n- Use `rules/source-fallbacks.md` order.\n- For each symbol, keep source audit log.\n- If source fails, schema check fails, or rows are insufficient, switch source.\n- In portfolio flow, fetch all holding symbols and candidate symbol when provided.\n\n5. Perform Wyckoff analysis first:\n- Analyze latest 500 days structure with MA50/MA200.\n- Identify phases/events without forcing full phase set.\n- Allow event-date news checks only for verification, not as decision basis.\n\n6. In portfolio flow, produce a Wyckoff-style portfolio recommendation:\n- For each holding, give one action: `add / reduce / hold / exit`.\n- If candidate is provided, compare candidate vs current holdings from structure strength, phase position, and event quality.\n- If candidate is provided, identify which current holding is structurally weakest and whether rotation is needed.\n- If holdings are empty, provide an empty-position suggestion using available cash and current structure context.\n- Use `cost/qty/cash` to give concrete action suggestions in narrative form.\n- Keep final recommendation in Wyckoff tone and clearly state action labels such as `switch / partial switch / hold / add / reduce`.\n\n7. Plot only when allowed:\n- If current time is intraday trading time, skip plotting.\n- Otherwise generate plotting code/result using hard rendering constraints from system prompt.\n\n## Fixed Output Contract\n\nAlways output in this order:\n1. `当前北京时间：YYYY-MM-DD HH:MM（UTC+8）`\n2. Trading verdict:\n- `当前是否可盘中交易：是/否`\n- If no: `当前不可盘中交易（原因：...）`\n3. Data audit table per symbol:\n- `symbol`\n- `source_used`\n- `rows_kept`\n- `window_end_date`\n- `fallback_count`\n4. Wyckoff analysis result:\n- Current cycle background and phase (only what is evidenced).\n- Key events (SC/ST/Spring/LPS/SOS/UTAD if present) with concise rationale.\n- Action boundaries respecting T+1 and current session status.\n5. Portfolio action section (portfolio flow only):\n- Holdings snapshot from provided `cost/qty/cash`.\n- Per-holding action suggestions (`add / reduce / hold / exit`) with reasoning.\n- Candidate vs weakest holding comparison (if candidate is provided).\n- Empty-position cash action suggestion (if holdings are empty).\n- Final action summary in Wyckoff tone.\n6. Plotting section (only when allowed by session rules):\n- Python code and/or generated chart result with Chinese annotation constraints.\n\n## Failure And Degrade Rules\n\n- If all data sources fail for a symbol, report that symbol as `data_unavailable` and continue with remaining symbols.\n- If fewer than 30 valid rows are available, do not force phase labeling; return \"insufficient structure depth\".\n- If image is unreadable, explicitly state parse failure reason and continue with text/CSV path.\n- Never invent OHLCV rows, event timestamps, or trading-day status.\n\n## Hard Constraints\n\n- Do not change the fixed prompt wording unless explicitly requested.\n- Do not fabricate missing OHLCV rows.\n- Do not ignore image input if image is parseable.\n- Do not use opaque white text boxes in chart annotations.\n- If fetching data requires running Python scripts, run them only in a sandboxed environment.\n- Prefer direct web/API fetch first; use Python scripts only when needed for fallback, parsing, or normalization.\n\n## Resources\n\n- `rules/alpha-system-prompt.md`: fixed role and hard rules.\n- `rules/source-fallbacks.md`: online source switching policy.\n","topics":["CSV","Deployment","System Prompt","Stock Analysis","Trading"],"tags":{"latest":"1.0.0"},"stats":{"comments":0,"downloads":621,"installsAllTime":23,"installsCurrent":0,"stars":0,"versions":1},"createdAt":1773626201616,"updatedAt":1778491933006},"latestVersion":{"version":"1.0.0","createdAt":1773626201616,"changelog":"akshare-online-alpha 1.0.0 initial release:\n\n- Provides Wyckoff-style analysis for A-shares using online multi-source data with automatic source switching.\n- Supports analysis from stock codes, CSVs, chart images, and portfolio holdings (symbol/cost/qty/cash/candidate).\n- Enforces strict Beijing-time trading session checks before suggesting any trading actions.\n- Automatically infers user intent (add/reduce/switch/cash-deployment) based on provided fields.\n- Outputs follow a fixed contract: session info, data audit, Wyckoff analysis, portfolio actions, and plotting (when allowed).\n- Implements robust error handling for data availability, structure depth, and image parsing.","license":"MIT-0"},"metadata":null,"owner":{"handle":"youngcan-wang","userId":"s174z9s1sbky3r2bdxfwys6n9s83h5py","displayName":"YoungCan-Wang","image":"https://avatars.githubusercontent.com/u/73347006?v=4"},"moderation":null}