@abliteration/sdk 0.1.6 → 0.1.8

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.
Files changed (62) hide show
  1. package/.openapi-generator/FILES +16 -0
  2. package/README.md +12 -0
  3. package/dist/apis/ModelsApi.d.ts +230 -0
  4. package/dist/apis/ModelsApi.js +231 -1
  5. package/dist/esm/apis/ModelsApi.d.ts +230 -0
  6. package/dist/esm/apis/ModelsApi.js +230 -0
  7. package/dist/esm/models/DownloadAnomaly.d.ts +66 -0
  8. package/dist/esm/models/DownloadAnomaly.js +62 -0
  9. package/dist/esm/models/DownloadPoint.d.ts +34 -0
  10. package/dist/esm/models/DownloadPoint.js +43 -0
  11. package/dist/esm/models/GetModelDownloadHistory200Response.d.ts +67 -0
  12. package/dist/esm/models/GetModelDownloadHistory200Response.js +79 -0
  13. package/dist/esm/models/GetModelReadmeAt200Response.d.ts +67 -0
  14. package/dist/esm/models/GetModelReadmeAt200Response.js +79 -0
  15. package/dist/esm/models/ListAnomalies200Response.d.ts +67 -0
  16. package/dist/esm/models/ListAnomalies200Response.js +79 -0
  17. package/dist/esm/models/ListModelReadmeDrifts200Response.d.ts +67 -0
  18. package/dist/esm/models/ListModelReadmeDrifts200Response.js +79 -0
  19. package/dist/esm/models/ReadmeAt.d.ts +38 -0
  20. package/dist/esm/models/ReadmeAt.js +45 -0
  21. package/dist/esm/models/ReadmeDrift.d.ts +46 -0
  22. package/dist/esm/models/ReadmeDrift.js +49 -0
  23. package/dist/esm/models/index.d.ts +8 -0
  24. package/dist/esm/models/index.js +8 -0
  25. package/dist/models/DownloadAnomaly.d.ts +66 -0
  26. package/dist/models/DownloadAnomaly.js +70 -0
  27. package/dist/models/DownloadPoint.d.ts +34 -0
  28. package/dist/models/DownloadPoint.js +50 -0
  29. package/dist/models/GetModelDownloadHistory200Response.d.ts +67 -0
  30. package/dist/models/GetModelDownloadHistory200Response.js +87 -0
  31. package/dist/models/GetModelReadmeAt200Response.d.ts +67 -0
  32. package/dist/models/GetModelReadmeAt200Response.js +87 -0
  33. package/dist/models/ListAnomalies200Response.d.ts +67 -0
  34. package/dist/models/ListAnomalies200Response.js +87 -0
  35. package/dist/models/ListModelReadmeDrifts200Response.d.ts +67 -0
  36. package/dist/models/ListModelReadmeDrifts200Response.js +87 -0
  37. package/dist/models/ReadmeAt.d.ts +38 -0
  38. package/dist/models/ReadmeAt.js +52 -0
  39. package/dist/models/ReadmeDrift.d.ts +46 -0
  40. package/dist/models/ReadmeDrift.js +56 -0
  41. package/dist/models/index.d.ts +8 -0
  42. package/dist/models/index.js +8 -0
  43. package/docs/DownloadAnomaly.md +49 -0
  44. package/docs/DownloadPoint.md +37 -0
  45. package/docs/GetModelDownloadHistory200Response.md +48 -0
  46. package/docs/GetModelReadmeAt200Response.md +48 -0
  47. package/docs/ListAnomalies200Response.md +48 -0
  48. package/docs/ListModelReadmeDrifts200Response.md +48 -0
  49. package/docs/ModelsApi.md +332 -0
  50. package/docs/ReadmeAt.md +39 -0
  51. package/docs/ReadmeDrift.md +43 -0
  52. package/package.json +1 -1
  53. package/src/apis/ModelsApi.ts +462 -0
  54. package/src/models/DownloadAnomaly.ts +116 -0
  55. package/src/models/DownloadPoint.ts +69 -0
  56. package/src/models/GetModelDownloadHistory200Response.ts +132 -0
  57. package/src/models/GetModelReadmeAt200Response.ts +132 -0
  58. package/src/models/ListAnomalies200Response.ts +132 -0
  59. package/src/models/ListModelReadmeDrifts200Response.ts +132 -0
  60. package/src/models/ReadmeAt.ts +75 -0
  61. package/src/models/ReadmeDrift.ts +87 -0
  62. package/src/models/index.ts +8 -0
