Trader to Trader: From Quant Workflows to LLM-Assisted Trading with Alpaca

By Laurentiu Gabriel Raducu

This content is for educational and informational purposes only and should not be construed as investment advice, a recommendation, or an offer to buy or sell any securities or cryptocurrencies. Any strategies discussed are illustrative only and may not be suitable for all investors. This article reflects the experience of an individual user, is not representative of all customers, and should not be considered an endorsement or guarantee of future performance. The views and opinions expressed are those of the author and do not reflect or represent the views and opinions of Alpaca. Alpaca does not recommend any specific securities or investment strategies.The author was not compensated for this content but did receive nominal promotional items from Alpaca.

How I Got Started

After graduating from college, I got my first job as a software engineer at a company developing software for investment bankers. My role as a junior developer was to learn as much as possible about capital markets, and assist the team in developing the pricing module of an app that was calculating Greeks and risk indicators for derivatives.

I had close to zero experience in finance, but something about capital markets always intrigued me. Working with quantitative developers made me realize that finance was much deeper than reacting to news cycles, and that realization pulled me into a much larger world of ideas. So I decided to dig deeper. 

In 2020 I placed in a quantitative trading competition, which encouraged me to continue exploring systematic trading.  The experience gave me confidence that systematic trading was something I wanted to explore more seriously and potentially pursue as a larger part of my professional development.

As I continued building and testing strategies during the COVID era, I started looking for reliable market access, clean developer tooling, and enough flexibility to experiment quickly. That’s when I discovered Alpaca.

Fast forward to 2026, and my focus had shifted from simply building systematic strategies to finding ways to improve the research and development process behind them.

At the same time, we were in the middle of an explosion in generative AI, advanced robotics, and quantum computing. Bubble or not, LLMs felt like one of those technologies that could meaningfully expand what individuals can build.

For me, that meant integrating them directly into my trading software, not as hype-driven features, but as tools for research, signal interpretation, strategy iteration, and faster decision-making.

Over the past few years, that approach has evolved into a collection of projects exploring how AI and systematic trading can work together within structured, rule-based workflows.

How AI Changed My Workflow

My original process was very rule-driven:

  • Source market data  
  • Build signals  
  • Backtest  
  • Deploy  
  • Iterate

That foundation still matters, and I still keep execution deterministic. What changed is how I now use AI in the workflow.

Instead of treating LLMs as “black-box decision makers,” I use them for structured analysis and hypothesis generation while keeping execution and risk controls deterministic. In other words, AI can support the decision process, but guardrails must always control live actions.

Alpaca fit this shift naturally because I could work with market data, account context, and execution in one API-first environment.

High-level AI-assisted workflow from data ingestion to constrained execution

Data and Orchestration Workflow

The practical workflow matters more than the architecture diagram, so here’s what the system looks like on a typical day:

  • Pre-market data load: Pull OHLCV and account context, then enrich with fundamentals/news/sentiment snapshots.
  • Feature packaging: Convert raw inputs into a consistent schema so each model run is comparable.
  • Model pass: Generate structured hypotheses per symbol with explicit confidence and invalidation criteria.
  • Constraint pass: Apply deterministic checks (position caps, exposure concentration, execution eligibility).
  • Execution and logging: Submit approved orders through Alpaca and persist a full decision trace.

This order of operations solved two recurring problems for me: inconsistent prompts, and untraceable decisions.

Project #1: GPT Trading Agent

GPT Trading Agent is my open-source playground for AI-assisted trading agents connected to Alpaca workflows.

The core design principle is simple: the LLM should be one component inside a structured pipeline and not an unconstrained actor.

Example run

How the Pipeline Works

At a high level, each run follows this sequence:

  1. Gather multi-source context (price/volume structure, financials, news, sentiment, and prediction-market inputs when available).
  2. Normalize the data into a compact prompt schema so model inputs are consistent across assets.
  3. Ask the model for a structured output (thesis, confidence, invalidation conditions, and time horizon).
  4. Validate output against deterministic risk and execution constraints.
  5. Translate approved decisions into Alpaca orders.
  6. Log all intermediate artifacts for audit and post-trade review.

Design Decisions

In my experience, structured outputs have been easier to parse, test, and compare across runs than free-form text.

Risk checks remain external to the model, helping ensure that prompt drift does not directly translate into execution risk.The sizing and routing remain deterministic, which has helped maintain more consistent behavior as prompts and models evolve.

Finally, full trace logging makes it easier to answer a simple but important question: “What changed?”

Key Experiments

Some experiments produced clear improvements, others were mostly noise:

  • In my testing, adding fundamental context appeared to improve holding-period consistency more than adding additional social signals.
  • Prompt compression also appeared useful, as shorter schema-based prompts were associated with fewer contradictory model responses in my testing.
  • Ensemble model voting looked attractive initially, but increased complexity faster than it improved reliability for my use case.

The key lesson for me was that pipeline discipline often mattered more than model novelty in the environments I tested.

Failure Modes

Three issues showed up early and shaped the current implementation:

  • Context drift, meaning the model quality drops when inputs are not normalized across runs.
  • Silent risk creep, when good-looking ideas can still violate exposure constraints if risk checks are not strict and external.
  • Debugging blind spots without step-level logs.

Most of the architecture choices in this project came from addressing these failure modes, not from trying to maximize sophistication.

Project #2: Greek-Alpaca  

If GPT-Trading-Agent is about AI-assisted decision workflows, Greek-Alpaca is about options intelligence and risk context.

This project came from a practical need: I wanted a cleaner Alpaca-connected layer for options analytics that I could reuse across systems rather than rebuilding Greek logic every time.

