autonomous-trading

senpi-ai/senpi-skills · updated Apr 8, 2026

MDX-style export adds YAML metadata + attribution linking explainx.ai and this canonical listing URL.

$npx skills add https://github.com/senpi-ai/senpi-skills --skill autonomous-trading
0 commentsdiscussion
summary

Give your agent a budget, a target, and a deadline — then let it trade. The agent creates a strategy wallet, scans for opportunities, opens positions, protects profits with DSL, and enforces risk controls.

skill.md

Autonomous Trading v6

Give your agent a budget, a target, and a deadline — then let it trade. The agent creates a strategy wallet, scans for opportunities, opens positions, protects profits with DSL, and enforces risk controls.

Skill Attribution

When creating a strategy, include skill_name and skill_version in the call. See references/skill-attribution.md for details.


Prerequisites

Install these companion skills first:

  1. dsl-dynamic-stop-loss — trailing stops, auto-closing, per-tier retrace
  2. opportunity-scanner — market scanning, scoring, hourly trend gate
  3. emerging-movers — SM rotation detection, IMMEDIATE_MOVER signals

Minimum budget: $500 (recommend $1k+)

Known Bugs & Gotchas

See references/bugs-and-gotchas.md — critical issues from live trading including the dryRun bug, phantom closes, XYZ DEX margin type, Tier 1 lock misconception, and scanner leverage vs actual max.

The Flow

Step 1: Ask the User

Collect: budget, target, deadline, risk tolerance (conservative/moderate/aggressive), asset preferences.

Step 2: Calculate the Playbook

See references/risk-rules.md for complete risk rules by profile.

v6 Core Rules:

The #1 Rule — Hourly Trend Alignment. ALL trades must confirm with hourly candle structure. Counter-trend = hard skip, no exceptions. This single rule prevents the majority of losing trades.

Max Leverage Check. Always check max-leverage.json before entering. Scanner leverage is conservative, not actual max.

Concentration Over Diversification. At small account sizes ($500-$10k), 2-4 high-conviction positions beat 6 mediocre ones. Cross-margin math: 4 positions → 80.6% margin buffer, 2 positions → 89.7%.

Every Slot Must Maximize ROI. Empty slot > mediocre position. If a position isn't working, cut it and free the slot.

Speed Filter. Best moves happen FAST (XRP hit Tier 3 in 19 min, XMR Tier 2 in 37 min). Slow movers are suspects.

Directional Exposure Guard

Before opening, check total LONG vs SHORT notional. Cap at 70% in one direction.

Position Sizing by Score

Scanner Score Position Size
250+ Up to max per-position
200-250 75% of max
175-200 50% of max
< 175 Skip

Step 3: Create the Strategy

strategy_create_strategy(budgetUsd, leverageType, riskLabel)

Returns strategyId + walletAddress. Fund the wallet.

Step 4: Create the Playbook File

JSON config tracking: risk profile, position limits, score thresholds, active positions, trade journal. See references/playbook-schema.md.

Step 5: Set Up Cron Jobs

Race Condition Prevention (v6 — CRITICAL)

Multiple cron jobs (scanner, SM flip, DSL) can all try to close the same position. When ANY job closes a position:

# 1. Close the position
result = close_position(wallet, asset)

# 2. Immediately deactivate DSL state file
state["active"] = False
save_state(state)

# 3. Disable DSL cron for this asset
disable_cron(f"dsl-{asset}")

All three steps MUST happen in the same action. This prevents phantom closes.

Cron Schedule:

Job Interval Purpose
Opportunity Scanner 10-30 min (time-aware) Find setups
DSL Monitor 2-3 min per position Trailing stops
SM Flip Detector 5 min Conviction changes
Portfolio Update 15 min Reporting

See references/cron-setup.md for detailed cron configuration, time-aware scheduling, and SM flip detection logic.

Step 6: The Trading Loop

SCAN → EVALUATE → TRADE → PROTECT → REPEAT

