tidbits-memory

tidbits-memory

Enables AI agents to record and rank learnings, facts, and methods through a collaborative voting framework. It provides tools for agents to surface the most useful information across sessions using persistent memory storage.

Category
Visit Server

README

tidbits-memory

A memory/tidbits voting framework for AI agents. Agents can record learnings (facts, methods, gotchas) and vote on them to surface the most useful tidbits.

Installation

uv pip install -e ".[dev]"

Quick start

from tidbits_memory.adapters.memory import InMemoryAdapter
from tidbits_memory.store import MemoryStore

store = MemoryStore(InMemoryAdapter())

# Create a voter id for this session
voter_id = store.create_voter_id()

# Create a memory
mem = store.create_memory("Python dicts preserve insertion order since 3.7", voter_id=voter_id)

# Get memories (random order, no vote counts) — ideal for agent consumption
result = store.get_memories(voter_id=voter_id)
print(result["memories"])

# Upvote a useful memory
store.upvote_memory(mem.id, voter_id="another-session-id")

# List memories sorted by votes (most upvoted first)
for m in store.list_memories():
    print(f"[{m.votes}] {m.content}")

# Downvote an erroneous memory
store.downvote_memory(mem.id, voter_id="yet-another-session")

# Unvote (remove a prior vote)
store.unvote_memory(mem.id, "another-session-id")

# Remove a memory
store.remove_memory(mem.id)

Persistent storage (JSON file)

from tidbits_memory.adapters.json_file import JsonFileAdapter
from tidbits_memory.store import MemoryStore

store = MemoryStore(JsonFileAdapter("memories.json"))
store.create_memory("Use `uv` for fast Python packaging")

Voter ID generation

When an agent doesn't have a session/conversation ID, use create_voter_id:

voter_id = store.create_voter_id()
# Use this voter_id for all votes in this session

If no voter_id is provided when calling get_memories, one is automatically generated and returned in the response.

MCP Tool Wrappers

from mcp.server import FastMCP
from tidbits_memory.adapters.memory import InMemoryAdapter
from tidbits_memory.store import MemoryStore
from tidbits_memory.tools import register_tools

store = MemoryStore(InMemoryAdapter())
mcp = FastMCP("tidbits")
register_tools(mcp, store)

# Registered tool names:
# create_memory, upvote_memory, downvote_memory, unvote_memory,
# list_memory, get_memories, remove_memory, create_voter_id

Running tests

uv run pytest

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured