Skip to main content
Glama

Search random

search_random
Read-only

Return random photos from your Immich library, optionally filtered by city, country, camera, favorites, or OCR text, to sample matches or spot-check large collections.

Instructions

Random assets from the library, optionally filtered. Use this for sampling — a quick feel of what a filter matches, a surprise pick for a story, or spot checks over a big library. Read-only.

Args:
    size: How many random assets to return (default 10, max 100).
    city: Only assets from this city.
    country: Only assets from this country.
    make: Only assets from this camera make.
    model: Only assets from this camera model.
    is_favorite: If true, only favorites.
    ocr: Only assets whose recognized text matches (needs OCR on the server).

Returns: JSON with the matching assets array.

Input Schema

NameRequiredDescriptionDefault
ocrNo
cityNo
makeNo
sizeNo
modelNo
countryNo
is_favoriteNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv2.0.2

TDQS

A3.8/5.0
Behavior3/5

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

Annotations already declare readOnlyHint and destructiveHint=false, and the description's "Read-only" merely restates that. It does add genuinely new context: the size cap of 100 and the server-side OCR prerequisite, but says nothing about randomization cost, ordering guarantees, or pagination behavior.

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?

Front-loaded with purpose and use cases, followed by a compact Args list where each line earns its place. The trailing "Returns: JSON with the matching assets array" is low-value given an output schema exists.

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 7-param, read-only filtered search with an output schema and safety annotations, the description covers purpose, usage, parameter meaning, and the one environmental dependency (OCR). Only filter-matching semantics remain unstated.

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%, so the description carries the full burden, and it does document all seven parameters with intent and the size default/max. It omits matching semantics (exact vs. partial string match for city/country/make/model, and what false vs. null means for is_favorite).

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 and resource ("Random assets from the library, optionally filtered") and frames the sampling intent, which distinguishes it from the search_metadata/search_explore/smart-search family. However, it never names a sibling directly, so the agent must infer which search variant to pick.

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 concrete use cases (quick feel of a filter, surprise pick, spot checks over a big library) that make the sampling role clear. It lacks explicit exclusions or a named alternative for exhaustive/ordered retrieval.

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

Deploy Server

Other Tools