@@ -23,8 +23,12 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
23
23
  import * as runtime from '../runtime';
24
24
  import { GetHistoricalDeletionSummary200ResponseFromJSON, } from '../models/GetHistoricalDeletionSummary200Response';
25
25
  import { GetModel200ResponseFromJSON, } from '../models/GetModel200Response';
26
+ import { GetModelDownloadHistory200ResponseFromJSON, } from '../models/GetModelDownloadHistory200Response';
27
+ import { GetModelReadmeAt200ResponseFromJSON, } from '../models/GetModelReadmeAt200Response';
28
+ import { ListAnomalies200ResponseFromJSON, } from '../models/ListAnomalies200Response';
26
29
  import { ListDelistedModels200ResponseFromJSON, } from '../models/ListDelistedModels200Response';
27
30
  import { ListHistoricalDeletions200ResponseFromJSON, } from '../models/ListHistoricalDeletions200Response';
31
+ import { ListModelReadmeDrifts200ResponseFromJSON, } from '../models/ListModelReadmeDrifts200Response';
28
32
  import { ListModels200ResponseFromJSON, } from '../models/ListModels200Response';
29
33
  /**
30
34
  *
@@ -122,6 +126,168 @@ export class ModelsApi extends runtime.BaseAPI {
122
126
  return yield response.value();
123
127
  });
124
128
  }
129
+ /**
130
+ * Creates request options for getModelDownloadHistory without sending the request
131
+ */
132
+ getModelDownloadHistoryRequestOpts(requestParameters) {
133
+ return __awaiter(this, void 0, void 0, function* () {
134
+ if (requestParameters['id'] == null) {
135
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling getModelDownloadHistory().');
136
+ }
137
+ const queryParameters = {};
138
+ if (requestParameters['days'] != null) {
139
+ queryParameters['days'] = requestParameters['days'];
140
+ }
141
+ const headerParameters = {};
142
+ if (this.configuration && this.configuration.accessToken) {
143
+ const token = this.configuration.accessToken;
144
+ const tokenString = yield token("bearerAuth", []);
145
+ if (tokenString) {
146
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
147
+ }
148
+ }
149
+ let urlPath = `/api/v1/models/{id}/download-history`;
150
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
151
+ return {
152
+ path: urlPath,
153
+ method: 'GET',
154
+ headers: headerParameters,
155
+ query: queryParameters,
156
+ };
157
+ });
158
+ }
159
+ /**
160
+ * Cost: 5 credits, flat. Raw signal that /market/anomalies scans over. Callers with a chart or their own anomaly detector pull it once per model.
161
+ * Per-model download timeline
162
+ */
163
+ getModelDownloadHistoryRaw(requestParameters, initOverrides) {
164
+ return __awaiter(this, void 0, void 0, function* () {
165
+ const requestOptions = yield this.getModelDownloadHistoryRequestOpts(requestParameters);
166
+ const response = yield this.request(requestOptions, initOverrides);
167
+ return new runtime.JSONApiResponse(response, (jsonValue) => GetModelDownloadHistory200ResponseFromJSON(jsonValue));
168
+ });
169
+ }
170
+ /**
171
+ * Cost: 5 credits, flat. Raw signal that /market/anomalies scans over. Callers with a chart or their own anomaly detector pull it once per model.
172
+ * Per-model download timeline
173
+ */
174
+ getModelDownloadHistory(requestParameters, initOverrides) {
175
+ return __awaiter(this, void 0, void 0, function* () {
176
+ const response = yield this.getModelDownloadHistoryRaw(requestParameters, initOverrides);
177
+ return yield response.value();
178
+ });
179
+ }
180
+ /**
181
+ * Creates request options for getModelReadmeAt without sending the request
182
+ */
183
+ getModelReadmeAtRequestOpts(requestParameters) {
184
+ return __awaiter(this, void 0, void 0, function* () {
185
+ if (requestParameters['id'] == null) {
186
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling getModelReadmeAt().');
187
+ }
188
+ if (requestParameters['commit'] == null) {
189
+ throw new runtime.RequiredError('commit', 'Required parameter "commit" was null or undefined when calling getModelReadmeAt().');
190
+ }
191
+ const queryParameters = {};
192
+ const headerParameters = {};
193
+ if (this.configuration && this.configuration.accessToken) {
194
+ const token = this.configuration.accessToken;
195
+ const tokenString = yield token("bearerAuth", []);
196
+ if (tokenString) {
197
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
198
+ }
199
+ }
200
+ let urlPath = `/api/v1/models/{id}/readme-at/{commit}`;
201
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
202
+ urlPath = urlPath.replace('{commit}', encodeURIComponent(String(requestParameters['commit'])));
203
+ return {
204
+ path: urlPath,
205
+ method: 'GET',
206
+ headers: headerParameters,
207
+ query: queryParameters,
208
+ };
209
+ });
210
+ }
211
+ /**
212
+ * Cost: 10 credits, flat. The wayback-machine leg of the change-stream. Returns the exact README content for one model at one commit sha — used after spotting a suspicious drift on GET /api/v1/models/{id}/drifts.
213
+ * README content at one commit (wayback)
214
+ */
215
+ getModelReadmeAtRaw(requestParameters, initOverrides) {
216
+ return __awaiter(this, void 0, void 0, function* () {
217
+ const requestOptions = yield this.getModelReadmeAtRequestOpts(requestParameters);
218
+ const response = yield this.request(requestOptions, initOverrides);
219
+ return new runtime.JSONApiResponse(response, (jsonValue) => GetModelReadmeAt200ResponseFromJSON(jsonValue));
220
+ });
221
+ }
222
+ /**
223
+ * Cost: 10 credits, flat. The wayback-machine leg of the change-stream. Returns the exact README content for one model at one commit sha — used after spotting a suspicious drift on GET /api/v1/models/{id}/drifts.
224
+ * README content at one commit (wayback)
225
+ */
226
+ getModelReadmeAt(requestParameters, initOverrides) {
227
+ return __awaiter(this, void 0, void 0, function* () {
228
+ const response = yield this.getModelReadmeAtRaw(requestParameters, initOverrides);
229
+ return yield response.value();
230
+ });
231
+ }
232
+ /**
233
+ * Creates request options for listAnomalies without sending the request
234
+ */
235
+ listAnomaliesRequestOpts(requestParameters) {
236
+ return __awaiter(this, void 0, void 0, function* () {
237
+ const queryParameters = {};
238
+ if (requestParameters['windowDays'] != null) {
239
+ queryParameters['window_days'] = requestParameters['windowDays'];
240
+ }
241
+ if (requestParameters['minBaseline'] != null) {
242
+ queryParameters['min_baseline'] = requestParameters['minBaseline'];
243
+ }
244
+ if (requestParameters['kind'] != null) {
245
+ queryParameters['kind'] = requestParameters['kind'];
246
+ }
247
+ if (requestParameters['limit'] != null) {
248
+ queryParameters['limit'] = requestParameters['limit'];
249
+ }
250
+ if (requestParameters['offset'] != null) {
251
+ queryParameters['offset'] = requestParameters['offset'];
252
+ }
253
+ const headerParameters = {};
254
+ if (this.configuration && this.configuration.accessToken) {
255
+ const token = this.configuration.accessToken;
256
+ const tokenString = yield token("bearerAuth", []);
257
+ if (tokenString) {
258
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
259
+ }
260
+ }
261
+ let urlPath = `/api/v1/market/anomalies`;
262
+ return {
263
+ path: urlPath,
264
+ method: 'GET',
265
+ headers: headerParameters,
266
+ query: queryParameters,
267
+ };
268
+ });
269
+ }
270
+ /**
271
+ * Cost: 15 credits, flat. Every row is a model whose downloads-per-window has crossed a threshold: 2× jump = `spike`, 0.5× fall = `drop`. Sorted by absolute delta so biggest movers surface first. Consumers get \"what is happening in the field right now\" without re-implementing the ETL over `download_history`.
272
+ * Anomalies in the download counter (change stream)
273
+ */
274
+ listAnomaliesRaw(requestParameters, initOverrides) {
275
+ return __awaiter(this, void 0, void 0, function* () {
276
+ const requestOptions = yield this.listAnomaliesRequestOpts(requestParameters);
277
+ const response = yield this.request(requestOptions, initOverrides);
278
+ return new runtime.JSONApiResponse(response, (jsonValue) => ListAnomalies200ResponseFromJSON(jsonValue));
279
+ });
280
+ }
281
+ /**
282
+ * Cost: 15 credits, flat. Every row is a model whose downloads-per-window has crossed a threshold: 2× jump = `spike`, 0.5× fall = `drop`. Sorted by absolute delta so biggest movers surface first. Consumers get \"what is happening in the field right now\" without re-implementing the ETL over `download_history`.
283
+ * Anomalies in the download counter (change stream)
284
+ */
285
+ listAnomalies() {
286
+ return __awaiter(this, arguments, void 0, function* (requestParameters = {}, initOverrides) {
287
+ const response = yield this.listAnomaliesRaw(requestParameters, initOverrides);
288
+ return yield response.value();
289
+ });
290
+ }
125
291
  /**
126
292
  * Creates request options for listDelistedModels without sending the request
127
293
  */
