src/skills/builtin/searching-messages/SKILL.md
Search past messages to recall context. Use when you need to remember previous discussions, find specific topics mentioned before, pull up context from earlier in the conversation history, or find which agent discussed a topic.
npx skillsauth add letta-ai/letta-code searching-messagesInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
This skill helps you search through past conversations to recall context that may have fallen out of your context window.
finding-agents skill)letta messages search --query <text> [options]
| Option | Description |
|--------|-------------|
| --query <text> | Search query (required) |
| --mode <mode> | Search mode: vector, fts, hybrid (default: hybrid) |
| --start-date <date> | Filter messages after this date (ISO format) |
| --end-date <date> | Filter messages before this date (ISO format) |
| --limit <n> | Max results (default: 10) |
| --all-agents | Search all agents, not just current agent |
| --agent <id> | Explicit agent ID (overrides LETTA_AGENT_ID) |
| --agent-id <id> | Alias for --agent |
Use this to expand around a found needle by message ID cursor:
letta messages list [options]
| Option | Description |
|--------|-------------|
| --after <message-id> | Get messages after this ID (cursor) |
| --before <message-id> | Get messages before this ID (cursor) |
| --order <asc\|desc> | Sort order (default: desc = newest first) |
| --limit <n> | Max results (default: 20) |
| --agent <id> | Explicit agent ID (overrides LETTA_AGENT_ID) |
| --agent-id <id> | Alias for --agent |
Use when you need full conversation context around a specific topic:
Find the needle - Search with keywords to discover relevant messages:
letta messages search --query "flicker inline approval" --limit 5
Note the message_id - Find the most relevant result and copy its message_id
Expand before - Get messages leading up to the needle:
letta messages list --before "message-xyz" --limit 10
Expand after - Get messages following the needle (use --order asc for chronological):
letta messages list --after "message-xyz" --order asc --limit 10
Use when you know approximately when something was discussed:
letta messages search --query "topic" --start-date "2025-12-31T00:00:00Z" --end-date "2025-12-31T23:59:59Z" --limit 15
Results are sorted by relevance within the date window.
Use when you're not sure what you're looking for:
letta messages search --query "vague topic" --mode vector --limit 10
Vector mode finds semantically similar messages even without exact keyword matches.
Use with --all-agents to search across all agents and identify which one discussed a topic:
letta messages search --query "authentication refactor" --all-agents --limit 10
Results include agent_id for each message. Use this to:
finding-agents skill to get agent detailsTip: Load both searching-messages and finding-agents skills together when you need to find and identify agents by topic.
Returns search results with:
message_id - Use this for cursor-based expansionmessage_type - user_message, assistant_message, reasoning_messagecontent or reasoning - The actual message textcreated_at - When the message was sent (ISO format)agent_id - Which agent the message belongs totools
Schedules reminders and recurring tasks via the letta cron CLI. Use when the user asks to be reminded of something, wants periodic messages, or needs to manage scheduled tasks.
tools
# Skill Execute a skill within the main conversation When users ask you to perform tasks, check if any of the available skills match. Skills provide specialized capabilities and domain knowledge. When users reference a "slash command" or "/<something>" (e.g., "/commit", "/review-pr"), they are referring to a skill. Use this tool to invoke it. How to invoke: - Use this tool with the skill name and optional arguments - Examples: - `skill: "pdf"` - invoke the pdf skill - `skill: "commit", a
documentation
Guide for working in parallel with other agents. Use when another agent is already working in the same directory, or when you need to work on multiple features simultaneously. Covers git worktrees as the recommended approach.
testing
Manage git-backed memory repos. Load this skill when working with git-backed agent memory, setting up remote memory repos, resolving sync conflicts, or managing memory via git workflows.