← All skills
Tencent SkillHub · Data Analysis

Stock Strategy Backtester

Backtest stock trading strategies on historical OHLCV data and report win rate, return, CAGR, drawdown, Sharpe ratio, and trade logs. Use when evaluating or...

skill openclawclawhub Free
0 Downloads
0 Stars
0 Installs
0 Score
High Signal

Backtest stock trading strategies on historical OHLCV data and report win rate, return, CAGR, drawdown, Sharpe ratio, and trade logs. Use when evaluating or...

⬇ 0 downloads ★ 0 stars Unverified but indexed

Install for OpenClaw

Quick setup
  1. Download the package from Yavira.
  2. Extract the archive and review SKILL.md first.
  3. Import or place the package into your OpenClaw setup.

Requirements

Target platform
OpenClaw
Install method
Manual import
Extraction
Extract archive
Prerequisites
OpenClaw
Primary doc
SKILL.md

Package facts

Download mode
Yavira redirect
Package format
ZIP package
Source platform
Tencent SkillHub
What's included
SKILL.md, agents/openai.yaml, references/backtest-metrics.md, scripts/backtest_strategy.py

Validation

  • Use the Yavira download entry.
  • Review SKILL.md after the package is downloaded.
  • Confirm the extracted package contains the expected setup assets.

Install with your agent

Agent handoff

Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.

  1. Download the package from Yavira.
  2. Extract it into a folder your agent can access.
  3. Paste one of the prompts below and point your agent at the extracted folder.
New install

I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete.

Upgrade existing

I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run.

Trust & source

Release facts

Source
Tencent SkillHub
Verification
Indexed source record
Version
1.0.4

Documentation

ClawHub primary doc Primary doc: SKILL.md 8 sections Open source page

Version Notice

1.0.0 and 1.0.1 are deprecated. Use 1.0.2 or newer only. Deprecation reason: early versions bundled non-core marketplace automation files and may trigger security scanner warnings in some environments.

Overview

Run repeatable, long-only stock strategy backtests from daily OHLCV CSV files. Use bundled scripts to generate consistent metrics and trade-level output, then summarize with investor-friendly conclusions.

Quick Start

Prepare a CSV with at least Date and Close columns. Run a baseline backtest: python scripts/backtest_strategy.py \ --csv /path/to/prices.csv \ --strategy sma-crossover \ --fast-window 20 \ --slow-window 60 Export artifacts for review: python scripts/backtest_strategy.py \ --csv /path/to/prices.csv \ --strategy rsi-reversion \ --rsi-period 14 \ --rsi-entry 30 \ --rsi-exit 55 \ --commission-bps 5 \ --slippage-bps 2

Workflow

Validate data Ensure Date is parseable and sorted ascending. Ensure Open/High/Low/Close are numeric; missing Open/High/Low falls back to Close. Pick strategy logic sma-crossover: trend-following with fast/slow moving averages. rsi-reversion: buy oversold and exit on momentum recovery. breakout: enter on highs breakout and exit on lows breakdown. Set realistic assumptions Always set --commission-bps and --slippage-bps. Avoid reporting cost-free backtests as production-ready. Compare variants Change one parameter block at a time. Compare on the same date range and same cost model. Produce final summary Report: total_return_pct, cagr_pct, win_rate_pct, max_drawdown_pct, sharpe_ratio, profit_factor, and trade count. Use trade CSV to explain where alpha is coming from.

Supported Commands

Baseline SMA strategy: python scripts/backtest_strategy.py \ --csv /path/to/prices.csv \ --strategy sma-crossover \ --fast-window 10 \ --slow-window 50 Breakout strategy: python scripts/backtest_strategy.py \ --csv /path/to/prices.csv \ --strategy breakout \ --lookback 20 JSON-only output (for automation pipelines): python scripts/backtest_strategy.py \ --csv /path/to/prices.csv \ --strategy rsi-reversion \ --quiet

Output Contract

Script prints a JSON object to stdout with: strategy period metrics config trades

Analysis Guardrails

Use out-of-sample logic Prefer walk-forward validation over one-shot tuning. Avoid leakage Compute signals from bar t, execute at bar t+1 open. Report downside with upside Never present return without drawdown and trade count. Treat results as research Backtests are not guarantees and should not be framed as financial advice.

References

Metrics details: references/backtest-metrics.md

Category context

Data access, storage, extraction, analysis, reporting, and insight generation.

Source: Tencent SkillHub

Largest current source with strong distribution and engagement signals.

Package contents

Included in package
2 Docs1 Scripts1 Config
  • SKILL.md Primary doc
  • references/backtest-metrics.md Docs
  • scripts/backtest_strategy.py Scripts
  • agents/openai.yaml Config