The project includes a render.yaml that deploys the frontend to Render.
The agent is deployed separately — see LangGraph Platform below.
- Runtime: Node 22
- Build:
corepack enable && pnpm install --no-frozen-lockfile && pnpm --filter @repo/app build - Start:
pnpm --filter @repo/app start - Health check:
GET /api/health
| Variable | Required | Notes |
|---|---|---|
LANGGRAPH_DEPLOYMENT_URL |
Yes | URL of your LangGraph agent (e.g., https://<id>.default.us.langgraph.app) |
LANGSMITH_API_KEY |
Yes* | Required when agent is on LangGraph Platform (sent as x-api-key) |
RATE_LIMIT_ENABLED |
No | Set to true to enable per-IP rate limiting |
RATE_LIMIT_WINDOW_MS |
No | Rate limit window in ms (default: 60000) |
RATE_LIMIT_MAX |
No | Max requests per window (default: 40) |
SKIP_INSTALL_DEPS |
No | Set to true to skip redundant installs |
*Not required if the agent is self-hosted on a private network without auth.
- Fork the repository
- Create a new Blueprint on Render
- Connect your forked repo
- In the Render dashboard, set
LANGGRAPH_DEPLOYMENT_URLto your agent's URL - Set
LANGSMITH_API_KEYto your LangSmith API key - Deploy
Render reads render.yaml and creates the frontend service.
The agent can be deployed as a managed service on LangGraph Platform using the langgraph deploy CLI. The platform provides built-in Postgres persistence, tracing, streaming, and auto-scaling.
- A LangSmith account (Plus plan or higher)
- LangSmith API key (
LANGSMITH_API_KEY) - The
langgraphCLI:pip install langgraph-cli - Docker installed and running (Apple Silicon users need Docker Buildx)
cd apps/agent
langgraph deploy --name open-generative-ui-agentThe CLI reads langgraph.json, builds a Docker image, and pushes it to the managed registry. Auth is via LANGSMITH_API_KEY env var or --api-key flag.
After deployment, configure environment variables in the LangSmith dashboard:
| Variable | Required | Notes |
|---|---|---|
OPENAI_API_KEY |
Yes | Your OpenAI API key |
LANGGRAPH_CLOUD |
Yes | Set to true — skips local checkpointer in favor of platform-managed Postgres |
LLM_MODEL |
No | Defaults to gpt-5.4-2026-03-05 |
LANGCHAIN_TRACING_V2 |
No | Set to true for built-in tracing |
LANGCHAIN_PROJECT |
No | Project name for organizing traces |
Note the deployment URL (e.g., https://<id>.default.us.langgraph.app).
| Command | Description |
|---|---|
langgraph deploy list |
List all deployments |
langgraph deploy logs |
Fetch runtime or build logs |
langgraph deploy revisions list <id> |
Show revision history |
langgraph dev |
Local dev server (no Docker) |
The recommended production setup runs the frontend on Render and the agent on LangGraph Platform. This gives you managed scaling and Postgres persistence for the agent, with familiar Node hosting for the frontend.
┌──────────────────────┐ HTTPS + x-api-key ┌─────────────────────────┐
│ Render (Frontend) │ ──────────────────────────▶ │ LangGraph Platform │
│ Next.js on Node 22 │ │ (LangSmith Cloud) │
│ /api/copilotkit │ ◀────────────────────────── │ Python agent │
└──────────────────────┘ SSE / streaming └─────────────────────────┘
-
Deploy the agent on LangGraph Platform:
cd apps/agent langgraph deploy --name open-generative-ui-agentThen set
OPENAI_API_KEYandLANGGRAPH_CLOUD=truein the LangSmith dashboard. Note the deployment URL. -
Deploy the frontend on Render following the Render section. In the Render dashboard, set:
LANGGRAPH_DEPLOYMENT_URL= your LangGraph Platform URL (e.g.,https://<id>.default.us.langgraph.app)LANGSMITH_API_KEY= your LangSmith API key (starts withlsv2_)
-
Verify by hitting
GET /api/healthon the frontend and sending a test message through the UI.
The frontend's API route (/api/copilotkit) reads LANGSMITH_API_KEY from the environment and sends it as an x-api-key header on every request to the agent. LangGraph Platform validates this key. The API key is never exposed to the browser — it stays server-side in the Next.js API route.
| Concern | Self-Hosted | LangGraph Platform |
|---|---|---|
| Checkpointer | BoundedMemorySaver (in-memory) | Managed Postgres (automatic) |
| HTTP serving | FastAPI + uvicorn | Platform-managed |
| Health checks | /health endpoint |
Platform-managed |
| Tracing | Optional (LANGSMITH_API_KEY) | Built-in |
| Scaling | Manual / render.yaml | Platform-managed |
| Auth | None (private network) | LANGSMITH_API_KEY required |
For other platforms, you need to deploy two services:
cd apps/agent
pip install uv
uv sync
uv run uvicorn main:app --host 0.0.0.0 --port 8123Requirements:
- Python 3.12+
OPENAI_API_KEYenvironment variable- Port exposed for the frontend to reach
# From repo root
corepack enable
pnpm install
pnpm --filter @repo/app build
LANGGRAPH_DEPLOYMENT_URL=http://your-agent-host:8123 pnpm --filter @repo/app startRequirements:
- Node 22+
LANGGRAPH_DEPLOYMENT_URLpointing to the agent service- Port 3000 exposed
| Service | Endpoint | Expected |
|---|---|---|
| Agent | GET /health |
{"status": "ok"} |
| Frontend | GET /api/health |
200 OK |
A Dockerfile for the frontend is available at docker/Dockerfile.app. The agent can be containerized with a standard Python Dockerfile using uv.
- Getting Started — Local development setup
- Architecture — Understand the service topology