using AIStudio.Chat; namespace AIStudio.Assistants.Dynamic; public sealed class FileAttachmentState { public HashSet DocumentPaths { get; set; } = []; /// /// Creates a copy which shares nothing with this state. /// /// The copy. public FileAttachmentState Copy() => new() { DocumentPaths = new HashSet(this.DocumentPaths, this.DocumentPaths.Comparer) }; /// /// Tells whether another state holds the same files as this one. /// /// The state to compare with. /// true when both states hold the same files; otherwise, false. public bool HasSameInputsAs(FileAttachmentState other) => this.DocumentPaths.SetEquals(other.DocumentPaths); }