This guide will help you get started with Agent-as-Code in just a few minutes. You'll learn how to install the framework, create your first agent, and deploy it.
- Python 3.8 or later
- Docker (optional, for container-based deployment)
- An OpenAI API key or other LLM provider key
Choose your preferred installation method:
pip install agent-as-code# Linux/macOS
curl -L https://api.myagentregistry.com/install.sh | sh
# Windows (PowerShell)
iwr -useb https://api.myagentregistry.com/install.ps1 | iexgit clone https://github.com/pxkundu/agent-as-code
cd agent-as-code
make install# Create a new agent from the chatbot template
agent init my-chatbot --template chatbot
cd my-chatbotEdit agent.yaml:
apiVersion: agent.dev/v1
kind: Agent
metadata:
name: my-chatbot
version: 1.0.0
spec:
runtime: python:3.11
model:
provider: openai
name: gpt-4
environment:
- name: OPENAI_API_KEY
from: secret# Build the agent
agent build -t my-chatbot:latest .
# Run locally
agent run my-chatbot:latest
# Test it
curl -X POST http://localhost:8080/chat \
-H "Content-Type: application/json" \
-d '{"message": "Hello, how can you help me?"}'# Push to registry
agent push my-chatbot:latest
# Deploy to cloud
agent deploy my-chatbot:latest --cloud aws --replicas 3- Agent Configuration Guide - Learn about all configuration options
- Templates Guide - Explore available templates and create your own
- Deployment Guide - Learn about different deployment options
- Examples - See more example agents and use cases
| Command | Description | Example |
|---|---|---|
agent init |
Create new agent | agent init my-bot --template chatbot |
agent build |
Build agent | agent build -t my-bot:latest . |
agent run |
Run locally | agent run my-bot:latest |
agent push |
Push to registry | agent push my-bot:latest |
agent pull |
Pull from registry | agent pull my-bot:latest |
agent deploy |
Deploy to cloud | agent deploy my-bot:latest --cloud aws |
-
Installation Problems
# Verify installation agent --version # Check Python version python --version
-
Build Failures
# Check build logs agent build -t my-bot:latest . --verbose
-
Runtime Errors
# Check agent logs agent logs my-bot:latest
- Visit our Community Forum
- Check the FAQ
- Report issues on GitHub
- Never commit API keys or secrets to version control
- Use environment variables or secret management systems
- Keep your Agent-as-Code installation updated
- Follow the principle of least privilege when configuring agents
After completing this quickstart guide, you can:
- Explore more advanced features
- Learn about local LLM integration
- Set up monitoring and observability
- Join our community
Remember to check our documentation for detailed information about all features and capabilities.