Skip to main content
Glama

consolidate_decisions

Read-onlyIdempotent

Deduplicate decision store entries by evaluating semantic similarity with LLM. Merges, replaces, or invalidates duplicates to reduce redundancy.

Instructions

LLM-driven semantic dedup of the decision store. For each decision in scope, finds top-K similar candidates (FTS + title-trigram) and asks the LLM to merge / replace / invalidate where appropriate. Mutating; respects dry_run (default true). Requires an active AI provider. Returns: { evaluated, verdicts: [{subject_id, verdict, affected_ids}], applied_count, dry_run }.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dry_runNoWhen true (default), compute verdicts without writing. Set false to apply merges / invalidations.
project_rootNoProject root to consolidate (default: current project).
service_nameNoFilter input + scope of consolidation to this subproject.
max_decisionsNoCost guard: max subject decisions evaluated per call (default: config.memory.consolidation.defaultMaxDecisions or 50).
same_type_onlyNoWhen true, only compare decisions of the same DecisionType (more conservative; default: config or false).
purge_low_qualityNoMaintenance mode (no AI required). When true, invalidate active MINED/AUTO decisions that fail the quality gate — truncated mid-sentence titles, single-word or broken-encoding summaries, non-English fragments. Respects dry_run (default true → preview only). Manual decisions are never touched. Use this to clean legacy garbage produced before the extraction gate shipped.
min_title_similarityNoMinimum trigram-title similarity for candidate consideration (default: config.memory.consolidation.defaultMinTitleSimilarity or 0.4).
Behavior1/5

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

The description states 'Mutating' actions (merge/replace/invalidate), but annotations declare readOnlyHint=true. This is a direct contradiction. Additionally, the description does not clarify the contradiction or explain why the tool behaves differently under dry_run versus applied mode.

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 concise, conveying purpose, method, constraints, and return format in three sentences. No redundant information, though the structure could be slightly improved with bullet points for readability.

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

Completeness3/5

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

The description covers purpose, method, parameters, and return shape adequately. However, the contradiction with annotations undermines completeness, and some behavioral details (e.g., whether it modifies external state when dry_run=false) remain ambiguous.

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?

The description does not add significant meaning beyond the already exhaustive parameter descriptions in the schema (coverage 100%). It mentions FTS + title-trigram and LLM usage, but these are not parameter-specific. Baseline score of 3 is appropriate.

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?

The description clearly states it performs 'LLM-driven semantic dedup' of decisions, explaining the process of finding similar candidates and merging/replacing/invalidating. It lacks explicit differentiation from siblings like check_duplication, but the purpose is specific and actionable.

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

Usage Guidelines3/5

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

The description mentions dry_run default and that it mutates, implying caution. It also requires an active AI provider. However, it does not specify when not to use it or provide alternatives, such as using check_duplication for non-destructive analysis.

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/nikolai-vysotskyi/trace-mcp'

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