Introduction to LlamaDeploy v2
LlamaDeploy is still in beta. You can try it out locally, or request access by contacting us
Build and ship small, focused agentic appsâfast. Start from LlamaIndex workflows you already prototyped, iterate locally, and deploy to LlamaCloud right from your terminal.
- Customizable agentic apps for backâoffice and utility useâcases
- Rapid iteration; great fit for codeâassistant driven development
- Run headless (APIâonly) or with a bundled UI
- Powered by LlamaIndex workflows you control
- Firstâclass with LlamaCloud for documentâcentric apps
- Oneâcommand deploy to LlamaCloud
Getting Started
Section titled âGetting StartedâThis guide walks you through installing llamactl
and creating your first local app and deployment.
Prerequisites
Section titled âPrerequisitesâ- UV for Python and dependency management (required)
- Node.js for UI development (optional unless you add a UI). Use your package manager of choice (
pnpm
,yarn
, ornpm
).
Install
Section titled âInstallâChoose one:
- Try without installing:
uvx llamactl --help
- Install globally (recommended):
uv tool install -U llamactlllamactl --help
Initialize a project
Section titled âInitialize a projectâllamactl
includes starter templates for headless services and fullâstack UI apps. Pick a template and customize it.
llamactl init
This creates a Python module that exposes your LlamaIndex workflows, plus an optional UI you can serve as a static frontend.
Develop
Section titled âDevelopâRun the dev server for your application:
llamactl serve
llamactl serve
reads configuration from your appâs pyproject.toml
(or llama_deploy.yaml
) to discover workflow instances in your Python module. See the Deployment Config Reference for details and examples. For CLI flags, see llamactl serve
.
To define and export workflows, see Workflows & App Server API.
To persist and query structured outputs from your workflows or UI, see Agent Data Overview, with guides for TypeScript and Python.
.env
files
Section titled â.env filesâMost apps need API keys (e.g., OpenAI). Load them via .env
and reference the file in your config:
[tool.llamadeploy]env_files = [".env"]
Then set your secrets:
OPENAI_API_KEY=sk-xxxx
Create a Deployment
Section titled âCreate a DeploymentâPush your code to a Git repository. LlamaCloud will clone, build, and serve your app.
From your project directory, create a deployment:
llamactl deployment create
The first time you run this, youâll be prompted to log into LlamaCloud. See llamactl auth
for more info
Fill in the interactive form (most fields are autoâdetected):
- Name: Humanâreadable and URLâsafe; appears in your deployment URL
- Git repository: Public HTTP or private GitHub (install the LlamaCloud GitHub app for private repos)
- Git branch: Branch to pull and build from (use
llamactl deployment update
to roll forward) - Secrets: Preâfilled from your local
.env
; edit as needed
After creation, the TUI shows status and logs. Later, use llamactl deployment get
to view, llamactl deployment edit
to change config, or llamactl deployment update
to roll a new version.
Next: Read about defining and exposing workflows in Workflows & App Server API.