Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
dynamo
Commits
0c50a233
Unverified
Commit
0c50a233
authored
Aug 21, 2025
by
Graham King
Committed by
GitHub
Aug 21, 2025
Browse files
chore: Remove Clone / Sync from DeltaGenerator (#2598)
parent
923e1ee7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
27 deletions
+3
-27
lib/llm/src/protocols/openai.rs
lib/llm/src/protocols/openai.rs
+2
-14
lib/llm/src/protocols/openai/chat_completions/delta.rs
lib/llm/src/protocols/openai/chat_completions/delta.rs
+1
-13
No files found.
lib/llm/src/protocols/openai.rs
View file @
0c50a233
// SPDX-FileCopyrightText: Copyright (c) 2024-2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
// SPDX-FileCopyrightText: Copyright (c) 2024-2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
// SPDX-License-Identifier: Apache-2.0
// SPDX-License-Identifier: Apache-2.0
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
use
anyhow
::
Result
;
use
anyhow
::
Result
;
use
serde
::{
Deserialize
,
Serialize
};
use
serde
::{
Deserialize
,
Serialize
};
...
@@ -194,8 +182,8 @@ impl<T: OpenAIOutputOptionsProvider> OutputOptionsProvider for T {
...
@@ -194,8 +182,8 @@ impl<T: OpenAIOutputOptionsProvider> OutputOptionsProvider for T {
}
}
}
}
pub
trait
DeltaGeneratorExt
<
ResponseType
:
Send
+
Sync
+
'static
+
std
::
fmt
::
Debug
>
:
pub
trait
DeltaGeneratorExt
<
ResponseType
:
Send
+
'static
+
std
::
fmt
::
Debug
>
:
Send
+
Sync
+
'static
Send
+
'static
{
{
fn
choice_from_postprocessor
(
fn
choice_from_postprocessor
(
&
mut
self
,
&
mut
self
,
...
...
lib/llm/src/protocols/openai/chat_completions/delta.rs
View file @
0c50a233
// SPDX-FileCopyrightText: Copyright (c) 2024-2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
// SPDX-FileCopyrightText: Copyright (c) 2024-2025 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
// SPDX-License-Identifier: Apache-2.0
// SPDX-License-Identifier: Apache-2.0
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
use
super
::{
NvCreateChatCompletionRequest
,
NvCreateChatCompletionStreamResponse
};
use
super
::{
NvCreateChatCompletionRequest
,
NvCreateChatCompletionStreamResponse
};
use
crate
::{
use
crate
::{
...
@@ -46,7 +34,7 @@ pub struct DeltaGeneratorOptions {
...
@@ -46,7 +34,7 @@ pub struct DeltaGeneratorOptions {
}
}
/// Generates incremental chat completion responses in a streaming fashion.
/// Generates incremental chat completion responses in a streaming fashion.
#[derive(Debug
,
Clone
)]
#[derive(Debug)]
pub
struct
DeltaGenerator
{
pub
struct
DeltaGenerator
{
/// Unique identifier for the chat completion session.
/// Unique identifier for the chat completion session.
id
:
String
,
id
:
String
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment