In this guide, we will explain how to generate an AI response using an embedding, also known as a knowledge base, within our platform.
Using embedding in AI
Accessing the Knowledge Base
- Find the Integration: On our dashboard, locate the integration for OpenAI.
- Locate Embeddings: Here you can add or edit embeddings. Please refer to our previous video for detailed instructions on modifying embeddings.
Utilizing Embeddings in a Workflow
Using the Master AI Flow
- Add an Action: Go to the master AI flow we shared previously and add an action.
- Select Integration: Under “add action”, choose the integration with OpenAI.
- Edit the Action: Select embedding match and completion as the action to perform.
Setting Up the Request
- Input: Use an initial input, such as “hi”.
- Introduction: Provide context to the AI and instructions, for example, “You are a helpful assistant.”
- Type: Ensure it matches the type for the embeddings you’ve added. You may leave this empty if you have a single type.
- Maximum Response Length: Set this according to your requirements.
Testing the Request
- Test Request: Press the test request button to initiate the process.
- AI Processing: The AI will use the provided input to search for relevant information within the knowledge base.
- Generating Response: Based on the retrieved information, the AI will generate a completion as the output for the user.
Saving and Using the Response
- Save the Output: Follow the logic used previously, save the generated completion.
- Review Questions: Ensure that questions relate back to the AI appropriately for consistency.
Embedding Match Explanation
The embedding match function operates similarly to a query response. However, the AI strictly fetches relevant information for potential future usage. For instance, you may want to save this information for creating a custom check completion in the future.