Generate a sparse embedding for the input data. Args: input (MD): Multimodal input data to embed. Can be: - TEXT (str): Text string - IMAGE (str | bytes | np.ndarray): Image file path, raw bytes, or array - AUDIO (str | bytes | np.
(self, input: MD)
| 132 | |
| 133 | @abstractmethod |
| 134 | def embed(self, input: MD) -> SparseVectorType: |
| 135 | """Generate a sparse embedding for the input data. |
| 136 | |
| 137 | Args: |
| 138 | input (MD): Multimodal input data to embed. Can be: |
| 139 | - TEXT (str): Text string |
| 140 | - IMAGE (str | bytes | np.ndarray): Image file path, raw bytes, or array |
| 141 | - AUDIO (str | bytes | np.ndarray): Audio file path, raw bytes, or array |
| 142 | |
| 143 | Returns: |
| 144 | SparseVectorType: Mapping from dimension index to non-zero weight. |
| 145 | Only dimensions with non-zero values are included. |
| 146 | """ |
| 147 | ... |
nothing calls this directly
no outgoing calls
no test coverage detected