Open-source project
The-Swarm-Corporation/AutoHedge avatar
The-Swarm-Corporation/AutoHedge

AutoHedge: A Four-Agent Trading Pipeline That Only Executes on Solana

Build your autonomous hedge fund in minutes. AutoHedge harnesses the power of swarm intelligence and AI agents to automate market analysis, risk management, and trade execution.

6,117 stars883 forksPythonMIT

At a glance

What is it?
AutoHedge chains a Director, Quant, Risk Manager and Execution agent into one autonomous trading loop, and the README claims full autonomous trading on Solana only. The architecture is legible and the install is one pip command, but the documented surface is thin enough that you should treat this as a framework to read, not a fund to fund.
Who is it for?
AutoHedge is worth reading if you already run Python trading infrastructure on Solana and want a reference implementation of a staged agent pipeline with a risk gate before execution. It is the wrong choice if you need multi-venue routing, if you trade on Coinbase or any CEX today, or if you want backtested evidence before risking capital.
Can I use it commercially?
Yes. MIT is a permissive licence: you can use, modify and sell software built on it, as long as you keep its copyright and licence notices.
Is it still maintained?
Yes. The repository last received commits 128 days ago.
What is it written in?
Mainly Python, according to GitHub's language statistics.

Answers come from the project's GitHub data, last synced on September 15, 2026, and from our analysis. They are not legal advice.

DEEP OPEN-SOURCE ANALYSIS

The Gap AutoHedge Claims to Fill

Most retail trading bots are one script with one strategy and a hardcoded order call. AutoHedge's pitch is the opposite shape: a pipeline of specialized agents where strategy generation, quantitative analysis, risk sizing and order placement are separate stages with separate responsibilities. The README lists four named agents for these four stages, and describes the output as JSON-formatted recommendations for downstream systems. That is the actual product claim. It is not a strategy. It is a scaffold for building one, with the risk check placed before the execution step in the documented flow. The intended user is a developer who already has opinions about signals and wants a structure for wiring them to an exchange without writing the orchestration, logging and risk plumbing from scratch. The topic list on the repository (quant, quantitative-trading, hedgefund) points at the same audience. Anyone looking for a ready-made strategy with a track record will not find one described here.

How the Four Agents Are Wired

The README's mermaid diagram is the clearest artifact in the repository. It shows a linear chain: Director Agent to Quant Agent to Risk Manager to Execution Agent to Trade Output. Each arrow is a handoff, and the diagram implies no branching and no feedback loop back to the Director. The Director is described as handling strategy and thesis generation, the Quant as technical and statistical analysis, the Risk Manager as position sizing and risk assessment, and the Execution Agent as order generation and execution. The README states the system uses structured output, JSON-formatted recommendations, which is what makes a linear chain workable: each stage can parse the previous stage's payload rather than passing free text. Two environment variables hint at where the intelligence comes from. OPENAI_API_KEY is annotated as being for experimental agents, and ANTHROPIC_API_KEY appears next to it without annotation. JUPITER_API_KEY is annotated as covering token price and search tools. That combination suggests the agents reason over market data fetched through Jupiter rather than through a dedicated market data vendor. The README does not say which model backs which agent, whether the Risk Manager is a model call or arithmetic, or how state is persisted between runs. WORKSPACE_DIR="agent_workspace" is the only hint that anything is written to disk, and the README does not describe what lands there.

Getting It Running: One Install, Five Variables

The documented setup is short. Installation is a single command: pip install -U autohedge. Configuration is a set of environment variables, with the README pointing at .env.example as the full reference. The five named variables are JUPITER_API_KEY, sourced from portal.jup.ag for token price and search tools; OPENAI_API_KEY for what the README calls experimental agents; ANTHROPIC_API_KEY; WORKSPACE_DIR, defaulted in the example to "agent_workspace"; and WALLET_PRIVATE_KEY, left empty in the example. That last variable is the one to think hardest about. A private key in a plain environment variable is the standard pattern for this kind of tool, and it is also the pattern that turns a leaked shell history or a committed .env file into a drained wallet. The README does not document any key management alternative, a hardware signer, or a scoped key. The usage section is where the documentation gives out. Under Basic Usage the code block contains the single token autohedge and nothing else: no import, no constructor, no call, no arguments. Whether that is a rendering artifact in the README or the full extent of the published example cannot be determined from the supplied material. Until you read the package source, assume the entry point is undocumented.

Solana Only, and the Cost of That Boundary

