Ingesting Data into the Knowledge Base
In this tutorial, you'll learn how to send data to the SnackPrompt AI Engine Knowledge Base.
What is an Elemental?
An elemental is the basic unit of data in SnackPrompt. It can be:
A table with columns and items
A document with sections
A file with structured content
When you send an elemental, the API:
Processes the content
Generates embeddings (vector representations)
Stores in the Knowledge Base
Makes the data searchable
How to create a simple Knowledge Base
Step 1: Set up your Knowledge Base
The first step is to ensure your data is accessible to the AI. In Snackprompt, you can transform any element into a data source:
Create a Table, Document, or Prompt.
Populate it with your data.
Enable the Knowledge Base toggle in the settings menu.
For a detailed step-by-step on this process, see our guide: Creating your first Knowledge Base.
What Happens During Ingestion?
When you send an elemental, the API executes the following steps:
Stored Metadata
During ingestion, the following metadata is stored with each chunk:
tenant_id
Tenant ID (for isolation)
user_id
User ID
snack_elemental_id
Source elemental ID
snack_column_id
Column ID (if applicable)
snack_item_id
Specific item ID
source
Source type (elemental, document, file)
type_name
Elemental type (Table, Document, etc.)
category_name
Elemental category
original_text
Original chunk content
tag_ids
Associated tag IDs
tag_names
Associated tag names
Tag Inheritance
Tags are inherited in cascade:
The final item will have the merge of all tags (no duplicates).
Next Steps
Now that your data is in the Knowledge Base:
Semantic Search - Learn how to search your data
Chat with your Data - Chat with your data using AI
Filter by Tags - Use tags to filter results
Estimated time: 10 minutes ✅
Last updated
Was this helpful?