Skip to main content
Glama

Merit — Ukrainian Law & Registers

Search Legislation Provisions by Text

ua_law__search_units
Read-onlyIdempotent

Find provisions by their text: which articles, points or clauses say X.

Every word of text must appear (quote it for an exact phrase). Searches the text as published on on_date (default today); nreg limits it to acts. Each hit is the smallest unit holding it, with that day's urn. ⟦ ⟧ in excerpt mark matches, not the law's text. amending_act hits restate other acts. search finds acts by title.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "text": "<text>"
    },
    "name": "ua_law__search_units"
  }
}

Input Schema

NameRequiredDescriptionDefault
nregNoOnly these acts.
textYesWords to find.
limitNo
offsetNo
on_dateNoText as published that day.
per_actNoHits per act, 0: all (default 3; 1 act: all).
amending_actsNoFalse: no amending laws.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior3/5

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

Annotations already cover the safety profile (readOnly, idempotent, non-destructive, closed-world), so the description's added value is about result semantics — each hit is the smallest unit containing the match, carrying that day's urn, and ⟦ ⟧ in `excerpt` marks matches rather than law text. That is genuinely useful disclosure with no output schema to lean on. However, it says nothing about result ordering, what a hit looks like beyond `urn`/`excerpt`, or how pagination truncation manifests in the response.

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 core purpose is front-loaded in the first clause and every subsequent sentence adds distinct information — matching rule, date semantics, hit granularity, excerpt notation, amending-act caveat, sibling routing. The telegraphic register and the '⟦ ⟧' glyph are slightly opaque on first read, but no sentence is filler.

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?

With seven parameters and no output schema, the description carries the burden of explaining the return shape, and it does — hit granularity, urn, excerpt markers, amending-act hits. Missing pieces are pagination/limit behavior and result ordering, which matter for a search tool that caps at 50 results.

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?

Well above the 71% schema baseline for the parameters it touches: `text` gains AND-semantics plus quoting for exact phrases (the schema only says 'Words to find'), `on_date` gains 'default today' and published-text semantics, `nreg` gains 'limits it to acts', and the amending-act parameter gains an explanation of what such hits mean. `limit`, `offset`, and `per_act` are left entirely to the schema, which keeps it from a 5.

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?

Opens with a specific verb and resource — 'Find provisions by their text: which articles, points or clauses say X' — and explicitly separates itself from the sibling `search` ('finds acts by title') and by implication from the get_unit* tools. An agent knows exactly which tool to pick for a text-search versus a title-search.

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?

It draws the boundary against the closest alternative ('`search` finds acts by title') and explains the matching rule that governs when this tool will return results (every word must appear; quote for an exact phrase). It does not state when-not-to-use or mention the get_unit tools for retrieving a full provision once found, so a bit of routing context is left implicit.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.