Skip to main content
Glama

index_terminal_sessions

Index local Claude Code terminal sessions into Memex for searchable memory. Captures new or changed sessions incrementally.

Instructions

Index the user's local Claude Code / terminal sessions into Memex now.

Runs the same incremental scan as memex ingest-claude-code: reads ~/.claude/projects/**/*.jsonl and ingests new or changed sessions (source claude_code) so they become searchable. Unchanged sessions are skipped, so this is cheap. The CURRENT session is captured up to what Claude Code has flushed to its transcript on disk.

USE when the user asks to index / capture / save their terminal or Claude Code work into their memory ("indexá esta charla", "index my sessions", "guardá esta conversación en memex"). To also send it to the user's other devices, follow with sync_now.

Returns: JSON with status and, on success, indexed (new sessions), unchanged, messages, chunks, errors.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so description carries full burden. It details the incremental scan, file sources, skipping unchanged sessions, and that it captures up to what Claude Code has flushed. Also describes return value structure. Highly transparent for a read/index operation.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Well-structured with paragraphs, bullet points, and examples. Front-loaded with main action. Could be slightly trimmed, but overall efficient and clear.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Complete given no parameters and existence of output schema. Covers behavior, file locations, performance characteristic (cheap), return structure, and follow-up action (sync_now). No gaps.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Zero parameters, so baseline is 4. Description provides context but no parameter details needed. Schema coverage is 100% (empty schema).

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

Clearly states it indexes local Claude Code/terminal sessions into Memex with specific verbs and resources. Mentions similar functionality to 'memex ingest-claude-code' but doesn't explicitly distinguish from sibling tools like search_chats or get_chat; however, the purpose is unmistakable.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly lists when to use: 'when the user asks to index / capture / save their terminal or Claude Code work' with concrete examples including Spanish phrases. Also recommends following with sync_now for multi-device sync. Lacks explicit 'when not to use' but covers key usage clearly.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/dioniipereyraa/memex'

If you have feedback or need assistance with the MCP directory API, please join our Discord server