BACK TO CLAUDE SKILLS
◈
generate_trade_plan
Claude AIClaude APITrade
INSTALLATION
$python -c "exec(open('generate_trade_plan.py').read())"
#or paste directly into your Claude Code terminal
[ ABOUT ]
Constructs a prompt containing the coin name, signal direction, and support/resistance level data, then asks Claude to generate a complete trade plan in JSON format with entry price, stop loss, take profit 1 (TP1), and take profit 2 (TP2) fields. The JSON format request ensures structured output that can be parsed without brittle string matching.
Trade plans generated by Claude are based on common risk management heuristics: stop loss below nearest support for longs, TP1 at the nearest resistance, TP2 at the next major resistance. For production use, validate the JSON output with `json.loads()` and add error handling for cases where Claude returns explanatory text instead of pure JSON.
[ USAGE EXAMPLE ]
[ FULL CODE ]
[ METADATA ]
CategoryClaude AI
ComplexityBeginner
LanguagePython 3.10+
TagsClaude API, Trade
[ ASK CLAUDE ]
Ask AI about this skill before installing it.