Quick Start
Create and run your first Viber agent in minutes.
Start the Daemon
Launch the Viber daemon to enable agent execution:
openviber start This starts the Viber server on port 8080 by default.
Create an Agent
You can create agents programmatically or via configuration.
Programmatic Approach
// Create and start an agent
const agent = await ViberAgent.start("Build a simple todo app", {
name: "TodoBuilder",
model: "anthropic/claude-3.5-sonnet",
});
// The agent will:
// 1. Create a plan
// 2. Break it into tasks
// 3. Execute each task
// 4. Save artifacts (code, docs, etc.) Configuration File
Create a job configuration in YAML:
# jobs/my-agent.yaml
name: MyFirstAgent
goal: Create a README file for a new project
model: anthropic/claude-3.5-sonnet
config:
autoApprove: true
maxIterations: 10 Run it with:
openviber run jobs/my-agent.yaml Monitor Progress
The agent will output its progress to the console. You can also:
- Use the Viber Board to monitor agents in real-time
- Check the
artifacts/directory for generated files - View logs in the
logs/directory
Example: Research Agent
Here’s a more complete example:
const agent = await ViberAgent.start(
"Research the latest trends in AI and write a summary report",
{
name: "Researcher",
model: "anthropic/claude-3.5-sonnet",
tools: ["web_search", "file_write", "browser"],
config: {
autoApprove: true,
},
}
);
// Wait for completion
const result = await agent.waitForCompletion();
console.log("Artifacts:", result.artifacts); Next Steps
- Agents Guide - Deep dive into agent capabilities
- Tools Guide - Learn about available tools
- Spaces Guide - Understand workspaces