Skip to main content
Glama

context_pack

Assemble a token-budgeted, relevance-ranked context brief from the shared blackboard for a given task, using semantic relevance, recency, and namespace affinity.

Instructions

Assemble a token-budgeted, relevance-ranked context brief from the shared blackboard for a given task. Use this INSTEAD of blackboard_list + many blackboard_read calls: it returns only the entries most relevant to your task, ranked by semantic/lexical relevance, recency (half-life decay), and namespace affinity, assembled position-aware (strongest items first and last) under a hard token budget. Read-only — never modifies the blackboard. Returns {ok:true, text, used_tokens, budget_tokens, utilization, included:[{key,score,tokens}], excluded:[{key,reason}]}. The text field is ready to use as working context. Entries past their TTL are excluded automatically.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
taskYesThe task or question driving relevance ranking (e.g. "diagnose the failing payment webhook")
agent_idYesThe agent requesting the pack (used for scoped access checks and audit)
max_itemsNoOptional hard cap on the number of included entries (0 = unlimited)
scope_tagsNoOptional comma-separated scope tags for namespace affinity (e.g. "task,analytics")
budget_tokensNoHard token budget for the returned context text (default 2000)
Behavior5/5

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

Given no annotations are provided, the description fully discloses behavioral traits: it is read-only ('never modifies the blackboard'), uses relevance ranking with semantic/lexical and recency factors, applies a hard token budget, and auto-excludes expired entries without requiring user action.

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?

The description is comprehensive and well-structured, front-loading the main action and return format. It is not overly verbose, though it could be slightly more concise without losing clarity. Every sentence serves a purpose.

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?

With no output schema, the description covers return values explicitly, listing the structure and stating that the 'text' field is ready to use. All key aspects (token budgeting, ranking, excluded entries) are addressed, making it self-sufficient for agent comprehension.

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?

Schema description coverage is 100%, but the description adds context by explaining how each parameter contributes to the tool's behavior (e.g., 'task' drives relevance ranking, 'agent_id' for scoped access). This reinforces the meaning beyond the schema, earning a score slightly above baseline.

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 states the tool assembles a token-budgeted, relevance-ranked context brief from the shared blackboard for a given task. It uses specific verbs ('assemble', 'returns') and distinguishes from siblings like blackboard_list and blackboard_read by emphasizing relevance ranking and token budgeting.

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?

Explicitly says 'Use this INSTEAD of blackboard_list + many blackboard_read calls', providing precise when-to-use guidance and alternatives. Also notes read-only nature and automatic TTL exclusion, leaving no ambiguity about appropriate 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/Jovancoding/network-ai'

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