From 4d1b9997c99daf587837ac6fcd8a6b93c8623fe5 Mon Sep 17 00:00:00 2001 From: Jicheng Lu <103353@smsassist.com> Date: Tue, 19 Aug 2025 12:01:27 -0500 Subject: [PATCH] override to string --- .../VectorStorage/Models/VectorFilterGroup.cs | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/src/Infrastructure/BotSharp.Abstraction/VectorStorage/Models/VectorFilterGroup.cs b/src/Infrastructure/BotSharp.Abstraction/VectorStorage/Models/VectorFilterGroup.cs index 7940b359..327645f9 100644 --- a/src/Infrastructure/BotSharp.Abstraction/VectorStorage/Models/VectorFilterGroup.cs +++ b/src/Infrastructure/BotSharp.Abstraction/VectorStorage/Models/VectorFilterGroup.cs @@ -39,6 +39,11 @@ public class VectorFilterMatch : KeyValue [JsonPropertyName("data_type")] public VectorPayloadDataType DataType { get; set; } = VectorPayloadDataType.String; + + public override string ToString() + { + return $"{Key} => {Value} ({DataType}), Operator: {Operator}"; + } } public class VectorFilterRange @@ -51,6 +56,16 @@ public class VectorFilterRange [JsonPropertyName("data_type")] public VectorPayloadDataType DataType { get; set; } = VectorPayloadDataType.String; + + public override string ToString() + { + var str = $"Data type: {DataType};"; + Conditions?.ForEach(x => + { + str += $"{Key} {x.Operator} {x.Value};"; + }); + return str; + } } public class VectorFilterRangeCondition @@ -63,4 +78,9 @@ public class VectorFilterRangeCondition /// [JsonPropertyName("operator")] public string Operator { get; set; } = "lt"; + + public override string ToString() + { + return $"Value: {Value}, Operator: {Operator}"; + } } \ No newline at end of file