Skip to content

Commit 837c4fa

Browse files
committed
fix code
1 parent 0c055d7 commit 837c4fa

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

articles/ai-services/openai/includes/gpt-v-dotnet.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,10 +100,14 @@ To run the quickstart, follow these steps:
100100
101101
var imageUrl = "YOUR_IMAGE_URL";
102102
103+
var textPart = ChatMessageContentPart.CreateTextPart("Describe this picture:");
104+
var imgPart = ChatMessageContentPart.CreateImagePart(imageUrl);
105+
103106
var chatMessages = new List<ChatMessage>
104107
{
105108
new SystemChatMessage("You are a helpful assistant."),
106-
new UserChatMessage($"Describe this picture: {imageUrl}")
109+
new UserChatMessage(textPart, imgPart)
110+
107111
};
108112
109113
ChatCompletion chatCompletion = await chatClient.CompleteChatAsync(chatMessages);

0 commit comments

Comments
 (0)