@huggingface/tasks 0.13.1-test → 0.13.1-test2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +4 -2
- package/src/dataset-libraries.ts +89 -0
- package/src/default-widget-inputs.ts +718 -0
- package/src/gguf.ts +40 -0
- package/src/hardware.ts +482 -0
- package/src/index.ts +59 -0
- package/src/library-to-tasks.ts +76 -0
- package/src/local-apps.ts +412 -0
- package/src/model-data.ts +149 -0
- package/src/model-libraries-downloads.ts +18 -0
- package/src/model-libraries-snippets.ts +1128 -0
- package/src/model-libraries.ts +820 -0
- package/src/pipelines.ts +698 -0
- package/src/snippets/common.ts +39 -0
- package/src/snippets/curl.spec.ts +94 -0
- package/src/snippets/curl.ts +120 -0
- package/src/snippets/index.ts +7 -0
- package/src/snippets/inputs.ts +167 -0
- package/src/snippets/js.spec.ts +148 -0
- package/src/snippets/js.ts +305 -0
- package/src/snippets/python.spec.ts +144 -0
- package/src/snippets/python.ts +321 -0
- package/src/snippets/types.ts +16 -0
- package/src/tasks/audio-classification/about.md +86 -0
- package/src/tasks/audio-classification/data.ts +81 -0
- package/src/tasks/audio-classification/inference.ts +52 -0
- package/src/tasks/audio-classification/spec/input.json +35 -0
- package/src/tasks/audio-classification/spec/output.json +11 -0
- package/src/tasks/audio-to-audio/about.md +56 -0
- package/src/tasks/audio-to-audio/data.ts +70 -0
- package/src/tasks/automatic-speech-recognition/about.md +90 -0
- package/src/tasks/automatic-speech-recognition/data.ts +82 -0
- package/src/tasks/automatic-speech-recognition/inference.ts +160 -0
- package/src/tasks/automatic-speech-recognition/spec/input.json +35 -0
- package/src/tasks/automatic-speech-recognition/spec/output.json +38 -0
- package/src/tasks/chat-completion/inference.ts +322 -0
- package/src/tasks/chat-completion/spec/input.json +350 -0
- package/src/tasks/chat-completion/spec/output.json +206 -0
- package/src/tasks/chat-completion/spec/stream_output.json +213 -0
- package/src/tasks/common-definitions.json +100 -0
- package/src/tasks/depth-estimation/about.md +45 -0
- package/src/tasks/depth-estimation/data.ts +70 -0
- package/src/tasks/depth-estimation/inference.ts +35 -0
- package/src/tasks/depth-estimation/spec/input.json +25 -0
- package/src/tasks/depth-estimation/spec/output.json +16 -0
- package/src/tasks/document-question-answering/about.md +53 -0
- package/src/tasks/document-question-answering/data.ts +85 -0
- package/src/tasks/document-question-answering/inference.ts +110 -0
- package/src/tasks/document-question-answering/spec/input.json +85 -0
- package/src/tasks/document-question-answering/spec/output.json +36 -0
- package/src/tasks/feature-extraction/about.md +72 -0
- package/src/tasks/feature-extraction/data.ts +57 -0
- package/src/tasks/feature-extraction/inference.ts +40 -0
- package/src/tasks/feature-extraction/spec/input.json +47 -0
- package/src/tasks/feature-extraction/spec/output.json +15 -0
- package/src/tasks/fill-mask/about.md +51 -0
- package/src/tasks/fill-mask/data.ts +79 -0
- package/src/tasks/fill-mask/inference.ts +62 -0
- package/src/tasks/fill-mask/spec/input.json +38 -0
- package/src/tasks/fill-mask/spec/output.json +29 -0
- package/src/tasks/image-classification/about.md +50 -0
- package/src/tasks/image-classification/data.ts +88 -0
- package/src/tasks/image-classification/inference.ts +52 -0
- package/src/tasks/image-classification/spec/input.json +35 -0
- package/src/tasks/image-classification/spec/output.json +11 -0
- package/src/tasks/image-feature-extraction/about.md +23 -0
- package/src/tasks/image-feature-extraction/data.ts +59 -0
- package/src/tasks/image-segmentation/about.md +63 -0
- package/src/tasks/image-segmentation/data.ts +99 -0
- package/src/tasks/image-segmentation/inference.ts +69 -0
- package/src/tasks/image-segmentation/spec/input.json +45 -0
- package/src/tasks/image-segmentation/spec/output.json +26 -0
- package/src/tasks/image-text-to-text/about.md +76 -0
- package/src/tasks/image-text-to-text/data.ts +102 -0
- package/src/tasks/image-to-3d/about.md +62 -0
- package/src/tasks/image-to-3d/data.ts +75 -0
- package/src/tasks/image-to-image/about.md +129 -0
- package/src/tasks/image-to-image/data.ts +101 -0
- package/src/tasks/image-to-image/inference.ts +68 -0
- package/src/tasks/image-to-image/spec/input.json +55 -0
- package/src/tasks/image-to-image/spec/output.json +12 -0
- package/src/tasks/image-to-text/about.md +61 -0
- package/src/tasks/image-to-text/data.ts +82 -0
- package/src/tasks/image-to-text/inference.ts +143 -0
- package/src/tasks/image-to-text/spec/input.json +34 -0
- package/src/tasks/image-to-text/spec/output.json +14 -0
- package/src/tasks/index.ts +312 -0
- package/src/tasks/keypoint-detection/about.md +57 -0
- package/src/tasks/keypoint-detection/data.ts +50 -0
- package/src/tasks/mask-generation/about.md +65 -0
- package/src/tasks/mask-generation/data.ts +55 -0
- package/src/tasks/object-detection/about.md +37 -0
- package/src/tasks/object-detection/data.ts +86 -0
- package/src/tasks/object-detection/inference.ts +75 -0
- package/src/tasks/object-detection/spec/input.json +31 -0
- package/src/tasks/object-detection/spec/output.json +50 -0
- package/src/tasks/placeholder/about.md +15 -0
- package/src/tasks/placeholder/data.ts +21 -0
- package/src/tasks/placeholder/spec/input.json +35 -0
- package/src/tasks/placeholder/spec/output.json +17 -0
- package/src/tasks/question-answering/about.md +56 -0
- package/src/tasks/question-answering/data.ts +75 -0
- package/src/tasks/question-answering/inference.ts +99 -0
- package/src/tasks/question-answering/spec/input.json +67 -0
- package/src/tasks/question-answering/spec/output.json +29 -0
- package/src/tasks/reinforcement-learning/about.md +167 -0
- package/src/tasks/reinforcement-learning/data.ts +75 -0
- package/src/tasks/sentence-similarity/about.md +97 -0
- package/src/tasks/sentence-similarity/data.ts +101 -0
- package/src/tasks/sentence-similarity/inference.ts +32 -0
- package/src/tasks/sentence-similarity/spec/input.json +40 -0
- package/src/tasks/sentence-similarity/spec/output.json +12 -0
- package/src/tasks/summarization/about.md +58 -0
- package/src/tasks/summarization/data.ts +76 -0
- package/src/tasks/summarization/inference.ts +57 -0
- package/src/tasks/summarization/spec/input.json +42 -0
- package/src/tasks/summarization/spec/output.json +14 -0
- package/src/tasks/table-question-answering/about.md +43 -0
- package/src/tasks/table-question-answering/data.ts +59 -0
- package/src/tasks/table-question-answering/inference.ts +61 -0
- package/src/tasks/table-question-answering/spec/input.json +44 -0
- package/src/tasks/table-question-answering/spec/output.json +40 -0
- package/src/tasks/tabular-classification/about.md +65 -0
- package/src/tasks/tabular-classification/data.ts +68 -0
- package/src/tasks/tabular-regression/about.md +87 -0
- package/src/tasks/tabular-regression/data.ts +57 -0
- package/src/tasks/text-classification/about.md +173 -0
- package/src/tasks/text-classification/data.ts +103 -0
- package/src/tasks/text-classification/inference.ts +51 -0
- package/src/tasks/text-classification/spec/input.json +35 -0
- package/src/tasks/text-classification/spec/output.json +11 -0
- package/src/tasks/text-generation/about.md +154 -0
- package/src/tasks/text-generation/data.ts +114 -0
- package/src/tasks/text-generation/inference.ts +200 -0
- package/src/tasks/text-generation/spec/input.json +219 -0
- package/src/tasks/text-generation/spec/output.json +179 -0
- package/src/tasks/text-generation/spec/stream_output.json +103 -0
- package/src/tasks/text-to-3d/about.md +62 -0
- package/src/tasks/text-to-3d/data.ts +56 -0
- package/src/tasks/text-to-audio/inference.ts +143 -0
- package/src/tasks/text-to-audio/spec/input.json +31 -0
- package/src/tasks/text-to-audio/spec/output.json +17 -0
- package/src/tasks/text-to-image/about.md +96 -0
- package/src/tasks/text-to-image/data.ts +100 -0
- package/src/tasks/text-to-image/inference.ts +75 -0
- package/src/tasks/text-to-image/spec/input.json +63 -0
- package/src/tasks/text-to-image/spec/output.json +13 -0
- package/src/tasks/text-to-speech/about.md +63 -0
- package/src/tasks/text-to-speech/data.ts +79 -0
- package/src/tasks/text-to-speech/inference.ts +145 -0
- package/src/tasks/text-to-speech/spec/input.json +31 -0
- package/src/tasks/text-to-speech/spec/output.json +7 -0
- package/src/tasks/text-to-video/about.md +41 -0
- package/src/tasks/text-to-video/data.ts +102 -0
- package/src/tasks/text2text-generation/inference.ts +55 -0
- package/src/tasks/text2text-generation/spec/input.json +55 -0
- package/src/tasks/text2text-generation/spec/output.json +14 -0
- package/src/tasks/token-classification/about.md +76 -0
- package/src/tasks/token-classification/data.ts +92 -0
- package/src/tasks/token-classification/inference.ts +85 -0
- package/src/tasks/token-classification/spec/input.json +65 -0
- package/src/tasks/token-classification/spec/output.json +37 -0
- package/src/tasks/translation/about.md +65 -0
- package/src/tasks/translation/data.ts +70 -0
- package/src/tasks/translation/inference.ts +67 -0
- package/src/tasks/translation/spec/input.json +50 -0
- package/src/tasks/translation/spec/output.json +14 -0
- package/src/tasks/unconditional-image-generation/about.md +50 -0
- package/src/tasks/unconditional-image-generation/data.ts +72 -0
- package/src/tasks/video-classification/about.md +37 -0
- package/src/tasks/video-classification/data.ts +84 -0
- package/src/tasks/video-classification/inference.ts +59 -0
- package/src/tasks/video-classification/spec/input.json +42 -0
- package/src/tasks/video-classification/spec/output.json +10 -0
- package/src/tasks/video-text-to-text/about.md +98 -0
- package/src/tasks/video-text-to-text/data.ts +66 -0
- package/src/tasks/visual-question-answering/about.md +48 -0
- package/src/tasks/visual-question-answering/data.ts +97 -0
- package/src/tasks/visual-question-answering/inference.ts +62 -0
- package/src/tasks/visual-question-answering/spec/input.json +41 -0
- package/src/tasks/visual-question-answering/spec/output.json +21 -0
- package/src/tasks/zero-shot-classification/about.md +40 -0
- package/src/tasks/zero-shot-classification/data.ts +70 -0
- package/src/tasks/zero-shot-classification/inference.ts +67 -0
- package/src/tasks/zero-shot-classification/spec/input.json +50 -0
- package/src/tasks/zero-shot-classification/spec/output.json +11 -0
- package/src/tasks/zero-shot-image-classification/about.md +75 -0
- package/src/tasks/zero-shot-image-classification/data.ts +84 -0
- package/src/tasks/zero-shot-image-classification/inference.ts +61 -0
- package/src/tasks/zero-shot-image-classification/spec/input.json +45 -0
- package/src/tasks/zero-shot-image-classification/spec/output.json +10 -0
- package/src/tasks/zero-shot-object-detection/about.md +45 -0
- package/src/tasks/zero-shot-object-detection/data.ts +67 -0
- package/src/tasks/zero-shot-object-detection/inference.ts +66 -0
- package/src/tasks/zero-shot-object-detection/spec/input.json +40 -0
- package/src/tasks/zero-shot-object-detection/spec/output.json +47 -0
- package/src/tokenizer-data.ts +32 -0
- package/src/widget-example.ts +125 -0
package/src/pipelines.ts
ADDED
|
@@ -0,0 +1,698 @@
|
|
|
1
|
+
export const MODALITIES = ["multimodal", "nlp", "cv", "audio", "tabular", "rl", "other"] as const;
|
|
2
|
+
|
|
3
|
+
export type Modality = (typeof MODALITIES)[number];
|
|
4
|
+
|
|
5
|
+
export const MODALITY_LABELS = {
|
|
6
|
+
multimodal: "Multimodal",
|
|
7
|
+
nlp: "Natural Language Processing",
|
|
8
|
+
audio: "Audio",
|
|
9
|
+
cv: "Computer Vision",
|
|
10
|
+
rl: "Reinforcement Learning",
|
|
11
|
+
tabular: "Tabular",
|
|
12
|
+
other: "Other",
|
|
13
|
+
} satisfies Record<Modality, string>;
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* Public interface for a sub task.
|
|
17
|
+
*
|
|
18
|
+
* This can be used in a model card's `model-index` metadata.
|
|
19
|
+
* and is more granular classification that can grow significantly
|
|
20
|
+
* over time as new tasks are added.
|
|
21
|
+
*/
|
|
22
|
+
export interface SubTask {
|
|
23
|
+
/**
|
|
24
|
+
* type of the task (e.g. audio-source-separation)
|
|
25
|
+
*/
|
|
26
|
+
type: string;
|
|
27
|
+
/**
|
|
28
|
+
* displayed name of the task (e.g. Audio Source Separation)
|
|
29
|
+
*/
|
|
30
|
+
name: string;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* Public interface for a PipelineData.
|
|
35
|
+
*
|
|
36
|
+
* This information corresponds to a pipeline type (aka task)
|
|
37
|
+
* in the Hub.
|
|
38
|
+
*/
|
|
39
|
+
export interface PipelineData {
|
|
40
|
+
/**
|
|
41
|
+
* displayed name of the task (e.g. Text Classification)
|
|
42
|
+
*/
|
|
43
|
+
name: string;
|
|
44
|
+
subtasks?: SubTask[];
|
|
45
|
+
modality: Modality;
|
|
46
|
+
/**
|
|
47
|
+
* color for the tag icon.
|
|
48
|
+
*/
|
|
49
|
+
color: "blue" | "green" | "indigo" | "orange" | "red" | "yellow";
|
|
50
|
+
/**
|
|
51
|
+
* whether to hide in /models filters
|
|
52
|
+
*/
|
|
53
|
+
hideInModels?: boolean;
|
|
54
|
+
/**
|
|
55
|
+
* whether to hide in /datasets filters
|
|
56
|
+
*/
|
|
57
|
+
hideInDatasets?: boolean;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/// Coarse-grained taxonomy of tasks
|
|
61
|
+
///
|
|
62
|
+
/// This type is used in multiple places in the Hugging Face
|
|
63
|
+
/// ecosystem:
|
|
64
|
+
/// - To determine which widget to show.
|
|
65
|
+
/// - To determine which endpoint of Inference Endpoints to use.
|
|
66
|
+
/// - As filters at the left of models and datasets page.
|
|
67
|
+
///
|
|
68
|
+
/// Note that this is sensitive to order.
|
|
69
|
+
/// For each domain, the order should be of decreasing specificity.
|
|
70
|
+
/// This will impact the default pipeline tag of a model when not
|
|
71
|
+
/// specified.
|
|
72
|
+
export const PIPELINE_DATA = {
|
|
73
|
+
"text-classification": {
|
|
74
|
+
name: "Text Classification",
|
|
75
|
+
subtasks: [
|
|
76
|
+
{
|
|
77
|
+
type: "acceptability-classification",
|
|
78
|
+
name: "Acceptability Classification",
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
type: "entity-linking-classification",
|
|
82
|
+
name: "Entity Linking Classification",
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
type: "fact-checking",
|
|
86
|
+
name: "Fact Checking",
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
type: "intent-classification",
|
|
90
|
+
name: "Intent Classification",
|
|
91
|
+
},
|
|
92
|
+
{
|
|
93
|
+
type: "language-identification",
|
|
94
|
+
name: "Language Identification",
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
type: "multi-class-classification",
|
|
98
|
+
name: "Multi Class Classification",
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
type: "multi-label-classification",
|
|
102
|
+
name: "Multi Label Classification",
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
type: "multi-input-text-classification",
|
|
106
|
+
name: "Multi-input Text Classification",
|
|
107
|
+
},
|
|
108
|
+
{
|
|
109
|
+
type: "natural-language-inference",
|
|
110
|
+
name: "Natural Language Inference",
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
type: "semantic-similarity-classification",
|
|
114
|
+
name: "Semantic Similarity Classification",
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
type: "sentiment-classification",
|
|
118
|
+
name: "Sentiment Classification",
|
|
119
|
+
},
|
|
120
|
+
{
|
|
121
|
+
type: "topic-classification",
|
|
122
|
+
name: "Topic Classification",
|
|
123
|
+
},
|
|
124
|
+
{
|
|
125
|
+
type: "semantic-similarity-scoring",
|
|
126
|
+
name: "Semantic Similarity Scoring",
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
type: "sentiment-scoring",
|
|
130
|
+
name: "Sentiment Scoring",
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
type: "sentiment-analysis",
|
|
134
|
+
name: "Sentiment Analysis",
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
type: "hate-speech-detection",
|
|
138
|
+
name: "Hate Speech Detection",
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
type: "text-scoring",
|
|
142
|
+
name: "Text Scoring",
|
|
143
|
+
},
|
|
144
|
+
],
|
|
145
|
+
modality: "nlp",
|
|
146
|
+
color: "orange",
|
|
147
|
+
},
|
|
148
|
+
"token-classification": {
|
|
149
|
+
name: "Token Classification",
|
|
150
|
+
subtasks: [
|
|
151
|
+
{
|
|
152
|
+
type: "named-entity-recognition",
|
|
153
|
+
name: "Named Entity Recognition",
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
type: "part-of-speech",
|
|
157
|
+
name: "Part of Speech",
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
type: "parsing",
|
|
161
|
+
name: "Parsing",
|
|
162
|
+
},
|
|
163
|
+
{
|
|
164
|
+
type: "lemmatization",
|
|
165
|
+
name: "Lemmatization",
|
|
166
|
+
},
|
|
167
|
+
{
|
|
168
|
+
type: "word-sense-disambiguation",
|
|
169
|
+
name: "Word Sense Disambiguation",
|
|
170
|
+
},
|
|
171
|
+
{
|
|
172
|
+
type: "coreference-resolution",
|
|
173
|
+
name: "Coreference-resolution",
|
|
174
|
+
},
|
|
175
|
+
],
|
|
176
|
+
modality: "nlp",
|
|
177
|
+
color: "blue",
|
|
178
|
+
},
|
|
179
|
+
"table-question-answering": {
|
|
180
|
+
name: "Table Question Answering",
|
|
181
|
+
modality: "nlp",
|
|
182
|
+
color: "green",
|
|
183
|
+
},
|
|
184
|
+
"question-answering": {
|
|
185
|
+
name: "Question Answering",
|
|
186
|
+
subtasks: [
|
|
187
|
+
{
|
|
188
|
+
type: "extractive-qa",
|
|
189
|
+
name: "Extractive QA",
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
type: "open-domain-qa",
|
|
193
|
+
name: "Open Domain QA",
|
|
194
|
+
},
|
|
195
|
+
{
|
|
196
|
+
type: "closed-domain-qa",
|
|
197
|
+
name: "Closed Domain QA",
|
|
198
|
+
},
|
|
199
|
+
],
|
|
200
|
+
modality: "nlp",
|
|
201
|
+
color: "blue",
|
|
202
|
+
},
|
|
203
|
+
"zero-shot-classification": {
|
|
204
|
+
name: "Zero-Shot Classification",
|
|
205
|
+
modality: "nlp",
|
|
206
|
+
color: "yellow",
|
|
207
|
+
},
|
|
208
|
+
translation: {
|
|
209
|
+
name: "Translation",
|
|
210
|
+
modality: "nlp",
|
|
211
|
+
color: "green",
|
|
212
|
+
},
|
|
213
|
+
summarization: {
|
|
214
|
+
name: "Summarization",
|
|
215
|
+
subtasks: [
|
|
216
|
+
{
|
|
217
|
+
type: "news-articles-summarization",
|
|
218
|
+
name: "News Articles Summarization",
|
|
219
|
+
},
|
|
220
|
+
{
|
|
221
|
+
type: "news-articles-headline-generation",
|
|
222
|
+
name: "News Articles Headline Generation",
|
|
223
|
+
},
|
|
224
|
+
],
|
|
225
|
+
modality: "nlp",
|
|
226
|
+
color: "indigo",
|
|
227
|
+
},
|
|
228
|
+
"feature-extraction": {
|
|
229
|
+
name: "Feature Extraction",
|
|
230
|
+
modality: "nlp",
|
|
231
|
+
color: "red",
|
|
232
|
+
},
|
|
233
|
+
"text-generation": {
|
|
234
|
+
name: "Text Generation",
|
|
235
|
+
subtasks: [
|
|
236
|
+
{
|
|
237
|
+
type: "dialogue-modeling",
|
|
238
|
+
name: "Dialogue Modeling",
|
|
239
|
+
},
|
|
240
|
+
{
|
|
241
|
+
type: "dialogue-generation",
|
|
242
|
+
name: "Dialogue Generation",
|
|
243
|
+
},
|
|
244
|
+
{
|
|
245
|
+
type: "conversational",
|
|
246
|
+
name: "Conversational",
|
|
247
|
+
},
|
|
248
|
+
{
|
|
249
|
+
type: "language-modeling",
|
|
250
|
+
name: "Language Modeling",
|
|
251
|
+
},
|
|
252
|
+
],
|
|
253
|
+
modality: "nlp",
|
|
254
|
+
color: "indigo",
|
|
255
|
+
},
|
|
256
|
+
"text2text-generation": {
|
|
257
|
+
name: "Text2Text Generation",
|
|
258
|
+
subtasks: [
|
|
259
|
+
{
|
|
260
|
+
type: "text-simplification",
|
|
261
|
+
name: "Text simplification",
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
type: "explanation-generation",
|
|
265
|
+
name: "Explanation Generation",
|
|
266
|
+
},
|
|
267
|
+
{
|
|
268
|
+
type: "abstractive-qa",
|
|
269
|
+
name: "Abstractive QA",
|
|
270
|
+
},
|
|
271
|
+
{
|
|
272
|
+
type: "open-domain-abstractive-qa",
|
|
273
|
+
name: "Open Domain Abstractive QA",
|
|
274
|
+
},
|
|
275
|
+
{
|
|
276
|
+
type: "closed-domain-qa",
|
|
277
|
+
name: "Closed Domain QA",
|
|
278
|
+
},
|
|
279
|
+
{
|
|
280
|
+
type: "open-book-qa",
|
|
281
|
+
name: "Open Book QA",
|
|
282
|
+
},
|
|
283
|
+
{
|
|
284
|
+
type: "closed-book-qa",
|
|
285
|
+
name: "Closed Book QA",
|
|
286
|
+
},
|
|
287
|
+
],
|
|
288
|
+
modality: "nlp",
|
|
289
|
+
color: "indigo",
|
|
290
|
+
},
|
|
291
|
+
"fill-mask": {
|
|
292
|
+
name: "Fill-Mask",
|
|
293
|
+
subtasks: [
|
|
294
|
+
{
|
|
295
|
+
type: "slot-filling",
|
|
296
|
+
name: "Slot Filling",
|
|
297
|
+
},
|
|
298
|
+
{
|
|
299
|
+
type: "masked-language-modeling",
|
|
300
|
+
name: "Masked Language Modeling",
|
|
301
|
+
},
|
|
302
|
+
],
|
|
303
|
+
modality: "nlp",
|
|
304
|
+
color: "red",
|
|
305
|
+
},
|
|
306
|
+
"sentence-similarity": {
|
|
307
|
+
name: "Sentence Similarity",
|
|
308
|
+
modality: "nlp",
|
|
309
|
+
color: "yellow",
|
|
310
|
+
},
|
|
311
|
+
"text-to-speech": {
|
|
312
|
+
name: "Text-to-Speech",
|
|
313
|
+
modality: "audio",
|
|
314
|
+
color: "yellow",
|
|
315
|
+
},
|
|
316
|
+
"text-to-audio": {
|
|
317
|
+
name: "Text-to-Audio",
|
|
318
|
+
modality: "audio",
|
|
319
|
+
color: "yellow",
|
|
320
|
+
},
|
|
321
|
+
"automatic-speech-recognition": {
|
|
322
|
+
name: "Automatic Speech Recognition",
|
|
323
|
+
modality: "audio",
|
|
324
|
+
color: "yellow",
|
|
325
|
+
},
|
|
326
|
+
"audio-to-audio": {
|
|
327
|
+
name: "Audio-to-Audio",
|
|
328
|
+
modality: "audio",
|
|
329
|
+
color: "blue",
|
|
330
|
+
},
|
|
331
|
+
"audio-classification": {
|
|
332
|
+
name: "Audio Classification",
|
|
333
|
+
subtasks: [
|
|
334
|
+
{
|
|
335
|
+
type: "keyword-spotting",
|
|
336
|
+
name: "Keyword Spotting",
|
|
337
|
+
},
|
|
338
|
+
{
|
|
339
|
+
type: "speaker-identification",
|
|
340
|
+
name: "Speaker Identification",
|
|
341
|
+
},
|
|
342
|
+
{
|
|
343
|
+
type: "audio-intent-classification",
|
|
344
|
+
name: "Audio Intent Classification",
|
|
345
|
+
},
|
|
346
|
+
{
|
|
347
|
+
type: "audio-emotion-recognition",
|
|
348
|
+
name: "Audio Emotion Recognition",
|
|
349
|
+
},
|
|
350
|
+
{
|
|
351
|
+
type: "audio-language-identification",
|
|
352
|
+
name: "Audio Language Identification",
|
|
353
|
+
},
|
|
354
|
+
],
|
|
355
|
+
modality: "audio",
|
|
356
|
+
color: "green",
|
|
357
|
+
},
|
|
358
|
+
"voice-activity-detection": {
|
|
359
|
+
name: "Voice Activity Detection",
|
|
360
|
+
modality: "audio",
|
|
361
|
+
color: "red",
|
|
362
|
+
},
|
|
363
|
+
"depth-estimation": {
|
|
364
|
+
name: "Depth Estimation",
|
|
365
|
+
modality: "cv",
|
|
366
|
+
color: "yellow",
|
|
367
|
+
},
|
|
368
|
+
"image-classification": {
|
|
369
|
+
name: "Image Classification",
|
|
370
|
+
subtasks: [
|
|
371
|
+
{
|
|
372
|
+
type: "multi-label-image-classification",
|
|
373
|
+
name: "Multi Label Image Classification",
|
|
374
|
+
},
|
|
375
|
+
{
|
|
376
|
+
type: "multi-class-image-classification",
|
|
377
|
+
name: "Multi Class Image Classification",
|
|
378
|
+
},
|
|
379
|
+
],
|
|
380
|
+
modality: "cv",
|
|
381
|
+
color: "blue",
|
|
382
|
+
},
|
|
383
|
+
"object-detection": {
|
|
384
|
+
name: "Object Detection",
|
|
385
|
+
subtasks: [
|
|
386
|
+
{
|
|
387
|
+
type: "face-detection",
|
|
388
|
+
name: "Face Detection",
|
|
389
|
+
},
|
|
390
|
+
{
|
|
391
|
+
type: "vehicle-detection",
|
|
392
|
+
name: "Vehicle Detection",
|
|
393
|
+
},
|
|
394
|
+
],
|
|
395
|
+
modality: "cv",
|
|
396
|
+
color: "yellow",
|
|
397
|
+
},
|
|
398
|
+
"image-segmentation": {
|
|
399
|
+
name: "Image Segmentation",
|
|
400
|
+
subtasks: [
|
|
401
|
+
{
|
|
402
|
+
type: "instance-segmentation",
|
|
403
|
+
name: "Instance Segmentation",
|
|
404
|
+
},
|
|
405
|
+
{
|
|
406
|
+
type: "semantic-segmentation",
|
|
407
|
+
name: "Semantic Segmentation",
|
|
408
|
+
},
|
|
409
|
+
{
|
|
410
|
+
type: "panoptic-segmentation",
|
|
411
|
+
name: "Panoptic Segmentation",
|
|
412
|
+
},
|
|
413
|
+
],
|
|
414
|
+
modality: "cv",
|
|
415
|
+
color: "green",
|
|
416
|
+
},
|
|
417
|
+
"text-to-image": {
|
|
418
|
+
name: "Text-to-Image",
|
|
419
|
+
modality: "cv",
|
|
420
|
+
color: "yellow",
|
|
421
|
+
},
|
|
422
|
+
"image-to-text": {
|
|
423
|
+
name: "Image-to-Text",
|
|
424
|
+
subtasks: [
|
|
425
|
+
{
|
|
426
|
+
type: "image-captioning",
|
|
427
|
+
name: "Image Captioning",
|
|
428
|
+
},
|
|
429
|
+
],
|
|
430
|
+
modality: "cv",
|
|
431
|
+
color: "red",
|
|
432
|
+
},
|
|
433
|
+
"image-to-image": {
|
|
434
|
+
name: "Image-to-Image",
|
|
435
|
+
subtasks: [
|
|
436
|
+
{
|
|
437
|
+
type: "image-inpainting",
|
|
438
|
+
name: "Image Inpainting",
|
|
439
|
+
},
|
|
440
|
+
{
|
|
441
|
+
type: "image-colorization",
|
|
442
|
+
name: "Image Colorization",
|
|
443
|
+
},
|
|
444
|
+
{
|
|
445
|
+
type: "super-resolution",
|
|
446
|
+
name: "Super Resolution",
|
|
447
|
+
},
|
|
448
|
+
],
|
|
449
|
+
modality: "cv",
|
|
450
|
+
color: "indigo",
|
|
451
|
+
},
|
|
452
|
+
"image-to-video": {
|
|
453
|
+
name: "Image-to-Video",
|
|
454
|
+
modality: "cv",
|
|
455
|
+
color: "indigo",
|
|
456
|
+
},
|
|
457
|
+
"unconditional-image-generation": {
|
|
458
|
+
name: "Unconditional Image Generation",
|
|
459
|
+
modality: "cv",
|
|
460
|
+
color: "green",
|
|
461
|
+
},
|
|
462
|
+
"video-classification": {
|
|
463
|
+
name: "Video Classification",
|
|
464
|
+
modality: "cv",
|
|
465
|
+
color: "blue",
|
|
466
|
+
},
|
|
467
|
+
"reinforcement-learning": {
|
|
468
|
+
name: "Reinforcement Learning",
|
|
469
|
+
modality: "rl",
|
|
470
|
+
color: "red",
|
|
471
|
+
},
|
|
472
|
+
robotics: {
|
|
473
|
+
name: "Robotics",
|
|
474
|
+
modality: "rl",
|
|
475
|
+
subtasks: [
|
|
476
|
+
{
|
|
477
|
+
type: "grasping",
|
|
478
|
+
name: "Grasping",
|
|
479
|
+
},
|
|
480
|
+
{
|
|
481
|
+
type: "task-planning",
|
|
482
|
+
name: "Task Planning",
|
|
483
|
+
},
|
|
484
|
+
],
|
|
485
|
+
color: "blue",
|
|
486
|
+
},
|
|
487
|
+
"tabular-classification": {
|
|
488
|
+
name: "Tabular Classification",
|
|
489
|
+
modality: "tabular",
|
|
490
|
+
subtasks: [
|
|
491
|
+
{
|
|
492
|
+
type: "tabular-multi-class-classification",
|
|
493
|
+
name: "Tabular Multi Class Classification",
|
|
494
|
+
},
|
|
495
|
+
{
|
|
496
|
+
type: "tabular-multi-label-classification",
|
|
497
|
+
name: "Tabular Multi Label Classification",
|
|
498
|
+
},
|
|
499
|
+
],
|
|
500
|
+
color: "blue",
|
|
501
|
+
},
|
|
502
|
+
"tabular-regression": {
|
|
503
|
+
name: "Tabular Regression",
|
|
504
|
+
modality: "tabular",
|
|
505
|
+
subtasks: [
|
|
506
|
+
{
|
|
507
|
+
type: "tabular-single-column-regression",
|
|
508
|
+
name: "Tabular Single Column Regression",
|
|
509
|
+
},
|
|
510
|
+
],
|
|
511
|
+
color: "blue",
|
|
512
|
+
},
|
|
513
|
+
"tabular-to-text": {
|
|
514
|
+
name: "Tabular to Text",
|
|
515
|
+
modality: "tabular",
|
|
516
|
+
subtasks: [
|
|
517
|
+
{
|
|
518
|
+
type: "rdf-to-text",
|
|
519
|
+
name: "RDF to text",
|
|
520
|
+
},
|
|
521
|
+
],
|
|
522
|
+
color: "blue",
|
|
523
|
+
hideInModels: true,
|
|
524
|
+
},
|
|
525
|
+
"table-to-text": {
|
|
526
|
+
name: "Table to Text",
|
|
527
|
+
modality: "nlp",
|
|
528
|
+
color: "blue",
|
|
529
|
+
hideInModels: true,
|
|
530
|
+
},
|
|
531
|
+
"multiple-choice": {
|
|
532
|
+
name: "Multiple Choice",
|
|
533
|
+
subtasks: [
|
|
534
|
+
{
|
|
535
|
+
type: "multiple-choice-qa",
|
|
536
|
+
name: "Multiple Choice QA",
|
|
537
|
+
},
|
|
538
|
+
{
|
|
539
|
+
type: "multiple-choice-coreference-resolution",
|
|
540
|
+
name: "Multiple Choice Coreference Resolution",
|
|
541
|
+
},
|
|
542
|
+
],
|
|
543
|
+
modality: "nlp",
|
|
544
|
+
color: "blue",
|
|
545
|
+
hideInModels: true,
|
|
546
|
+
},
|
|
547
|
+
"text-retrieval": {
|
|
548
|
+
name: "Text Retrieval",
|
|
549
|
+
subtasks: [
|
|
550
|
+
{
|
|
551
|
+
type: "document-retrieval",
|
|
552
|
+
name: "Document Retrieval",
|
|
553
|
+
},
|
|
554
|
+
{
|
|
555
|
+
type: "utterance-retrieval",
|
|
556
|
+
name: "Utterance Retrieval",
|
|
557
|
+
},
|
|
558
|
+
{
|
|
559
|
+
type: "entity-linking-retrieval",
|
|
560
|
+
name: "Entity Linking Retrieval",
|
|
561
|
+
},
|
|
562
|
+
{
|
|
563
|
+
type: "fact-checking-retrieval",
|
|
564
|
+
name: "Fact Checking Retrieval",
|
|
565
|
+
},
|
|
566
|
+
],
|
|
567
|
+
modality: "nlp",
|
|
568
|
+
color: "indigo",
|
|
569
|
+
hideInModels: true,
|
|
570
|
+
},
|
|
571
|
+
"time-series-forecasting": {
|
|
572
|
+
name: "Time Series Forecasting",
|
|
573
|
+
modality: "tabular",
|
|
574
|
+
subtasks: [
|
|
575
|
+
{
|
|
576
|
+
type: "univariate-time-series-forecasting",
|
|
577
|
+
name: "Univariate Time Series Forecasting",
|
|
578
|
+
},
|
|
579
|
+
{
|
|
580
|
+
type: "multivariate-time-series-forecasting",
|
|
581
|
+
name: "Multivariate Time Series Forecasting",
|
|
582
|
+
},
|
|
583
|
+
],
|
|
584
|
+
color: "blue",
|
|
585
|
+
},
|
|
586
|
+
"text-to-video": {
|
|
587
|
+
name: "Text-to-Video",
|
|
588
|
+
modality: "cv",
|
|
589
|
+
color: "green",
|
|
590
|
+
},
|
|
591
|
+
"image-text-to-text": {
|
|
592
|
+
name: "Image-Text-to-Text",
|
|
593
|
+
modality: "multimodal",
|
|
594
|
+
color: "red",
|
|
595
|
+
hideInDatasets: true,
|
|
596
|
+
},
|
|
597
|
+
"visual-question-answering": {
|
|
598
|
+
name: "Visual Question Answering",
|
|
599
|
+
subtasks: [
|
|
600
|
+
{
|
|
601
|
+
type: "visual-question-answering",
|
|
602
|
+
name: "Visual Question Answering",
|
|
603
|
+
},
|
|
604
|
+
],
|
|
605
|
+
modality: "multimodal",
|
|
606
|
+
color: "red",
|
|
607
|
+
},
|
|
608
|
+
"document-question-answering": {
|
|
609
|
+
name: "Document Question Answering",
|
|
610
|
+
subtasks: [
|
|
611
|
+
{
|
|
612
|
+
type: "document-question-answering",
|
|
613
|
+
name: "Document Question Answering",
|
|
614
|
+
},
|
|
615
|
+
],
|
|
616
|
+
modality: "multimodal",
|
|
617
|
+
color: "blue",
|
|
618
|
+
hideInDatasets: true,
|
|
619
|
+
},
|
|
620
|
+
"zero-shot-image-classification": {
|
|
621
|
+
name: "Zero-Shot Image Classification",
|
|
622
|
+
modality: "cv",
|
|
623
|
+
color: "yellow",
|
|
624
|
+
},
|
|
625
|
+
"graph-ml": {
|
|
626
|
+
name: "Graph Machine Learning",
|
|
627
|
+
modality: "other",
|
|
628
|
+
color: "green",
|
|
629
|
+
},
|
|
630
|
+
"mask-generation": {
|
|
631
|
+
name: "Mask Generation",
|
|
632
|
+
modality: "cv",
|
|
633
|
+
color: "indigo",
|
|
634
|
+
},
|
|
635
|
+
"zero-shot-object-detection": {
|
|
636
|
+
name: "Zero-Shot Object Detection",
|
|
637
|
+
modality: "cv",
|
|
638
|
+
color: "yellow",
|
|
639
|
+
},
|
|
640
|
+
"text-to-3d": {
|
|
641
|
+
name: "Text-to-3D",
|
|
642
|
+
modality: "cv",
|
|
643
|
+
color: "yellow",
|
|
644
|
+
},
|
|
645
|
+
"image-to-3d": {
|
|
646
|
+
name: "Image-to-3D",
|
|
647
|
+
modality: "cv",
|
|
648
|
+
color: "green",
|
|
649
|
+
},
|
|
650
|
+
"image-feature-extraction": {
|
|
651
|
+
name: "Image Feature Extraction",
|
|
652
|
+
modality: "cv",
|
|
653
|
+
color: "indigo",
|
|
654
|
+
},
|
|
655
|
+
"video-text-to-text": {
|
|
656
|
+
name: "Video-Text-to-Text",
|
|
657
|
+
modality: "multimodal",
|
|
658
|
+
color: "blue",
|
|
659
|
+
hideInDatasets: false,
|
|
660
|
+
},
|
|
661
|
+
"keypoint-detection": {
|
|
662
|
+
name: "Keypoint Detection",
|
|
663
|
+
subtasks: [
|
|
664
|
+
{
|
|
665
|
+
type: "pose-estimation",
|
|
666
|
+
name: "Pose Estimation",
|
|
667
|
+
},
|
|
668
|
+
],
|
|
669
|
+
modality: "cv",
|
|
670
|
+
color: "red",
|
|
671
|
+
hideInDatasets: true,
|
|
672
|
+
},
|
|
673
|
+
"any-to-any": {
|
|
674
|
+
name: "Any-to-Any",
|
|
675
|
+
modality: "multimodal",
|
|
676
|
+
color: "yellow",
|
|
677
|
+
hideInDatasets: true,
|
|
678
|
+
},
|
|
679
|
+
other: {
|
|
680
|
+
name: "Other",
|
|
681
|
+
modality: "other",
|
|
682
|
+
color: "blue",
|
|
683
|
+
hideInModels: true,
|
|
684
|
+
hideInDatasets: true,
|
|
685
|
+
},
|
|
686
|
+
} satisfies Record<string, PipelineData>;
|
|
687
|
+
|
|
688
|
+
export type PipelineType = keyof typeof PIPELINE_DATA;
|
|
689
|
+
|
|
690
|
+
export type WidgetType = PipelineType | "conversational";
|
|
691
|
+
|
|
692
|
+
export const PIPELINE_TYPES = Object.keys(PIPELINE_DATA) as PipelineType[];
|
|
693
|
+
|
|
694
|
+
export const SUBTASK_TYPES = Object.values(PIPELINE_DATA)
|
|
695
|
+
.flatMap((data) => ("subtasks" in data ? data.subtasks : []))
|
|
696
|
+
.map((s) => s.type);
|
|
697
|
+
|
|
698
|
+
export const PIPELINE_TYPES_SET = new Set(PIPELINE_TYPES);
|