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
Copy file name to clipboardExpand all lines: README.md
+69-8Lines changed: 69 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,15 +24,15 @@ The application is designed for home cooks, culinary enthusiasts, individuals wi
24
24
25
25
### Integration of Generative AI
26
26
27
-
Generative AI is integrated meaningfully through a dedicated LLM microservice developed in Python. This service processes user inputs in natural language, generates recipes based on the provided ingredients, modifies existing recipes according to user needs, and provides meal suggestions. The use of GenAI enhances the user experience by offering creative, context-aware, and highly adaptable culinary solutions.
27
+
Generative AI is integrated meaningfully through a dedicated LLM microservice developed in Python. This service processes user inputs in natural language, generates recipes based on the provided ingredients, modifies existing recipes according to user needs, and provides meal suggestions based on the user dietary preferences. The use of GenAI enhances the user experience by offering a personalized RAG system that emphasizes user-specific recipe collections. Through the use of a conversational AI system, we provide to the users with a multi-turn chat with context preservation.
28
28
29
29
### Functional Scenarios
30
30
31
31
1.**Ingredient-Based Recipe Generation**: A user inputs, "Suggest a quick dinner recipe with chicken and broccoli." The system uses the LLM to generate a relevant recipe, which is presented to the user through the user interface.
32
32
33
33
2.**Recipe Modification**: A user submits a traditional recipe and requests, "Make this vegan." The LLM identifies non-vegan ingredients and substitutes them with plant-based alternatives, returning a modified version of the recipe.
34
34
35
-
3.**Meal Planning**: A user asks for a weekly meal plan. The LLM generates a diverse and nutritionally balanced plan, optionally based on dietary restrictions or cuisine preferences.
35
+
3.**Meal Planning with User Preferences**: A user defines his/her dietary preferences in the web application and asks for a weekly meal plan in the chat. The LLM generates a diverse and nutritionally balanced plan, based on dietary restrictions or cuisine preferences.
36
36
37
37
4.**Ingredient-Limited Cooking**: A user specifies available ingredients, such as "eggs, spinach, and cheese," and the system suggests recipes that can be prepared using those ingredients, optimizing for simplicity and flavor.
38
38
@@ -57,6 +57,7 @@ Generative AI is integrated meaningfully through a dedicated LLM microservice de
@@ -82,9 +83,9 @@ Generative AI is integrated meaningfully through a dedicated LLM microservice de
82
83
**Responsibilities:**
83
84
84
85
- Process incoming prompts and preferences.
85
-
- Use LLM (e.g., GPT via LangChain) to generate, modify, and plan recipes.
86
+
- Use LLM (e.g., GPT via LangChain or Llama3) to generate, modify, and plan recipes.
87
+
- Fetch additional data from a well known recipe source stored in the vector database Qdrant to enable document retrieval for answering recipe document based questions.
86
88
- Structure outputs into JSON responses and provide endpoints via FastAPI for server module.
87
-
- Fetch additional data from a well known recipe source stored in the vector database Qdrant.
88
89
89
90
**Design:**
90
91
@@ -107,7 +108,7 @@ Generative AI is integrated meaningfully through a dedicated LLM microservice de
107
108
108
109
**Collections:**
109
110
110
-
-`recipes` – Stores embedded recipe documents which are uploaded by the user
111
+
-`recipes` – Stores user specific embedded recipe documents which are uploaded by the user
111
112
112
113
### 6. DevOps
113
114
@@ -135,7 +136,8 @@ Generative AI is integrated meaningfully through a dedicated LLM microservice de
135
136
### Communication Flow Example
136
137
137
138
1. User logs in via GitLab LRZ → token returned.
138
-
2. User types: _"Suggest a vegan dinner with lentils."_
139
+
2. User select his/her didtary preferences.
140
+
2. User types: _"Suggest a dinner with lentils."_
139
141
3. React sends prompt + preferences to Spring Boot API.
140
142
4. API calls GenAI microservice with combined data.
141
143
5. GenAI returns structured recipe.
@@ -185,6 +187,48 @@ cd team-continuous-disappointment
185
187
186
188
### Server Setup
187
189
190
+
**Note**: Please be aware that you need to manually add the GITLAB_CLIENT_SECRET from the `.env` file (see [.env.template](.env.template)) to the [application.yaml](server/api-gw/src/main/resources/application.yaml) file for the field `client-secret` for local development.
@@ -286,7 +330,7 @@ The LLM service will be available at [http://localhost:8000](http://localhost:80
286
330
287
331
- Built with FastAPI for AI-powered recipe recommendations.
288
332
- Integrates with local and cloud LLMs for generating suggestions based on the given ingredients.
289
-
- Stores embedded documents in a vector database to be able to make similarity search.
333
+
- Stores embedded documents in a vector database to be able to make similarity search and document retrieval.
290
334
- Source code is in the `genai` directory.
291
335
- Tests are in the `genai/tests` directory.
292
336
@@ -510,7 +554,24 @@ API documentation is available in the [`genai/openapi.yaml`](genai/openapi.yaml)
510
554
- Usability: The chat interface must be responsive and intuitive.
511
555
- Observability & Monitoring: The system must expose Prometheus metrics for all critical services. Dashboards must be created in Grafana to visualize response latency, error rates, and user request volume. Besides that, at least one alert must be defined.
512
556
513
-
## Architecture Overview - TODO
557
+
## Architecture Overview
558
+
559
+
### UML Component Diagram
560
+
561
+
The following UML component diagram shows the details of the RecipAI application architecture and provides a comprehensive overview of the interfaces offered by the genai, chat, user, and API gateway services.
0 commit comments