Skip to main content

A Custom AI stock trader.

Project description

Description

CI Tests Static Badge Static Badge License: MIT

Syndicate is an AI-powered stock trading agent with a built-in integration with Alpaca's brokerage API. It allows you to automatically monitor and trade a customizable watchlist of tickers with minimal manual intervention. The system is designed to combine multiple forms of analysis into a single, cohesive decision-making pipeline. It includes:

  • A news analyst that reads and summarizes recent news affecting your assets.
  • A fundamental analyst that evaluates company financials and balance sheets.
  • A technical analyst that interprets indicators and price action.
  • A trader that executes buy/sell decisions based on the combined recommendations of the analysts, while respecting deterministic guardrails defined by the user.

The package is open source and freely available via PyPI or this repository. However, it follows a bring-your-own-keys model: you will need active API credentials for both market data and an LLM provider to run it. Currently supported model providers include Anthropic, Google, OpenAI, Qwen, and Moonshot.

Syndicate also ships with a terminal user interface (TUI), making setup, configuration, and monitoring straightforward and intuitive—even for first-time users.

Prerequisites

Syndicate relies on a few external services to function properly:

  • A UNIX operating system to schedule jobs (i.e. linux, macos)
  • A brokerage account with Alpaca (for trading, account data, news, and real-time quotes)
  • An API key from Alpha Vantage (for technical indicators and supplementary market data)
  • API access to at least one supported LLM provider

You can sign up for Alpaca and Alpha Vantage and obtain free API keys using the links provided in this document. Most users can get started entirely on free tiers.

Installation

You can install the package from pypi just as you would any other:

pip install syndicate-trading

or, download the build artifacts from this repo:

pip install git+https://github.com/mskmay66/syndicate@v0.1.0

Setup

Configuring your syndicate agen is easy, simply open a terminal and run:

syndicate

You will then be confronted with the TUI which should look something like this:

From there simply press the s key to toggle to the setup screen. This is what you should see (minus my setup, yours should be blank)

From here just follow the prompts from the TUI to fill things out, if you are confused about what anything means, read on and it will be explained.

How to Configure your Agent

There are lot of choices you need to make when you first confiure your agent, let's go through them one by one.

1. What stocks do you want to follow?

Choose the tickers you want the agent to monitor and trade. This can be a focused list (e.g., a few tech stocks) or a broader portfolio. Keep in mind that more tickers = more API usage and potentially higher LLM costs.

2. What model do you want to use?

If you already have access to a supported provider, this may be an easy choice. Otherwise, consider:

  • Performance: Some models are better at reasoning over financial data.
  • Cost: Pricing varies significantly between providers.
  • Latency: Faster models may be preferable for frequent trading cycles.

For a deeper comparison, see this paper: 👉 https://arxiv.org/html/2510.02209v1

TLDR: Models like Qwen and Kimi tend to perform well for structured reasoning tasks, but the “best” choice depends on your priorities (cost vs performance).

3. How do I get all these keys?

📊 Alpha Vantage API Key (Market Data)

  1. Go to the Alpha Vantage signup page: 👉 https://www.alphavantage.co/support/#api-key
  2. Enter your email and request a free API key.
  3. Your key will be shown immediately and also sent to your email.

Notes:

  • Free tier includes rate limits (typically 5 requests/minute, 500/day).
  • No credit card required.
  • Provides technical indicators, time series data, and more

📈 Alpaca API Keys (Trading)

  1. Create an account at Alpaca: 👉 https://app.alpaca.markets/signup
  2. After signing in, navigate to the API Keys section: 👉 https://app.alpaca.markets/paper/dashboard/overview

Notes:

  • Use Paper Trading mode for testing (no real money).

Configuring Guardrails

These settings control how your agent behaves in live markets and are critical for managing risk.

  • Execution Frequency: Determines how often the agent runs. Syndicate creates a background cron job for you.
    • Use preset intervals (e.g., hourly, daily), or
    • Select Custom to provide your own cron expression.
  • Position Concentration: Limits how much of your portfolio can be allocated to a single asset.
  • Stop Loss (%): Defines the maximum acceptable loss per position before exiting.
  • Take Profit (%): Specifies when gains should be locked in automatically.

These controls ensure that, regardless of model output, trading behavior stays within predictable and user-defined risk bounds.

Paper Trading

Alpaca supports paper trading, allowing you to test strategies without risking real money.

You can enable this via the toggle at the bottom of the setup screen. This is highly recommended when:

First configuring your agent Testing new strategies or guardrails Evaluating different models

Changing Settings

To update your configuration:

  1. Return to the setup screen (s)
  2. Modify any fields
  3. Press f to save and apply changes

Your previous settings will be preloaded for convenience.

Tracking Your Agent

To monitor your agent in real time, open the TUI’s main screen. This serves as your central dashboard, giving you a clear view into both performance and decision-making.

From here, you can:

  • Track your portfolio performance over time
  • Review recent trades and transactions
  • Interact directly with your trading team through an integrated LLM-powered chatbot

The chatbot allows you to ask questions about recent decisions, market conditions, or portfolio state—making the system more transparent and easier to reason about.

Here’s what the main screen looks like:

TradingAgents

The agent framework used in this project is inspired by the excellent TradingAgents repository.

Syndicate extends this work by adding automated trade execution, enabling a fully end-to-end pipeline from analysis → decision → execution. If you’re interested in the analysis side without automated trading, that project is worth exploring.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

syndicate_trading-0.1.0.tar.gz (605.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

syndicate_trading-0.1.0-py3-none-any.whl (48.5 kB view details)

Uploaded Python 3

File details

Details for the file syndicate_trading-0.1.0.tar.gz.

File metadata

  • Download URL: syndicate_trading-0.1.0.tar.gz
  • Upload date:
  • Size: 605.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for syndicate_trading-0.1.0.tar.gz
Algorithm Hash digest
SHA256 8ea45f5253c9e5f64daf9b85908f3dc471552b741a1f1b42f1a07546b472229f
MD5 dea00a93a47966d03f07c9c66888ae0c
BLAKE2b-256 6a038f951081c21f1a25863774cec681b7a51e8a433bb0b9846599ae91317faa

See more details on using hashes here.

Provenance

The following attestation bundles were made for syndicate_trading-0.1.0.tar.gz:

Publisher: deploy.yaml on mskmay66/syndicate

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file syndicate_trading-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for syndicate_trading-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 803c7ebf4d541d4a97377f290885905e67f193eba1a2cb0b03fb87c7e04f8e93
MD5 8ff3e1b0ea670e8748432e154579f5a2
BLAKE2b-256 902554143876fdaf3a1404acbd64a22be6e5531cdaf05f9284f57a2c2d2cd92e

See more details on using hashes here.

Provenance

The following attestation bundles were made for syndicate_trading-0.1.0-py3-none-any.whl:

Publisher: deploy.yaml on mskmay66/syndicate

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page