Skip to main content
Glama

AIDataNordic — Food Recipe MCP

Ein produktionsreifer semantischer Suchserver für Kochrezepte – entwickelt für KI-Agenten unter Verwendung des Model Context Protocol (MCP). Durchsuche über 50.000 Rezepte mit hybrider dichter + dünner Suche und Cross-Encoder-Reranking.


Was ist das?

Ein selbst gehosteter MCP-Server, der einen Rezeptdatensatz durch semantische Suche bereitstellt. Agenten können per natürlicher Sprache suchen, nach Ernährung, Schwierigkeitsgrad, Zeit und Portionen filtern – und erhalten bewertete, strukturierte Rezeptdaten inklusive Zutaten, Anleitungen und Nährwerten.

Entwickelt für die autonome Maschine-zu-Maschine-Nutzung via FastMCP 3.2 über HTTP.


Architektur

Query (natural language)
        ↓
  Dense embedding          Sparse embedding
  (e5-large-v2)            (BM25 / fastembed)
        ↓                        ↓
       Qdrant — Hybrid Fusion (RRF)
                    ↓
          Cross-encoder reranking
          (mmarco-mMiniLMv2-L12-H384-v1)
                    ↓
          Structured JSON response
                    ↓
           MCP tool / AI agent

Datenabdeckung

Feld

Details

Gesamte Rezepte

50.000+

Quelle

food.com und andere

Felder

title, description, ingredients, instructions, nutrition, rating, difficulty, diet, total_time, servings

Ernährungstags

vegetarian, vegan, gluten-free, dairy-free

Schwierigkeitsgrad

easy, medium, hard


Technischer Stack

Suche

  • Dichte Einbettungen: intfloat/e5-large-v2 (1024 dim)

  • Dünne Einbettungen: Qdrant/bm25 via fastembed

  • Fusion: Reciprocal Rank Fusion (RRF) in Qdrant

  • Reranker: cross-encoder/mmarco-mMiniLMv2-L12-H384-v1

Bereitstellung

  • FastMCP 3.2 über HTTP (/mcp Endpunkt)

  • Kompatibel mit Claude, LangChain und jedem MCP-fähigen Agenten

Infrastruktur

  • Ubuntu Server 24 LTS, selbst gehostet

  • Qdrant Vektordatenbank (selbst gehostet)


MCP-Tool

search_recipes(
    query="quick chicken pasta",       # required — natural language
    diet="vegetarian",                 # optional: vegetarian, vegan, gluten-free, dairy-free
    difficulty="easy",                 # optional: easy, medium, hard
    max_minutes=30,                    # optional: maximum total time in minutes
    servings=4,                        # optional: number of servings
    limit=5                            # optional: number of results (default 5)
)
# Returns semantically ranked recipes with ingredients, instructions, nutrition, and ratings

Beispielantwort

[
  {
    "rerank_score": 7.96,
    "title": "quick and easy chicken pasta salad",
    "description": "great use for left-over chicken.",
    "total_time": 25,
    "difficulty": "medium",
    "diet": [],
    "main_ingredient": "chicken",
    "ingredients": ["cooked chicken", "pasta shells", "tomatoes", "italian dressing"],
    "instructions": ["combine ingredients", "pour dressing", "chill 1 hour"],
    "nutrition": {"calories": 424, "protein_g": 26, "carbs_g": 38.5, "fat_g": 19.5},
    "rating": 4.8,
    "rating_count": 5
  }
]

Schnellstart

1. Abhängigkeiten installieren

pip install -r requirements.txt

2. Server starten

python recipe_mcp_server.py

Der Server startet unter http://localhost:8004/mcp

3. Mit FastMCP-Client verbinden

import fastmcp, asyncio

async def main():
    async with fastmcp.Client("http://localhost:8004/mcp") as client:
        result = await client.call_tool("search_recipes", {
            "query": "quick chicken pasta",
            "max_minutes": 30,
            "limit": 3
        })
        for recipe in result.structured_content["result"]:
            print(recipe["title"], "-", recipe["total_time"], "min")

asyncio.run(main())

4. Mit Claude Desktop verbinden

Füge dies zu deiner claude_desktop_config.json hinzu:

{
  "mcpServers": {
    "food-recipes": {
      "url": "https://recipes.aidatanorge.no/mcp"
    }
  }
}

Live-Demo

Probiere die Suchoberfläche unter recipes.aidatanorge.no aus


Dateien

Datei

Beschreibung

recipe_mcp_server.py

FastMCP-Server mit hybrider Suche

mcp_client.py

Beispiel-Python-Client

requirements.txt

Python-Abhängigkeiten


Entwickelt und betrieben als Teil von AIDataNordic — selbst gehostete KI-Dateninfrastruktur für autonome Agenten.

Install Server
A
security – no known vulnerabilities
F
license - not found
A
quality - A tier

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/AIDataNordic/Food-Recipe-MCP'

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