
Charting
Generate TradingView-style dark-theme candlestick charts with indicators from market data without flooding the agent context by calling separate OHLC tools.
Overview
Charting is an agent skill for the Build phase that generates TradingView-style candlestick chart PNGs via standalone Python scripts without calling separate market-data tools in the agent loop.
Install
npx skills add https://github.com/starchild-ai-agent/official-skills --skill chartingWhat is this skill?
- 4-step workflow: read template → write script → bash run → read_file PNG and markdown image display
- Critical rule: do not call price_chart, get_coin_ohlc_range_by_id, twelvedata_time_series, or other market data tools (a
- Standalone Python scripts per chart—no internal core imports; requests directly
- TradingView-quality candlesticks, dark theme, indicators via mplfinance/pandas/numpy
- Requires COINGECKO_API_KEY; optional PROXY_HOST auto-configuration in templates
- 4-step chart workflow documented in SKILL.md
- 3 pip dependencies: mplfinance, pandas, numpy
- Explicit warning against context flood from 78KB+ when calling market data tools separately
Adoption & trust: 4.4k installs on skills.sh; 13 GitHub stars; 1/3 security scanners passed (skills.sh audits).
What problem does it solve?
You want a visual chart but calling OHLC or price tools inline bloats context and breaks a clean plotting workflow.
Who is it for?
Agents and indie builders who need one-off or repeatable technical charts with indicators and a dark professional layout.
Skip if: Live trade execution, portfolio backtesting platforms, or workflows that require the agent to stream large OHLC payloads through tool calls.
When should I use this skill?
User wants a visual chart, price visualization, or technical analysis plot (TradingView-style candlesticks with indicators).
What do I get? / Deliverables
You get a runnable standalone chart script and an output PNG displayed in markdown, with data fetched inside the script per template rules.
- Standalone Python chart script under scripts/
- Output PNG under output/ referenced via markdown image syntax
Recommended Skills
Journey fit
Charting is shelved under Build integrations because it wires CoinGecko (and template) data fetch, Python plotting, and shell execution into one agent-driven deliverable. Integrations subphase matches external API keys, pip deps (mplfinance, pandas, numpy), and the four-step script workflow rather than app UI work.
How it compares
A chart generator skill with bundled templates—not an MCP market-data server you query for every bar.
Common Questions / FAQ
Who is charting for?
Solo builders using Claude Code, Cursor, or similar agents who want candlestick and indicator charts for crypto or market analysis without manual matplotlib setup.
When should I use charting?
Use it during Build when you need a visual chart, price visualization, or technical analysis plot and can supply COINGECKO_API_KEY and run Python in the workspace.
Is charting safe to install?
It runs shell scripts and network calls to price APIs using your API key; review the Security Audits panel on this Prism page and treat keys as secrets.
SKILL.md
READMESKILL.md - Charting
# Charting ## ⚠️ CRITICAL: DO NOT CALL DATA TOOLS **NEVER** call `price_chart`, `get_coin_ohlc_range_by_id`, `twelvedata_time_series`, or ANY market data tools when creating charts. Chart scripts fetch data internally. Calling these tools floods your context with 78KB+ of unnecessary data. **Workflow (4 steps):** 1. Read template from `skills/charting/scripts/` 2. Write script to `scripts/` 3. Run script with `bash` 4. Call `read_file` on the output PNG, then display it using markdown image syntax: `` --- You generate TradingView-quality candlestick charts. Dark theme, clean layout, professional colors. Every chart is a standalone Python script — no internal imports. **Additional Rules:** - Chart scripts run in workspace and cannot import from `core`. Use `requests` library directly, NOT `proxied_get()`. - Templates include proxy auto-configuration. If `PROXY_HOST` env var exists, scripts automatically configure `HTTP_PROXY`/`HTTPS_PROXY`. Tools: `write_file`, `bash`, `read_file` ## When to Use Which Chart **Simple price action** → Candlestick with no indicators. Good for "show me BTC this month." **Trend analysis** → Add EMA/SMA overlays. Good for "is ETH in an uptrend?" **Momentum check** → Add RSI or MACD as subplots. Good for "is SOL overbought?" **Full technical view** → Candles + Bollinger Bands + RSI + MACD. Good for "give me the full picture on BTC." **Volume analysis** → Requires separate fetch from market_chart endpoint (OHLC endpoint has no volume). **Asset comparison** → Line chart comparing two assets (BTC vs Gold, ETH vs S&P500, etc.). Use comparison template for normalized or percentage-based comparisons. ## How to Build Charts Read and customize the template scripts in `skills/charting/scripts/`: - `chart_template.py` — Baseline candlestick chart with TradingView styling (crypto via CoinGecko) - `chart_with_indicators.py` — RSI, MACD, Bollinger Bands, EMA/SMA examples (crypto via CoinGecko) - `chart_stock_template.py` — Stock/forex chart using Twelve Data API - `chart_comparison_template.py` — Compare two assets (crypto vs commodity, stock vs crypto, etc.) Copy the relevant template to `scripts/`, customize the config section (coin, days, indicators), and run it. The templates handle all data fetching internally with retry logic and error handling. **Note:** These templates are for market data visualization (price charts, indicators). For backtest result charts (equity curves, drawdowns, performance dashboards), add matplotlib charting directly to your backtest script — the data is already there, no need to re-fetch or create a separate file. ## TradingView Color Palette | Element | Color | Hex | |---------|-------|-----| | Up candles | Teal | `#26a69a` | | Down candles | Red | `#ef5350` | | Background | Dark | `#131722` | | Grid | Subtle dotted | `#1e222d` | | Text / axes | Light gray | `#d1d4dc` | | MA lines | Blue / Orange | `#2196f3` / `#ff9800` | | RSI line | Purple | `#b39ddb` | | MACD line | Blue | `#2196f3` | | Signal line | Orange | `#ff9800` | Do not deviate from this palette unless the user asks. ## Data Source APIs ### CoinGecko (Crypto Only) **Endpoint:** `https://pro-api.coingecko.com/api/v3/coins/{coin_id}/ohlc/range` **Auth:** Header `x-cg-pro-api-key: {COINGECKO_API_KEY}` **Use for:** BTC, ETH, SOL, and all cryptocurrencies Example: ```python url = f"https://pro-api.coingecko.com/api/v3/coins/{COIN_ID}/ohlc/range" params = {"vs_currenc