Add guided cook prompts to the MCP server#291
Merged
Merged
Conversation
Register three MCP prompts (diagnose_cook, when_to_wrap, food_safety_check) that return step-by-step plans composing the existing read tools. Prompts give the assistant a guided starting point for common cook questions without adding any new tools, so the server stays at 21 tools. Closes #290 Co-authored-by: Copilot App <[email protected]>
# Conflicts: # packages/mcp/src/server.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds three guided prompts to the MCP server using the prompts API:
diagnose_cook(optionalserial): reads the live snapshot and recent history, then reports whether temps are climbing, stalled, or need attention.when_to_wrap(optionalserial,channel): checks the meat probe against the stall band and calls whether to wrap now, wait, or that the stall already broke.food_safety_check(optionalserial): confirms the cook cleared the danger zone in time and reached a safe internal temp for the cut.Prompts are user-initiated templates that return a step-by-step plan naming the existing tools to call (
get_live_cook_snapshot,get_temperature_history,get_temperature_guide,get_eta). They add guidance without adding tools, so the server stays at 21 tools.How
registerPromptcalls inpackages/mcp/src/server.tswith a smalluserPrompthelper and a shareddeviceClausefor the optional serial argument.Tests
packages/mcp/tests/server.test.ts: each prompt is registered, the tool count stays at 21, callbacks return a user message referencing the expected tools, and the serial and channel arguments are honored (including blank-string fallback).pnpm lintclean.Closes #290