Developing a real-time automated trading platform with Python
In OpenSistemas we have developed a general-purpose multi-agent system which is written in pure Python: osBrain. Agents communicate with each other using ZeroMQ, allowing the user to define different communication patterns based on their needs.
Based on this multi-agent system, we have also developed a broker-independent platform for real-time automated trading: osMarkets. This platform implements specialized agents:
- Feeder is an agent which receives real-time data from the broker.
- Router is an agent which receives data from feeders. It manages the historical data and distributes updates to all the subscribed agents in the network.
- Brain is the most common agent. It receives data from router or from other brains and processes them, sending the results to other brains or sending orders to be executed. Brains can make use of many useful packages avilable in the Python ecosystem: NumPy, SciPy, Numba, Theano…
- Trader is an agent which is designed to interact with the broker, just as the feeder, but to execute market orders.
While it is still in its earliest stages, we are developing a tool for real-time visualization of trading strategies using PyQtGraph. This tool acts as an agent in the multi-agent system.
Do you have some questions on this talk?