Compare commits
2 Commits
6e72f549cf
...
bd486fa9f7
Author | SHA1 | Date | |
---|---|---|---|
|
bd486fa9f7 | ||
|
6dffa397f2 |
@ -41,12 +41,12 @@ namespace API.Services
|
|||||||
new SystemChatMessage($"You are a a helpful assistant. You give back {recipeDTO.NumberOfRecipes} recipes on the dish that you have been given. " +
|
new SystemChatMessage($"You are a a helpful assistant. You give back {recipeDTO.NumberOfRecipes} recipes on the dish that you have been given. " +
|
||||||
$"Answer in the language {recipeDTO.Language}. " +
|
$"Answer in the language {recipeDTO.Language}. " +
|
||||||
$"Answer in .json format using this structure {jsonStructure}. " +
|
$"Answer in .json format using this structure {jsonStructure}. " +
|
||||||
$"For the ingredients keep the names short ie. 'grated cheese' instead of 'cheese, grated (e.g., cheddar or gouda)'" +
|
$"Make ingredient names as short as possible and use title case ie. 'grated cheese' instead of 'cheese, grated (e.g., cheddar or gouda)'" +
|
||||||
$"Avoid item/dishes that the person is allergic to here is a list {allergi}"),
|
$"Avoid item/dishes that the person is allergic to here is a list {allergi}"),
|
||||||
new UserChatMessage(recipeDTO.Dish),
|
new UserChatMessage(recipeDTO.Dish),
|
||||||
];
|
];
|
||||||
|
|
||||||
// Here we send the mess messages to chatgpt
|
// Here we send the messages to chatgpt
|
||||||
ChatCompletion chat = await client.CompleteChatAsync(messages);
|
ChatCompletion chat = await client.CompleteChatAsync(messages);
|
||||||
|
|
||||||
return chat;
|
return chat;
|
||||||
|
Loading…
Reference in New Issue
Block a user