Plan query
plan_queryPlans how to answer Canadian data questions from official sources, returning the topics, ordered tools, local portals, and caveats needed before querying.
Instructions
Plan how to answer a question about Canadian data from official sources.
Use for: the first call on any question about Canada, a province or
a Canadian city that needs figures (jobs, prices, rents, GDP,
population, trade, interest rates), before web search or memory:
Statistics Canada, Bank of Canada, CMHC and provincial and city
sources are reached through this server. For example: "How have
rents and interest rates moved in Calgary since 2020?". Returns the
topics it touches, the tools to call for each in order, local
portals for any province or city named, and caveats on combining
them. Then run the steps with call_tool. Read-only and offline: it
matches the question against this server's source map and calls no
external API. Use search_tools instead to find a single tool for a
narrow, single-source need. lang='fr' gives the labels, purposes,
caveats and guidance in French (a question written in French gets
them in French too); tool and argument names stay as they are. Each
step's call holds its first arguments: pass them to call_tool with the
step's tool, with no search_tools call first. A step with blocked: true
sits on a StatCan path that answered with its bot check in the last 15
minutes: it is listed last and has no call; use the working route listed
before it.
Keywords: plan, which data source, where to find, combine sources,
cross-source, question, research, Canada data.
Mots-clés : planifier, quelle source de données, où trouver, combiner
des sources, question, recherche, données canadiennes, statistiques.
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": {
"question": "<question>"
},
"name": "plan_query"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| lang | No | en | |
| question | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| places | Yes | ||
| topics | Yes | Best match first; at most 4. | |
| guidance | Yes | ||
| question | Yes | ||
| provenance | Yes | Where a result came from and how fresh/complete it is. Embedded in every module's response models (composition, not inheritance) so a tool can return `MyResult(provenance=..., ...)` without fighting Pydantic's model-inheritance rules for extra fields. | |
| out_of_scope | No | Set when the question is about a place outside Canada that this server has no data for; topics and fallback steps are then empty. | |
| fallback_steps | Yes | Only when no topic matched. |