Slack
Retrieve data from Slack channels
What is an Slack node?
Node in Stack AI
Slack is a messaging platform for teams to collaborate. Users can communicate with each other via channels, which can be organized by project, topic, team, or whatever else is relevant to the organization. Slack also allows for private conversations between two or more users, as well as the sharing of files and documents.
The Slack node allows you to connect with your Slack account and retrieve data from specific channels, so you can feed an AI assistant with that data.
How to use it?
Connections to an Slack node
You will need to link the node with an account. You will need to add your Slack Bot Token and the Channel ID of the channel you want to connect to.
- Slack Bot Token: your personal ID to identify yourself to Slack. Here more information on how to get it: https://api.slack.com/tutorials/tracks/getting-a-token
- Channel ID: the ID of the channel you want to connect to. Here more information on how to get it: https://help.socialintents.com/article/148-how-to-find-your-slack-team-id-and-slack-channel-id
Slack node settings
By clicking on settings, you will be able to change different parameters:
- Chunking algorithm: by default, the system uses
naive
algorithm, although you have the option to selectsentence
. - Chunk overlap: by default, the system uses
500
. You can also choose as many as you want by clicking the number and editing it. - Chunk length: by default, the system uses
1500
. You can also choose as many as you want by clicking the number and editing it. - Unstructured.io: by default, this option is deselected. Enable it to extract unstructured data from documents.
- Text in images (OCR): by default, this option is deselected. Enable it if you want to extract text from images that are present in your documents.
Example of usage
A practical application of Slack involves integrating it with an AI assistant designed to answer user queries based on context data from a Slack channel.
Answering questions from users using a Slack channel data
To construct this workflow, employ an LLM to address the users’ inquiries. Incorporate an Input node to funnel the users’ submissions.
Now, build the knowledge base by adding a Slack node and a vector store, to perform the embeddings of the data and store them. The input should query the vector database to only retrieve the bits of information in the channel related to the question (so you don’t spend tokens sending useless information to the LLM).