Skip to main content

Minimal Example

name: my-agent
runtime: python3
module: agent.py
entrypoint: handler

Full Example

name: my-agent
runtime: python3
module: agent.py
entrypoint: handler

# Resources
memory: 512          # MB per worker
timeout: 300         # Seconds max execution

# Autoscaling
scaling:
  min_workers: 1
  max_workers: 10
  scale_up_threshold: 3.0
  scale_down_threshold: 0.5
  idle_timeout_seconds: 300

Required Fields

FieldTypeDescription
namestringUnique agent identifier (lowercase, hyphens allowed)
runtimestringpython3 or nodejs20
modulestringEntry point file (agent.py or index.js)
entrypointstringHandler function name

Resource Fields

FieldTypeDefaultDescription
memoryint512Memory limit in MB
timeoutint300Max execution time in seconds

Scaling Fields

All scaling fields are optional.
FieldTypeDefaultDescription
min_workersint1Minimum warm workers
max_workersint10Maximum workers
scale_up_thresholdfloat3.0Scale up when queue/workers > this
scale_down_thresholdfloat0.5Scale down when queue/workers < this
idle_timeout_secondsint300Remove idle workers after this

Runtime Options

Python

runtime: python3
  • Python 3.10+
  • Include requirements.txt for dependencies
  • Dependencies installed on first deploy

Node.js

runtime: nodejs20
  • Node.js 20.x
  • Include package.json for dependencies
  • Uses npm install on first deploy

Examples

Minimal (zero cold starts)

name: fast-agent
runtime: python3
module: agent.py
entrypoint: handler

scaling:
  min_workers: 1

High throughput

name: batch-processor
runtime: python3
module: agent.py
entrypoint: handler

memory: 1024
timeout: 600

scaling:
  min_workers: 2
  max_workers: 20
  scale_up_threshold: 2.0

Long-running tasks

name: analysis-agent
runtime: python3
module: agent.py
entrypoint: handler

memory: 2048
timeout: 1800  # 30 minutes

scaling:
  min_workers: 1
  max_workers: 5

Validation

Deploy validates your agent.yaml:
orpheus deploy .
Common errors:
  • name contains invalid characters
  • runtime not recognized
  • module file not found
  • entrypoint function not found

Quick Start

Deploy your first agent →