Skip to main content

Chunk

Struct Chunk 

Source
pub struct Chunk {
Show 23 fields pub id: String, pub project: String, pub agent: String, pub date: String, pub session_id: String, pub cwd: Option<String>, pub kind: Kind, pub frame_kind: Option<FrameKind>, pub run_id: Option<String>, pub prompt_id: Option<String>, pub agent_model: Option<String>, pub started_at: Option<String>, pub completed_at: Option<String>, pub token_usage: Option<u64>, pub findings_count: Option<u32>, pub workflow_phase: Option<String>, pub mode: Option<String>, pub skill_code: Option<String>, pub framework_version: Option<String>, pub msg_range: (usize, usize), pub text: String, pub token_estimate: usize, pub highlights: Vec<String>,
}
Expand description

A single chunk ready for vector indexing.

Fields§

§id: String

Unique ID: {project}_{agent}_{date}_{seq:03}

§project: String§agent: String§date: String

Date string (YYYY-MM-DD)

§session_id: String

Session ID from first message in chunk

§cwd: Option<String>

Working directory from the first message in the chunk window

§kind: Kind

Classified kind for this chunk’s content

§frame_kind: Option<FrameKind>

Stable stream/channel classification for the chunk contents.

§run_id: Option<String>

Optional correlation ID for the originating run

§prompt_id: Option<String>

Optional prompt or task identity for the originating run

§agent_model: Option<String>

Optional agent model reported by the source frontmatter

§started_at: Option<String>

Optional run start timestamp reported by the source frontmatter

§completed_at: Option<String>

Optional run completion timestamp reported by the source frontmatter

§token_usage: Option<u64>

Optional token usage reported by the source frontmatter

§findings_count: Option<u32>

Optional findings count reported by the source frontmatter

§workflow_phase: Option<String>

Optional workflow phase reported by the source frontmatter

§mode: Option<String>

Optional routing mode reported by the source frontmatter

§skill_code: Option<String>

Optional framework skill code reported by the source frontmatter

§framework_version: Option<String>

Optional steering schema/framework version reported by the source frontmatter

§msg_range: (usize, usize)

Index range in original day’s entries (start, end exclusive)

§text: String

Formatted chunk text with header

§token_estimate: usize

Estimated token count (~chars/4)

§highlights: Vec<String>

Decision/plan highlights extracted from the chunk

Trait Implementations§

Source§

impl Clone for Chunk

Source§

fn clone(&self) -> Chunk

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Chunk

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl From<&Chunk> for ChunkMetadataSidecar

Source§

fn from(chunk: &Chunk) -> Self

Converts to this type from the input type.

Auto Trait Implementations§

§

impl Freeze for Chunk

§

impl RefUnwindSafe for Chunk

§

impl Send for Chunk

§

impl Sync for Chunk

§

impl Unpin for Chunk

§

impl UnsafeUnpin for Chunk

§

impl UnwindSafe for Chunk

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.