Skip to content

Getting Started with Knowledge Bases

How to create a Knowledge Base

Follow these steps to create a Knowledge Base. For this example, we will use the fully-managed Griptape Cloud database. EDB customers can select the pgvector option.

  1. Navigate to the Knowledge Bases page in the Griptape Cloud Console.
  2. Click Create Knowledge Base.
  3. Select the Griptape Cloud Knowledge Base type.
  4. Give your Knowledge Base a name and a description (optional).
  5. Select the Data Source(s) you want to include in the Knowledge Base.
  6. Click Create to submit the form.

Pro Tip:

You can add a Data Source to as many Knowledge Bases (KBs) as you want. For example, you can include a Frequently Asked Questions Data Source in both a New Employee Onboarding KB and a Customer Support Playbook KB.

What's happening?

Once you have created the Knowledge Base, we will automatically begin the process of upserting your data to a database. This process is known as a Knowledge Base job. It typically takes just a few moments.

While the job is in progress, you will be directed to the Knowledge Base detail page where you can observe the job status as well as view and edit Knowledge Base details such as the name, description, and Data Sources to be included.

How to use a Knowledge Base

When your Knowledge Base is ready, the data it contains becomes available for applications to retrieve via Griptape Assistants, or Structures such as Agents.

Pro Tip:

You can perform a test query by selecting the Query tab and entering some information that you know is in your data. The result will be a 'raw' response that contains the embedded text and other query parameters. This feature is useful for quick testing and debugging.

The next step of using your Knowledge Base is connecting it to an application, such as a chat Assistant, that can retrieve your data and use it to generate useful responses.

Follow these steps to create and use a simple chat Assistant.

  1. Navigate to the Assistants page in the Griptape Cloud Console.
  2. Click Create Assistant.
  3. Give your Assistant a name and description (optional).
  4. Select your Knowledge Base from the Knowledge Bases dropdown menu.
  5. Click Create to submit the form.

You will be directed to the Assistant chat screen. Type a message to start a conversation thread with your new Assistant. Try asking it something about your data!

Pro Tip:

Add a Ruleset to provide your Assistant with instructions and guidance for how it should behave.

Types of Knowledge Base engine

Knowledge Bases are stored and accessed in various ways, according to the data types they contain and where the Data Sources are located. For example, unstructured text data is typically stored in a vector database. Griptape Cloud provides a fully-managed vector database, so that you don't need to deploy and operate it yourself. However, some customers have existing database installations where they would like their Knowledge Bases to reside.

Griptape Cloud

Upsert your data to a fully-managed Griptape Cloud database.

PostgreSQL with pgvector

Upsert your data to your own PostgreSQL pgvector database by providing the connection string and password for authorization.