assistant2: Avoid unnecessary String
cloning in tool use (#25725)
This PR removes some unnecessary `String` cloning in the tool use paths. We now store the data in `Arc<str>`s for cheap cloning. Release Notes: - N/A
This commit is contained in:
parent
da22f21dec
commit
e7df5ce61c
5 changed files with 19 additions and 16 deletions
|
@ -90,7 +90,7 @@ where
|
|||
#[derive(Debug, PartialEq, Eq, Hash, Clone, Serialize, Deserialize)]
|
||||
pub struct LanguageModelToolUse {
|
||||
pub id: LanguageModelToolUseId,
|
||||
pub name: String,
|
||||
pub name: Arc<str>,
|
||||
pub input: serde_json::Value,
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue