Debian Codegraph @

t/purl/types/huggingface-test.json

raw
1 {
2 "$schema": "https://packageurl.org/schemas/purl-test.schema-0.1.json",
3 "tests": [
4 {
5 "description": "minimal Hugging Face model. Roundtrip an input purl to canonical.",
6 "test_group": "advanced",
7 "test_type": "roundtrip",
8 "input": "pkg:huggingface/distilbert-base-uncased@043235d6088ecd3dd5fb5ca3592b6913fd516027",
9 "expected_output": "pkg:huggingface/distilbert-base-uncased@043235d6088ecd3dd5fb5ca3592b6913fd516027",
10 "expected_failure": false,
11 "expected_failure_reason": null
12 },
13 {
14 "description": "minimal Hugging Face model",
15 "test_group": "base",
16 "test_type": "parse",
17 "input": "pkg:huggingface/distilbert-base-uncased@043235d6088ecd3dd5fb5ca3592b6913fd516027",
18 "expected_output": {
19 "type": "huggingface",
20 "namespace": null,
21 "name": "distilbert-base-uncased",
22 "version": "043235d6088ecd3dd5fb5ca3592b6913fd516027",
23 "qualifiers": null,
24 "subpath": null
25 },
26 "expected_failure": false,
27 "expected_failure_reason": null
28 },
29 {
30 "description": "minimal Hugging Face model. Roundtrip a canonical input to canonical output.",
31 "test_group": "base",
32 "test_type": "roundtrip",
33 "input": "pkg:huggingface/distilbert-base-uncased@043235d6088ecd3dd5fb5ca3592b6913fd516027",
34 "expected_output": "pkg:huggingface/distilbert-base-uncased@043235d6088ecd3dd5fb5ca3592b6913fd516027",
35 "expected_failure": false,
36 "expected_failure_reason": null
37 },
38 {
39 "description": "minimal Hugging Face model",
40 "test_group": "base",
41 "test_type": "build",
42 "input": {
43 "type": "huggingface",
44 "namespace": null,
45 "name": "distilbert-base-uncased",
46 "version": "043235d6088ecd3dd5fb5ca3592b6913fd516027",
47 "qualifiers": null,
48 "subpath": null
49 },
50 "expected_output": "pkg:huggingface/distilbert-base-uncased@043235d6088ecd3dd5fb5ca3592b6913fd516027",
51 "expected_failure": false,
52 "expected_failure_reason": null
53 },
54 {
55 "description": "Hugging Face model with staging endpoint. Roundtrip an input purl to canonical.",
56 "test_group": "advanced",
57 "test_type": "roundtrip",
58 "input": "pkg:huggingface/microsoft/deberta-v3-base@559062ad13d311b87b2c455e67dcd5f1c8f65111?repository_url=https://hub-ci.huggingface.co",
59 "expected_output": "pkg:huggingface/microsoft/deberta-v3-base@559062ad13d311b87b2c455e67dcd5f1c8f65111?repository_url=https:%2F%2Fhub-ci.huggingface.co",
60 "expected_failure": false,
61 "expected_failure_reason": null
62 },
63 {
64 "description": "Hugging Face model with staging endpoint",
65 "test_group": "base",
66 "test_type": "parse",
67 "input": "pkg:huggingface/microsoft/deberta-v3-base@559062ad13d311b87b2c455e67dcd5f1c8f65111?repository_url=https://hub-ci.huggingface.co",
68 "expected_output": {
69 "type": "huggingface",
70 "namespace": "microsoft",
71 "name": "deberta-v3-base",
72 "version": "559062ad13d311b87b2c455e67dcd5f1c8f65111",
73 "qualifiers": {
74 "repository_url": "https://hub-ci.huggingface.co"
75 },
76 "subpath": null
77 },
78 "expected_failure": false,
79 "expected_failure_reason": null
80 },
81 {
82 "description": "Hugging Face model with staging endpoint. Roundtrip a canonical input to canonical output.",
83 "test_group": "base",
84 "test_type": "roundtrip",
85 "input": "pkg:huggingface/microsoft/deberta-v3-base@559062ad13d311b87b2c455e67dcd5f1c8f65111?repository_url=https://hub-ci.huggingface.co",
86 "expected_output": "pkg:huggingface/microsoft/deberta-v3-base@559062ad13d311b87b2c455e67dcd5f1c8f65111?repository_url=https:%2F%2Fhub-ci.huggingface.co",
87 "expected_failure": false,
88 "expected_failure_reason": null
89 },
90 {
91 "description": "Hugging Face model with staging endpoint",
92 "test_group": "base",
93 "test_type": "build",
94 "input": {
95 "type": "huggingface",
96 "namespace": "microsoft",
97 "name": "deberta-v3-base",
98 "version": "559062ad13d311b87b2c455e67dcd5f1c8f65111",
99 "qualifiers": {
100 "repository_url": "https://hub-ci.huggingface.co"
101 },
102 "subpath": null
103 },
104 "expected_output": "pkg:huggingface/microsoft/deberta-v3-base@559062ad13d311b87b2c455e67dcd5f1c8f65111?repository_url=https:%2F%2Fhub-ci.huggingface.co",
105 "expected_failure": false,
106 "expected_failure_reason": null
107 },
108 {
109 "description": "Hugging Face model with various cases. Roundtrip an input purl to canonical.",
110 "test_group": "advanced",
111 "test_type": "roundtrip",
112 "input": "pkg:huggingface/EleutherAI/gpt-neo-1.3B@797174552AE47F449AB70B684CABCB6603E5E85E",
113 "expected_output": "pkg:huggingface/EleutherAI/gpt-neo-1.3B@797174552ae47f449ab70b684cabcb6603e5e85e",
114 "expected_failure": false,
115 "expected_failure_reason": null
116 },
117 {
118 "description": "Hugging Face model with various cases",
119 "test_group": "base",
120 "test_type": "parse",
121 "input": "pkg:huggingface/EleutherAI/gpt-neo-1.3B@797174552AE47F449AB70B684CABCB6603E5E85E",
122 "expected_output": {
123 "type": "huggingface",
124 "namespace": "EleutherAI",
125 "name": "gpt-neo-1.3B",
126 "version": "797174552ae47f449ab70b684cabcb6603e5e85e",
127 "qualifiers": null,
128 "subpath": null
129 },
130 "expected_failure": false,
131 "expected_failure_reason": null
132 },
133 {
134 "description": "Hugging Face model with various cases. Roundtrip a canonical input to canonical output.",
135 "test_group": "base",
136 "test_type": "roundtrip",
137 "input": "pkg:huggingface/EleutherAI/gpt-neo-1.3B@797174552ae47f449ab70b684cabcb6603e5e85e",
138 "expected_output": "pkg:huggingface/EleutherAI/gpt-neo-1.3B@797174552ae47f449ab70b684cabcb6603e5e85e",
139 "expected_failure": false,
140 "expected_failure_reason": null
141 },
142 {
143 "description": "Hugging Face model with various cases",
144 "test_group": "base",
145 "test_type": "build",
146 "input": {
147 "type": "huggingface",
148 "namespace": "EleutherAI",
149 "name": "gpt-neo-1.3B",
150 "version": "797174552ae47f449ab70b684cabcb6603e5e85e",
151 "qualifiers": null,
152 "subpath": null
153 },
154 "expected_output": "pkg:huggingface/EleutherAI/gpt-neo-1.3B@797174552ae47f449ab70b684cabcb6603e5e85e",
155 "expected_failure": false,
156 "expected_failure_reason": null
157 },
158 {
159 "description": "Parse test for PURL type: huggingface",
160 "test_group": "base",
161 "test_type": "parse",
162 "input": "pkg:huggingface/distilbert-base-uncased@043235d6088ecd3dd5fb5ca3592b6913fd516027",
163 "expected_output": {
164 "type": "huggingface",
165 "namespace": null,
166 "name": "distilbert-base-uncased",
167 "version": "043235d6088ecd3dd5fb5ca3592b6913fd516027",
168 "qualifiers": null,
169 "subpath": null
170 },
171 "expected_failure": false,
172 "expected_failure_reason": null
173 },
174 {
175 "description": "Roundtrip test for PURL type: huggingface",
176 "test_group": "base",
177 "test_type": "roundtrip",
178 "input": "pkg:huggingface/distilbert-base-uncased@043235d6088ecd3dd5fb5ca3592b6913fd516027",
179 "expected_output": "pkg:huggingface/distilbert-base-uncased@043235d6088ecd3dd5fb5ca3592b6913fd516027",
180 "expected_failure": false,
181 "expected_failure_reason": null
182 },
183 {
184 "description": "Build test for PURL type: huggingface",
185 "test_group": "base",
186 "test_type": "build",
187 "input": {
188 "type": "huggingface",
189 "namespace": null,
190 "name": "distilbert-base-uncased",
191 "version": "043235d6088ecd3dd5fb5ca3592b6913fd516027",
192 "qualifiers": null,
193 "subpath": null
194 },
195 "expected_output": "pkg:huggingface/distilbert-base-uncased@043235d6088ecd3dd5fb5ca3592b6913fd516027",
196 "expected_failure": false,
197 "expected_failure_reason": null
198 },
199 {
200 "description": "Parse test for PURL type: huggingface",
201 "test_group": "base",
202 "test_type": "parse",
203 "input": "pkg:huggingface/microsoft/deberta-v3-base@559062ad13d311b87b2c455e67dcd5f1c8f65111?repository_url=https://hub-ci.huggingface.co",
204 "expected_output": {
205 "type": "huggingface",
206 "namespace": "microsoft",
207 "name": "deberta-v3-base",
208 "version": "559062ad13d311b87b2c455e67dcd5f1c8f65111",
209 "qualifiers": {
210 "repository_url": "https://hub-ci.huggingface.co"
211 },
212 "subpath": null
213 },
214 "expected_failure": false,
215 "expected_failure_reason": null
216 },
217 {
218 "description": "Roundtrip test for PURL type: huggingface",
219 "test_group": "base",
220 "test_type": "roundtrip",
221 "input": "pkg:huggingface/microsoft/deberta-v3-base@559062ad13d311b87b2c455e67dcd5f1c8f65111?repository_url=https://hub-ci.huggingface.co",
222 "expected_output": "pkg:huggingface/microsoft/deberta-v3-base@559062ad13d311b87b2c455e67dcd5f1c8f65111?repository_url=https:%2F%2Fhub-ci.huggingface.co",
223 "expected_failure": false,
224 "expected_failure_reason": null
225 },
226 {
227 "description": "Build test for PURL type: huggingface",
228 "test_group": "base",
229 "test_type": "build",
230 "input": {
231 "type": "huggingface",
232 "namespace": "microsoft",
233 "name": "deberta-v3-base",
234 "version": "559062ad13d311b87b2c455e67dcd5f1c8f65111",
235 "qualifiers": {
236 "repository_url": "https://hub-ci.huggingface.co"
237 },
238 "subpath": null
239 },
240 "expected_output": "pkg:huggingface/microsoft/deberta-v3-base@559062ad13d311b87b2c455e67dcd5f1c8f65111?repository_url=https:%2F%2Fhub-ci.huggingface.co",
241 "expected_failure": false,
242 "expected_failure_reason": null
243 }
244 ]
245 }