Skip to main content
Glama

approval

Determine the election winner using approval voting. Each approved candidate accumulates the ballot's weight; the candidate with the highest total weight is selected.

Instructions

Approval voting: each candidate scores the total weight approving it.

Consumes approval ballots ({kind: "approval", approved: [...]}). An empty approval set is valid and adds nothing. Errors if any ballot is not approval.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
seedNo
profileYes
tie_breakNolexicographic

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
noteNo
ruleYes
scoresNo
winnerYes
rankingNo
winnersYes
tie_breakNolexicographic
Behavior4/5

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

With no annotations provided, the description covers key behaviors: accepts approval ballots, treats empty approval set as valid, and errors on non-approval ballots. However, it does not mention tie-breaking behavior (despite a tie_break parameter) or the seed parameter's effect.

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 three sentences with no wasted words. It front-loads the core purpose, uses a code block for clarity on ballot format, and every sentence adds unique value.

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?

Given the tool's complexity (voting rule) and the existence of an output schema, the description covers the main input requirement but omits the optional parameters (seed, tie_break). It also fails to explain handling of ballot weights or tie-breaking scenarios, leaving gaps for a thorough understanding.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must compensate. It only hints at the profile parameter ('Consumes approval ballots') and neglects to explain the 'seed' and 'tie_break' parameters at all. The description adds minimal meaning beyond the schema's titles.

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 states 'Approval voting: each candidate scores the total weight approving it,' clearly specifying the voting rule and its mechanism. It distinguishes from other sibling tools by explicitly noting it only consumes approval ballots, contrasting with other rules.

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 states 'Consumes approval ballots... Errors if any ballot is not approval,' clearly indicating the tool is only appropriate when all ballots are approval type. It does not explicitly name alternatives, but the sibling tool names imply other rules for different ballot types.

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/HrishiKabra/voting-mcp'

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