Skip to main content
Glama

Make a decision

decide

Evaluate a query against a domain's rule set to return a deterministic, auditable decision, with an explanation generated from policy documents.

Instructions

Make a deterministic, auditable decision in a domain.

The verdict comes from the domain's rule set (Rete engine, never the LLM), so it is reproducible and compliant. The explanation is generated from the domain's ingested policy documents.

Args: domain: Rule-set domain, e.g. "loan", "fraud", "clinical". query: Natural-language question or decision request. facts: Structured facts for working memory, e.g. {"credit_score": 710, "annual_income": 85000}. Use list_rules to see which fields a domain's rules test. unstructured_text: Optional free text (an application, a case note); facts are extracted from it automatically and merged. response_mode: "verdict_only" (fastest), "verdict_with_explanation", or "full_audit" (every rule evaluation + retrieved chunks, available on every plan including the free tier). rule_firings come back in causal order: a rule that matched a fact asserted by an earlier firing appears after it, with the derived facts listed under asserted_facts. filter_retrieval_with_rules: Pattern 01 — run the rules first and let a fired rule's retrieval_scope action narrow which documents the retrieval searches before it runs. extract_from_retrieval: Pattern 02 — parse the retrieved documents into facts and assert them into working memory, so rules fire on what was actually read (not just the facts you passed).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
factsNo
queryYes
domainYes
response_modeNoverdict_with_explanation
unstructured_textNo
extract_from_retrievalNo
filter_retrieval_with_rulesNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior5/5

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

Beyond the annotations (readOnlyHint=false, destructiveHint=false), the description discloses key behavioral traits: decisions are deterministic, reproducible, and compliant because they are produced by the rule engine rather than the LLM. It also details how rule_firings are ordered causally and what response modes return, adding substantial value beyond structured annotations.

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?

Although the description is long, it is well-structured and front-loaded with the core purpose, followed by a clear Args list and advanced usage patterns. Each sentence adds necessary information for a complex 7-parameter tool with no schema descriptions, so there is little waste.

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?

Given the tool's complexity and 7 parameters, the description is thorough: it covers what the tool does, how verdicts are produced, how to inspect rules, how response modes work, and how advanced retrieval patterns can be used. The presence of an output schema reduces the need to document return values, but the description still offers relevant return behavior for audit mode.

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

Parameters5/5

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

With 0% schema description coverage, the description fully compensates by explaining every parameter in the Args section, including an example for facts and clarifying the meaning of response_mode and the two retrieval patterns. The enum values are enriched with practical guidance (e.g., 'verdict_only' is fastest, 'full_audit' is available on every plan).

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 opens with 'Make a deterministic, auditable decision in a domain' which uses a specific verb and resource, and distinguishes the tool from siblings like list_rules and ingest_text. It further clarifies that the verdict comes from a Rete engine, not the LLM, leaving no ambiguity about its core function.

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?

The description provides clear context for use: making decisions in a domain based on rule sets, with examples of domains. It references list_rules as a way to determine which facts a domain requires, giving the agent a path for preparation, but it does not explicitly state when not to use the tool or name alternatives for exclusion. This falls just short of a 5.

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/zaharajabeen13-create/ai-rete-rag-mcp'

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