Class FileManifest

java.lang.Object
com.tnsai.intelligence.rag.binding.FileManifest

public final class FileManifest extends Object
What one FILE-source load observed, per file, so the next load can reuse the files that did not change.

A manifest is immutable and opaque. FileSourceReconciler returns the manifest of each load; passing it back to the next reconcile lets that load skip reading files whose stat key is unchanged, and skip extraction, chunking and chunk-context enrichment for files whose bytes and pipeline fingerprint are unchanged.

The stat key is the size, the modification time, the file key and, on file systems with a unix attribute view, the inode change time (unix:ctime), which also moves on a permission change or on a write that restores the modification time. Where the change time is not available, a change that keeps size, modification time and file key is not seen until the bytes are read again. A file modified within two seconds of the load that recorded it is always read on the next load.

A manifest lives only in memory and is valid only in the JVM and for the FileIngestionService configuration that produced it.

Since:
0.18.7
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the manifest of a source that was never loaded; reconciling against it reads every file, as a cold load does.
    Returns a copy whose entries can no longer be reused, so the next reconcile reads and rebuilds every file while still reporting the chunks it replaces.
     

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Method Details

    • empty

      public static FileManifest empty()
      Returns the manifest of a source that was never loaded; reconciling against it reads every file, as a cold load does.
      Returns:
      the empty manifest
    • invalidated

      public FileManifest invalidated()
      Returns a copy whose entries can no longer be reused, so the next reconcile reads and rebuilds every file while still reporting the chunks it replaces.
      Returns:
      a manifest with the same files and no reusable entry
    • toString

      public String toString()
      Overrides:
      toString in class Object