@@ -237,6 +403,63 @@ export class ModelsApi extends runtime.BaseAPI {
237
403
  return yield response.value();
238
404
  });
239
405
  }
406
+ /**
407
+ * Creates request options for listModelReadmeDrifts without sending the request
408
+ */
409
+ listModelReadmeDriftsRequestOpts(requestParameters) {
410
+ return __awaiter(this, void 0, void 0, function* () {
411
+ if (requestParameters['id'] == null) {
412
+ throw new runtime.RequiredError('id', 'Required parameter "id" was null or undefined when calling listModelReadmeDrifts().');
413
+ }
414
+ const queryParameters = {};
415
+ if (requestParameters['sinceTs'] != null) {
416
+ queryParameters['since_ts'] = requestParameters['sinceTs'];
417
+ }
418
+ if (requestParameters['limit'] != null) {
419
+ queryParameters['limit'] = requestParameters['limit'];
420
+ }
421
+ if (requestParameters['offset'] != null) {
422
+ queryParameters['offset'] = requestParameters['offset'];
423
+ }
424
+ const headerParameters = {};
425
+ if (this.configuration && this.configuration.accessToken) {
426
+ const token = this.configuration.accessToken;
427
+ const tokenString = yield token("bearerAuth", []);
428
+ if (tokenString) {
429
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
430
+ }
431
+ }
432
+ let urlPath = `/api/v1/models/{id}/drifts`;
433
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
434
+ return {
435
+ path: urlPath,
436
+ method: 'GET',
437
+ headers: headerParameters,
438
+ query: queryParameters,
439
+ };
440
+ });
441
+ }
442
+ /**
443
+ * Cost: 5 credits, flat. Every commit that changed the model\'s README on HF, with `size_delta` between commits so a consumer spots growth spurts and hard prunes without fetching each version. Poll with `since_ts=<max commit_ts of your previous run>` for an incremental drift feed.
444
+ * README drift stream for one model
445
+ */
446
+ listModelReadmeDriftsRaw(requestParameters, initOverrides) {
447
+ return __awaiter(this, void 0, void 0, function* () {
448
+ const requestOptions = yield this.listModelReadmeDriftsRequestOpts(requestParameters);
449
+ const response = yield this.request(requestOptions, initOverrides);
450
+ return new runtime.JSONApiResponse(response, (jsonValue) => ListModelReadmeDrifts200ResponseFromJSON(jsonValue));
451
+ });
452
+ }
453
+ /**
454
+ * Cost: 5 credits, flat. Every commit that changed the model\'s README on HF, with `size_delta` between commits so a consumer spots growth spurts and hard prunes without fetching each version. Poll with `since_ts=<max commit_ts of your previous run>` for an incremental drift feed.
455
+ * README drift stream for one model
456
+ */
457
+ listModelReadmeDrifts(requestParameters, initOverrides) {
458
+ return __awaiter(this, void 0, void 0, function* () {
459
+ const response = yield this.listModelReadmeDriftsRaw(requestParameters, initOverrides);
460
+ return yield response.value();
461
+ });
462
+ }
240
463
  /**
241
464
  * Creates request options for listModels without sending the request
242
465
  */
