Skip to main content
skill CX Codex

python-workspace — Claude Code skill: what it does, how to install

python-workspace converts MQL5 indicators to Python and exports MetaTrader 5 data headlessly with automated correlation checks.

MIT 131 installs ★ 3 updated 2026-10-25

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add terrylica/cc-skills --skill python-workspace -a claude-code
Open on GitHub

What python-workspace does

This skill prepares an environment for translating MetaTrader 5 indicators into Python implementations. It handles headless exports of OHLCV candles and standard indicators such as RSI and SMA by triggering Wine Python inside a CrossOver bottle.

Validation gates all work behind an accuracy threshold: correlation between Python output and the MQL5 benchmark must reach 0.999 or higher. The skill also guides the agent through aligning warmup periods and calculation logic when values diverge.

Direct API access to custom indicator buffers is blocked by MetaTrader 5 restrictions, meaning those require manual CSV exports. You also need an existing CrossOver installation with an initialized bottle for the export commands to execute.

What it helps with

  • export OHLCV candles and standard indicators without opening the MT5 GUI
  • translate MQL5 indicator calculations to Python code
  • validate Python indicator outputs against MT5 using a 0.999 correlation gate
  • troubleshoot MT5 API connection issues inside a Wine bottle

Example prompts for the agent

  • Export 5000 bars of EURUSD M1 with RSI using the headless MT5 script
  • Translate this MQL5 indicator into Python and verify calculation correlation
  • Fix the MT5 API connection failure in the CrossOver prefix

How to install python-workspace

1Skills CLI (Vercel)

npx skills add terrylica/cc-skills --skill python-workspace -a claude-code

2Manually: put the files in place

~/.claude/skills/python-workspace/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/python-workspace/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about python-workspace

How to install python-workspace in Claude Code?

Run npx skills add terrylica/cc-skills --skill python-workspace -a claude-code in your terminal. This writes the skill file to ~/.claude/skills/python-workspace/SKILL.md.

What does python-workspace do?

It automates exporting market data from MetaTrader 5 via Wine, translates MQL5 indicators into Python, and verifies output accuracy against reference data.

Can it read custom MT5 indicator buffers directly?

No, because MetaTrader 5 API restrictions prevent direct buffer access for custom indicators. Those buffers must be exported via CSV files instead.

Source text

SKILL.md · MIT
---
name: python-workspace
description: Python workspace for MQL5 integration. TRIGGERS - MetaTrader 5 Python, mt5 package, MQL5-Python setup.
allowed-tools: Bash, Read, Write
---

# MQL5-Python Translation Workspace Skill

Seamless MQL5 indicator translation to Python with autonomous validation and self-correction.

---

> **Self-Evolving Skill**: This skill improves through use. If instructions are wrong, parameters drifted, or a workaround was needed — fix this file immediately, don't defer. Only update for real, reproducible issues.

## When to Use This Skill

Use this skill when the user wants to:

- Export market data or indicator values from MetaTrader 5
- Translate MQL5 indicators to Python implementations
- Validate Python indicator accuracy against MQL5 reference
- Understand MQL5-Python workflow capabilities and limitations
- Troubleshoot common translation issues

**Activation Phrases**: "MQL5", "MetaTrader", "indicator translation", "Python validation", "export data", "mql5-crossover workspace"

---

## Core Mission

**Main Theme**: Make MQL5-Python translation **as seamless as possible** through:

