Bill Ackman Concentrated AI Trading Team

AI trading team workflow for Bill Ackman concentrated style investing

This strategy is inspired by Bill Ackman and Pershing Square-style concentrated investing: do deep work on a small number of understandable, high-quality businesses, make a strong bull case, invite a brutal bear case, and then act with conviction if the thesis survives.

The team is intentionally adversarial. The quality researcher finds the best candidate, the activist bull looks for catalysts and value creation, the short-seller bear attacks the thesis, and the portfolio manager decides whether one concentrated position is still justified.

See this strategy running live on BotSpot

How the team works

  • quality_researcher finds the best high-quality large-cap candidate.

  • activist_bull argues for catalysts, pricing power, and value creation.

  • short_seller_bear attacks leverage, governance, accounting, competition, and valuation risk.

  • portfolio_manager builds one concentrated position and is the only agent allowed to trade.

Backtest snapshot

Top of the Bill Ackman concentrated AI trading team backtest tear sheet

Run it with a broker

The file defaults to broker-connected execution. With Alpaca, it runs in paper mode unless you set ALPACA_IS_PAPER=false.

export GEMINI_API_KEY='your-key-here'
export ALPACA_API_KEY='your-alpaca-key'
export ALPACA_API_SECRET='your-alpaca-secret'
export ALPACA_IS_PAPER=true
python lumibot/example_strategies/ai_trading_team_bill_ackman_concentrated.py

Backtest it

Use the same strategy class and change IS_BACKTESTING = False to IS_BACKTESTING = True in the runner:

export GEMINI_API_KEY='your-key-here'
python lumibot/example_strategies/ai_trading_team_bill_ackman_concentrated.py

Example code

"""Bill Ackman / Pershing Square-inspired concentrated AI trading team example.

This example is inspired by public descriptions of concentrated, high-quality
large-cap investing. It is not affiliated with or endorsed by Bill Ackman,
Pershing Square, or related companies.

Set GEMINI_API_KEY plus Alpaca credentials, then run paper trading:
    python ai_trading_team_bill_ackman_concentrated.py

Set IS_BACKTESTING=True in the runner to run the historical example instead.
"""

import os
from datetime import datetime

from lumibot.strategies.strategy import Strategy


class AITradingTeamBillAckmanConcentratedStrategy(Strategy):
    parameters = {
        "universe": ["GOOGL", "CMG", "HLT", "QSR", "UBER", "CP", "LOW", "MDLZ", "BKNG", "MSFT"],
    }

    def initialize(self):
        self.sleeptime = "1D"
        model = os.environ.get("AI_TRADING_TEAM_MODEL", "gemini-3.1-flash-lite")
        self.agents.create(
            name="quality_researcher",
            model=model,
            allow_trading=False,
            system_prompt="Find the best high-quality, large-cap business with durable free cash flow and clear upside.",
        )
        self.agents.create(
            name="activist_bull",
            model=model,
            allow_trading=False,
            system_prompt="Argue for the most concentrated high-conviction position. Focus on catalysts, pricing power, and value creation.",
        )
        self.agents.create(
            name="short_seller_bear",
            model=model,
            allow_trading=False,
            system_prompt="Attack the thesis like a short seller. Find leverage, governance, accounting, competition, and valuation risk.",
        )
        self.agents.create(
            name="portfolio_manager",
            model=model,
            allow_trading=True,
            system_prompt="Build one concentrated position from the universe if the bull case survives. Use nearly all cash in the best idea.",
        )

    def on_trading_iteration(self):
        context = {
            "date": self.get_datetime().date().isoformat(),
            "universe": self.parameters["universe"],
        }
        quality = self.agents["quality_researcher"].run(task_prompt="Pick the best high-quality large-cap candidate.", context=context)
        bull = self.agents["activist_bull"].run(task_prompt="Make the concentrated bull case.", context={**context, "quality": quality.summary})
        bear = self.agents["short_seller_bear"].run(
            task_prompt="Attack the concentrated thesis.",
            context={**context, "quality": quality.summary, "bull": bull.summary},
        )
        self.agents["portfolio_manager"].run(
            task_prompt="Sell anything that is not the surviving best idea, then buy the best stock with nearly all available cash.",
            context={**context, "quality": quality.summary, "bull": bull.summary, "bear": bear.summary},
        )


if __name__ == "__main__":
    IS_BACKTESTING = False

    if IS_BACKTESTING:
        from lumibot.backtesting import YahooDataBacktesting

        AITradingTeamBillAckmanConcentratedStrategy.backtest(
            YahooDataBacktesting,
            datetime(2026, 4, 7),
            datetime(2026, 5, 22),
        )
    else:
        from lumibot.brokers import Alpaca
        from lumibot.traders import Trader

        ALPACA_CONFIG = {
            "API_KEY": os.environ["ALPACA_API_KEY"],
            "API_SECRET": os.environ["ALPACA_API_SECRET"],
            "PAPER": os.environ.get("ALPACA_IS_PAPER", "true").lower() != "false",
        }

        broker = Alpaca(ALPACA_CONFIG)
        strategy = AITradingTeamBillAckmanConcentratedStrategy(broker=broker)

        trader = Trader()
        trader.add_strategy(strategy)
        trader.run_all()