The supported venues table has three rows. Solana is marked Supported with the note full autonomous trading. Coinbase is marked Coming soon, in development. Other CEX is marked Roadmap, planned expansion. Read that table as a hard boundary rather than a roadmap promise. Every execution path described in the README terminates on Solana, and the only venue-specific credential the README names is a Jupiter API key, which is a Solana DEX aggregator. If your book is on a centralized exchange, AutoHedge cannot touch it today, and the README gives no date for when it will. The second consequence is subtler. Solana execution means token-level trading against DEX liquidity, which brings slippage, MEV exposure and token risk that a CEX order book does not present in the same form. The README's risk-first framing and its Risk Management Agent are described in terms of position sizing and risk assessment. Nothing in the supplied material says the Risk Manager models slippage, liquidity depth or sandwich risk. A position sizer that knows your account equity but not the depth of the pool you are about to hit is sizing against the wrong denominator.

The Execution Agent Is the Part You Cannot Audit From Here

The pipeline's weakest documented link is the last one. The Execution Agent is described as handling order generation and execution, and the mermaid diagram ends at Trade Output. There is no description of order types, retry behavior on a failed transaction, slippage tolerance, or what happens when a Jupiter route returns worse than the Risk Manager assumed. Those are the failure modes that separate a demo from a trading system. A thesis can be sound, the quant analysis can be sound, the position size can be sound, and the trade can still fill badly because the execution layer had no slippage cap. The README does not mention one. It also does not describe what happens when an agent stage fails: whether the chain halts, retries, or proceeds with a partial payload. The enterprise logging feature is mentioned as detailed and configurable, which is the right instinct, but the README does not name a log level, a log destination, or a config key to set either. For a system whose selling point is minimal human intervention, the absence of documented halt conditions is the thing I would want resolved before the wallet key goes in.

What to Compare It Against

The obvious alternative for the same audience is Freqtrade, an open source crypto trading bot that takes a fundamentally different approach. Freqtrade is strategy-first and exchange-first: you write a strategy class against a documented interface, you point it at an exchange through CCXT, and you backtest it against downloaded historical candles before it ever sees live money. AutoHedge is agent-first and venue-first: the strategy is generated by a Director Agent rather than written by you, and execution is Solana-only through Jupiter. The practical difference is verifiability. Freqtrade's backtesting loop means you can see how a strategy would have behaved on past data before deploying it. The AutoHedge README describes no backtesting facility, no historical data path, and no dry-run mode. That is not an oversight in a README; it may simply be out of scope. But it changes the adoption decision. With Freqtrade you are adopting a strategy you wrote and tested. With AutoHedge you are adopting a pipeline and trusting the agents inside it. If your goal is a tested strategy on a CEX, Freqtrade is the shorter path. If your goal is a multi-agent scaffold you intend to modify heavily, AutoHedge's four-stage split is a reasonable starting shape.

Licence, Maintenance and the Upgrade Question

AutoHedge is MIT licensed, which is the permissive end of the spectrum: you can use it commercially, modify it, and redistribute it, provided the copyright notice and licence text travel with it. That matters for a trading system, because it means you can fork the execution layer and keep your changes private. It also means the project carries no warranty, and the README does not offer one. On maintenance, the repository shows no retrieved releases, so there is no version history to read and no changelog to check before upgrading. Installation is from PyPI via pip install -U autohedge, and the -U flag means every install pulls the latest published version. Without release notes, an upgrade is an unannounced change to code that holds a private key. The README does not document a version pinning strategy or a compatibility policy. If you build on this, pin the version in your own requirements file rather than relying on the README's upgrade command, and diff the package against the main branch before you bump it. The licence gives you the right to do that; the missing release history makes it necessary.

Editorial conclusion

AutoHedge is worth reading if you already run Python trading infrastructure on Solana and want a reference implementation of a staged agent pipeline with a risk gate before execution. It is the wrong choice if you need multi-venue routing, if you trade on Coinbase or any CEX today, or if you want backtested evidence before risking capital. Before funding a wallet, verify three things in the repository: that the Execution Agent actually routes through the Jupiter API key the README asks for, that the Risk Manager's position sizing is deterministic code rather than another model call, and that the published package on PyPI matches the main branch you are reading. The README's own usage block contains the single word autohedge and nothing else, so the first thing to check is whether that is a truncation in the README or the entire documented entry point.

Official sources

  1. Issues
  2. License: MIT
  3. Project website
  4. README
  5. The-Swarm-Corporation/AutoHedge on GitHub
Community notes

Community notes