Skip to main content
Glama
WhenYouAreStrange

goodbook-mcp

find_recipe_standards

Find standardized recipes and preparation methods for specific dishes using food service PDF guidelines.

Instructions

Find standardized recipes and preparation methods for specific dishes

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
dish_nameYesName of the dish to find recipe standards for
cuisine_typeNo

Implementation Reference

  • Core handler function executing the tool logic: generates search terms based on dish_name and optional cuisine_type, searches PDF content via pdfParser, deduplicates results, and formats a text response with up to 8 standards.
    async function findRecipeStandards(dish_name, cuisine_type) { const recipeTerms = [ dish_name, `рецепт ${dish_name}`, `стандарт ${dish_name}`, `приготовление ${dish_name}`, `recipe ${dish_name}`, `standard ${dish_name}`, `preparation ${dish_name}` ]; if (cuisine_type) { recipeTerms.push(`${cuisine_type} ${dish_name}`); } let allResults = []; for (const term of recipeTerms) { const results = pdfParser.searchContent(term); if (results.results) { allResults.push(...results.results); } } const uniqueResults = allResults.filter((result, index, self) => index === self.findIndex(r => r.content === result.content) ); let response = `Recipe standards for "${dish_name}"`; if (cuisine_type) response += ` (${cuisine_type} cuisine)`; response += ":\n\n"; if (uniqueResults.length === 0) { response += "No specific recipe standards found for this dish."; } else { uniqueResults.slice(0, 8).forEach((result, index) => { response += `Standard ${index + 1}:\n`; response += `${result.content}\n\n`; }); } return { content: [{ type: "text", text: response }] }; }
  • Zod schema for input validation of the tool's parameters: dish_name (required string) and cuisine_type (optional string). Converted to JSON schema for MCP.
    const findRecipeStandardsSchema = z.object({ dish_name: z.string().describe("Name of the dish to find recipe standards for"), cuisine_type: z.string().optional().describe("Optional: type of cuisine or cooking style"), });
  • src/index.js:197-200 (registration)
    Tool registration in the toolDefinitions array, including name, description, and inputSchema derived from Zod schema.
    name: "find_recipe_standards", description: "Find standardized recipes and preparation methods for specific dishes", inputSchema: zodToJsonSchema(findRecipeStandardsSchema) }
  • Alternative class method handler for the tool logic in GoodbookTools class (nearly identical to index.js implementation).
    async findRecipeStandards(dishName, cuisineType = null) { const recipeTerms = [ dishName, `рецепт ${dishName}`, `стандарт ${dishName}`, `приготовление ${dishName}`, `recipe ${dishName}`, `standard ${dishName}`, `preparation ${dishName}` ]; if (cuisineType) { recipeTerms.push(`${cuisineType} ${dishName}`); } let allResults = []; for (const term of recipeTerms) { const results = this.pdfParser.searchContent(term); if (results.results) { allResults.push(...results.results); } } const uniqueResults = allResults.filter((result, index, self) => index === self.findIndex(r => r.content === result.content) ); let response = `Recipe standards for "${dishName}"`; if (cuisineType) response += ` (${cuisineType} cuisine)`; response += ":\n\n"; if (uniqueResults.length === 0) { response += "No specific recipe standards found for this dish."; } else { uniqueResults.slice(0, 8).forEach((result, index) => { response += `Standard ${index + 1}:\n`; response += `${result.content}\n\n`; }); } return { content: [{ type: "text", text: response }] }; }
  • src/tools.js:97-112 (registration)
    Tool definition/registration in GoodbookTools.getToolDefinitions(), with inline JSON schema.
    name: "find_recipe_standards", description: "Find standardized recipes and preparation methods for specific dishes", inputSchema: { type: "object", properties: { dish_name: { type: "string", description: "Name of the dish to find recipe standards for" }, cuisine_type: { type: "string", description: "Optional: type of cuisine or cooking style" } }, required: ["dish_name"] }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/WhenYouAreStrange/goodbook-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server