pub struct ImageGenErrorInfo {
pub kind: &'static str,
pub code: Option<String>,
pub message: String,
pub retryable: bool,
}Expand description
Structured error info extracted from an ImageGenError, for returning
to the LLM in a machine-parseable form so it can decide whether to retry.
Fields§
§kind: &'static strError category.
One of: api_error, http_error, timeout, task_failed, parse_error.
code: Option<String>Provider-specific error code (only present for api_error).
message: StringHuman-readable error message.
retryable: boolWhether retrying the same request might succeed (e.g. rate limit,
transient network error). false for permission/parameter errors.
Trait Implementations§
Source§impl Clone for ImageGenErrorInfo
impl Clone for ImageGenErrorInfo
Auto Trait Implementations§
impl Freeze for ImageGenErrorInfo
impl RefUnwindSafe for ImageGenErrorInfo
impl Send for ImageGenErrorInfo
impl Sync for ImageGenErrorInfo
impl Unpin for ImageGenErrorInfo
impl UnsafeUnpin for ImageGenErrorInfo
impl UnwindSafe for ImageGenErrorInfo
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