Greekflow

Why It Matters

  • Greeks are commonly used to help evaluate options exposure, not just entry/exit timing.
  • I found AI-generated trade ideas easier to evaluate when paired with risk-sensitivity analysis.
  • A reusable OSS component reduces duplicated engineering effort across projects.

In practice, this helps answer better questions before execution:

  • "Is this idea still valid if implied volatility shifts?"
  •  "Am I adding directional exposure or convexity exposure?"
  • "What risk changes if the underlying moves 1-2 standard deviations?"

For me, Greek-Alpaca is about making options workflows easier to test, inspect, and improve over time.

Dashboard of GreekFlow
Recommendations of GreekFlow

Backtesting Lessons and Cross-Platform Validation

One lesson I keep relearning is that backtesting quality matters more than strategy storytelling.

I rely on custom evaluation tooling to inspect:

  • Signal behavior across market regimes.
  • Return distribution, not just average returns.
  • Drawdown dynamics and volatility sensitivity.
  • Edge cases around execution assumptions.

I also validate ideas across multiple environments, including platforms like Quantiacs, to separate robust logic from platform-specific artifacts. That process has helped me identify hidden assumptions earlier and has contributed to a more consistent development workflow.

This cross-platform validation has helped me identify hidden assumptions earlier and evaluate how strategies behave across different environments.

What I'd Build Differently If I Restarted

If I were starting from zero again, I'd do three things earlier:

1. Build a stricter experiment registry from day one (prompt version, feature set, model, and result snapshot per run).

2. Add regime-based strategy weighting earlier, especially to reduce contrarian exposure in strong trend regimes.

3. Add richer execution simulation sooner (partial fills/slippage sensitivity), before trusting clean backtest curves.

Those changes would likely provide a more realistic view of system behavior and assumptions.

What's Next

The next step in my own workflow is expanding from single-idea evaluation to portfolio-level orchestration:

  • Agent-level capital allocation based on regime confidence.
  • Deeper options integration between GPT-Trading-Agent and Greek-Alpaca.
  • Tighter live-vs-backtest tracking to better understand when assumptions begin to diverge from observed results.

The objective stays the same: practical, inspectable systems that improve through iteration.

Lessons for Builders

If you’re building in this space, these are a few lessons I’ve found useful through experimentation and iteration:

1. I’ve learned that AI has been most useful for synthesis and hypothesis generation rather than direct execution.

2. Building observability early proved valuable in my own workflow: decision logs, constraints, and outcome tracking.

3. I found that investing time in risk architecture often provided more value than pursuing additional model complexity.

4. Maintaining deterministic execution controls has been an important design choice in my own systems.

And one practical note: optimize for repeatability before optimization. A slower workflow you can trust beats a faster workflow you can't inspect.

Resources

If you’re interested in building AI-assisted trading workflows or systematic trading infrastructure, here are a few resources I found useful:

Sign up for Alpaca’s Trading API account to get started with programmatic trading, including access to market data, order execution, and paper trading.

Alpaca MCP Server – An open-source Model Context Protocol (MCP) server that enables AI assistants to interact with Alpaca accounts, positions, and market data.

Alpaca Slack Community – A place to connect with other developers, share projects, ask questions, and learn from the broader Alpaca community.

GPT Trading Agent – An open-source project exploring structured LLM-assisted trading workflows, deterministic execution controls, and decision-trace logging.

Greek-Alpaca – An open-source options analytics toolkit focused on exposure analysis, risk sensitivities, and reusable options infrastructure.

Alpaca has been an important part of this journey, providing the market data, paper trading environment, and API-first infrastructure used throughout these projects. The repositories above reflect many of the ideas and experiments discussed in this article.

About the Author

Laurentiu Gabriel Raducu is a software engineer and systematic trading researcher focused on quantitative workflows, AI-assisted trading systems, options analytics, and open-source trading infrastructure.


*The Paper Trading API is offered by AlpacaDB, Inc. and does not require real money or permit a user to transact in real securities in the market. Providing use of the Paper Trading API is not an offer or solicitation to buy or sell securities, securities derivative or futures products of any kind, or any type of trading or investment advice, recommendation or strategy, given or in any manner endorsed by AlpacaDB, Inc. or any AlpacaDB, Inc. affiliate and the information made available through the Paper Trading API is not an offer or solicitation of any kind in any jurisdiction where AlpacaDB, Inc. or any AlpacaDB, Inc. affiliate (collectively, “Alpaca”) is not authorized to do business.

The projects discussed in this article are experimental software tools developed by a third-party user and are not products, services, or recommendations of Alpaca. AI-assisted workflows and automated systems involve significant risks, including model errors, incomplete data, technology failures, and changing market conditions.

This article is for educational and informational purposes only and should not be construed as investment advice, a recommendation, or an offer to buy or sell any security or cryptocurrency. The views expressed are those of the author and do not necessarily reflect those of Alpaca. Alpaca does not recommend any specific securities, cryptocurrencies, or investment strategies. Examples provided are illustrative only and are not indicative of future results.

Alpaca does not prepare, edit, endorse, or guarantee the accuracy of third-party content and is not responsible for content available through third-party sources.

All investments involve risk, including the possible loss of principal. Past performance, hypothetical results, and backtested results do not guarantee future returns.

Cryptocurrency is highly speculative and involves substantial risk, including extreme volatility and the potential loss of value

This is not an offer, solicitation of an offer, or advice to buy or sell securities or cryptocurrencies or open a brokerage account or cryptocurrency account in any jurisdiction where Alpaca Securities or Alpaca Crypto, respectively, are not registered or licensed, as applicable.