strategy-on-actions

Implement LivTorgEx strategy event handlers and executable bot actions.

Updated Mar 29, 2026
One-click install
npx skills add https://github.com/LivTorgEx/strategy-skill --skill strategy-on-actions
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: strategy-on-actions
Source: https://github.com/LivTorgEx/strategy-skill/tree/main/skills/strategy-on-actions
Command: npx skills add https://github.com/LivTorgEx/strategy-skill --skill strategy-on-actions

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

LivTorgEx strategy builders need a precise way to script what bots do at analysis ticks, indicator candle closes, position open/close events, and manual UI triggers.

Core Features & Use Cases

  • Event handler structure: Defines on_analysis, on_indicators, on_created, on_finished, and on_actions with the correct payload shapes and filtering semantics.
  • State management via variables: Uses persistent variables with safe evaluation rules plus SetVariable/ClearVariable updates for multi-step strategies.
  • Comprehensive action catalog: Documents how to start/stop bots and positions, create/remove orders safely (including mark to prevent duplicates), and implement conditional flow with Actions and Break.
  • Entry lifecycle control: Guides correct usage of enter_price: Force vs enter_price: Wait and when to invoke ForceStartPosition.

Quick Start

Ask your AI agent to generate a professional block that uses on_indicators to set an indicator flag in a variable and then uses on_analysis to ForceStartPosition, with on_finished stopping the bot after closing the position.

Frequently Asked Questions about strategy-on-actions

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

FAQPage Schema
How do I define trading bot event handlers for indicator-driven entries and position lifecycle events?

Trading bot event handlers are defined using on_analysis, on_indicators, on_created, on_finished, and on_actions flows to script actions at analysis ticks, candle closes, and manual triggers. Each handler requires mandatory Action typing and correct payload schemas to execute indicator-driven entries and position lifecycle events.

How do I manage state in a multi-step trading bot strategy with persistent variables?

Multi-step trading bot strategy state is managed using persistent variables with safe evaluation rules. You can update these variables using SetVariable and ClearVariable actions to store indicator flags across handler events for conditional entry logic.

How do I prevent duplicate orders in trading bot strategy execution?

Duplicate orders in trading bot strategy execution are prevented using order marks. By assigning a mark to create and remove order actions, the strategy deduplicates orders safely, ensuring the same order is not placed multiple times across event handler triggers.

When should I use ForceStartPosition versus enter_price Wait in trading bot logic?

ForceStartPosition is used to immediately trigger position entry, while enter_price Wait queues the entry until price conditions are met. Use ForceStartPosition in on_analysis when an indicator flag variable confirms entry criteria, bypassing the waiting period.

Can I implement hedged LONG and SHORT positions within a single trading bot lifecycle?

Hedged LONG and SHORT scenarios are supported within a single trading bot lifecycle using conditional order placement and explicit ForceStopBot semantics. The strategy uses on_finished handlers to stop or revert bot behavior after closing hedged positions.

How do I structure on_indicators actions arrays for timeframe-based candle close events?

Timeframe-based on_indicators actions arrays are structured with correct handler schemas that filter semantic payloads at indicator candle closes. You define action arrays mapped to specific timeframes, applying conditional flow with Actions and Break to control execution.