@@ -318,6 +541,13 @@ export class ModelsApi extends runtime.BaseAPI {
318
541
  });
319
542
  }
320
543
  }
544
+ /**
545
+ * @export
546
+ */
547
+ export const ListAnomaliesKindEnum = {
548
+ Spike: 'spike',
549
+ Drop: 'drop',
550
+ };
321
551
  /**
322
552
  * @export
323
553
  */
@@ -0,0 +1,66 @@
1
+ /**
2
+ * abliteration.org Public API
3
+ * Read access to the abliteration.org catalog: models and their method classification, alignment datasets and their passports, the M-code taxonomy, the four flagship indices and the curated field timeline. Every call is authenticated with a bearer key and metered in credits against the same wallet the Research Agent spends from. There is no free tier for machine traffic and no separate billing. Responses report `cost` and `credits_remaining` on every success. While `metering` reads `preview`, the cost shown is what the call will bill once metering is enabled and nothing is actually deducted; when it reads `billed`, it was.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ * One model whose downloads-per-window crossed a threshold.
14
+ * @export
15
+ * @interface DownloadAnomaly
16
+ */
17
+ export interface DownloadAnomaly {
18
+ /**
19
+ *
20
+ */
21
+ model_id?: string;
22
+ /**
23
+ * ISO-8601 timestamp of the current snapshot.
24
+ */
25
+ current_at?: string;
26
+ /**
27
+ *
28
+ */
29
+ current_downloads?: number;
30
+ /**
31
+ * ISO-8601 timestamp of the baseline snapshot the delta is computed against.
32
+ */
33
+ baseline_at?: string;
34
+ /**
35
+ *
36
+ */
37
+ baseline_downloads?: number;
38
+ /**
39
+ * current_downloads / baseline_downloads.
40
+ */
41
+ ratio?: number;
42
+ /**
43
+ * current_downloads - baseline_downloads (signed).
44
+ */
45
+ delta?: number;
46
+ /**
47
+ * `spike` when ratio >= 2, `drop` when ratio <= 0.5.
48
+ */
49
+ kind?: DownloadAnomalyKindEnum;
50
+ }
51
+ /**
52
+ * @export
53
+ */
54
+ export declare const DownloadAnomalyKindEnum: {
55
+ readonly Spike: "spike";
56
+ readonly Drop: "drop";
57
+ };
58
+ export type DownloadAnomalyKindEnum = typeof DownloadAnomalyKindEnum[keyof typeof DownloadAnomalyKindEnum];
59
+ /**
60
+ * Check if a given object implements the DownloadAnomaly interface.
61
+ */
62
+ export declare function instanceOfDownloadAnomaly(value: object): value is DownloadAnomaly;
63
+ export declare function DownloadAnomalyFromJSON(json: any): DownloadAnomaly;
64
+ export declare function DownloadAnomalyFromJSONTyped(json: any, ignoreDiscriminator: boolean): DownloadAnomaly;
65
+ export declare function DownloadAnomalyToJSON(json: any): DownloadAnomaly;
66
+ export declare function DownloadAnomalyToJSONTyped(value?: DownloadAnomaly | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,62 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * abliteration.org Public API
5
+ * Read access to the abliteration.org catalog: models and their method classification, alignment datasets and their passports, the M-code taxonomy, the four flagship indices and the curated field timeline. Every call is authenticated with a bearer key and metered in credits against the same wallet the Research Agent spends from. There is no free tier for machine traffic and no separate billing. Responses report `cost` and `credits_remaining` on every success. While `metering` reads `preview`, the cost shown is what the call will bill once metering is enabled and nothing is actually deducted; when it reads `billed`, it was.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ /**
15
+ * @export
16
+ */
17
+ export const DownloadAnomalyKindEnum = {
18
+ Spike: 'spike',
19
+ Drop: 'drop',
20
+ };
21
+ /**
22
+ * Check if a given object implements the DownloadAnomaly interface.
23
+ */
24
+ export function instanceOfDownloadAnomaly(value) {
25
+ return true;
26
+ }
27
+ export function DownloadAnomalyFromJSON(json) {
28
+ return DownloadAnomalyFromJSONTyped(json, false);
29
+ }
30
+ export function DownloadAnomalyFromJSONTyped(json, ignoreDiscriminator) {
31
+ if (json == null) {
32
+ return json;
33
+ }
34
+ return {
35
+ 'model_id': json['model_id'] == null ? undefined : json['model_id'],
36
+ 'current_at': json['current_at'] == null ? undefined : json['current_at'],
37
+ 'current_downloads': json['current_downloads'] == null ? undefined : json['current_downloads'],
38
+ 'baseline_at': json['baseline_at'] == null ? undefined : json['baseline_at'],
39
+ 'baseline_downloads': json['baseline_downloads'] == null ? undefined : json['baseline_downloads'],
40
+ 'ratio': json['ratio'] == null ? undefined : json['ratio'],
41
+ 'delta': json['delta'] == null ? undefined : json['delta'],
42
+ 'kind': json['kind'] == null ? undefined : json['kind'],
43
+ };
44
+ }
45
+ export function DownloadAnomalyToJSON(json) {
46
+ return DownloadAnomalyToJSONTyped(json, false);
47
+ }
48
+ export function DownloadAnomalyToJSONTyped(value, ignoreDiscriminator = false) {
49
+ if (value == null) {
50
+ return value;
51
+ }
52
+ return {
53
+ 'model_id': value['model_id'],
54
+ 'current_at': value['current_at'],
55
+ 'current_downloads': value['current_downloads'],
56
+ 'baseline_at': value['baseline_at'],
57
+ 'baseline_downloads': value['baseline_downloads'],
58
+ 'ratio': value['ratio'],
59
+ 'delta': value['delta'],
60
+ 'kind': value['kind'],
61
+ };
62
+ }
@@ -0,0 +1,34 @@
1
+ /**
2
+ * abliteration.org Public API
3
+ * Read access to the abliteration.org catalog: models and their method classification, alignment datasets and their passports, the M-code taxonomy, the four flagship indices and the curated field timeline. Every call is authenticated with a bearer key and metered in credits against the same wallet the Research Agent spends from. There is no free tier for machine traffic and no separate billing. Responses report `cost` and `credits_remaining` on every success. While `metering` reads `preview`, the cost shown is what the call will bill once metering is enabled and nothing is actually deducted; when it reads `billed`, it was.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ * One snapshot in a per-model download timeline.
14
+ * @export
15
+ * @interface DownloadPoint
16
+ */
17
+ export interface DownloadPoint {
18
+ /**
19
+ * ISO-8601 timestamp of the observation.
20
+ */
21
+ date?: string;
22
+ /**
23
+ *
24
+ */
25
+ downloads?: number;
26
+ }
27
+ /**
28
+ * Check if a given object implements the DownloadPoint interface.
29
+ */
30
+ export declare function instanceOfDownloadPoint(value: object): value is DownloadPoint;
31
+ export declare function DownloadPointFromJSON(json: any): DownloadPoint;
32
+ export declare function DownloadPointFromJSONTyped(json: any, ignoreDiscriminator: boolean): DownloadPoint;
33
+ export declare function DownloadPointToJSON(json: any): DownloadPoint;
34
+ export declare function DownloadPointToJSONTyped(value?: DownloadPoint | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,43 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * abliteration.org Public API
5
+ * Read access to the abliteration.org catalog: models and their method classification, alignment datasets and their passports, the M-code taxonomy, the four flagship indices and the curated field timeline. Every call is authenticated with a bearer key and metered in credits against the same wallet the Research Agent spends from. There is no free tier for machine traffic and no separate billing. Responses report `cost` and `credits_remaining` on every success. While `metering` reads `preview`, the cost shown is what the call will bill once metering is enabled and nothing is actually deducted; when it reads `billed`, it was.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ /**
15
+ * Check if a given object implements the DownloadPoint interface.
16
+ */
17
+ export function instanceOfDownloadPoint(value) {
18
+ return true;
19
+ }
20
+ export function DownloadPointFromJSON(json) {
21
+ return DownloadPointFromJSONTyped(json, false);
22
+ }
23
+ export function DownloadPointFromJSONTyped(json, ignoreDiscriminator) {
24
+ if (json == null) {
25
+ return json;
26
+ }
27
+ return {
28
+ 'date': json['date'] == null ? undefined : json['date'],
29
+ 'downloads': json['downloads'] == null ? undefined : json['downloads'],
30
+ };
31
+ }
32
+ export function DownloadPointToJSON(json) {
33
+ return DownloadPointToJSONTyped(json, false);
34
+ }
35
+ export function DownloadPointToJSONTyped(value, ignoreDiscriminator = false) {
36
+ if (value == null) {
37
+ return value;
38
+ }
39
+ return {
40
+ 'date': value['date'],
41
+ 'downloads': value['downloads'],
42
+ };
43
+ }
@@ -0,0 +1,67 @@
1
+ /**
2
+ * abliteration.org Public API
3
+ * Read access to the abliteration.org catalog: models and their method classification, alignment datasets and their passports, the M-code taxonomy, the four flagship indices and the curated field timeline. Every call is authenticated with a bearer key and metered in credits against the same wallet the Research Agent spends from. There is no free tier for machine traffic and no separate billing. Responses report `cost` and `credits_remaining` on every success. While `metering` reads `preview`, the cost shown is what the call will bill once metering is enabled and nothing is actually deducted; when it reads `billed`, it was.
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { DownloadPoint } from './DownloadPoint';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface GetModelDownloadHistory200Response
17
+ */
18
+ export interface GetModelDownloadHistory200Response {
19
+ /**
20
+ *
21
+ */
22
+ data: Array<DownloadPoint>;
23
+ /**
24
+ * Credits this call costs.
25
+ */
26
+ cost: number;
27
+ /**
28
+ * Wallet balance after the call. Unchanged while metering is preview.
29
+ */
30
+ credits_remaining: number;
31
+ /**
32
+ * Ceiling for the current window. Also returned as X-RateLimit-Limit.
33
+ */
34
+ rate_limit_limit: number;
35
+ /**
36
+ * Calls left in the current window for this key. Also returned as X-RateLimit-Remaining.
37
+ */
38
+ rate_limit_remaining: number;
39
+ /**
40
+ * Unix seconds at which the window resets to full ceiling. Also returned as X-RateLimit-Reset.
41
+ */
42
+ rate_limit_reset: number;
43
+ /**
44
+ * Whether cost was actually deducted.
45
+ */
46
+ metering: GetModelDownloadHistory200ResponseMeteringEnum;
47
+ /**
48
+ * Also returned in the x-request-id header.
49
+ */
50
+ request_id: string;
51
+ }
52
+ /**
53
+ * @export
54
+ */
55
+ export declare const GetModelDownloadHistory200ResponseMeteringEnum: {
56
+ readonly Preview: "preview";
57
+ readonly Billed: "billed";
58
+ };
59
+ export type GetModelDownloadHistory200ResponseMeteringEnum = typeof GetModelDownloadHistory200ResponseMeteringEnum[keyof typeof GetModelDownloadHistory200ResponseMeteringEnum];
60
+ /**
61
+ * Check if a given object implements the GetModelDownloadHistory200Response interface.
62
+ */
63
+ export declare function instanceOfGetModelDownloadHistory200Response(value: object): value is GetModelDownloadHistory200Response;
64
+ export declare function GetModelDownloadHistory200ResponseFromJSON(json: any): GetModelDownloadHistory200Response;
65
+ export declare function GetModelDownloadHistory200ResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetModelDownloadHistory200Response;
66
+ export declare function GetModelDownloadHistory200ResponseToJSON(json: any): GetModelDownloadHistory200Response;
67
+ export declare function GetModelDownloadHistory200ResponseToJSONTyped(value?: GetModelDownloadHistory200Response | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,79 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * abliteration.org Public API
5
+ * Read access to the abliteration.org catalog: models and their method classification, alignment datasets and their passports, the M-code taxonomy, the four flagship indices and the curated field timeline. Every call is authenticated with a bearer key and metered in credits against the same wallet the Research Agent spends from. There is no free tier for machine traffic and no separate billing. Responses report `cost` and `credits_remaining` on every success. While `metering` reads `preview`, the cost shown is what the call will bill once metering is enabled and nothing is actually deducted; when it reads `billed`, it was.
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ import { DownloadPointFromJSON, DownloadPointToJSON, } from './DownloadPoint';
15
+ /**
16
+ * @export
17
+ */
18
+ export const GetModelDownloadHistory200ResponseMeteringEnum = {
19
+ Preview: 'preview',
20
+ Billed: 'billed',
21
+ };
22
+ /**
23
+ * Check if a given object implements the GetModelDownloadHistory200Response interface.
24
+ */
25
+ export function instanceOfGetModelDownloadHistory200Response(value) {
26
+ if (!('data' in value) || value['data'] === undefined)
27
+ return false;
28
+ if (!('cost' in value) || value['cost'] === undefined)
29
+ return false;
30
+ if (!('credits_remaining' in value) || value['credits_remaining'] === undefined)
31
+ return false;
32
+ if (!('rate_limit_limit' in value) || value['rate_limit_limit'] === undefined)
33
+ return false;
34
+ if (!('rate_limit_remaining' in value) || value['rate_limit_remaining'] === undefined)
35
+ return false;
36
+ if (!('rate_limit_reset' in value) || value['rate_limit_reset'] === undefined)
37
+ return false;
38
+ if (!('metering' in value) || value['metering'] === undefined)
39
+ return false;
40
+ if (!('request_id' in value) || value['request_id'] === undefined)
41
+ return false;
42
+ return true;
43
+ }
44
+ export function GetModelDownloadHistory200ResponseFromJSON(json) {
45
+ return GetModelDownloadHistory200ResponseFromJSONTyped(json, false);
46
+ }
47
+ export function GetModelDownloadHistory200ResponseFromJSONTyped(json, ignoreDiscriminator) {
48
+ if (json == null) {
49
+ return json;
50
+ }
51
+ return {
52
+ 'data': (json['data'].map(DownloadPointFromJSON)),
53
+ 'cost': json['cost'],
54
+ 'credits_remaining': json['credits_remaining'],
55
+ 'rate_limit_limit': json['rate_limit_limit'],
56
+ 'rate_limit_remaining': json['rate_limit_remaining'],
57
+ 'rate_limit_reset': json['rate_limit_reset'],
58
+ 'metering': json['metering'],
59
+ 'request_id': json['request_id'],
60
+ };
61
+ }
62
+ export function GetModelDownloadHistory200ResponseToJSON(json) {
63
+ return GetModelDownloadHistory200ResponseToJSONTyped(json, false);
64
+ }
65
+ export function GetModelDownloadHistory200ResponseToJSONTyped(value, ignoreDiscriminator = false) {
66
+ if (value == null) {
67
+ return value;
68
+ }
69
+ return {
70
+ 'data': (value['data'].map(DownloadPointToJSON)),
71
+ 'cost': value['cost'],
72
+ 'credits_remaining': value['credits_remaining'],
73
+ 'rate_limit_limit': value['rate_limit_limit'],
74
+ 'rate_limit_remaining': value['rate_limit_remaining'],
75
+ 'rate_limit_reset': value['rate_limit_reset'],
76
+ 'metering': value['metering'],
77
+ 'request_id': value['request_id'],
78
+ };
79
+ }