1. **Autonomous workflows** (headless export, CLI compilation, automated validation)
1. **Validation-driven iteration** (>=0.999 correlation gates all work)
1. **Self-correction** (documented failures prevent future mistakes)
1. **Clear boundaries** (what works vs what doesn't, with alternatives)

**Project Root**: `~/Library/Application Support/CrossOver/Bottles/MetaTrader 5/drive_c`

---

## Workspace Capabilities Matrix

### WHAT THIS WORKSPACE CAN DO

#### 1. Automated Headless Market Data Export (v3.0.0)

**Status**: PRODUCTION (0.999920 correlation validated)

**What It Does**:

- Fetches OHLCV data + built-in indicators (RSI, SMA) from any symbol/timeframe
- True headless via Wine Python + MetaTrader5 API
- No GUI initialization required (cold start supported)
- Execution time: 6-8 seconds for 5000 bars

**Command Example**:

```bash
CX_BOTTLE="MetaTrader 5" \
WINEPREFIX="$HOME/Library/Application Support/CrossOver/Bottles/MetaTrader 5" \
wine "C:\\Program Files\\Python312\\python.exe" \
  "C:\\users\\crossover\\export_aligned.py" \
  --symbol EURUSD --period M1 --bars 5000
```

**Use When**: User needs automated market data exports without GUI interaction

**Limitations**: Cannot access custom indicator buffers (API restriction)

**Reference**: `/docs/guides/WINE_PYTHON_EXECUTION.md`

---

## Reference Documentation

For detailed information, see:

- [Capabilities Detailed](./references/capabilities-detailed.md) - In-depth capability documentation
- [Complete Workflows](./references/workflows-complete.md) - End-to-end user workflows
- [Troubleshooting & Errors](./references/troubleshooting-errors.md) - Requirements, assumptions, error patterns
- [Validation Metrics](./references/validation-metrics.md) - Success metrics and version history

---

## Troubleshooting

| Issue                        | Cause                        | Solution                                             |
| ---------------------------- | ---------------------------- | ---------------------------------------------------- |
| Wine Python not found        | CrossOver/Wine not installed | Install CrossOver, verify bottle path                |
| MT5 API connection failed    | MetaTrader not running       | Launch MetaTrader 5 before running export            |
| Correlation below 0.999      | Indicator mismatch           | Verify warmup periods, check calculation alignment   |
| Custom indicator not working | API restriction              | Use CSV export from MT5, not Python API              |
| UnicodeDecodeError           | Windows path encoding        | Use raw strings for Windows paths in Wine            |
| Symbol not found             | Wrong symbol format          | Use exact MT5 symbol name (e.g., EURUSD not EUR/USD) |
| Timeout on export            | Too many bars requested      | Reduce bar count, default 5000 is safe               |
| Permission denied            | Wine prefix incorrect        | Set WINEPREFIX to correct CrossOver bottle path      |


## Post-Execution Reflection

After this skill completes, check before closing:

1. **Did the command succeed?** — If not, fix the instruction or error table that caused the failure.
2. **Did parameters or output change?** — If the underlying tool's interface drifted, update Usage examples and Parameters table to match.
3. **Was a workaround needed?** — If you had to improvise (different flags, extra steps), update this SKILL.md so the next invocation doesn't need the same workaround.

Only update if the issue is real and reproducible — not speculative.

© terrylica · MIT · terrylica/cc-skills

Similar skills

All skills for Finance and business →

From the same set79

The whole set →
session-chronicle session-chronicle connects findings, decisions, and code changes to session UUIDs. Use it when you need to trace where work came from or record session provenance. CX Codex +1 135installs notion-sdk notion-sdk — a skill for managing Notion via the official Python SDK. Creates pages and databases, queries information, adds content blocks — all programmatically. CX Codex +1 133installs hooks-development The hooks-development skill guides you through building and debugging Claude Code hooks, with a focus on output visibility. Use it when a hook runs but its message never reaches the agent. CX Codex +1 133installs asciinema-cast-format asciinema-cast-format is a Claude Code skill that helps parse NDJSON headers and terminal events in asciinema v3 .cast recordings. CX Codex +1 132installs terminal-print terminal-print turns iTerm2 output or a session file into a PDF, then sends it to a network printer. It also provides an AirPrint workaround for blank pages on listed HP LaserJet Pro models. CX Codex +1 131installs doppler-workflows The doppler-workflows skill guides commands that use Doppler secrets for Python package publishing and AWS tasks. It also covers common authentication errors. CX Codex +1 130installs ml-data-pipeline-architecture The ml-data-pipeline-architecture skill covers ML data pipelines built with Polars, Arrow, and ClickHouse. Use it to choose between Polars and Pandas or prepare data for PyTorch. CX Codex +1 130installs clickhouse-pydantic-config clickhouse-pydantic-config turns Pydantic v2 ClickHouse models and environment variables into a DBeaver connection file. Handy when one repo talks to both a local and a cloud database. CX Codex +1 130installs

Project sponsors

Companies that keep this analytics open