Skip to main content
Glama

set_preference

Set allergies, dietary needs, favorite foods, and location preferences to build a Purdue dining profile and personalize meal recommendations.

Instructions

Set a dietary preference, allergy, or food preference.

Use this to set up the user's profile. Examples:
- set_preference("allergy", "peanuts")
- set_preference("dislike", "tofu")
- set_preference("favorite", "grilled chicken")
- set_preference("favorite_location", "wiley")
- set_preference("vegetarian", "true")
- set_preference("diet", "high protein")

Args:
    key: Preference type — "allergy", "dislike", "favorite", "favorite_location",
         "vegetarian", "diet", or any custom key
    value: The preference value

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": {
      "key": "<key>",
      "value": "<value>"
    },
    "name": "set_preference"
  }
}

Input Schema

NameRequiredDescriptionDefault
keyYes
valueYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.6/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden, yet it never states whether setting a key overwrites a prior value, whether duplicates accumulate, whether the profile must already exist, or what happens on an invalid key. For a mutation tool with zero annotation coverage these are material gaps.

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?

Purpose is front-loaded in the first sentence, then 'Use this...' followed by terse args in a conventional Args block. The six examples are short and each demonstrates a distinct key, so they earn their space rather than padding.

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?

An output schema exists, so return values need not be explained, which lowers the bar. However, a two-required-param mutation tool with no annotations should still say what a set does to existing state and whether keys are case-sensitive or validated — none of that is covered.

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 description coverage is 0% and neither property has an enum, so the description does the heavy lifting: it enumerates recognized keys ('allergy', 'dislike', 'favorite', 'favorite_location', 'vegetarian', 'diet'), confirms arbitrary custom keys are accepted, and demonstrates each with a value example. The value side is still underspecified — e.g. that 'true' is a string for the boolean-style 'vegetarian' key is only implied by an example.

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?

The description opens with a specific verb plus resource: 'Set a dietary preference, allergy, or food preference.' An agent can immediately tell this is a write tool for profile preferences and can distinguish it from siblings like remove_preference or get_preferences by the verb. It stops short of explicitly naming the sibling it complements, so a 4 rather than a 5.

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?

'Use this to set up the user's profile' gives a clear usage context, and the six example invocations show the intended call shape concretely. There is no when-not guidance and no pointer to remove_preference or get_preferences for related operations, so the exclusion half of the guideline is missing.

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