spot_img
HomeResearch & DevelopmentUnveiling the Swiss Food Knowledge Graph: AI's Role in...

Unveiling the Swiss Food Knowledge Graph: AI’s Role in Personalized Nutrition

TLDR: The Swiss Food Knowledge Graph (SwissFKG) is a new AI-powered system that integrates Swiss recipes, ingredients, nutritional data, allergens, and dietary guidelines into a single, comprehensive knowledge graph. It uses Large Language Models (LLMs) for data enrichment and a Graph-Retrieval Augmented Generation (Graph-RAG) pipeline to answer personalized nutrition queries, addressing the limitations of existing dietary assessment tools and fragmented food information in Switzerland.

In an era where artificial intelligence is rapidly transforming various fields, its application in nutrition holds immense promise. However, current automated dietary assessment systems often fall short by overlooking crucial non-visual factors, such as subtle ingredient substitutions in home-cooked meals, or by failing to account for individual dietary needs like allergies, restrictions, cultural practices, and personal preferences. In Switzerland, specifically, food-related information is available but remains fragmented, lacking a central repository that integrates all relevant nutrition aspects within the local context.

To address these significant gaps, researchers have introduced a groundbreaking initiative: the Swiss Food Knowledge Graph (SwissFKG). This innovative resource is, to the best of their knowledge, the first of its kind to comprehensively unite recipes, ingredients, and their substitutions with detailed nutrient data, dietary restrictions, allergen information, and national nutrition guidelines, all within a single, interconnected graph structure.

The development of SwissFKG involves a sophisticated, AI-powered enrichment pipeline. This pipeline leverages Large Language Models (LLMs) to populate the graph with rich, accurate information. The researchers also conducted a pioneering benchmark of four off-the-shelf LLMs (under 70 billion parameters) specifically for food knowledge augmentation. Their findings demonstrate that these LLMs can effectively enhance the graph with relevant nutritional data.

What sets SwissFKG apart is its ability to go beyond simple recipe recommendations. It offers granular, ingredient-level information, including detailed allergen and dietary restriction data, and provides guidance that is directly aligned with established nutritional guidelines. This level of detail is crucial for truly personalized nutrition advice.

To showcase the practical utility of SwissFKG’s rich natural-language data structure, the team implemented a Graph-Retrieval Augmented Generation (Graph-RAG) application. This application allows LLMs to answer user-specific nutrition queries by drawing upon the verified knowledge within the graph. The effectiveness of different LLM-embedding pairings was evaluated by comparing user-query responses against predefined expected answers, yielding promising results.

The foundation of SwissFKG involved meticulous data collection. One thousand recipes were carefully curated from popular Swiss culinary websites, with flawed or duplicate entries filtered out. These recipes provided a solid base, including macro-nutrition, ingredients, utensils, instructions, seasons, cuisines, and keywords. To enrich the ingredient level, the Swiss Food Composition Database (FCDB) was primarily used for nutrient profiles, supplemented by the USDA’s FoodData Central when necessary. Ingredient substitution data came from Foodsubs, and glycemic index values were sourced from FoodStruct to cater to the diabetic population. Crucially, Swiss food regulations on allergen categories and guidelines from the Swiss Food Pyramid were integrated.

The data enrichment process was largely semi-automated using LLMs. Non-English content, predominantly French, was translated, with Gemma3 (27B) showing superior performance. LLMs were also instrumental in normalizing ingredient names, extracting preparation details, and assigning quantities and units. Furthermore, LLMs inferred dietary restrictions, assigned allergens based on Swiss regulations, and mapped ingredients to Swiss Food Pyramid categories. While LLMs performed well overall in these tasks, some challenges were noted, particularly with the “diabetic diet” mapping, which often had higher error rates due to the variable nature of such guidelines.

The final SwissFKG is a robust knowledge graph comprising 5,896 nodes and 62,499 relationships. The most frequently occurring nodes include ingredients, instructions, and recipes. The graph reveals interesting insights, such as 893 recipes containing allergens, and the most commonly used ingredients being salt, pepper, olive oil, water, and sugar. It also highlights that a significant number of recipes are vegetarian-friendly, gluten-free, suitable for religious restrictions, or low/free of lactose.

The Graph-RAG pipeline demonstrated the practical application of SwissFKG. When a user submits a query, the system extracts key concepts and uses graph embeddings to retrieve contextually aligned knowledge. This retrieved information is then passed to an LLM, which synthesizes it into a coherent, natural-language answer. The evaluation showed that Gemma3 (27B) paired with the Mxbai Embed Large embedding model achieved the highest accuracy of 80% in answering curated questions, underscoring the critical role of embedding models in retrieval-augmented inference.

Also Read:

This work represents a significant step towards the next generation of dietary assessment tools that seamlessly integrate visual, contextual, and cultural dimensions of eating. It lays the groundwork for a general-population use case and paves the way for a global Food Knowledge Graph, built on verified, personalized nutrition recommendations. For more in-depth information, you can read the full research paper here.

Karthik Mehta
Karthik Mehtahttps://blogs.edgentiq.com
Karthik Mehta is a data journalist known for his data-rich, insightful coverage of AI news and developments. Armed with a degree in Data Science from IIT Bombay and years of newsroom experience, Karthik merges storytelling with metrics to surface deeper narratives in AI-related events. His writing cuts through hype, revealing the real-world impact of Generative AI on industries, policy, and society. You can reach him out at: [email protected]

- Advertisement -

spot_img

Gen AI News and Updates

spot_img

- Advertisement -