back to tutorials

Creating a Help Bot for Slack

Learn how to use ChatBotKit to create a help bot that provides detailed answers from a custom knowledge base and integrates with Slack.

In this tutorial you will create a help bot that answers questions from a custom knowledge base and integrates directly with Slack. The bot uses a ChatBotKit dataset to store your documentation, FAQs, or support articles and retrieves the most relevant information when users ask questions in your Slack workspace.

What Is a Dataset?

A dataset is a structured collection of records - text paragraphs, code snippets, FAQ entries, or any other content - that the bot searches when composing answers. Connecting a dataset to your bot gives it a private knowledge base that it can draw on during conversations.

Step 1: Create a Dataset

  1. From your dashboard, navigate to Datasets.
  2. Click Create Dataset and give it a descriptive name, such as "Help Bot Knowledge Base".
  3. Once the dataset is created, open it and click Create Record to start adding content.
  4. Each record can be a paragraph of documentation, a frequently asked question with its answer, a code snippet, or any other text your users might ask about.
  5. To bulk-import existing documentation, click Import inside the dataset. ChatBotKit supports common document formats such as PDF, DOCX, and plain text.

Tip: Well-structured records produce better answers. Use clear headings and concise paragraphs so the bot can retrieve and present the information cleanly.

Step 2: Create a Bot

  1. Navigate to Bots and click Create Bot.
  2. Give the bot a name such as "Slack Help Bot" and an optional description.
  3. Choose a language model. For a help bot that needs accurate, context-aware answers, claude-4.5-sonnet or gpt-4.1 are strong choices. If you want a more cost-effective option, gpt-4o-mini works well for straightforward question-and-answer scenarios.

Step 3: Write a Backstory

The backstory is the system prompt that defines your bot's behavior. Paste something like the following into the Backstory field, then customize it for your use case:

A well-written backstory removes ambiguity and improves the quality of responses, especially when paired with a lower-cost model.

Step 4: Connect the Dataset to the Bot

  1. In the bot's configuration settings, find the Datasets section.
  2. Select the dataset you created in Step 1.
  3. Save the bot configuration.

Once connected, the bot automatically searches the dataset for relevant records before composing each reply.

Step 5: Test in the Conversation Playground

Before deploying to Slack, test the bot using the built-in Conversation Playground:

  1. Open your bot and click the Playground button.
  2. Ask questions that are covered by your dataset records and verify the answers are accurate.
  3. Ask a question that is not in the dataset to confirm the bot handles missing information gracefully.
  4. Adjust the backstory or add more dataset records as needed until you are satisfied with the responses.

Step 6: Create a Slack Integration

  1. Navigate to Integrations and click Create Slack Integration.
  2. Connect your Slack workspace by following the OAuth prompts.
  3. In the integration settings, select the bot you created in Step 2.
  4. Configure which Slack channels or direct messages the bot should respond in.
  5. Save the integration.

Your Slack help bot is now live. Users can mention the bot or send it a direct message to get instant answers from your knowledge base.

Optional: Enhance the Bot with Abilities

You can extend the bot's capabilities by attaching a skillset with additional abilities:

  • Memory (memory/*) - Lets the bot remember context across conversations, useful for personalised support.
  • Fetch - Allows the bot to retrieve live information from URLs, so your knowledge base can reference external documentation.
  • Dataset search - Gives the bot programmatic search over multiple datasets when you have more than one knowledge source.

To add abilities, navigate to Skillsets, create a new skillset with the desired abilities, then attach the skillset to your bot in the bot's configuration settings.

Troubleshooting

IssueSolution
Bot gives vague or incorrect answersReview your dataset records for accuracy and completeness. Add more specific records covering the topics where the bot struggles.
Bot says it cannot find information that exists in the datasetCheck that the dataset is connected to the bot. Open the bot settings and confirm the dataset appears in the Datasets section.
Slack integration does not respondVerify the integration is active and the connected bot is saved. Check that the bot has permission to post in the target channels.
Responses are too long or unformattedTighten the backstory with explicit instructions on response length and format.

Summary of Steps

  1. Create a dataset and populate it with knowledge base records.
  2. Create a bot, choose a model, and write a backstory.
  3. Connect the dataset to the bot in the bot's configuration settings.
  4. Test the bot using the Conversation Playground.
  5. Create a Slack integration, connect your workspace, and link the bot.
  6. Optionally add a skillset with abilities to extend bot functionality.