Skip to main content
Glama

discover_declare

Discover declarative process constraints from event logs using DECLARE notation, extracting patterns like response and precedence with support and confidence metrics.

Instructions

Discover a DECLARE model from an event log.

DECLARE is a declarative constraint notation capturing patterns like "response" (if A then eventually B) or "precedence" (B requires A earlier). PM4Py returns a nested dict: template → (activity-tuple → {"support": N, "confidence": N}).

min_support_ratio / min_confidence_ratio prune weak constraints (both in [0, 1]; default None uses pm4py's internal defaults).

Returns a handle plus counts of templates covered and constraints found.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
log_idYes
min_support_ratioNo
min_confidence_ratioNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior2/5

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

No annotations provided, so the description must fully disclose behavior. It mentions pruning weak constraints via parameters but does not address potential side effects, required permissions, computational expense, or data volume impacts. Significant gaps in transparency.

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?

A single paragraph that front-loads purpose, explains DECLARE, and describes parameters. It is concise but could benefit from bullet points for readability. No wasted sentences.

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?

Mentions return format (nested dict) and counts, but lacks detailed explanation of the output schema structure. With an output schema present, more guidance on interpreting results would enhance completeness.

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 coverage is 0%. The description adds meaning for min_support_ratio and min_confidence_ratio, explaining they prune constraints with ranges and defaults. However, log_id's purpose is not elaborated beyond 'Log Id' from schema.

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 it discovers a DECLARE model from an event log, explains what DECLARE is (declarative constraints), and mentions the nested dict return format. This is specific and distinguishes from sibling discovery tools like discover_dfg or discover_petri_net.

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

Usage Guidelines2/5

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

No explicit guidance on when to use this tool versus alternatives, nor when not to use it. The description lacks context for selection among sibling tools (e.g., when to choose DECLARE over DFG or Petri nets).

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/azizketata/pm4py-mcp'

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