Stephen Chu 31ff30496f Initial commit: SQL Support Bot Starter
Simple starter code for building a customer support agent using LangGraph Studio.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-23 09:22:47 -08:00

Music Store Customer Support Bot - Starter Code

Simple starter code for building a customer support agent for the Chinook music store database using create_agent().

Setup

# 1. Install dependencies
pip install -r requirements.txt
pip install langgraph-cli

# 2. Add your API key to .env
# Edit OPENAI_API_KEY in the .env file

# 3. Run Studio
langgraph dev

This opens LangGraph Studio in your browser where you can chat with the agent. The Chinook database is loaded automatically from GitHub on startup.

Project Structure

take_home/
├── README.md
├── langgraph.json         # LangGraph Studio configuration
├── requirements.txt       # Python dependencies
├── .env                   # Environment variables (add your API keys here)
├── .env.example           # Template
└── src/
    ├── agent.py           # Agent definition using create_agent()
    ├── db.py              # Database connection (loads from GitHub)
    └── tools/
        ├── customer_tools.py # get_customer_orders tool
        └── music_tools.py    # list_tracks_by_artist tool

Capabilities

The agent can:

  1. Order history - View recent orders for a customer
  2. Browse music - List tracks by artist name

Database

The Chinook database is a sample music store database loaded automatically from GitHub. Tables include:

  • Customer - Customer information
  • Invoice - Purchase orders
  • InvoiceLine - Items in each order
  • Track - Music tracks
  • Album - Albums containing tracks
  • Artist - Artists who created albums
  • Genre - Music genres
S
Description
Simple starter code for building a customer support agent with LangSmith Studio
Readme 120 KiB
Languages
Python 100%