Skip to main content
Glama

pack

Assemble a prompt-ready context block from one or more queries: retrieve, rerank, and budget top memories into injectable text.

Instructions

Assemble a compact, prompt-ready context block from one or more queries: retrieves, reranks, and budgets the top memories into injectable text. Read-only. This is the retrieval path for putting memory into an agent's prompt; use search instead when you want individual scored records rather than an assembled block.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tagsNoRestrict retrieval to memories carrying these tags.
spaceNoRestrict retrieval to a single memory space (namespace), or "*" for all spaces. Omit for the default space.
titleNoHeading for the assembled pack. Default "context".
queriesYesOne or more natural-language queries to retrieve and merge into the pack. Required.
max_charsNoCharacter budget for the assembled pack. Default 6000.
min_scoreNoDrop memories scoring below this threshold; the pack abstains (returns empty) when nothing clears it. Default 0 (no floor).
graph_decayNoDefault 0.5. Per-hop activation decay for graph expansion.
max_memoriesNoMaximum memories to include in the pack. Default 10.
graph_expansionNoDefault false. Associative recall: graph-expand the rerank pool one hop from the top seeds so a relationship-reachable memory below the ANN/BM25 threshold can still be reranked (hybrid_assoc_v0).
max_graph_seedsNoDefault 3. Top-of-pool anchors used for graph expansion.
query_expansionNoDefault false. Deterministically add subqueries before retrieval.
max_thread_seedsNoDefault 3.
thread_expansionNoDefault false. Add same-entity/same-claim neighbors to the rerank pool.
graph_rerank_slotsNoDefault 0. Reserve N pack slots for top-activation graph candidates so a hop-reached memory the reranker scored low can still land (0 = recall-widening only).
max_query_variantsNoDefault engine maximum.
max_graph_neighborsNoDefault 5. Graph-reachable neighbors unioned into the pool (activation budget).
max_thread_neighborsNoDefault 3.
graph_activation_floorNoDefault 0.0. Minimum activation a graph candidate needs to claim a reserved rerank slot.
graph_within_entity_maxsimNoDefault false. Experimental: select one memory per graph entity by first-query MaxSim; requires late-interaction tokens.
Behavior4/5

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

With no annotations, the description alone must convey behavioral traits. It explicitly states 'Read-only' and mentions the retrieval, reranking, and budgeting process. It also hints at behavior with `min_score` ('abstains when nothing clears it'). While not exhaustive, it covers key behaviors.

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

Conciseness5/5

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

The description is two sentences, each earning its place. The first states the primary action, the second provides usage guidance and distinguishes from a sibling. No waste, perfectly concise.

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

Completeness4/5

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

Given the tool's complexity (19 parameters, no output schema, no annotations), the description provides a solid high-level overview and usage context. It lacks details on output format but compensates with clear purpose and sibling differentiation. The thorough schema fills many gaps, making the description fairly complete for effective selection.

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

Parameters3/5

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

Schema description coverage is 100%, so the baseline is 3. The description adds some context for parameters like `queries`, `max_chars`, and `min_score` but does not significantly enhance understanding beyond the schema. The description's added value is moderate.

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

Purpose5/5

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

The description clearly identifies the tool's function: 'Assemble a compact, prompt-ready context block from one or more queries: retrieves, reranks, and budgets the top memories into injectable text.' It also distinguishes it from the sibling tool `search` by specifying when to use each, making the purpose very specific and clear.

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

Usage Guidelines5/5

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

The description explicitly states when to use this tool vs. `search`: 'use `search` instead when you want individual scored records rather than an assembled block.' It also notes that it is read-only, providing clear context for usage.

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/teflon07/memkeeper'

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