Documentation Index
Fetch the complete documentation index at: https://kapso-1adbad2d.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
The Kapso Builder is a Python library that enables you to programmatically create sophisticated conversational AI agents using Python’s type-safe, IDE-friendly environment.
Quick example
from kapso.builder import Agent
from kapso.builder.nodes import SubagentNode, WarmEndNode, HandoffNode
from kapso.builder.nodes.subagent import WebhookTool, KnowledgeBaseTool
from kapso.builder.agent.constants import START_NODE, END_NODE
# Create an agent
agent = Agent(
name="customer_support",
system_prompt="You are a helpful customer support assistant"
)
# Create a SubagentNode with tools
subagent = SubagentNode(
name="assistant",
prompt="Help customers with their inquiries using available tools"
)
# Add tools
subagent.add_tool(WebhookTool(
name="check_order",
url="https://api.example.com/orders/{{order_id}}",
description="Check order status"
))
subagent.add_tool(KnowledgeBaseTool(
name="policies",
knowledge_base_text="Return policy: 30 days...",
description="Company policies"
))
# Add nodes and create flow
agent.add_node(START_NODE)
agent.add_node(subagent)
agent.add_node(END_NODE)
agent.add_edge(START_NODE, "assistant")
agent.add_edge("assistant", END_NODE)
# Validate and deploy
agent.validate()
Installation
Getting started
- Initialize a project:
kapso init
- Create your agent:
kapso agent init <name>, then edit agents/<name>/agent.py
- Test with web interface:
kapso agent snapshot <name>
- Push to cloud:
kapso agent push <name>
Learn more
For comprehensive documentation on all Builder SDK features, node types, and advanced patterns, see the Builder Reference section in the top navigation.