Communitygithub.com

austin-starks/Public-Portfolio-Challenge

在 NexusTrade 上构建替代数据自定义指标(Reddit/WSB 提及、国会披露、内幕交易、新闻流),并将其作为排名/倾斜/过滤信号接入认证账簿。

Public-Portfolio-Challenge 是什么?

该技能旨在帮助开发者和交易策略师利用替代数据(如 Reddit/WSB 情绪、国会交易、内幕文件归档和新闻流)在 NexusTrade 平台上构建并集成自定义指标。它提供了一种受控的计算会话工作流(compute_session_start/exec/promote/end),用于多步骤构建,避免零散操作,并确保每个来源都经过点计数、覆盖范围检查、前瞻性偏差审计以及与主要来源的数值核对。技能强调了“稀疏序列规则”:覆盖不全的序列只能用于倾斜或覆盖,不能用作排名输入,否则会导致退化接线。此外,它涵盖了四种集成形态(排名混合、权重倾斜、入场过滤器、确认覆盖),并提供了参考配方(如 Reddit WSB 提及管道和国会披露管道),以帮助用户快速上手并避免常见陷阱。

兼容平台~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/austin-starks/Public-Portfolio-Challenge/tree/HEAD/skills/alt-data-indicators

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

替代数据自定义指标

替代数据是一个信号实验,而非结构实验——它只触及排名/权重/过滤信号,绝不触及期权结构(参见 options-structure-rules)。基准是标杆:替代数据必须通过击败(或实质性降低风险)经过相同 OOS 门槛的认证账簿来赢得一席之地。“指标很酷”不是结果。

使用可引导的计算会话构建(首选)

对于任何多步骤数据构建,首选 compute_session_start / compute_session_exec → compute_session_promote_indicator / compute_session_end:/work 持久化,你观察每一步,整个历史记录落在一个推广指标中。首先列出并结束过期的会话(compute_session_list);在长时间运行时发送定期 exec。一次性 run_compute 仅用于小型单查询任务。其他堆栈工具:dataset_to_indicator、build_signal_indicator、create_indicator、list_custom_indicators、collect_web_data、discover_sources、enrich_source、ingest_content、probe_url、sec_edgar、get_compute_status、cancel_compute_job。

每个来源都要经历:构建 → 点计数 + 覆盖范围检查 → 前瞻性偏差审计 → 与主要来源数值抽查 → 记录。 平台故障执行 bug-protocol;在一个来源上遇到两个不同的故障后,暂停并继续——不要让一个损坏的管道拖慢整个活动。

