strategy_trailing_stop

Automate trailing stop loss management with Alpaca market sell orders.

2|4|Updated Apr 27, 2026
One-click install
npx skills add https://github.com/khoks/ClaudeTrading --skill strategy-trailing-stop
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: strategy_trailing_stop
Source: https://github.com/khoks/ClaudeTrading/tree/main/.claude/skills/strategy_trailing_stop
Command: npx skills add https://github.com/khoks/ClaudeTrading --skill strategy-trailing-stop

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires jq, and includes scripts (resource) components.

What problem does it solve?

This Skill eliminates the error-prone and time-consuming manual work of tracking stock price peaks and triggering sell orders when prices drop, which is critical for consistent risk management in automated paper trading systems.

Core Features & Use Cases

  • Floor-only trailing stop logic: Automatically raises the high watermark as stock prices increase (never lowering it) to track peak performance without repainting historical data.
  • Configurable risk thresholds: Supports per-stock custom drop and raise percentages with sensible defaults, allowing traders to match the strategy to their individual risk tolerance.
  • Use case: For users of the ClaudeTrading paper trading system, it automatically exits positions when prices fall below the trailing stop, locking in gains without requiring constant manual price monitoring.

Quick Start

Invoke the strategy_trailing_stop skill as part of a master_trading run with the trailing-stop strategy enabled to automatically evaluate and execute trailing stop sell orders for eligible stocks in your sellable set.

Frequently Asked Questions about strategy_trailing_stop

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate a trailing stop loss strategy for stock trading?

An automated trailing stop loss strategy tracks high watermarks and triggers market sell orders when stock prices fall below configured drop thresholds. This Skill executes that logic automatically by processing sellable stock sets and integrating with Alpaca trading APIs for order execution.

How does a floor-only trailing stop logic work without repainting historical data?

Floor-only trailing stop logic automatically raises the high watermark as stock prices increase but never lowers it. This tracks peak performance without repainting historical data, ensuring the trailing stop only moves in a favorable direction to lock in gains.

Can I configure custom drop and raise percentages for each stock in my portfolio?

Yes, the trailing stop strategy supports per-stock custom drop and raise percentages alongside sensible defaults. This allows traders to match the automated exit thresholds to their individual risk tolerance for each specific position.

Do I need an Alpaca paper trading account to use automated trailing stop exits?

Yes, integration with Alpaca trading APIs is required for order execution and state persistence. This Skill is designed to run within automated paper trading workflows, specifically processing sellable stock sets from master trading orchestrators.

What is the best way to lock in trading gains without manual price monitoring?

Automated trailing stop exits eliminate manual price monitoring by tracking high watermarks and triggering sell orders when prices drop below configured thresholds. Invoking this strategy as part of a master trading run automatically evaluates and executes risk-managed exits for eligible stocks.

Why does the trailing stop strategy require processing a sellable stock set?

The trailing stop strategy processes sellable stock sets from master trading orchestrators to validate position quantities before executing sell orders. This ensures automated risk-managed exit strategies only apply to eligible stocks within your automated paper trading workflows.