Skip to main content

Action Space

In short

The set of decisions the RL agent can make — buy, sell, hold fractions

The action space defines what choices the AI can make. A simple agent has 3 actions: buy, sell, hold. A more sophisticated one can trade any fraction of its portfolio. More actions = more flexibility but harder to train.

The action space for trading RL agents can be discrete (buy/sell/hold) or continuous (fractional position sizes). Continuous action spaces allow precise position sizing but require more training. Bounded actions prevent leverage or short-selling in constrained configurations.

Related concepts

  • Reinforcement LearningRL is how an AI learns to make decisions by trying things and getting rewards or penalties. Think of training a dog — good moves get treats, bad moves get nothing. The AI keeps adjusting until it finds the best strategy.
  • Observation SpaceThe observation space is everything the AI trading agent can see before making a decision. It might include price data, technical indicators, sentiment scores, and portfolio state. More useful data = better decisions (up to a point).
  • PPO AlgorithmPPO is one of the best algorithms for training AI agents. It learns slowly and steadily instead of making wild policy changes that could destabilize training. Think of it as a careful student who improves step by step.