pub struct SessionMeta {
pub provider_session_id: Option<String>,
pub cwd: Option<String>,
pub repo_root: Option<String>,
pub title: Option<String>,
pub updated_at: Option<DateTime<Utc>>,
pub last_message_at: Option<DateTime<Utc>>,
pub message_count: Option<i64>,
pub parse_warning: Option<String>,
pub parent_session_id: Option<String>,
pub agent_label: Option<String>,
}Expand description
Lightweight per-session metadata used to enrich message hits with human-readable
context (working dir / repo / title) in the MCP search_messages response, so an
agent can interpret and group results without a follow-up get_session per hit.
Kept off MessageHit so the CLI table rendering is unchanged; the MCP layer joins
it on via crate::db::Db::session_metadata.
Fields§
§provider_session_id: Option<String>§cwd: Option<String>§repo_root: Option<String>§title: Option<String>§updated_at: Option<DateTime<Utc>>§last_message_at: Option<DateTime<Utc>>§message_count: Option<i64>§parse_warning: Option<String>§parent_session_id: Option<String>The spawning session, mirroring SessionRecord::parent_session_id, or None for a
root run. Carried here because a hit’s session id alone cannot say whether it came from a
root conversation, a subagent run, or a compaction fragment, and answering that with a
follow-up query per session id defeats the deduplicated join this struct exists to be.
agent_label: Option<String>The spawned agent’s name, mirroring SessionRecord::agent_label. Display and grouping
only; the link is parent_session_id.
Trait Implementations§
Source§impl Clone for SessionMeta
impl Clone for SessionMeta
Source§impl Debug for SessionMeta
impl Debug for SessionMeta
Source§impl Default for SessionMeta
impl Default for SessionMeta
Auto Trait Implementations§
impl Freeze for SessionMeta
impl RefUnwindSafe for SessionMeta
impl Send for SessionMeta
impl Sync for SessionMeta
impl Unpin for SessionMeta
impl UnsafeUnpin for SessionMeta
impl UnwindSafe for SessionMeta
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more