Skip to main content
ClaudeWave
Skill171 repo starsupdated 27d ago

chatbot-conversation-design

Design structured, engaging chatbot conversations with robust intent handling, slot filling, disambiguation, error recovery, and graceful fallback strategies. Use when the user requests chatbot conversation design or provides relevant inputs for this workflow.

Install in Claude Code
Copy
git clone --depth 1 https://github.com/seb1n/awesome-ai-agent-skills /tmp/chatbot-conversation-design && cp -r /tmp/chatbot-conversation-design/communication/chatbot-conversation-design ~/.claude/skills/chatbot-conversation-design
Then start a new Claude Code session; the skill loads automatically.

SKILL.md

# Chatbot Conversation Design

This skill provides a comprehensive framework for designing chatbot conversations that feel natural, handle ambiguity gracefully, and guide users toward successful outcomes. It covers the full design lifecycle — from persona definition and intent mapping through dialog state management, error recovery, and iterative testing. The focus is on building conversations that are resilient to unexpected inputs while maintaining a consistent, helpful tone.

## Workflow

1. **Define the bot persona and scope.** Establish the chatbot's personality traits (friendly, professional, concise, witty) and guardrails. Define what the bot can and cannot do. A well-scoped bot that excels at five tasks outperforms a vague bot that attempts fifty. Document the persona in a style guide that includes vocabulary preferences, emoji usage rules, response length targets, and escalation triggers.

2. **Map intents, entities, and user journeys.** Identify every intent the bot must handle — both primary task intents (e.g., `order.place`, `account.reset_password`) and meta-intents (e.g., `help`, `cancel`, `speak_to_human`). For each intent, list the required entities (slots) the bot must collect. Map the conversation flows as directed graphs showing happy paths, branching points, and exit conditions. Ensure every path terminates in either a resolution or a graceful handoff.

3. **Design slot-filling and disambiguation dialogs.** For each intent, define the slot-filling sequence — which entities are required, which are optional, and in what order the bot should prompt for them. When user input is ambiguous (e.g., "the large one" when multiple products qualify), design disambiguation prompts that present clear options without overwhelming the user. Use confirmation prompts for high-stakes actions like payments or cancellations.

4. **Build error recovery and fallback flows.** Design three tiers of fallback: (1) rephrasing the question when confidence is low, (2) offering a constrained set of options when the intent is unclear after two attempts, and (3) escalating to a human agent when the bot cannot recover. Never let the conversation hit a dead end. Every error state should include a recovery path and a way to restart or exit gracefully.

