MCPcopy Create free account
hub / github.com/arctic-cli/interface / mimeToModality

Function mimeToModality

packages/arctic/src/provider/transform.ts:9–15  ·  view source on GitHub ↗
(mime: string)

Source from the content-addressed store, hash-verified

7type Modality = NonNullable<ModelsDev.Model["modalities"]>["input"][number]
8
9function mimeToModality(mime: string): Modality | undefined {
10 if (mime.startsWith("image/")) return "image"
11 if (mime.startsWith("audio/")) return "audio"
12 if (mime.startsWith("video/")) return "video"
13 if (mime === "application/pdf") return "pdf"
14 return undefined
15}
16
17export namespace ProviderTransform {
18

Callers 1

unsupportedPartsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected