Skip to main content

Knowledge Base

As your memories accumulate, Memsolus automatically compiles them into structured knowledge entries organized by category. The Knowledge Base gives you a clean, synthesized view of everything the system has learned about a user — without requiring you to query dozens of individual memories.

What Is the Knowledge Base?

The Knowledge Base is a per-user synthesis of all processed memories. Rather than storing a raw list of facts, Memsolus groups related memories by topic, resolves contradictions, and produces a single up-to-date knowledge entry per category.

For example, if a user mentions over time that they prefer TypeScript, then updates that preference to also include Go, the Knowledge Base reflects the current state — not a growing list of individual memory fragments.


Knowledge Categories

Memsolus automatically infers categories from your memories. Common categories include:

  • tech_stack — tools, frameworks, languages
  • preferences — UI, communication, and workflow preferences
  • work_context — job role, team, and project context
  • goals — objectives and priorities
  • relationships — people and organizations the user interacts with

You can also assign categories manually when storing a memory using the categories field.


Accessing the Knowledge Base

Get all knowledge entries for a user

const entries = await client.knowledge.get({ userId: 'user_123' });
curl "https://api.memsolus.com/v1/knowledge?user_id=user_123" \
-H "X-Api-Key: msk_live_..."

Get a merged profile

The merged profile combines all knowledge entries into a single document — the most convenient format for injecting full user context at the start of an AI conversation.

const profile = await client.knowledge.get({
userId: 'user_123',
merged: true,
});

console.log(profile.content);
// => Structured summary of everything Memsolus knows about this user
curl "https://api.memsolus.com/v1/knowledge?user_id=user_123&merge=true" \
-H "X-Api-Key: msk_live_..."

Example response

{
"data": [
{
"id": "kn_abc123",
"user_id": "user_123",
"category": "tech_stack",
"content": "Uses TypeScript as primary language. Prefers NestJS for backend APIs and React for frontend. Avoids JavaScript for new projects.",
"updated_at": "2026-01-15T10:30:00Z"
},
{
"id": "kn_def456",
"user_id": "user_123",
"category": "preferences",
"content": "Prefers async communication. Dislikes meetings without agendas. Uses dark mode in all tools.",
"updated_at": "2026-01-14T08:00:00Z"
}
]
}

How Knowledge Is Built

You don't need to do anything to build the Knowledge Base — it is maintained automatically as memories are processed.

When new memories arrive and are processed, related entries in the Knowledge Base are updated to reflect the latest information. Conflicting information is resolved, and outdated facts are replaced.