Skip to content

On-premise users: click in-app to access the full platform documentation for your version of DataRobot.

Enterprise chatbots for Teams and Slack

Slack and Microsoft teams support the creation of custom applications or bots that can interact with a DataRobot deployment. Using Slack or Teams as a front-end for a LLM-based chat application enables broad availability in an organization, providing the ability to upload documents easily as well as leverage internal knowledge stored in team channels or conversations.

Obtain permissions from your IT organization to create a Slack App in your Slack organization. Then, create the app with the Slack API.

Obtain permissions from your IT organization to upload a customized app. Then, register for an application and a ot in the Microsoft Developer Portal.

Within the message send action in both Slack and Teams, export the user question as a prompt into your DataRobot LLM deployment, and provide the response from the REST API call to the user message in your bot. DataRobot enables you to track token usage, prompts, responses, toxicity, and other custom metrics to monitor and govern your application internally.

The following code can be adapted to the Slack or Teams messaging structure to pass a message as a query to the DataRobot LLM deployment and get a response.

    import datarobotx as drx

    # configure drx LLM Deployment
    RAG = drx.Deployment.from_url(

    def make_datarobot_deployment_unstructured_predictions(
        query = json.loads(data)
        response = RAG.predict_unstructured(query)
        return json.dumps(response)

    def make_prediction(prompt, history=None) -> dict:

        data = {
            "prompt": prompt,
        if history:
            data["chat_history"] = [
                [entry.get("user", ""), entry.get("chatbot", "")] for entry in history
        response = make_datarobot_deployment_unstructured_predictions(
        response = json.loads(response)

        return response

Updated March 20, 2024