Knowledge & Cognition
A character's Knowledge defines what they know about themselves, other characters, and the world around them.
While the Core Description, Motivations, and Flaws fields enable you to define key information about the character, Knowledge enables you to store and organize far more information; everything from world lore & history to details about the character’s childhood can be stored within Knowledge, allowing characters to pull from a much larger knowledge base to ground and guide their responses.
Shared or Individual Knowledge
Knowledge is accessed on a per-character basis and can either be attached to multiple characters or limited to a single character.
When shared between Multiple Characters, this system can create a common set of facts for groups of characters, which can be vital for portraying a shared experience of a cohesive, immersive world.
When attached to only a Single Character, the system acts as a a type of "internal knowledge," allowing for personal secrets and exclusive facts that only that characters knows.
Knowledge vs Other Traits
Unlike a character's Core Description, Motivations, and Flaws, the information in their Knowledge is only made available to them when it would be relevant to the conversation, such as when answering a specific question. Therefore, information you want to have available to a character at all times should be contained within these other three systems, rather than Knowledge.
Adding Knowledge
Knowledge is organized into Knowledge Collections. A Knowledge Collection is composed of multiple Knowledge Records.
Knowledge Collections can be grouped via Tags, and can be attached to one or more characters.
There are two ways to create Knowledge Collections:
-
Create Knowledge from Scratch - Manually create knowledge from scratch by entering in the information for each knowledge record. This is the default and most direct way of adding knowledge.
-
Autogenerate Knowledge from a Document - Upload an existing document (txt or pdf), which will be used to automatically generate Knowledge Records. This can expedite the knowledge creation process when you already have existing documentation, such as an article about a specific subject or a character sheet.
Create Knowledge from Scratch
To manually create knowledge from scratch, perform the following steps:
1. Add Knowledge
On the Knowledge tab, select +Add Knowledge, then Create from Scratch.
A Knowledge Collection drawer opens.
2. Enter Name and Tag
Within the Knowledge Collection drawer, enter a Name and a Tag.
Tags are used to label and organize the knowledge.
3. Add Knowledge Records
Add individual Knowledge Records that you want a character to be able to retrieve, and press Save.
Knowledge Writing Best Practices
When writing individual Knowledge Records within a Knowledge Collection from scratch, keep the following tips in mind.
Best Practice: Use Short, Declarative Statements
Try to avoid long knowledge statements. Instead, opt for short, concise, more declarative statements. As a general rule, try to avoid exceeding 2 lines of text within the interface for each individual knowledge entry.
If you need to include an extensive or complex knowledge fact, attempt to break it down into multiple separate points and enter each individually, as these smaller facts are easier for the AI to parse and produce better, more accurate results in-game.
Best Practice: Use Complete Sentences
It is recommended that each individual line be a complete, self-contained sentence that mentions the subject in some way. This assures the AI has enough context to make sense of each fact so they can portray them in the way you envision during player interactions.
Best Practice: Be Specific
When referring to other characters in a knowledge fact, use actual names instead of titles, nicknames, or other non-specific information.
If necessary, handle any references that establish character titles or nicknames as separate facts.
For example, for a character named Akoya, instead of referring to "their ex husband," refer to "Thaddius." Then, in a separate knowledge entry, specify "Thaddius is Akoya's ex-husband."
Similarly, be sure to leave no way for the AI to misinterpret your intent by using non-specific references within your sentences. Be aware of how these statements are worded and ensure you deliberately specify the context around anything that is mentioned.
For example, the statement Akoya wants to interrogate Detective Harris regarding the fate of their former partner” could be misinterpreted as either (1) Akoya's former partner or (2) Detective Harris' former partner. Recognizing these situations where the wording of a sentence could be misinterpreted and then adjusting your writing accordingly is key to creating a successful fact that will be represented correctly during the character's interactions.
Autogenerate Knowledge from a Document
To autogenerate knowledge from an pre-existing document, perform the following steps:
1. Add Knowledge and Autogenerate
On the Knowledge tab, select +Add Knowledge, then Autogenerate from Document(s).
2. Upload Document
You are then be taken to an upload screen where you can upload a Text or PDF document. This document could be a world building document, fictional description, factual dossier, or similar written document.
3. Add Knowledge
Wait for the document to finish processing. If the document is particularly large, this may take some time.
Select Add Knowledge once the upload completes.
4. Re-Name Knowledge Collection
Once the upload is complete, the newly-created Knowledge Record appears in your Knowledge Collection.
If desired, re-name the Knowledge Collection, add any necessary Tags for organization, and press Save.
Finally, review and edit the auto-generated Knowledge Records as needed.
Create Tabular Knowledge from Structured Data
To generate knowledge from a structured data format, perform the following steps:
1. Add Knowledge
On the Knowledge tab, select +Add Knowledge then Create Tabular Knowledge.
2. Define Knowledge
The Tabular Knowledge interface then opens.
Using this interface, add a Knowledge Collection Name, Tabular Data Description, and (if needed) any relevant Tags.
When entering a Knowledge Collection Name, follow the guidelines below:
- Begin with a letter or underscore.
- Subsequent characters can be either (1) letters, (2) underscores, or (3) digits from 0-9.
- The name must be 63 bytes or less.
The Tabular Data Description should describe what is in your table. Make sure to be descriptive and accurate regarding the table and its contents, as this description will be used by the AI to determine if the table is relevant to the conversation.
3. Upload .CSV File
Next, under Tabular Data Source, upload your .CSV File, and press Save.
File Preparation
When preparing your .CSV file, follow the guidelines below.
- The first row should contain the column headers.
- The file should have no more than 50 columns.
- The file should have no more than 1000 rows.
- Each row should have no more than 600 characters.
- Column names should adhere to the following conventions:
- Each column should begin with a letter or underscore.
- Subsequent characters can be letters, underscores, or digits (0-9).
- Each column should be 63 bytes or less.
Re-Uploading
Once saved, you may re-upload files to the tabular data collection as needed to refresh the knowledge within it.
Tags
Tags allow you to link similar groups of Knowledge Collections together, creating a convenient way to organize various types of knowledge.
Adding Tags to a Knowledge Collection
To add a Tag to any Knowledge Collection, press the Edit button for the collection and enter desired tags in the Tags field.
Filtering for Tags
You can filter for specific Knowledge Collections via Tags in the Knowledge tab.
Select the Tags you want, and the results are filtered to show every Knowledge Collection associated with selected Tags.
Applying Tags to Characters
Tags can be applied to individual characters. This allows Knowledge Collections to be exposed to characters when they have both have the same tags.
To add a Tag to a character, go to the Characters tab and select Edit on the character you want to add a Tag for. Then, press Edit Details.
Add tags to the character using the Tags Interface. Each character can have a maximum of up to six (6) Tags.
Attaching Knowledge to a Character
Each Knowledge Collection can be attached to one or more characters.
This can be accomplished by either (1) adding the character explicitly, or (2) using Tags.
Directly Adding Knowledge to a Character
To add knowledge to a character, perform the following steps:
1. Select Knowledge Collection
Open the knowledge drawer by selecting the Knowledge Collection you want to attach to a character.
2. Add Character
From the knowledge drawer, select +Add Character.
3. Select Characters and Train
A character window appears.
Select which characters you wish to attach this Knowledge Collection to and press Save And Train.
The knowledge is then attached to this character, allowing them to reference it during their interactions with the player.
Attaching Knowledge via Tags
Knowledge Collections can also be attached to characters via Tags.
When a Tag is added to a character that matches a Tag on a Knowledge Collection, that character is then granted access to that Knowledge Collection.
To add a Tag to a character in this way, perform the following steps:
1. Open Edit Interface
Go to the Characters tab, press Edit, and Edit Details.
2. Add Tags
Using the Tags field, add a Tag that matches a Tag on your desired Knowledge Collection, then click Save.
For example, if several of your knowledge collections have a Tag labelled "Blacksmithing", you can link these to any blacksmith-oriented character by also giving that character the "Blacksmithing" Tag. You can add a maximum of Six (6) Tags to a single character this way.
3. Review and Finalize
Review that the knowledge collections you expect to get added are added.
After clicking Save, the knowledge is then attached to the character, allowing them to reference it during interactions with the player.
Note that if you have an existing character tag and then add that same tag to a Knowledge Collection, all the characters that already have that tag will also have the knowledge attached to them.
Utilizing Knowledge
Once one or more Knowledge Collections are attached to a character, that character is then able to retrieve individual Knowledge Records from that Knowledge Collection.
The character will then access this information whenever it may be relevant during a conversation.
Testing a Character’s Knowledge
You can test a character’s knowledge in the Chat Simulator. Whenever a character accesses information using the Knowledge system for a response, this usage is indicated within the Inspect option in each chat response, which you may click on to access.
A common workflow for checking if the character is using knowledge is as follows:
1. Ask a Related Question
Ask the character about something related to their attached Knowledge Collections.
2. Inspect Replies
After the character responds, click Inspect to see the Knowledge Records that were retrieved to generate that response.
Knowledge Filters
A character's Knowledge Filters restrict the types of knowledge they have access to.
This system can reduce unwanted hallucinations and cognition that may deviate from a character's established parameters.
Information Categories
The Knowledge Filter system separates information into four distinct Information Categories:
- Creator-Specified Information: Includes anything entered into the character's Core Description, Knowledge & Cognition fields, and Scenes they inhabit.
- Mutations of Creator-Specified Information: Refers to tangential information related to facts directly specified by the character's designer.
- Probable Character Knowledge: Based on the character's setup, encompasses Common Knowledge and other information that the character is more likely to know.
- Improbable Character Knowledge: Based on the character's setup, encompasses Common Knowledge and other information that the character is less likely to know.
These categories are used when determining how a Knowledge Filter Tier gates information for a character.
Knowledge Filter Tiers
There are three tiers of knowledge filters that can be applied to a character: None, Mild, and Strict.
Selecting the circle beside the appropriate Knowledge Filter activates that filter for your character.
None
- The most permissive setting; all four Information Categories are used.
- Use: This tier is ideal for assistant, oracle, or search use cases where the character is intended to be omniscient.
Mild
- Allows characters to use information from Information Categories 1, 2, and 3.
- This setting tends to restrict knowledge that is out-of-character.
- Use: This tier is ideal for simulations, RPGs, and companion characters that depict an NPC with a subjective point of view that lives within a world.
Strict
- The character is restricted only to knowledge within Information Category 1.
- Use: This tier is ideal for characters within murder mysteries, brand ambassador roles, and professional training scenarios who must have specific and limited knowledge bases.
Knowledge Filter Visualization
Provided below is a visualization of how the Strict and Mild filters gate knowledge for a character.