@abliteration/sdk 0.1.0 → 0.1.1

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 (102) hide show
  1. package/.openapi-generator/FILES +76 -0
  2. package/.openapi-generator/VERSION +1 -0
  3. package/.openapi-generator-ignore +23 -0
  4. package/README.md +140 -49
  5. package/dist/apis/AuthorsApi.d.ts +11 -3
  6. package/dist/apis/AuthorsApi.js +8 -0
  7. package/dist/apis/DatasetsApi.d.ts +9 -3
  8. package/dist/apis/DatasetsApi.js +6 -0
  9. package/dist/apis/IndicesApi.d.ts +9 -3
  10. package/dist/apis/IndicesApi.js +6 -0
  11. package/dist/apis/ModelsApi.d.ts +9 -3
  12. package/dist/apis/ModelsApi.js +6 -0
  13. package/dist/esm/apis/AuthorsApi.d.ts +11 -3
  14. package/dist/esm/apis/AuthorsApi.js +8 -0
  15. package/dist/esm/apis/DatasetsApi.d.ts +9 -3
  16. package/dist/esm/apis/DatasetsApi.js +6 -0
  17. package/dist/esm/apis/IndicesApi.d.ts +9 -3
  18. package/dist/esm/apis/IndicesApi.js +6 -0
  19. package/dist/esm/apis/ModelsApi.d.ts +9 -3
  20. package/dist/esm/apis/ModelsApi.js +6 -0
  21. package/dist/esm/models/Author.d.ts +4 -0
  22. package/dist/esm/models/Author.js +2 -0
  23. package/dist/esm/models/AuthorDetail.d.ts +4 -0
  24. package/dist/esm/models/AuthorDetail.js +2 -0
  25. package/dist/models/Author.d.ts +4 -0
  26. package/dist/models/Author.js +2 -0
  27. package/dist/models/AuthorDetail.d.ts +4 -0
  28. package/dist/models/AuthorDetail.js +2 -0
  29. package/docs/Author.md +44 -0
  30. package/docs/AuthorDetail.md +46 -0
  31. package/docs/AuthorsApi.md +167 -0
  32. package/docs/DaiPoint.md +38 -0
  33. package/docs/Dataset.md +54 -0
  34. package/docs/DatasetDetail.md +39 -0
  35. package/docs/DatasetsApi.md +176 -0
  36. package/docs/Envelope.md +48 -0
  37. package/docs/Event.md +46 -0
  38. package/docs/GetAuthor200Response.md +48 -0
  39. package/docs/GetDataset200Response.md +48 -0
  40. package/docs/GetIndex200Response.md +48 -0
  41. package/docs/GetMethod200Response.md +48 -0
  42. package/docs/GetModel200Response.md +48 -0
  43. package/docs/IndexDetail.md +54 -0
  44. package/docs/IndicesApi.md +153 -0
  45. package/docs/ListAuthors200Response.md +48 -0
  46. package/docs/ListDatasets200Response.md +48 -0
  47. package/docs/ListIndices200Response.md +48 -0
  48. package/docs/ListMethods200Response.md +48 -0
  49. package/docs/ListModels200Response.md +48 -0
  50. package/docs/ListTimeline200Response.md +48 -0
  51. package/docs/Method.md +44 -0
  52. package/docs/MethodDetail.md +50 -0
  53. package/docs/MethodDetailAllOfTopAuthors.md +36 -0
  54. package/docs/MethodsApi.md +153 -0
  55. package/docs/ModelDetail.md +45 -0
  56. package/docs/ModelError.md +42 -0
  57. package/docs/ModelIndex.md +52 -0
  58. package/docs/ModelSummary.md +58 -0
  59. package/docs/ModelsApi.md +191 -0
  60. package/docs/Passport.md +38 -0
  61. package/docs/TimelineApi.md +93 -0
  62. package/openapi-generator-config.json +10 -0
  63. package/package.json +14 -16
  64. package/src/apis/AuthorsApi.ts +248 -0
  65. package/src/apis/DatasetsApi.ts +278 -0
  66. package/src/apis/IndicesApi.ts +213 -0
  67. package/src/apis/MethodsApi.ts +214 -0
  68. package/src/apis/ModelsApi.ts +328 -0
  69. package/src/apis/TimelineApi.ts +148 -0
  70. package/src/apis/index.ts +8 -0
  71. package/src/index.ts +5 -0
  72. package/src/models/Author.ts +93 -0
  73. package/src/models/AuthorDetail.ts +107 -0
  74. package/src/models/DaiPoint.ts +75 -0
  75. package/src/models/Dataset.ts +123 -0
  76. package/src/models/DatasetDetail.ts +86 -0
  77. package/src/models/Envelope.ts +124 -0
  78. package/src/models/Event.ts +99 -0
  79. package/src/models/GetAuthor200Response.ts +132 -0
  80. package/src/models/GetDataset200Response.ts +132 -0
  81. package/src/models/GetIndex200Response.ts +132 -0
  82. package/src/models/GetMethod200Response.ts +132 -0
  83. package/src/models/GetModel200Response.ts +132 -0
  84. package/src/models/IndexDetail.ts +153 -0
  85. package/src/models/ListAuthors200Response.ts +132 -0
  86. package/src/models/ListDatasets200Response.ts +132 -0
  87. package/src/models/ListIndices200Response.ts +132 -0
  88. package/src/models/ListMethods200Response.ts +132 -0
  89. package/src/models/ListModels200Response.ts +132 -0
  90. package/src/models/ListTimeline200Response.ts +132 -0
  91. package/src/models/Method.ts +106 -0
  92. package/src/models/MethodDetail.ts +139 -0
  93. package/src/models/MethodDetailAllOfTopAuthors.ts +69 -0
  94. package/src/models/ModelDetail.ts +104 -0
  95. package/src/models/ModelError.ts +89 -0
  96. package/src/models/ModelIndex.ts +147 -0
  97. package/src/models/ModelSummary.ts +135 -0
  98. package/src/models/Passport.ts +75 -0
  99. package/src/models/index.ts +29 -0
  100. package/src/runtime.ts +505 -0
  101. package/tsconfig.esm.json +7 -0
  102. package/tsconfig.json +16 -0
