pub enum Modality {
Iconic,
Symbolic,
Hybrid,
}Expand description
The semiotic modality of a signal source.
This captures a fundamental distinction in how meaning is encoded:
- Iconic: Physical resemblance (photos, audio waveforms)
- Symbolic: Arbitrary convention (text, notation)
- Indexical: Causal connection (smoke → fire, but rare in our domain)
§Why This Matters
The modality affects what linguistic features are relevant:
| Feature | Iconic (Vision) | Symbolic (Text) |
|---|---|---|
| Negation | No analogue | “not a doctor” |
| Quantification | Approximate | “every/some/no” |
| Recursion | Rare | Nested NPs |
| Compositionality | Limited | Full |
Detection in iconic modalities is more about geometry and physics. Detection in symbolic modalities requires cultural/linguistic knowledge.
Variants§
Iconic
Iconic sign: signifier resembles signified (images, audio). Detection is primarily geometric/physical.
Symbolic
Symbolic sign: arbitrary convention (text, notation). Detection requires linguistic/cultural knowledge.
Hybrid
Hybrid: OCR text in images, captions, etc. Has both iconic (visual layout) and symbolic (text content) aspects.
Implementations§
Source§impl Modality
impl Modality
Sourcepub const fn supports_linguistic_features(&self) -> bool
pub const fn supports_linguistic_features(&self) -> bool
Check if linguistic features (negation, quantification) are relevant.
Sourcepub const fn supports_geometric_features(&self) -> bool
pub const fn supports_geometric_features(&self) -> bool
Check if geometric features (bbox, IoU) are relevant.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Modality
impl<'de> Deserialize<'de> for Modality
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>,
Deserialize this value from the given Serde deserializer. Read more
impl Copy for Modality
impl Eq for Modality
impl StructuralPartialEq for Modality
Auto Trait Implementations§
impl Freeze for Modality
impl RefUnwindSafe for Modality
impl Send for Modality
impl Sync for Modality
impl Unpin for Modality
impl UnsafeUnpin for Modality
impl UnwindSafe for Modality
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