Skip to content

Commit 90ac2aa

Browse files
committed
Resolve merge conflicts
2 parents 04ab5f7 + 8f0a402 commit 90ac2aa

File tree

3 files changed

+18
-9
lines changed

3 files changed

+18
-9
lines changed

dotnet/src/Connectors/Connectors.OpenAI/AzureSdk/ClientCore.cs

+11-7
Original file line numberDiff line numberDiff line change
@@ -699,16 +699,20 @@ internal async IAsyncEnumerable<OpenAIStreamingChatMessageContent> GetStreamingC
699699
role = new AuthorRole(streamedRole.Value.ToString());
700700
}
701701

702-
OpenAIStreamingChatMessageContent openAIStreamingChatMessageContent = new(update, update.ChoiceIndex ?? 0, this.DeploymentOrModelName, metadata) { AuthorName = streamedName, Role = role, };
702+
OpenAIStreamingChatMessageContent openAIStreamingChatMessageContent =
703+
new(update, update.ChoiceIndex ?? 0, this.DeploymentOrModelName, metadata)
704+
{
705+
AuthorName = streamedName,
706+
Role = role,
707+
};
703708

704709
if (update.ToolCallUpdate is StreamingFunctionToolCallUpdate functionCallUpdate)
705710
{
706-
openAIStreamingChatMessageContent.Items.Add(
707-
new StreamingFunctionCallUpdateContent(
708-
callId: functionCallUpdate.Id,
709-
name: functionCallUpdate.Name,
710-
arguments: functionCallUpdate.ArgumentsUpdate,
711-
functionCallIndex: functionCallUpdate.ToolCallIndex));
711+
openAIStreamingChatMessageContent.Items.Add(new StreamingFunctionCallUpdateContent(
712+
callId: functionCallUpdate.Id,
713+
name: functionCallUpdate.Name,
714+
arguments: functionCallUpdate.ArgumentsUpdate,
715+
functionCallIndex: functionCallUpdate.ToolCallIndex));
712716
}
713717

714718
streamedContents?.Add(openAIStreamingChatMessageContent);

dotnet/src/IntegrationTests/Connectors/OpenAI/OpenAICompletionTests.cs

+5
Original file line numberDiff line numberDiff line change
@@ -128,6 +128,11 @@ public async Task AzureOpenAIStreamingTestAsync(bool useChatModel, string prompt
128128
// Act
129129
await foreach (var content in target.InvokeStreamingAsync<StreamingKernelContent>(plugins["ChatPlugin"]["Chat"], new() { [InputParameterName] = prompt }))
130130
{
131+
if (content is StreamingChatMessageContent messageContent)
132+
{
133+
Assert.NotNull(messageContent.Role);
134+
}
135+
131136
fullResult.Append(content);
132137
}
133138

python/DEV_SETUP.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ Read more about the extension here: https://github.com/astral-sh/ruff-vscode
157157
You can run the unit tests under the [tests/unit](tests/unit/) folder.
158158
159159
```bash
160-
poetry install
160+
poetry install --with unit-tests
161161
poetry run pytest tests/unit
162162
```
163163
@@ -167,7 +167,7 @@ Alternatively, you can run them using VSCode Tasks. Open the command palette
167167
You can run the integration tests under the [tests/integration](tests/integration/) folder.
168168
169169
```bash
170-
poetry install
170+
poetry install --with tests
171171
poetry run pytest tests/integration
172172
```
173173

0 commit comments

Comments
 (0)