pub struct ArtifactIndex {
pub entries: HashMap<String, ArtifactEntry>,
}Expand description
Tracks files touched during a session, surviving compaction.
Records file operations (create, modify, read, delete) with metadata so the agent retains awareness of workspace state post-compaction.
Fields§
§entries: HashMap<String, ArtifactEntry>Implementations§
Source§impl ArtifactIndex
impl ArtifactIndex
pub fn new() -> Self
Sourcepub fn record(&mut self, file_path: &str, operation: &str, details: &str)
pub fn record(&mut self, file_path: &str, operation: &str, details: &str)
Record a file operation.
Sourcepub fn as_summary(&self) -> String
pub fn as_summary(&self) -> String
Format the artifact index as a compact summary for injection into compaction.
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
Trait Implementations§
Source§impl Clone for ArtifactIndex
impl Clone for ArtifactIndex
Source§fn clone(&self) -> ArtifactIndex
fn clone(&self) -> ArtifactIndex
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ArtifactIndex
impl Debug for ArtifactIndex
Source§impl Default for ArtifactIndex
impl Default for ArtifactIndex
Source§fn default() -> ArtifactIndex
fn default() -> ArtifactIndex
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for ArtifactIndex
impl<'de> Deserialize<'de> for ArtifactIndex
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for ArtifactIndex
impl RefUnwindSafe for ArtifactIndex
impl Send for ArtifactIndex
impl Sync for ArtifactIndex
impl Unpin for ArtifactIndex
impl UnsafeUnpin for ArtifactIndex
impl UnwindSafe for ArtifactIndex
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more