AutoSignals - Autonomous Trading Signal Optimization

by DaVinci

Monitors and controls the AutoSignals autonomous research loop.

3.7k平台与服务未扫描2026年3月23日

安装

claude skill add --url github.com/openclaw/skills/tree/main/skills/clawdiri-ai/autosignals-davinci

文档

AutoSignals - Autonomous Trading Signal Optimization

Monitors and controls the AutoSignals autonomous research loop.

What It Is

AutoSignals is an adaptation of Karpathy's autoresearch pattern for trading signal optimization. An autonomous loop runs continuously, spawning sub-agents to modify signals.py, backtesting changes, and keeping improvements.

Architecture:

  • signals.py — The ONE file agents can modify (factor weights, thresholds, indicators, scoring)
  • backtest.py — Fixed evaluation engine (5-year backtest, composite score metric)
  • prepare.py — Data download (S&P 500 + held tickers)
  • program.md — Instructions for research agents
  • run.py — Autonomous loop controller
  • experiments.jsonl — Full experiment log

Location: /Users/clawdiri/Projects/autosignals/

How to Use

Check Status

bash
bash /Users/clawdiri/Projects/autosignals/status.sh

Shows:

  • Running status (PID, uptime)
  • Best composite score achieved
  • Total experiments run
  • Last 10 experiments with outcomes
  • Score trend (last 20)
  • Any errors

Start the Loop

bash
bash /Users/clawdiri/Projects/autosignals/start.sh

Starts the autonomous loop in the background. Runs forever until stopped.

Stop the Loop

bash
kill $(cat /Users/clawdiri/Projects/autosignals/autosignals.pid)

View Logs

bash
tail -f /Users/clawdiri/Projects/autosignals/logs/autosignals.log

View Best Signals

bash
cat /Users/clawdiri/Projects/autosignals/best_score.json

Then read the corresponding commit:

bash
cd /Users/clawdiri/Projects/autosignals
git show <commit_hash>:signals.py

Monitoring Script (for DaVinci heartbeats)

bash
bash /Users/clawdiri/Projects/autosignals/monitor.sh

Returns JSON with:

  • running: bool
  • experiment_count: int
  • best_score: float
  • best_commit: str
  • trend: "improving" | "declining" | "flat"
  • errors: list of recent errors

Evaluation Metric

code
composite_score = (0.35 * sharpe_normalized) + 
                  (0.25 * (1 - max_drawdown)) + 
                  (0.20 * win_rate) + 
                  (0.20 * profit_factor_normalized)

All components normalized to [0, 1].

Baseline targets:

  • Sharpe: 1.57 / 1.46 / 1.24
  • Starting weights: 40% Insider / 35% Earnings / 25% Sector Rotation

Good: Beat baseline Great: Sharpe > 2.0, drawdown < 15% Exceptional: Sharpe > 2.5, drawdown < 10%

Data

  • Price data: 5 years daily OHLCV for S&P 500 + META, GOOG, AMZN, TSLA, BTC-USD, IAU
  • Factor data: Currently mock (insider, earnings, sector). Can be enhanced with real API data.
  • Cache: /Users/clawdiri/Projects/autosignals/data/prices.parquet

Refresh data:

bash
cd /Users/clawdiri/Projects/autosignals
source .venv/bin/activate
python prepare.py

Design Principles (from Karpathy)

  1. Single modifiable file — agents only edit signals.py
  2. Fixed evaluationbacktest.py is immutable truth
  3. Self-contained — no external API calls during backtest (cached data only)
  4. Git-tracked progress — every improvement is a commit
  5. Resilient loop — individual failures don't stop the system

Alert Conditions (for DaVinci)

  • Loop stopped unexpectedly → WhatsApp alert
  • No experiments in last 30 minutes (if running) → check logs
  • Error rate > 50% (last 10 experiments) → investigate
  • New best score achieved → celebrate 🎉

When to Intervene

Hands-off:

  • Normal operation (experiments running, mix of keep/discard)
  • Gradual improvement trend
  • Low error rate

Check it out:

  • All experiments failing (agent spawn issues? data corruption?)
  • Score trend declining over 20+ experiments (overfitting? bad hypothesis?)
  • Loop stopped (crash? resource exhaustion?)

Celebrate:

  • New all-time best score
  • Sharpe > 2.0 achieved
  • Major breakthrough (e.g., 10%+ score improvement)

Future Enhancements

  • Real factor data integration (Finnhub insider API, FMP earnings, sector ETF momentum)
  • Multi-ticker portfolio optimization (vs current single-ticker signals)
  • Walk-forward validation (rolling window backtest to prevent overfitting)
  • Ensemble signals (combine multiple top-performing signal variants)
  • Risk-adjusted position sizing (Kelly criterion, volatility targeting)
  • Live paper trading integration (Alpaca API)

相关 Skills

MCP构建

by anthropics

Universal
热门

聚焦高质量 MCP Server 开发,覆盖协议研究、工具设计、错误处理与传输选型,适合用 FastMCP 或 MCP SDK 对接外部 API、封装服务能力。

想让 LLM 稳定调用外部 API,就用 MCP构建:从 Python 到 Node 都有成熟指引,帮你更快做出高质量 MCP 服务器。

平台与服务
未扫描109.6k

Slack动图

by anthropics

Universal
热门

面向Slack的动图制作Skill,内置emoji/消息GIF的尺寸、帧率和色彩约束、校验与优化流程,适合把创意或上传图片快速做成可直接发送的Slack动画。

帮你快速做出适配 Slack 的动图,内置约束规则和校验工具,少踩上传与播放坑,做表情包和演示都更省心。

平台与服务
未扫描109.6k

接口设计评审

by alirezarezvani

Universal
热门

审查 REST API 设计是否符合行业规范,自动检查命名、HTTP 方法、状态码与文档覆盖,识别破坏性变更并给出设计评分,适合评审接口方案和版本迭代前把关。

做API和架构方案时,它能帮你提前揪出接口设计问题并对齐最佳实践,评审视角系统,团队协作更省心。

平台与服务
未扫描9.0k

相关 MCP 服务

Slack 消息

编辑精选

by Anthropic

热门

Slack 是让 AI 助手直接读写你的 Slack 频道和消息的 MCP 服务器。

这个服务器解决了团队协作中需要 AI 实时获取 Slack 信息的痛点,特别适合开发团队让 Claude 帮忙汇总频道讨论或发送通知。不过,它目前只是参考实现,文档有限,不建议在生产环境直接使用——更适合开发者学习 MCP 如何集成第三方服务。

平台与服务
82.9k

by netdata

热门

io.github.netdata/mcp-server 是让 AI 助手实时监控服务器指标和日志的 MCP 服务器。

这个工具解决了运维人员需要手动检查系统状态的痛点,最适合 DevOps 团队让 Claude 自动分析性能数据。不过,它依赖 NetData 的现有部署,如果你没用过这个监控平台,得先花时间配置。

平台与服务
78.3k

by d4vinci

热门

Scrapling MCP Server 是专为现代网页设计的智能爬虫工具,支持绕过 Cloudflare 等反爬机制。

这个工具解决了爬取动态网页和反爬网站时的头疼问题,特别适合需要批量采集电商价格或新闻数据的开发者。不过,它依赖外部浏览器引擎,资源消耗较大,不适合轻量级任务。

平台与服务
34.5k

评论