diff options
| author | sigoden <sigoden@gmail.com> | 2024-11-30 08:40:58 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-11-30 08:40:58 +0800 |
| commit | 50bbfc4541bf2cb2ecb28f2fed3b9b3ab7d5005b (patch) | |
| tree | 5eaa0a1092320dfceeb980a728cc943f0cc8c258 /src/config/session.rs | |
| parent | 580b40e895f6b5d4b9ee350bfd0066cfe4ae5bcc (diff) | |
| download | aichat-50bbfc4541bf2cb2ecb28f2fed3b9b3ab7d5005b.tar.gz | |
refactor: improve code regarding tools/agents (#1021)
Diffstat (limited to 'src/config/session.rs')
| -rw-r--r-- | src/config/session.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/config/session.rs b/src/config/session.rs index 23658fd..4b3da76 100644 --- a/src/config/session.rs +++ b/src/config/session.rs @@ -35,7 +35,7 @@ pub struct Session { #[serde(skip_serializing_if = "Option::is_none")] role_name: Option<String>, #[serde(default, skip_serializing_if = "IndexMap::is_empty")] - agent_variables: IndexMap<String, String>, + agent_variables: AgentVariables, #[serde(default, skip_serializing_if = "Vec::is_empty")] compressed_messages: Vec<Message>, @@ -284,7 +284,7 @@ impl Session { } } - pub fn agent_variables(&self) -> &IndexMap<String, String> { + pub fn agent_variables(&self) -> &AgentVariables { &self.agent_variables } |
