OS Trading Engine
Getting Started
Core Concepts
Agents

Agents

Agents are the core trading entities in Nexgent. Each agent operates independently with its own configuration, wallet, and positions.


What is an Agent?

An agent is an autonomous trading entity that:

  • Evaluates incoming trading signals
  • Executes trades when criteria are met
  • Monitors open positions
  • Manages stop loss and DCA strategies

Think of an agent as a virtual trader that follows your configured rules.


Agent Properties

PropertyDescription
NameDescriptive identifier
Trading Modesimulation or live
Automated TradingToggle for auto-execution
WalletAssigned wallet for funds
Trading ConfigRules for trading behavior

Trading Modes

Each agent operates in either simulation or live mode. See Simulation vs Live for a detailed comparison.


Automated Trading

The automated trading toggle controls whether an agent executes trades automatically:

SettingBehavior
OFFAgent evaluates signals but doesn't execute. You see eligible signals in the dashboard.
ONAgent automatically executes trades for qualifying signals.

Simulation and live modes have separate automated trading toggles.


Trading Configuration

Each agent has a comprehensive trading configuration organized into tabs on the Agent Profile page under Trading Strategy.

Purchase & Position Tab

Configure purchase limits and position sizing:

Purchase Limits:

  • Minimum Agent Balance — Minimum SOL to maintain in wallet
  • Max Purchase Per Token — Maximum SOL per trade
  • Max Slippage — Maximum allowed slippage percentage

Position Calculator:

  • SOL Balance Thresholds — Define what counts as Small, Medium, and Large balances
  • Position Sizes by Category — Set min/max position sizes for each balance category
  • Position Randomization — Toggle to randomize position sizes within ranges
Balance CategoryDefault Position Range
Small0.02 - 0.05 SOL
Medium0.05 - 0.15 SOL
Large0.15 - 0.50 SOL

Signals Tab

Configure which signals the agent responds to:

  • Minimum Signal Strength — Filter signals by strength (1-5)
  • Signal Types — Select which signal types to trade
  • Token Filter — Blacklist or whitelist specific tokens

See Trading Signals for details on signal filtering.

Stop Loss Tab

Configure automatic loss protection. See Risk Management for details on stop loss modes and configuration.

DCA Tab

Configure dollar-cost averaging for positions. See Risk Management for details on DCA modes and configuration.

Stale Trade Tab

Configure handling of stagnant positions:

  • Enable Stale Trade Config — Toggle in header
  • Minimum Hold Time — Minutes before considering a trade stale
  • Profit Range — Min and Max profit percentages for exit

Agent Eligibility

When a signal arrives, the agent checks eligibility:

Signal Received


┌─────────────────┐
│ Signal Strength │──▶ Is strength >= minScore?
│     Check       │    
└────────┬────────┘
         │ Yes

┌─────────────────┐
│ Balance Check   │──▶ Has enough SOL?
│                 │    
└────────┬────────┘
         │ Yes

┌─────────────────┐
│ Blacklist Check │──▶ Token not blocked?
│                 │    
└────────┬────────┘
         │ Yes

┌─────────────────┐
│ Whitelist Check │──▶ Token allowed (if enabled)?
│                 │    
└────────┬────────┘
         │ Yes

┌─────────────────┐
│ Existing Check  │──▶ Not already holding?
│                 │    
└────────┬────────┘
         │ Yes

    ✓ ELIGIBLE
    Execute Trade

Creating an Agent

Via Dashboard

  1. Click Create new agent in the sidebar, or click Create Agent on the General page
  2. In the dialog, enter a Name for your agent
  3. Select a Stop Loss Strategy:
    • Fixed Stepper — Linear 10% steps
    • Exponential Decay — Smooth exponential curve
    • Step-Based Zones — 5-zone system
    • Custom — Manual levels
  4. Click Create Agent

Your agent is created and you're automatically redirected to the Performance Overview.

You can modify all other trading settings after creation on the Agent Profile page.

Via API

curl -X POST http://localhost:4000/api/v1/agents \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "My Agent",
    "tradingMode": "simulation"
  }'

Managing Agents

View All Agents

Navigate to the General page to see all your agents. Each agent card shows:

  • Agent name
  • Agent ID (with copy button)
  • Quick actions

Switch Between Agents

You can switch agents in two ways:

  • Use the Agent Switcher dropdown in the sidebar
  • Click Switch to agent on an agent card in the General page

View Agent Details

Navigate to Agent Profile (in the sidebar) to see:

  • Agent Profile section — Name and ID
  • Trading Strategy section — All configuration tabs

Update Configuration

  1. Navigate to Agent Profile in the sidebar
  2. Under Trading Strategy, select the tab you want to modify:
    • Purchase & Position
    • Signals
    • Stop Loss
    • DCA
    • Stale Trade
  3. Modify settings as needed

All changes auto-save automatically. You'll see "Saving...", "Saved", or "Save failed" indicators.

Rename an Agent

  1. Navigate to Agent Profile
  2. Edit the Agent Name field
  3. Changes auto-save after you stop typing

Delete Agent

  1. Navigate to the General page
  2. Find the agent you want to delete
  3. Click the trash icon on the agent card
  4. Confirm deletion in the dialog

Deleting an agent preserves historical swap data for reporting.


Multi-Agent Strategies

You can create multiple agents with different strategies:

AgentPurposeConfiguration
ConservativeLower riskHigh min score, tight stop loss
AggressiveHigher riskLower min score, wider stop loss
Specific TokenFocus on one tokenWhitelist enabled
Simulation TestStrategy testingSimulation mode

Best Practices

1. Start with Simulation

Always test new configurations in simulation mode first. See Simulation vs Live for details.

2. Set Appropriate Limits

Don't risk more than you can afford to lose per trade.

3. Use Signal Filters

Configure Minimum Signal Strength on the Signals tab to filter out weak signals. See Trading Signals for filtering options.

4. Monitor Performance

Regularly review historical swaps to assess strategy effectiveness.

5. Separate Live and Simulation

Use different agents for live trading vs testing.