pub struct WorkspaceReadImageSuccess {
pub ok: bool,
pub tool: String,
pub kind: String,
pub path: String,
pub source_format: String,
pub source_width: u32,
pub source_height: u32,
pub width: u32,
pub height: u32,
pub resized: bool,
pub source_bytes: usize,
pub png_bytes: usize,
}Expand description
Structured success envelope produced by read_file when reading an image.
The normalized PNG bytes themselves are attached to the tool outcome rather than embedded in this JSON envelope, keeping stored artifacts compact and avoiding duplicate base64 payloads.
Fields§
§ok: boolAlways true for a successful image read.
tool: StringStable tool name (read_file).
kind: StringContent kind discriminant (image).
path: StringNormalized display path (workspace-relative when inside the workspace root).
source_format: StringDetected source format (png, jpeg, gif, or webp).
source_width: u32Original decoded image width in pixels.
source_height: u32Original decoded image height in pixels.
width: u32Attached image width in pixels (equal to source_width when not resized).
height: u32Attached image height in pixels (equal to source_height when not resized).
resized: boolWhether the image was downscaled to fit vision dimension or byte budgets.
source_bytes: usizeByte length of the source file on disk.
png_bytes: usizeByte length of the normalized PNG attached to the model result.
Trait Implementations§
Source§impl Clone for WorkspaceReadImageSuccess
impl Clone for WorkspaceReadImageSuccess
Source§impl Debug for WorkspaceReadImageSuccess
impl Debug for WorkspaceReadImageSuccess
Source§impl<'de> Deserialize<'de> for WorkspaceReadImageSuccess
impl<'de> Deserialize<'de> for WorkspaceReadImageSuccess
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>,
impl Eq for WorkspaceReadImageSuccess
impl StructuralPartialEq for WorkspaceReadImageSuccess
Auto Trait Implementations§
impl Forget for WorkspaceReadImageSuccess
impl Freeze for WorkspaceReadImageSuccess
impl Move for WorkspaceReadImageSuccess
impl RefUnwindSafe for WorkspaceReadImageSuccess
impl Send for WorkspaceReadImageSuccesswhere
RawVecInner: Send,
impl Sync for WorkspaceReadImageSuccesswhere
RawVecInner: Sync,
impl Unpin for WorkspaceReadImageSuccess
impl UnsafeUnpin for WorkspaceReadImageSuccess
impl UnwindSafe for WorkspaceReadImageSuccesswhere
RawVecInner: UnwindSafe,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.