Inspiration

Priced In grew out of the belief that everyday investors should have the same AI-powered trading tools as the big players. We hooked everything up using GitHub Actions, so our “set-and-forget” trading agent runs nonstop—adapting to market swings and executing your strategy around the clock without any servers to babysit or manual tweaks. Just need a COMPOSIO_API_KEY and run it on GitHub directly - no backend required!

What it does

The github action uses the cron schedule event to run every 5 minutes. Here’s a breakdown of the single Agent and all of its tools defined in agent.ts:

• Agent (name: “Assistant”) – Loads its instructions from system-prompt.md – Orchestrates the conversation and invokes tools up to 100 turns

• thinkTool – name: “think” – parameters: an array of reasoning steps – logs each thought to agent.log and returns a confirmation

• webSearchTool – name: “web_search” – parameters: { query: string } – uses the OpenAI client’s web_search_preview tool to fetch and return a short markdown summary

• buyTool – name: “buy” – parameters: { ticker: string, shares: number } – fetches current price, updates portfolio.json (cash, holdings, history), logs purchase, and returns a confirmation or an insufficiency warning

• sellTool – name: “sell” – parameters: { ticker: string, shares: number } – validates available shares, fetches current price, updates portfolio.json, logs sale, and returns a confirmation or a warning

• getStockPriceTool – name: “get_stock_price” – parameters: { ticker: string } – calls getStockPrice() (which uses web_search_preview + zod parsing) and returns the numeric price

• getPortfolioTool – name: “get_portfolio” – parameters: {} – reads and validates portfolio.json via Zod, logs cash balance, and returns a human-readable summary of cash, holdings, and history

• getNetWorthTool – name: “get_net_worth” – parameters: {} – computes current net worth (cash + market value of holdings), calculates annualized return since first trade, logs both, and returns a formatted breakdown

How we built it

Challenges we ran into

Accomplishments that we’re proud of

  • Zero-ops deployment: From code push to live trading took under 10 minutes, with no manual server setup required.
  • Modular architecture: New strategies and data sources can be plugged in with minimal boilerplate, accelerating experimentation.

What we learned

  • Workflow orchestration at scale: GitHub Actions can power more than just CI—it's a viable platform for light-to-medium compute pipelines when structured properly.
  • Importance of end-to-end testing: Simulating broker responses and market hiccups early on prevented costly surprises in live trading.
  • Model governance matters: Automated commit-time checks (e.g., model performance thresholds) help maintain a robust trading system over time.
  • Trade-off of frequency vs. cost: Running workflows more often improves signal freshness but incurs runner minutes; we identified an optimal daily cadence for our strategy.

What’s next for Priced In (Composio)

  • Everyone: Fork the repo and beat my portfolio!

Built With

Share this project:

Updates