Skip to main content
ClaudeWave
Skill407 repo starsupdated yesterday

adk

The Botpress ADK skill provides guidance for building features within Botpress's Agent Development Kit, a convention-based TypeScript framework where file structure directly maps to bot behavior. Use this skill when developing actions, tools, workflows, conversations, tables, knowledge bases, triggers, or utilizing Zai for AI operations, as well as for CLI commands, configuration questions, and best practices related to ADK development.

Install in Claude Code
Copy
git clone --depth 1 https://github.com/majiayu000/claude-skill-registry /tmp/adk && cp -r /tmp/adk/skills/agent/adk ~/.claude/skills/adk
Then start a new Claude Code session; the skill loads automatically.

SKILL.md

# Botpress ADK Guidelines

Use this skill when you've got questions about the Botpress Agent Development Kit (ADK) - like when you're building a feature that involves tables, actions, tools, workflows, conversations, files, knowledge bases, triggers, or Zai.

## What is the ADK?

The Botpress ADK is a **convention-based TypeScript framework** where **file structure maps directly to bot behavior**. Place files in the correct directories, and they automatically become available as bot capabilities.

The ADK provides primitives for:

- Actions & Tools (reusable functions and AI-callable tools)
- Workflows (long-running, resumable processes)
- Conversations (message handling)
- Tables (data storage with semantic search)
- Files (file storage with semantic search)
- Knowledge Bases (RAG implementation)
- Triggers (event-driven automation)
- **Zai** (production-ready LLM utility library for common AI operations)

### Project Structure (Convention-Based)

All primitives must be placed in `src/` directory:

```
/                      # Project root
├── src/
│   ├── actions/       # Strongly-typed functions → auto-registered
│   ├── tools/         # AI-callable tools → available via execute()
│   ├── workflows/     # Long-running processes → resumable/scheduled
│   ├── conversations/ # Message handlers → routes by channel
│   ├── tables/        # Database schemas → auto-created with search
│   ├── triggers/      # Event handlers → subscribe to events
│   ├── knowledge/     # Knowledge bases → RAG with semantic search
│   └── utils/         # Shared helpers (not auto-registered)
└── agent.config.ts    # Bot configuration (includes integrations)
```

> **Note:** `dependencies.json` was removed in ADK 1.9+. All configuration including integrations now lives in `agent.config.ts`.

> **Critical:** Files outside `src/` are not discovered. Location = behavior.

## When to Use This Skill

Activate this skill when users ask ADK-related questions like:

- "How do I create an Action/Tool/Workflow/Conversation?"
- "What is the difference between X and Y?"
- "Show me an example of..."
- "How do I configure...?"
- "What's the CLI command for...?"
- "How do I use the Context API?"
- "How do I call integration actions?"
- "How do I use Zai for [extract/check/label/etc]?"
- "What are the best practices for...?"
- "How do I avoid common mistakes?"
- "How do I handle ticket assignment/escalation?"

## How to Answer ADK Questions

ADK questions fall into two categories: **CLI queries** and **documentation lookups**.

### Option 1: Direct CLI Commands (FAST - Use First!)

For integration discovery and CLI queries, use the Bash tool to run commands directly:

**Integration Discovery:**

```bash
# Search for integrations
adk search <query>

# List all available integrations
adk list --available

# Get detailed integration info (actions, channels, events)
adk info <integration-name>

# Check installed integrations (must be in ADK project)
adk list
```

**Project Info:**

```bash
# Check CLI version
adk --version

# Show project status
adk

# Get help
adk --help
```

**When to use CLI commands:**

- "What integrations are available?"
- "Search for Slack integration"
- "Show me details about the Linear integration"
- "What actions does the Slack integration have?"
- "What version of ADK am I using?"
- "How do I add an integration?"

**Response pattern:**

1. Use Bash tool to run the appropriate `adk` command
2. Parse and present the output to the user
3. Optionally suggest next steps (e.g., "Run `adk add slack@3.0.0` to install")

### Option 2: Documentation Questions (For Conceptual Questions)

For documentation, patterns, and how-to questions, search and reference the documentation files directly:

**When to use documentation:**

- "How do I create a workflow?"
- "What's the difference between Actions and Tools?"
- "Show me an example of using Zai"
- "What are best practices for state management?"
- "How do I fix this error?"
- "What's the pattern for X?"

**How to answer documentation questions:**

1. **Find relevant files** - Use Glob to discover documentation:

   ```
   pattern: **/references/*.md
   ```

2. **Search for keywords** - Use Grep to find relevant content:

   ```
   pattern: <keyword from user question>
   path: <path to references directory from step 1>
   output_mode: files_with_matches
   ```

3. **Read the files** - Use Read to load relevant documentation

4. **Provide answer** with:
   - Concise explanation
   - Code examples from the references
   - File references with line numbers (e.g., "From references/actions.md:215")
   - Common pitfalls if relevant
   - Related topics for further reading

## Available Documentation

Documentation should be located in `./references/` directory relative to this skill. When answering questions, search for these topics:

### Core Concepts

- **actions.md** - Actions with strong typing and validation
- **tools.md** - AI-callable tools and Autonomous namespace
- **workflows.md** - Workflows and step-based execution
- **conversations.md** - Conversation handlers and message routing
- **triggers.md** - Event-driven automation
- **messages.md** - Sending messages and events

### Data & Content

- **tables.md** - Data storage with semantic search
- **files.md** - File storage and management
- **knowledge-bases.md** - RAG implementation
- **zai-complete-guide.md** - Complete ZAI developer guide
- **zai-agent-reference.md** - Quick ZAI reference

### Configuration & Integration

- **agent-config.md** - Bot configuration and state management
- **model-configuration.md** - AI model configuration reference
- **context-api.md** - Runtime context access
- **integration-actions.md** - Using integration actions
- **tags.md** - Entity tags for bot, user, conversation, and workflow
- **cli.md** - Complete CLI command reference
- **mcp-server.md** - MCP server for AI assistants

### Frontend Integration

- **frontend/botpress-client.md** - Using @botpress/client in frontends
-