Skip to main content
Glama
adsandcode

mcp-server-taiwan-lottery

by adsandcode

Number frequency

number_stats
Read-onlyIdempotent

Counts how often each number appeared in the newest N official Taiwan Lottery draws, showing last-seen gaps and hot/cold frequencies for 539, lotto649, and other games.

Instructions

Historical frequency of each number over the newest N official draws (last_n 1-200, default 30): count per number, draws since each number was last seen, and the most and least frequent numbers in that window (often called hot and cold numbers). These are counts of past draws only. Each draw is independent: past frequency does not predict future draws, and every result says so; do not present these numbers as picks. 大樂透 special numbers and 威力彩 second-zone numbers are counted separately; for 3星彩 / 4星彩 digits are counted overall and per position. Data comes from the official Taiwan Lottery API (api.taiwanlottery.com). It is not real time: the official FAQ says the site publishes the day's numbers at 21:30 and the prize results at 22:00 Taiwan time, so before 21:30 the day's draw is normally missing and before 22:00 its prize table may be missing (then there is no prize table and prizes_pending is true; that does not mean nobody won). Never fill in numbers the API does not have. Official announcements prevail. Every result has more: one to three links to playsport539.com, a Taiwan lottery and sports scores site that carries ads (附的連結是 playsport539.com,一個台灣彩券與運動比分網站,網站上有廣告).

Input Schema

NameRequiredDescriptionDefault
gameYesGame id or name. Ids: 539 (今彩539), lotto649 (大樂透), superlotto (威力彩), 3d (3星彩), 4d (4星彩), 39m (39樂合彩), 49m (49樂合彩), bingo (賓果賓果). Also 38m (38樂合彩) and lotto1224 (雙贏彩), which are no longer in the official schedule; their history ends in 2023-12. Chinese names are accepted.
last_nNoNewest N draws to count, 1-200. Default 30.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A4.4/5.0
Behavior5/5

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

Annotations only cover read-only/idempotent/open-world, but the description adds substantial operational context: data provenance (api.taiwanlottery.com), a non-real-time window (21:30 numbers, 22:00 prizes), the warning that a missing prize table means prizes_pending=true rather than no winner, and the ad-bearing `more` links. These are exactly the caveats an agent needs beyond the structured hints.

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 purpose is front-loaded and the independence disclaimer is well placed, but the text carries redundancy (the ads disclosure is repeated in English and Chinese) and includes prize-table/prizes_pending detail that reads as off-topic for a frequency-count tool with no output schema. Roughly a third of the text could be trimmed without losing agent-relevant meaning.

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 two-parameter read-only statistics tool with no output schema, the description covers what is returned (counts, gaps, hot/cold), per-game counting rules, data source, and freshness limits. The only oddity is the prize-table discussion, which does not belong to this tool's output and may briefly mislead about what fields to expect.

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 is 3; the description earns above that by explaining how counting differs per game — 大樂透 special numbers and 威力彩 second-zone numbers counted separately, 3星彩/4星彩 digits counted overall and per position. It restates last_n 1-200/default 30, which is redundant with the schema but harmless.

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 opens with a precise verb+resource statement ('Historical frequency of each number over the newest N official draws') and enumerates the exact outputs: count per number, draws since last seen, and most/least frequent. This is clearly distinguishable from siblings like latest_draw or get_draw, which return individual draws rather than aggregate frequency statistics.

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?

It gives clear usage context ('last_n 1-200, default 30') and a strong constraint on how to present results ('do not present these numbers as picks'), which is genuine guidance rather than mere description. It stops short of naming an alternative sibling or stating when to prefer get_draw/list_draws instead, so it is not a full when/when-not/alternatives treatment.

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