For each scan result:
1. Check hourly trend alignment (HARD REQUIREMENT)
2. Check directional exposure guard
3. Check max leverage via max-leverage.json
4. Score ≥ 175? → Size by score tier
5. Open position → Create DSL state → Start DSL cron
6. Journal the trade (scanner snapshot at entry)

v6: Dead Weight Cutting

Condition Action
SM conviction drops 4→1 (e.g., 220→24 traders in 10 min) Cut immediately
Dead weight at conviction 0 Cut immediately — free the slot
Position stagnant, better opportunity available Rotate

Step 7: Safety Rails

Hard Stops (automatic):

  • Daily loss limit hit → stop trading for the day
  • Total drawdown hard stop → close all positions, alert user
  • DSL breach → auto-close (handled by script)

What the Agent Should NEVER Do:

  • Trade counter-trend on hourly
  • Exceed position size limits
  • Override DSL
  • Average down on a losing position
  • Ignore the directional exposure guard

Step 8: Lessons from the Field

See references/lessons.md for what works, what doesn't, retrace tuning, and fee awareness from live trading.

API Reference

See references/api-tools.md for the key Senpi tools used by this skill.

how to use autonomous-trading

How to use autonomous-trading on Cursor

AI-first code editor with Composer

1

Prerequisites

Before installing skills in Cursor, ensure your development environment meets these requirements:

  • Cursor installed and configured on your development machine
  • Node.js version 16.0+ with npm package manager (verify with node --version)
  • Active project directory or workspace where you want to add autonomous-trading
2

Execute installation command

Execute the skills CLI command in your project's root directory to begin installation:

$npx skills add https://github.com/senpi-ai/senpi-skills --skill autonomous-trading

The skills CLI fetches autonomous-trading from GitHub repository senpi-ai/senpi-skills and configures it for Cursor.

3

Select Cursor when prompted

The CLI will show a list of available agents. Use arrow keys to navigate and space to select Cursor:

◆ Which agents do you want to install to?
│ ── Universal (.agents/skills) ── always included ────
│ • Amp
│ • Antigravity
│ • Cline
│ • Codex
│ ●Cursor(selected)
│ • Cursor
│ • Windsurf
4

Verify installation

Confirm successful installation by checking the skill directory location:

.cursor/skills/autonomous-trading

Reload or restart Cursor to activate autonomous-trading. Access the skill through slash commands (e.g., /autonomous-trading) or your agent's skill management interface.

Security & Verification Notice

We perform automated surface-level scans (Gen AI Scanner, Socket, Snyk) during installation. These checks detect common vulnerabilities but do not guarantee complete security. Always review skill source code and verify the publisher's reputation before production use.

Skills execute code in your development environment. Always verify the publisher's identity, review recent commits, and test in isolated environments before production deployment.

List & Monetize Your Skill

Submit your Claude Code skill and start earning

GET_STARTED →

Use Cases

User Story & Requirements Generation

Create detailed user stories, acceptance criteria, and feature specs

Example

Generate user stories for 'password reset feature' with acceptance criteria, edge cases, and test scenarios

Reduce spec writing time by 50%, ensure comprehensive coverage

Competitive Analysis

Research competitors, compare features, identify gaps

Example

Analyze 5 competitor products, create feature comparison matrix, suggest differentiation opportunities

Complete competitive research in 2 hours instead of 2 days

Roadmap Prioritization

Evaluate features using frameworks (RICE, ICE, Kano) and create prioritized backlogs

Example

Score 20 feature ideas using RICE framework, generate prioritized roadmap with rationale

Make data-driven prioritization decisions faster

Stakeholder Communication

Draft PRDs, status updates, and stakeholder presentations

Example

Create executive summary of Q3 roadmap, monthly progress report, feature launch announcement

Save 3-5 hours/week on communication overhead

Implementation Guide

