Skip to main content
Glama

Draft rules from a policy

import_policy_rules
Read-only

Convert a written policy document into draft decision rules for review. Returns validated rules with citations and overlap warnings; nothing is saved until you persist explicitly.

Instructions

Convert a written policy document into DRAFT decision rules (LLM-assisted).

Returns validated draft rules (when/action, including chained asserts where the policy stages its determinations), derived rule→rule edges, and overlap warnings. Each returned rule carries a citation field holding the policy sentence it encodes (also summarized in the top-level citations map). NOTHING IS SAVED: review the drafts (and show them to the user), then persist explicitly with put_rules — validate first with dry_run=true, and keep each rule's citation in the YAML you save so the audit trail back to the policy survives.

Args: domain: Domain the rules are drafted for (an owned domain or a new name). policy_text: The policy document text (max ~50k characters).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
domainYes
policy_textYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior5/5

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

Beyond the readOnlyHint annotation, it discloses that nothing is saved, describes the return payload (validated draft rules, rule→rule edges, overlap warnings, citation fields), and warns to review drafts before persisting. This adds significant behavioral context not captured by the annotation.

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 densely informative but well-structured: purpose first, then return details, then critical workflow warning, then parameter docs. Every sentence earns its place with no fluff or repetition.

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 output schema exists, the description successfully covers all essential contextual aspects: what the output contains, citation tracking, no side effects, and the recommended persistence workflow. It is a complete mental model for an agent to act correctly.

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?

Despite 0% schema coverage, the description defines both parameters: domain ('an owned domain or a new name') and policy_text ('max ~50k characters'). This adds meaningful semantic constraints and context beyond the bare schema property names.

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 a specific verb and resource: 'Convert a written policy document into DRAFT decision rules.' It clearly distinguishes itself from sibling tools like put_rules (persist) and list_rules (list existing rules) by emphasizing the draft and no-save aspects.

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?

It explicitly states when to use this tool and what to do next: 'NOTHING IS SAVED: review the drafts... then persist explicitly with put_rules — validate first with dry_run=true.' This provides a concrete workflow and names the exact sibling tool for persistence.

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