5. **Implement context carryover and state management.** Define how dialog state persists across turns. Specify which slots carry forward (e.g., the user's name should persist for the session) and which reset between tasks. Design the context stack so the bot can handle mid-conversation topic switches ("Actually, before that, can you check my balance?") and return to the original flow afterward.

6. **Prototype, test, and iterate.** Build a low-fidelity prototype using conversation scripts or tools like Botmock, Voiceflow, or Dialogflow CX. Test with real users to identify where conversations break down. Track metrics: task completion rate, average turns to resolution, fallback trigger rate, and escalation rate. Iterate on the weakest flows first.

## Usage

This skill is for developers, UX writers, and product managers designing conversational interfaces. Provide the agent with the bot's purpose, target user base, and the list of tasks it should handle.

- **For new chatbots:** Follow the workflow end-to-end to build a complete conversational architecture.
- **For existing chatbots:** Use this skill to audit conversation flows, identify dead ends, and improve error handling.

**Prompt format:**

~~~
Design a chatbot conversation for [use case].
Bot persona: [personality traits]
Supported tasks: [list of tasks]
Platform: [web widget / Slack / WhatsApp / voice assistant]
~~~

## Examples

### Example 1: Customer Support Bot — Complete Conversation Flow

**Design specification:**

~~~json
{
  "bot_name": "HelpBot",
  "persona": "Friendly, efficient, empathetic",
  "intent": "order.track",
  "required_entities": [
    { "name": "order_id", "type": "string", "prompt": "What's your order number?" },
    { "name": "email", "type": "email", "prompt": "What email did you use for the order?" }
  ],
  "optional_entities": [
    { "name": "issue_type", "type": "enum", "values": ["delayed", "damaged", "wrong_item", "other"] }
  ]
}
~~~

**Conversation flow:**

~~~
User: Where's my order?

HelpBot: I'd be happy to look that up for you! Could you share your order number?
         It usually starts with "ORD-" and is in your confirmation email.

User: ORD-29481

HelpBot: Got it. And what email address did you place the order with?

User: marcus@email.com

HelpBot: Thanks, Marcus. I found your order — here's the latest status:

         Order: ORD-29481
         Status: In transit
         Carrier: FedEx
         Tracking: 7749 2381 0042
         Estimated delivery: Thursday, March 6

         Is there anything else about this order I can help with?

User: It was supposed to arrive yesterday.

HelpBot: I'm sorry about the delay. It looks like there was a weather-related
         shipping disruption. Based on the latest tracking update, it should
         arrive by end of day Thursday.

         Would you like me to:
         1. Send you tracking updates via email
         2. Connect you with our shipping team
         3. Something else

User: Option 1 please.

HelpBot: Done! You'll receive email updates at marcus@email.com whenever the
         tracking status changes. Is there anything else I can help with?
~~~

### Example 2: Error Handling and Fallback Flow

**Scenario:** The bot receives an input it cannot classify.

~~~
User: asdfghjkl

HelpBot: I didn't quite catch that. Could you rephrase what you're looking for?
         I can help with things like:
         - Tracking an order
         - Returns and refunds
         - Account questions

User: I want to do the thing with the stuff

HelpBot: I want to make sure I help you with the right thing. Which of these
         is closest to what you need?
         1. Track an existing order
         2. Start a return or re
agent-evaluationSkill

Design reproducible evaluations for AI agents with representative task sets, explicit rubrics, appropriate graders, baselines, regression gates, and failure analysis. Use when defining agent quality, comparing prompts or models, validating a release, measuring tool-use reliability, investigating regressions, or deciding whether an agent is ready for production.

agent-observabilitySkill

Design privacy-aware observability for AI agents using traces, spans, structured events, metrics, cost attribution, dashboards, alerts, and investigation workflows. Use when instrumenting an agent, debugging intermittent tool or model failures, defining service-level objectives, analyzing latency or spend, auditing agent decisions, or preparing production monitoring.

human-in-the-loopSkill

Design and verify auditable human oversight, approval gates, escalation paths, and safe state transitions for AI agent workflows. Use when deciding which agent actions require review, adding approve/reject or dual-control flows, preventing unauthorized autonomous effects, creating decision records, reducing rubber-stamping, or recovering safely from rejected, expired, or failed actions.

mcp-server-buildingSkill

Design, implement, harden, and verify Model Context Protocol (MCP) servers with precise tool contracts, least-privilege authorization, safe transports, structured errors, and interoperability tests. Use when creating a new MCP server, exposing an API or data source through MCP, reviewing an MCP server design, adding or revising MCP tools, or preparing an MCP server for production.

multi-agent-orchestrationSkill

Design and operate bounded multi-agent workflows with task decomposition, dependency graphs, ownership, handoff contracts, shared-state controls, approvals, recovery, and synthesis. Use when a task contains genuinely independent workstreams, specialized roles, parallel research or implementation, reviewer-worker loops, or coordination problems that one agent should not execute sequentially.

tool-schema-designSkill

Design and validate model-facing tool definitions with clear names, action-oriented descriptions, bounded JSON Schema parameters, explicit side effects, safe defaults, idempotency, errors, and realistic tests. Use when creating function-calling tools, MCP tools, agent actions, structured tool inputs, or when a model selects the wrong tool, invents arguments, or causes unsafe side effects.

agent-red-teamingSkill

Plan, execute, document, and retest authorized security assessments of AI agents and multi-agent workflows using safe adversarial cases, synthetic identities, canaries, and evidence-based findings. Use when defining red-team rules of engagement, assessing prompt injection or excessive agency, testing tool and identity boundaries, evaluating memory or cross-agent attacks, scoring a campaign, or verifying remediation in an approved environment.

prompt-injection-defenseSkill

Threat-model and harden AI agents, RAG systems, assistants, and tool-using workflows against direct, indirect, stored, cross-agent, and multimodal prompt injection. Use when reviewing an agent architecture, isolating untrusted content, constraining tools and egress, protecting secrets, adding injection-focused tests, investigating a suspected injection incident, or documenting residual prompt-injection risk.