Skip to main content
Glama

WAI Quantum job service

Sample recommendations from a low-rank preference matrix

dequant_recommend
Read-onlyIdempotent

Tang's (2019) recommendation sampler: the user's row projected onto the sketch's approximate top-k row space, its inner products with the sampled rows estimated by the median of means, and items drawn from the projection's length-squared distribution by rejection sampling. Where the reference is made, the draws' total-variation distance from the exact projection's distribution is given beside the distance chance alone gives. The answer carries its label: each source theorem's sample count as a formula evaluated at this instance's ‖A‖_F, ‖A‖, σ_k, k, κ, ε, δ and η (exact where the full decomposition was made), its exponents and whether it states its constant, set beside the counts this run used; the error measured against the full decomposition where the matrix is small enough (at most 2^17 entries); and the work counted (entry queries, length-squared samples, random words, the small decomposition's operations). Sealed with the service's key; verify_quantum_result checks the seal and runs it again for the same bits. Refusals: J210, J211.

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": {
      "matrix": "<matrix>"
    },
    "name": "dequant_recommend"
  }
}

Input Schema

NameRequiredDescriptionDefault
kNoThe singular vectors kept (default the generated rank, else 4).
etaNoThe width of the singular-value threshold's band the label's theorems take (default 0.2).
seedNoThe kernel's seed (default 1): the same seed and request give the same bits on every host.
userNoThe user: a row of the matrix (default 0).
deltaNoThe failure probability the label's theorems are asked for (default 0.1).
drawsNoLength-squared draws from the answer (default 1000).
budgetNoThe most rejection proposals the draws make (default: what the job's work bound leaves).
groupsNoThe median of means' groups (default 5).
matrixYesThe matrix: {"generate": {"rows", "cols", "rank", "condition", "noise", "seed"}} (a random rank-`rank` matrix, its singular values evenly from 1 down to 1/condition (default 2), plus Gaussian noise whose Frobenius norm is `noise` (default 0.01) of the low-rank part's, from `seed`) or {"entries": [[…], …]} (its rows). At most 2^20 entries.
epsilonNoThe error the label's theorems are asked for (default 0.1).
per_groupNoThe samples in each group's mean (default 2000).
referenceNoHold the answer to the full decomposition where the matrix is small enough (at most 2^17 entries, a smaller side of at most 256; default true).
cols_sampledNoColumns sampled from the sampled rows (default 160).
rows_sampledNoRows sampled by their squared norms (default 160).

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A3.7/5.0
Behavior5/5

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

Beyond the readOnlyHint, openWorldHint=false, and idempotentHint annotations, the description discloses sealing with the service key, verification via verify_quantum_result, refusal codes J210/J211, reference-error measurement limits, and work accounting. These are substantive behavioral details that materially help an agent understand the tool's execution and outputs.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is dense and jargon-heavy, with long sentences that are not front-loaded around a plain statement of the tool's outcome. It contains little filler, but its algorithmic exposition makes it harder to scan than necessary for tool selection.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the 14 parameters, nested input schema, output schema, and annotations, the description is complete enough for correct invocation. It covers the matrix limits, reference threshold, sealed output, verification path, refusal codes, and what the answer label contains.

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% and the parameters are already well documented in the input schema. The description adds some context by tying k, epsilon, delta, and eta to the label's theorem formulas, but most parameter meaning is already supplied by the schema, so this sits at the baseline for high coverage.

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 identifies a specific operation: Tang's recommendation sampler that draws items from a low-rank preference matrix projection. It is clear enough to distinguish the core behavior, but it does not explicitly differentiate this tool from related siblings such as dequant_lowrank, and the purpose is wrapped in dense algorithmic terminology.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no explicit guidance on when to use this tool versus alternatives, nor any stated exclusions or prerequisites for selection. The mention of verify_quantum_result concerns post-run verification, not when to choose dequant_recommend.

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