You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* feat(mcp): expose 6 MCP prompts + JMESPath schema parity
Turns on the MCP prompts capability with six concrete workflow templates
(country-briefing, energy-shock-watch, market-open-prep, conflict-pulse,
route-risk-check, freshness-audit). Each step pre-bakes a literal
JMESPath projection so the first execution lands on the right shape
without a discovery round-trip.
prompts/list + prompts/get are quota-exempt (per-minute limit still
applies) to mirror the describe_tool metadata posture — counting
template fetches against the 50/day Pro cap would discourage exploration.
`capabilities.prompts.listChanged: false` is advertised because the
stateless edge transport can't push notifications/prompts/list_changed
today.
Adds a parity test (tests/mcp-prompts.test.mjs) that compiles every
embedded JMESPath via the same parser used at runtime and asserts every
field identifier resolves to a property in the referenced tool's declared
outputSchema. A typo'd field path in a prompt OR a renamed field in a
tool's schema fails this test by name with both the prompt and the
broken path — verified by sabotaging both cases before commit.
SERVER_VERSION 1.7.0 -> 1.8.0; server-card prompts flag flipped in
lockstep. SERVER_INSTRUCTIONS mentions prompts/list as a discoverable
affordance.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* fix(mcp/prompts): strip empty-string optional args from rendered tool args
When a caller omits an optional prompt arg (e.g. country in
energy-shock-watch / conflict-pulse), the renderer used to emit
`arguments: {"country":""}` in the step block. The LLM then passed `""`
through to the tool literally. Today's referenced tools all truthy-check
filter args via argStr/argStrList (safe), but a future tool that guards
with `!== undefined` would try to filter by empty string instead of
serving the global view.
Strip top-level keys that resolved to '' so the no-filter call renders
as `arguments: {}` — unambiguous, matches the model's intent when the
arg is omitted. Required-arg absence already returned -32602 above, so
this only affects optional-arg absence.
Adds a regression test asserting the rendered block is `arguments: {}`
when an optional arg is omitted (and absent the literal `"country":""`).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
`Limits: expression ≤ ${JMESPATH_MAX_EXPR_BYTES} bytes; projected payload ≤ ${JMESPATH_MAX_OUTPUT_BYTES} bytes. Failures return {_jmespath_error, original_keys} inside the normal result envelope. Bad expressions DO consume one daily quota unit on retry — original_keys is echoed so you can self-correct in one extra call.`,
194
211
'',
195
212
`tools/list returns COMPRESSED tool descriptions (first sentence, ≤${TOOL_DESCRIPTION_MAX_BYTES}B per tool). Call describe_tool({tool_name}) to get the full uncompressed definition for any tool you're considering — especially useful when the compressed entry is ambiguous about behaviour or argument semantics. describe_tool is metadata-only and is EXEMPT from the Pro daily quota (still counts toward the 60/min rate limit), so use it freely while exploring. describe_tool({tool_name: 'nonexistent'}) returns {error: 'unknown_tool', available: [...]} so you can self-correct.`,
213
+
'',
214
+
'Issue prompts/list to discover pre-built workflow templates (country-briefing, energy-shock-watch, market-open-prep, conflict-pulse, route-risk-check, freshness-audit). Each prompt pre-bakes a JMESPath projection per step so the first execution lands on the right shape. prompts/list + prompts/get are quota-exempt (per-minute limit only).',
196
215
].join('\n');
197
216
198
217
// Country-code whitelist for get_consumer_prices. The consumer-prices seeder
0 commit comments