Skip to main content
Glama

Complete Learning Unit

complete_unit
Idempotent

Mark a learning unit as completed after the user achieves a passing score (≥50%). Awards XP, unlocks the next unit, and checks for course completion. Called automatically by learning widgets (quiz, flashcards, etc.) when the user finishes. FREE call - no coin cost.

Input Schema

NameRequiredDescriptionDefault
scoreYesThe user's score (0-100). Must be ≥50 to complete the unit.
unit_idYesThe unit ID being completed (required)
course_idYesThe course ID containing this unit (required)
learning_typeNoType of learning activity completed (mcq, flashcard, fill_blank, match_pair, ranking, crossword, podcast, infographic)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare it is a non-read-only, non-destructive, idempotent, closed-world mutation; the description adds real value beyond that by naming the side effects (XP award, next-unit unlock, course-completion check) and the cost profile ('FREE call - no coin cost'). It stops short of saying what happens when score < 50 (error vs. no-op) or what the call returns, which matters for a mutation with no output schema.

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?

Four short sentences, front-loaded with purpose, then trigger, then cost. Every sentence carries information the agent cannot get from the schema or annotations; there is no 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?

For a 4-parameter, 3-required mutation with no output schema, the description covers purpose, trigger, precondition, side effects, and cost. The remaining hole is outcome behavior on a failing score and the shape of the response (XP granted, next unit id, course-complete flag), which the agent cannot infer.

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 100%, so the baseline here is 3; the description still earns a bump by reinforcing the gating rule (≥50 passing score) and by contextualizing learning_type through the 'learning widgets (quiz, flashcards, etc.)' list. It adds nothing about the unit_id/course_id pairing (e.g., whether the unit must belong to that course).

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?

States a specific verb and resource ('Mark a learning unit as completed') plus the exact effect set (awards XP, unlocks the next unit, checks course completion). No sibling tool in the list performs unit completion, so an agent can disambiguate it from the create_*/edit_* family without opening any schema.

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?

Gives a clear trigger and provenance: 'Called automatically by learning widgets (quiz, flashcards, etc.) when the user finishes,' and states the ≥50% precondition. It does not explicitly say whether an agent should ever call it directly or what to do instead when the score is below threshold, so no exclusion/alternative routing is provided.

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.

Resources