Skip to content

Commit ebead66

Browse files
committed
added optional schema for backwards compatibility
1 parent a3622f8 commit ebead66

File tree

1 file changed

+6
-0
lines changed
  • crates/chat-cli/src/cli/agent

1 file changed

+6
-0
lines changed

crates/chat-cli/src/cli/agent/mod.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,12 @@ pub enum AgentConfigError {
129129
#[serde(rename_all = "camelCase", deny_unknown_fields)]
130130
#[schemars(description = "An Agent is a declarative way of configuring a given instance of q chat.")]
131131
pub struct Agent {
132+
#[serde(
133+
rename = "$schema",
134+
default = "default_schema",
135+
skip_serializing_if = "String::is_empty"
136+
)]
137+
pub schema: String,
132138
/// Name of the agent
133139
pub name: String,
134140
/// This field is not model facing and is mostly here for users to discern between agents

0 commit comments

Comments
 (0)