@@ -0,0 +1,213 @@
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
+ import * as runtime from '../runtime';
16
+ import {
17
+ type GetIndex200Response,
18
+ GetIndex200ResponseFromJSON,
19
+ GetIndex200ResponseToJSON,
20
+ } from '../models/GetIndex200Response';
21
+ import {
22
+ type ListIndices200Response,
23
+ ListIndices200ResponseFromJSON,
24
+ ListIndices200ResponseToJSON,
25
+ } from '../models/ListIndices200Response';
26
+
27
+ export interface GetIndexRequest {
28
+ /**
29
+ * Canonical id or one of the short aliases (DAI, FV, WEAP, F2W). Case-insensitive.
30
+ */
31
+ id: GetIndexIdEnum;
32
+ }
33
+
34
+ /**
35
+ * IndicesApi - interface
36
+ *
37
+ * @export
38
+ * @interface IndicesApiInterface
39
+ */
40
+ export interface IndicesApiInterface {
41
+ /**
42
+ * Creates request options for getIndex without sending the request
43
+ * @param {'dai' | 'DAI' | 'freedom-velocity' | 'FV' | 'freedom_velocity' | 'weaponization' | 'WEAP' | 'f2w-latency' | 'F2W' | 'f2w_latency'} id Canonical id or one of the short aliases (DAI, FV, WEAP, F2W). Case-insensitive.
44
+ * @throws {RequiredError}
45
+ * @memberof IndicesApiInterface
46
+ */
47
+ getIndexRequestOpts(requestParameters: GetIndexRequest): Promise<runtime.RequestOpts>;
48
+
49
+ /**
50
+ * Cost: 10 credits. Only dai has a history series; the others return an empty array with history_available false.
51
+ * @summary One index with history
52
+ * @param {'dai' | 'DAI' | 'freedom-velocity' | 'FV' | 'freedom_velocity' | 'weaponization' | 'WEAP' | 'f2w-latency' | 'F2W' | 'f2w_latency'} id Canonical id or one of the short aliases (DAI, FV, WEAP, F2W). Case-insensitive.
53
+ * @param {*} [options] Override http request option.
54
+ * @throws {RequiredError}
55
+ * @memberof IndicesApiInterface
56
+ */
57
+ getIndexRaw(requestParameters: GetIndexRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetIndex200Response>>;
58
+
59
+ /**
60
+ * Cost: 10 credits. Only dai has a history series; the others return an empty array with history_available false.
61
+ * One index with history
62
+ */
63
+ getIndex(requestParameters: GetIndexRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetIndex200Response>;
64
+
65
+ /**
66
+ * Creates request options for listIndices without sending the request
67
+ * @throws {RequiredError}
68
+ * @memberof IndicesApiInterface
69
+ */
70
+ listIndicesRequestOpts(): Promise<runtime.RequestOpts>;
71
+
72
+ /**
73
+ * Cost: 20 credits. Check the measured flag before treating a value as a finding.
74
+ * @summary All four indices
75
+ * @param {*} [options] Override http request option.
76
+ * @throws {RequiredError}
77
+ * @memberof IndicesApiInterface
78
+ */
79
+ listIndicesRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListIndices200Response>>;
80
+
81
+ /**
82
+ * Cost: 20 credits. Check the measured flag before treating a value as a finding.
83
+ * All four indices
84
+ */
85
+ listIndices(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListIndices200Response>;
86
+
87
+ }
88
+
89
+ /**
90
+ *
91
+ */
92
+ export class IndicesApi extends runtime.BaseAPI implements IndicesApiInterface {
93
+
94
+ /**
95
+ * Creates request options for getIndex without sending the request
96
+ */
97
+ async getIndexRequestOpts(requestParameters: GetIndexRequest): Promise<runtime.RequestOpts> {
98
+ if (requestParameters['id'] == null) {
99
+ throw new runtime.RequiredError(
100
+ 'id',
101
+ 'Required parameter "id" was null or undefined when calling getIndex().'
102
+ );
103
+ }
104
+
105
+ const queryParameters: any = {};
106
+
107
+ const headerParameters: runtime.HTTPHeaders = {};
108
+
109
+ if (this.configuration && this.configuration.accessToken) {
110
+ const token = this.configuration.accessToken;
111
+ const tokenString = await token("bearerAuth", []);
112
+
113
+ if (tokenString) {
114
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
115
+ }
116
+ }
117
+
118
+ let urlPath = `/api/v1/indices/{id}`;
119
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
120
+
121
+ return {
122
+ path: urlPath,
123
+ method: 'GET',
124
+ headers: headerParameters,
125
+ query: queryParameters,
126
+ };
127
+ }
128
+
129
+ /**
130
+ * Cost: 10 credits. Only dai has a history series; the others return an empty array with history_available false.
131
+ * One index with history
132
+ */
133
+ async getIndexRaw(requestParameters: GetIndexRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetIndex200Response>> {
134
+ const requestOptions = await this.getIndexRequestOpts(requestParameters);
135
+ const response = await this.request(requestOptions, initOverrides);
136
+
137
+ return new runtime.JSONApiResponse(response, (jsonValue) => GetIndex200ResponseFromJSON(jsonValue));
138
+ }
139
+
140
+ /**
141
+ * Cost: 10 credits. Only dai has a history series; the others return an empty array with history_available false.
142
+ * One index with history
143
+ */
144
+ async getIndex(requestParameters: GetIndexRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetIndex200Response> {
145
+ const response = await this.getIndexRaw(requestParameters, initOverrides);
146
+ return await response.value();
147
+ }
148
+
149
+ /**
150
+ * Creates request options for listIndices without sending the request
151
+ */
152
+ async listIndicesRequestOpts(): Promise<runtime.RequestOpts> {
153
+ const queryParameters: any = {};
154
+
155
+ const headerParameters: runtime.HTTPHeaders = {};
156
+
157
+ if (this.configuration && this.configuration.accessToken) {
158
+ const token = this.configuration.accessToken;
159
+ const tokenString = await token("bearerAuth", []);
160
+
161
+ if (tokenString) {
162
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
163
+ }
164
+ }
165
+
166
+ let urlPath = `/api/v1/indices`;
167
+
168
+ return {
169
+ path: urlPath,
170
+ method: 'GET',
171
+ headers: headerParameters,
172
+ query: queryParameters,
173
+ };
174
+ }
175
+
176
+ /**
177
+ * Cost: 20 credits. Check the measured flag before treating a value as a finding.
178
+ * All four indices
179
+ */
180
+ async listIndicesRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListIndices200Response>> {
181
+ const requestOptions = await this.listIndicesRequestOpts();
182
+ const response = await this.request(requestOptions, initOverrides);
183
+
184
+ return new runtime.JSONApiResponse(response, (jsonValue) => ListIndices200ResponseFromJSON(jsonValue));
185
+ }
186
+
187
+ /**
188
+ * Cost: 20 credits. Check the measured flag before treating a value as a finding.
189
+ * All four indices
190
+ */
191
+ async listIndices(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListIndices200Response> {
192
+ const response = await this.listIndicesRaw(initOverrides);
193
+ return await response.value();
194
+ }
195
+
196
+ }
197
+
198
+ /**
199
+ * @export
200
+ */
201
+ export const GetIndexIdEnum = {
202
+ Dai: 'dai',
203
+ Dai2: 'DAI',
204
+ FreedomVelocity: 'freedom-velocity',
205
+ Fv: 'FV',
206
+ FreedomVelocity2: 'freedom_velocity',
207
+ Weaponization: 'weaponization',
208
+ Weap: 'WEAP',
209
+ F2wLatency: 'f2w-latency',
210
+ F2W: 'F2W',
211
+ F2wLatency2: 'f2w_latency',
212
+ } as const;
213
+ export type GetIndexIdEnum = typeof GetIndexIdEnum[keyof typeof GetIndexIdEnum];
@@ -0,0 +1,214 @@
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
+ import * as runtime from '../runtime';
16
+ import {
17
+ type GetMethod200Response,
18
+ GetMethod200ResponseFromJSON,
19
+ GetMethod200ResponseToJSON,
20
+ } from '../models/GetMethod200Response';
21
+ import {
22
+ type ListMethods200Response,
23
+ ListMethods200ResponseFromJSON,
24
+ ListMethods200ResponseToJSON,
25
+ } from '../models/ListMethods200Response';
26
+
27
+ export interface GetMethodRequest {
28
+ /**
29
+ *
30
+ */
31
+ id: GetMethodIdEnum;
32
+ }
33
+
34
+ /**
35
+ * MethodsApi - interface
36
+ *
37
+ * @export
38
+ * @interface MethodsApiInterface
39
+ */
40
+ export interface MethodsApiInterface {
41
+ /**
42
+ * Creates request options for getMethod without sending the request
43
+ * @param {'M1' | 'M2' | 'M3' | 'M4' | 'M5' | 'M5-frankenstein' | 'M6' | 'M7' | 'M8' | 'M-uncensored' | 'unknown'} id
44
+ * @throws {RequiredError}
45
+ * @memberof MethodsApiInterface
46
+ */
47
+ getMethodRequestOpts(requestParameters: GetMethodRequest): Promise<runtime.RequestOpts>;
48
+
49
+ /**
50
+ * Cost: 1 credit.
51
+ * @summary Get one method
52
+ * @param {'M1' | 'M2' | 'M3' | 'M4' | 'M5' | 'M5-frankenstein' | 'M6' | 'M7' | 'M8' | 'M-uncensored' | 'unknown'} id
53
+ * @param {*} [options] Override http request option.
54
+ * @throws {RequiredError}
55
+ * @memberof MethodsApiInterface
56
+ */
57
+ getMethodRaw(requestParameters: GetMethodRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetMethod200Response>>;
58
+
59
+ /**
60
+ * Cost: 1 credit.
61
+ * Get one method
62
+ */
63
+ getMethod(requestParameters: GetMethodRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetMethod200Response>;
64
+
65
+ /**
66
+ * Creates request options for listMethods without sending the request
67
+ * @throws {RequiredError}
68
+ * @memberof MethodsApiInterface
69
+ */
70
+ listMethodsRequestOpts(): Promise<runtime.RequestOpts>;
71
+
72
+ /**
73
+ * Cost: 5-15 credits. Every code is returned, including ones with no models.
74
+ * @summary List the method taxonomy
75
+ * @param {*} [options] Override http request option.
76
+ * @throws {RequiredError}
77
+ * @memberof MethodsApiInterface
78
+ */
79
+ listMethodsRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListMethods200Response>>;
80
+
81
+ /**
82
+ * Cost: 5-15 credits. Every code is returned, including ones with no models.
83
+ * List the method taxonomy
84
+ */
85
+ listMethods(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListMethods200Response>;
86
+
87
+ }
88
+
89
+ /**
90
+ *
91
+ */
92
+ export class MethodsApi extends runtime.BaseAPI implements MethodsApiInterface {
93
+
94
+ /**
95
+ * Creates request options for getMethod without sending the request
96
+ */
97
+ async getMethodRequestOpts(requestParameters: GetMethodRequest): Promise<runtime.RequestOpts> {
98
+ if (requestParameters['id'] == null) {
99
+ throw new runtime.RequiredError(
100
+ 'id',
101
+ 'Required parameter "id" was null or undefined when calling getMethod().'
102
+ );
103
+ }
104
+
105
+ const queryParameters: any = {};
106
+
107
+ const headerParameters: runtime.HTTPHeaders = {};
108
+
109
+ if (this.configuration && this.configuration.accessToken) {
110
+ const token = this.configuration.accessToken;
111
+ const tokenString = await token("bearerAuth", []);
112
+
113
+ if (tokenString) {
114
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
115
+ }
116
+ }
117
+
118
+ let urlPath = `/api/v1/methods/{id}`;
119
+ urlPath = urlPath.replace('{id}', encodeURIComponent(String(requestParameters['id'])));
120
+
121
+ return {
122
+ path: urlPath,
123
+ method: 'GET',
124
+ headers: headerParameters,
125
+ query: queryParameters,
126
+ };
127
+ }
128
+
129
+ /**
130
+ * Cost: 1 credit.
131
+ * Get one method
132
+ */
133
+ async getMethodRaw(requestParameters: GetMethodRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetMethod200Response>> {
134
+ const requestOptions = await this.getMethodRequestOpts(requestParameters);
135
+ const response = await this.request(requestOptions, initOverrides);
136
+
137
+ return new runtime.JSONApiResponse(response, (jsonValue) => GetMethod200ResponseFromJSON(jsonValue));
138
+ }
139
+
140
+ /**
141
+ * Cost: 1 credit.
142
+ * Get one method
143
+ */
144
+ async getMethod(requestParameters: GetMethodRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetMethod200Response> {
145
+ const response = await this.getMethodRaw(requestParameters, initOverrides);
146
+ return await response.value();
147
+ }
148
+
149
+ /**
150
+ * Creates request options for listMethods without sending the request
151
+ */
152
+ async listMethodsRequestOpts(): Promise<runtime.RequestOpts> {
153
+ const queryParameters: any = {};
154
+
155
+ const headerParameters: runtime.HTTPHeaders = {};
156
+
157
+ if (this.configuration && this.configuration.accessToken) {
158
+ const token = this.configuration.accessToken;
159
+ const tokenString = await token("bearerAuth", []);
160
+
161
+ if (tokenString) {
162
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
163
+ }
164
+ }
165
+
166
+ let urlPath = `/api/v1/methods`;
167
+
168
+ return {
169
+ path: urlPath,
170
+ method: 'GET',
171
+ headers: headerParameters,
172
+ query: queryParameters,
173
+ };
174
+ }
175
+
176
+ /**
177
+ * Cost: 5-15 credits. Every code is returned, including ones with no models.
178
+ * List the method taxonomy
179
+ */
180
+ async listMethodsRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListMethods200Response>> {
181
+ const requestOptions = await this.listMethodsRequestOpts();
182
+ const response = await this.request(requestOptions, initOverrides);
183
+
184
+ return new runtime.JSONApiResponse(response, (jsonValue) => ListMethods200ResponseFromJSON(jsonValue));
185
+ }
186
+
187
+ /**
188
+ * Cost: 5-15 credits. Every code is returned, including ones with no models.
189
+ * List the method taxonomy
190
+ */
191
+ async listMethods(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListMethods200Response> {
192
+ const response = await this.listMethodsRaw(initOverrides);
193
+ return await response.value();
194
+ }
195
+
196
+ }
197
+
198
+ /**
199
+ * @export
200
+ */
201
+ export const GetMethodIdEnum = {
202
+ M1: 'M1',
203
+ M2: 'M2',
204
+ M3: 'M3',
205
+ M4: 'M4',
206
+ M5: 'M5',
207
+ M5Frankenstein: 'M5-frankenstein',
208
+ M6: 'M6',
209
+ M7: 'M7',
210
+ M8: 'M8',
211
+ MUncensored: 'M-uncensored',
212
+ Unknown: 'unknown',
213
+ } as const;
214
+ export type GetMethodIdEnum = typeof GetMethodIdEnum[keyof typeof GetMethodIdEnum];