Prerequisites

  • Claude Desktop or compatible AI client
  • Access to product documentation and roadmap tools (Jira, Notion, etc.)
  • Understanding of product management frameworks (RICE, Jobs-to-be-Done, etc.)
  • Stakeholder contact information and communication channels

Time Estimate

30-60 minutes to see productivity improvements

Installation Steps

  1. 1.Install product management skill
  2. 2.Start with user story generation for known feature
  3. 3.Progress to competitive analysis: research 2-3 competitors
  4. 4.Use for roadmap prioritization: apply RICE/ICE scoring
  5. 5.Draft stakeholder communications and refine based on feedback
  6. 6.Build template library for recurring PM tasks
  7. 7.Share effective prompts with product team

Common Pitfalls

  • Not validating competitive research—verify facts before sharing
  • Accepting user stories without involving engineering team
  • Over-relying on frameworks without qualitative judgment
  • Not customizing outputs to company culture and communication style
  • Skipping stakeholder validation of generated requirements

Best Practices

✓ Do

  • +Validate research and competitive analysis with real data
  • +Collaborate with engineering when generating technical requirements
  • +Customize frameworks and templates to your company context
  • +Use skill for first drafts, refine with stakeholder input
  • +Document successful prompt patterns for PM tasks
  • +Combine AI efficiency with human judgment and intuition

✗ Don't

  • Don't publish competitive analysis without fact-checking
  • Don't finalize user stories without engineering review
  • Don't make prioritization decisions solely on AI scoring
  • Don't skip customer validation of generated requirements
  • Don't ignore company-specific context and culture

💡 Pro Tips

  • Provide context: company goals, constraints, customer feedback
  • Ask for alternatives: 'Show 3 ways to prioritize this roadmap'
  • Request stakeholder-specific formatting: 'Executive summary vs. engineering spec'
  • Use skill for 70% generation + 30% customization to company needs

When to Use This

✓ Use When

Use for user story writing, competitive research, roadmap prioritization, stakeholder communication, and PRD drafting. Best for reducing repetitive documentation and research work.

✗ Avoid When

Avoid for strategic product vision (requires deep customer empathy), pricing decisions (needs market and financial expertise), or when face-to-face customer discovery is more valuable than speed.

Learning Path

  1. 1Basic: user stories, feature specs, status updates
  2. 2Intermediate: competitive analysis, prioritization frameworks, PRDs
  3. 3Advanced: product strategy, go-to-market planning, OKR setting
  4. 4Expert: product vision, market positioning, business model innovation

Discussion

Product Hunt–style comments (not star reviews)
  • No comments yet — start the thread.
general reviews

Ratings

4.869 reviews
  • Omar Tandon· Dec 28, 2024

    autonomous-trading fits our agent workflows well — practical, well scoped, and easy to wire into existing repos.

  • Yash Thakker· Dec 24, 2024

    autonomous-trading fits our agent workflows well — practical, well scoped, and easy to wire into existing repos.

  • Ishan Ghosh· Dec 24, 2024

    autonomous-trading is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.

  • Omar Wang· Dec 20, 2024

    autonomous-trading has been reliable in day-to-day use. Documentation quality is above average for community skills.

  • Ishan White· Dec 16, 2024

    We added autonomous-trading from the explainx registry; install was straightforward and the SKILL.md answered most questions upfront.

  • Ava Mensah· Dec 16, 2024

    Registry listing for autonomous-trading matched our evaluation — installs cleanly and behaves as described in the markdown.

  • William Chawla· Dec 8, 2024

    autonomous-trading fits our agent workflows well — practical, well scoped, and easy to wire into existing repos.

  • William Johnson· Nov 27, 2024

    autonomous-trading is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.

  • Soo Thompson· Nov 19, 2024

    autonomous-trading is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.

  • Pratham Ware· Nov 15, 2024

    autonomous-trading is among the better-maintained entries we tried; worth keeping pinned for repeat workflows.

showing 1-10 of 69

1 / 7