Cloodot

Skills Overview

How the skill system and architecture work.

Skills are JavaScript functions that extend your AI agent's capabilities. Once deployed, the AI can invoke them as tools during conversations.

Based on the official Skills documentation: Skills Overview - Cloodot

What skills can do

Custom JavaScript/TypeScript functions let AI agents:

  • Fetch and present data (informational)
  • Perform operations that change state (action)
  • Present interactive UI for continued interaction (interactive)

Skill types

Informational Skills

Fetch and return data without side effects.

Examples:

  • Weather lookup
  • Stock prices
  • Knowledge base search
  • Inventory check

Characteristics:

  • Read-only operations
  • No external state changes
  • Fast execution
  • Return data to display

Action Skills

Perform operations that change external state.

Examples:

  • Create calendar events
  • Send emails
  • Update CRM records
  • Process orders

Characteristics:

  • Modify external systems
  • Require configuration/credentials
  • May have side effects
  • Return confirmation/results

Interactive Skills

Present UI elements for continued user interaction.

Examples:

  • Multi-step forms
  • Approval workflows
  • Guided tutorials
  • Customer surveys

Characteristics:

  • Collect user input
  • Enable ongoing conversation
  • Dynamic response generation
  • Maintain interaction state

Tool call flow

When a user requests an action, skills execute through this flow:

  1. Tool discovery

    • The AI agent analyzes available skills.
    • It examines skill parameters and descriptions.
  2. Parameter extraction

    • The agent extracts relevant data from conversation context.
    • It maps the user request to skill parameters.
  3. Skill invocation

    • The platform executes the skill with the extracted parameters.
    • It runs inside an isolated sandbox.
  4. Response processing

    • Cloodot validates and formats the output.
    • Errors are captured and returned.
  5. Context integration

    • Results flow back into the conversation.
    • The AI generates a response to the user.

When skills are called

Skills trigger in these scenarios:

  • User Request: User explicitly asks for an action ("book a meeting", "check inventory")
  • Contextual AI Decision: AI determines that invoking a skill would help resolve the conversation
  • UI Interaction: User clicks skill-related buttons or carousels
  • Future: Scheduled or event-driven executions (planned feature)

Skill context

When a skill executes, it receives rich context about the conversation:

{
  "conversationMetadata": {
    "id": "conv_12345",
    "participantInfo": "customer details",
    "channelType": "whatsapp"
  },
  "organizationContext": {
    "settings": "org settings",
    "timezone": "America/New_York",
    "customFields": {}
  },
  "messageHistory": "recent messages for context",
  "userProfile": {
    "contactInfo": "customer info",
    "preferences": "user preferences"
  }
}

This context enables skills to provide personalized, relevant responses.

Skill definition fields

A skill definition includes:

  • slug: Unique identifier (alphanumeric + underscores)
  • name: Display name
  • description: What the skill does
  • prompt: How to describe it to the AI
  • definition: JavaScript/TypeScript code with handler function
  • parameters: Input schema expected from AI
  • response: Output schema returned to AI
  • buttons: Optional quick action buttons

Handler function

All skills require a handler function:

async function handler(input) {
  const { config, parameters, context } = input
  
  // Your skill logic here
  
  return {
    message: "Response to AI",
    // ... other fields
  }
}

Input structure

{
  config: Record<string, any>           // Configuration values
  parameters: Record<string, any>       // Input from AI tool call
  context: {
    conversationId?: string
    organizationId?: string
    // ... organization context
  }
}

Further reading

Build and deploy

  • Knowledge Base — Enhance skills with knowledge base integration
  • Custom Fields — Use custom fields in skill parameters and responses
  • Integrations — Connect skills to external APIs and services

Next steps

On this page