Skip to main content
Glama

evaluate_spdx_expression_policy

Read-onlyIdempotent

Evaluate single or compound SPDX license expressions across SaaS, binary, and internal deployment modes to determine policy compliance verdicts.

Instructions

Evaluates single or compound SPDX boolean license expressions (OR, AND, WITH, parentheses) across SaaS, Commercial Binary, and Internal Tool deployment modes.

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": {
      "expression": "<expression>"
    },
    "name": "evaluate_spdx_expression_policy"
  }
}

Input Schema

NameRequiredDescriptionDefault
expressionYesSingle SPDX identifier or compound boolean expression such as "(MIT OR GPL-3.0-only)", "GPL-3.0-only AND MIT", "BUSL-1.1", or "Apache-2.0 WITH Commons-Clause".
deploymentModeNoOptional primary deployment mode ("saas", "binary", or "internal") highlighted in the top-level verdict; all three modes are returned in matrix.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

B3.4/5.0
Behavior3/5

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

Annotations already declare readOnly, idempotent, non-destructive, and closed-world, so the safety profile is covered. The description adds that compound expressions and all three deployment modes are handled, but it says nothing about what 'policy' criteria are applied or what the verdict contains. Useful but thin context beyond the structured data.

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 dense sentence with the verb, expression forms, and scope front-loaded; nothing is wasted. It is slightly over-packed, but every clause carries information relevant to selecting the tool.

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?

With no output schema, the description does not explain the shape of the evaluation result (the schema only hints that a 'matrix' of all three modes is returned). For a policy-evaluation tool, an agent would benefit from knowing what the verdict expresses; the definition is adequate but leaves that gap.

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?

Schema description coverage is 100%, so the schema already documents both parameters, including the expression syntax examples and the deploymentMode enum. The description's mention of OR/AND/WITH/parentheses and the three modes largely restates what the schema provides, so the baseline 3 applies.

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?

States a specific verb (evaluates) and a precisely scoped resource (single or compound SPDX boolean expressions with OR/AND/WITH/parentheses) plus the three deployment modes covered. It is clearly distinct from the listed siblings (audit_lockfile_compliance, generate_cyclonedx_sbom, scan_supply_chain_hazards), but it never explicitly contrasts itself with them.

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?

Usage is only implied: an agent can infer it should call this when it has an SPDX expression and needs a policy/compliance verdict per deployment mode. There is no explicit when-to-use, when-not-to-use, or routing to an alternative tool or step.

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