切勿接入未经验证的指标(教训 #10/#11)

在策略中引用任何 CustomIndicator 之前,请使用 list_custom_indicators + 来源抽查确认以下四点:

  1. 点计数——剔除 0 点的残骸。
  2. 每个股票的覆盖范围遍及整个投资组合(全部 21 个名称,而非样本)。
  3. 新鲜度——最大日期;数据已过时的信号绝不能驱动活跃账簿。
  4. 前瞻性偏差安全——见下文。

稀疏序列规则

排名/权重表达式仅适用于在整个投资组合中密集的序列。稀疏/部分覆盖的序列(例如,一位政治人物的买入覆盖约 1/21 个名称)只能作为倾斜或覆盖,绝不能作为排名输入——基于它构建的排名将交易零次(退化接线)。明确说明并降低优先级;不要强行使用。

前瞻性偏差安全不可妥协(教训 #11)

每个替代数据点都标示在信息公开(归档/披露/发布)的日期,而不是交易/事件日期。国会交易具有最长约 45 天的 STOCK Act 延迟——信号必须嵌入该延迟。在任何回测使用之前,显式审计每个指标。尽可能使用第二个独立生成的构建对数值进行交叉验证(一个 WSB 计数序列就是通过这种方式验证的——两个独立构建完全匹配)。对历史帖子进行回溯抓取是可以的;对历史数据应用情感模型也是可以的(记为注意事项);使用删除幸存者也是一个需要注意的注意事项。

数据覆盖范围界定认证窗口

首先检查来源数据湖的最大月份,并将信号覆盖范围的结束视为认证窗口和可部署性的硬约束。滚动优化引擎将折叠日历裁剪到指标覆盖范围,因此认证比较必须日历对齐——在变体的裁剪日历上运行基准控制(参见 walk-forward-oos)。

集成形态(根据覆盖范围选择)

#集成方式位置所需覆盖范围
S1混合到排名——替代信号与动量 ROC 结合作为 weightIndicator / SelectTop 指标排名广泛(大部分 21 个)
S2倾斜——动量排名;替代数据对近期有信号的名称超配/低配权重部分覆盖 OK
S3入场过滤器——仅在 N 天内/高于 X 时替代信号触发时才开仓条件部分覆盖 OK(重新检查冷启动广度审计!)
S4确认覆盖——替代数据放松/收紧现有门控(例如 VIX)条件任何

动量保持主要地位,喧嚣是一种倾斜:仅关注注意力的排名表现很差;但在动量之上叠加对数衰减的注意力倾斜则表现良好。已验证的 S1 锚定形态: weightIndicator = Multiply(ROC63, Plus(1, Log(base 10, Plus(1, IndicatorSimpleMovingAverage(21d, CustomIndicator)))))。值得变化的网格轴:SMA 窗口(10/21/42)、倾斜强度(对数 vs 线性截断)。

集成是手工构建,而非扫描式的(CustomIndicator 不是可扫描的类型)——通过 create_portfolio_variant 构建变体网格(深拷贝基础 + JSON-Pointer 补丁,先 dry_run),标签手动设置(琥珀色),并在每个变体上进行一次 12 个月 25,000 美元的回测烟雾测试,然后再投入折叠(零/接近零交易 ⇒ 排名/过滤器未解析 → 修复或丢弃)。参见 sweep-reoptimization。

来源配方

  • references/reddit-wsb-recipe.md — 久经考验的 Reddit Arctic 湖提及计数管道。
  • references/congressional-disclosures.md — 众议院书记员 PTR 管道(所有国会汇总)。
  • references/other-sources.md — 内幕 Form 4、新闻流、注意力;以及 sec_edgar 范围。

Individual skills in this repo

This repo contains 11 individual skills — each has its own dedicated page.

austin-starks/Public-Portfolio-Challenge

Measure a NexusTrade options book's TRUE participation at a fixed cold-start capital base, defeating the compounded-NAV breadth illusion. Use whenever a book's headline \"holds N/21 names\" needs validating, when a live book collapses to a single name (the OSCR trap), when checking whether a SelectTop / per-name-allocation / total-budget change degraded simultaneous participation, or when a certification needs a breadth gate. Uses audit_backtest_breadth at held-fixed $25k.

austin-starks/Public-Portfolio-Challenge

The \"loudly declare\" protocol for platform, engine, or data bugs during a NexusTrade certification campaign — bugs are a first-class deliverable, not something to route around. Use whenever a NexusTrade tool errors, hangs, or returns numbers that contradict the config; whenever you're tempted to write \"probably an engine quirk\"; or when a discovered bug invalidates prior backtests and results must be quarantined. Includes the bug hand-off doc template (see references/BUG_TEMPLATE.md).

austin-starks/Public-Portfolio-Challenge

The GATED deploy + cleanup flow for a NexusTrade live book — clone the finalist, preview a delta reconcile, stage UNAPPROVED orders, verify fills. Use ONLY after the human explicitly says \"deploy + clean up\" and names a finalist. Covers the clone-before-reconcile ordering, the single-tick reconcile expectation, stale-pending-order hygiene, the signal-freshness gate, and why you can never approve orders yourself. Nothing here runs during certification.

austin-starks/Public-Portfolio-Challenge

The mandatory pre-flight contract checks (Stage S0) that must pass before trusting NexusTrade's certification engine for any strategy work. Use at the start of a bakeoff or certification campaign to prove the walk-forward engine runs end-to-end, windows don't leak, fold winners persist, and the engine doesn't fabricate values for dead/not-yet-listed names. Each check has a STOP-and-report failure mode; these runs do NOT count toward any certification minimum.

austin-starks/Public-Portfolio-Challenge

The single-touch lockbox — a final anti-overfitting holdout run once, after design freeze, on a window held out from every fold, sweep, and search. Use when finalizing a bakeoff winner before deploy, setting up the A/B/C baselines as OOS bars, or running the S1.5 gate-coherence auto-relax. Covers why looking at the lockbox twice burns it, the lockbox pass conditions, and the three baselines. The lockbox is distinct from the walk-forward OOS folds.

austin-starks/Public-Portfolio-Challenge

The hard structural constraints for the Public Portfolio Challenge momentum-LEAP options book — the spread-shape rule, the take-profit convexity-cap footgun, the affordability ladder, and the known losers not to re-test. Use whenever building or auditing an options strategy structure, checking spread-shape compliance before a certification, choosing DTE/strike rungs, or deciding whether a proposed structure change is even allowed. A violation is an automatic certification FAIL.

austin-starks/Public-Portfolio-Challenge

Orchestrate an out-of-sample certification of a NexusTrade trading strategy or live book — the master discipline behind the Public Portfolio Challenge. Use whenever you must decide PASS/FAIL on whether a portfolio holds up out of sample before deploying real money, replaying the Episode 10 runbooks, or running a \"certify my book\" / \"prove it out of sample\" / \"re-certify the fix\" task with the NexusTrade MCP connected. Pulls in walk-forward-oos, breadth-audit, sweep-reoptimization, options-structure-rules, bug-protocol, and deploy-gate.

austin-starks/Public-Portfolio-Challenge

The single entry point that executes a Public Portfolio Challenge episode or addendum runbook end-to-end, delegating each stage to the functional skills. Use when asked to run/execute/replay Episode 10, its bakeoff, or its addendum with the NexusTrade MCP connected. Reads the target runbook, pins its real artifacts (IDs, the incumbent bar), sequences the stages, and stops at the gated deploy. It orchestrates; the functional skills do the work.

austin-starks/Public-Portfolio-Challenge

Run a multi-family strategy bakeoff — the SEARCH→CERTIFY funnel that screens many candidate mechanisms down to a certified deploy winner without letting the cheap search layer issue a verdict. Use when replaying the Episode 10 bakeoff, when exploring several distinct strategy families before certifying, when deciding whether \"no deployable winner\" is even a legal conclusion, or when building the per-family certification ledger. Enforces verdict-integrity: only certification can end a campaign.

austin-starks/Public-Portfolio-Challenge

Re-optimize a NexusTrade strategy with a walk-forward SWEEP and label parameter provenance — the discipline that prevents deploying inherited knobs. Use whenever a structural change (sizing, rung depth, universe membership, DTE family, adding a rank signal) forces a re-sweep, when authoring gene_intents from get_sweep_surface, when choosing sweep over GA for a deploy cert, or when selecting the cross-fold-robust winner instead of the per-fold argmax. Invoke with the NexusTrade MCP connected.

austin-starks/Public-Portfolio-Challenge

Run and read a NexusTrade walk-forward out-of-sample study — the certification engine behind the Public Portfolio Challenge. Use when certifying a fixed portfolio (backtest_only) or re-optimizing one (sweep), when setting fold_count / anchored / validation / embargo params, when monitoring a run_walk_forward_study to completion, when reading per-fold OOS returns/Sortino/drawdown, or when a variant's fold calendar needs calendar-alignment against a base control. Invoke with the NexusTrade MCP connected.

相关技能