@relevanceai/sdk 1.3.0 → 1.5.0

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.
@@ -1,6 +0,0 @@
1
- "use strict";
2
- /**
3
- * This file was auto-generated by openapi-typescript.
4
- * Do not make direct changes to the file.
5
- */
6
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,6 +0,0 @@
1
- "use strict";
2
- /**
3
- * This file was auto-generated by openapi-typescript.
4
- * Do not make direct changes to the file.
5
- */
6
- Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,82 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.DiscoveryClient = void 0;
4
- const BaseClient_1 = require("../shared/BaseClient");
5
- class DiscoveryClient extends BaseClient_1._GenericClient {
6
- constructor(config) {
7
- super({ ...config, service_name: 'Discovery' });
8
- }
9
- async Insert(input, options) {
10
- return this.SendRequest({
11
- input,
12
- method: 'post',
13
- path: '/datasets/{dataset_id}/documents/insert',
14
- options
15
- });
16
- }
17
- async BulkInsert(input, options) {
18
- return this.SendRequest({
19
- input,
20
- method: 'post',
21
- path: '/datasets/{dataset_id}/documents/bulk_insert',
22
- options
23
- });
24
- }
25
- async BlobAccessURLs(input, options) {
26
- return this.SendRequest({
27
- input,
28
- method: 'post',
29
- path: '/datasets/{dataset_id}/blob_access_urls',
30
- options
31
- });
32
- }
33
- async ParseBlob(input, options) {
34
- return this.SendRequest({
35
- input,
36
- method: 'post',
37
- path: '/datasets/{dataset_id}/parse_blob',
38
- options
39
- });
40
- }
41
- async Update(input, options) {
42
- return this.SendRequest({
43
- input,
44
- method: 'post',
45
- path: '/datasets/{dataset_id}/documents/update',
46
- options
47
- });
48
- }
49
- async BulkUpdate(input, options) {
50
- return this.SendRequest({
51
- input,
52
- method: 'post',
53
- path: '/datasets/{dataset_id}/documents/bulk_update',
54
- options
55
- });
56
- }
57
- async UpdateWhere(input, options) {
58
- return this.SendRequest({
59
- input,
60
- method: 'post',
61
- path: '/datasets/{dataset_id}/documents/update_where',
62
- options
63
- });
64
- }
65
- async SimpleSearchPost(input, options) {
66
- return this.SendRequest({
67
- input,
68
- method: 'post',
69
- path: '/datasets/{dataset_id}/simple_search',
70
- options
71
- });
72
- }
73
- async SimpleSearchGet(input, options) {
74
- return this.SendRequest({
75
- input,
76
- method: 'get',
77
- path: '/datasets/{dataset_id}/simple_search',
78
- options
79
- });
80
- }
81
- }
82
- exports.DiscoveryClient = DiscoveryClient;
@@ -1,179 +0,0 @@
1
- var __extends = (this && this.__extends) || (function () {
2
- var extendStatics = function (d, b) {
3
- extendStatics = Object.setPrototypeOf ||
4
- ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
5
- function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
6
- return extendStatics(d, b);
7
- };
8
- return function (d, b) {
9
- if (typeof b !== "function" && b !== null)
10
- throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
11
- extendStatics(d, b);
12
- function __() { this.constructor = d; }
13
- d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
14
- };
15
- })();
16
- var __assign = (this && this.__assign) || function () {
17
- __assign = Object.assign || function(t) {
18
- for (var s, i = 1, n = arguments.length; i < n; i++) {
19
- s = arguments[i];
20
- for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
21
- t[p] = s[p];
22
- }
23
- return t;
24
- };
25
- return __assign.apply(this, arguments);
26
- };
27
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
28
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
29
- return new (P || (P = Promise))(function (resolve, reject) {
30
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
31
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
32
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
33
- step((generator = generator.apply(thisArg, _arguments || [])).next());
34
- });
35
- };
36
- var __generator = (this && this.__generator) || function (thisArg, body) {
37
- var _ = { label: 0, sent: function() { if (t[0] & 1) throw t[1]; return t[1]; }, trys: [], ops: [] }, f, y, t, g;
38
- return g = { next: verb(0), "throw": verb(1), "return": verb(2) }, typeof Symbol === "function" && (g[Symbol.iterator] = function() { return this; }), g;
39
- function verb(n) { return function (v) { return step([n, v]); }; }
40
- function step(op) {
41
- if (f) throw new TypeError("Generator is already executing.");
42
- while (_) try {
43
- if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
44
- if (y = 0, t) op = [op[0] & 2, t.value];
45
- switch (op[0]) {
46
- case 0: case 1: t = op; break;
47
- case 4: _.label++; return { value: op[1], done: false };
48
- case 5: _.label++; y = op[1]; op = [0]; continue;
49
- case 7: op = _.ops.pop(); _.trys.pop(); continue;
50
- default:
51
- if (!(t = _.trys, t = t.length > 0 && t[t.length - 1]) && (op[0] === 6 || op[0] === 2)) { _ = 0; continue; }
52
- if (op[0] === 3 && (!t || (op[1] > t[0] && op[1] < t[3]))) { _.label = op[1]; break; }
53
- if (op[0] === 6 && _.label < t[1]) { _.label = t[1]; t = op; break; }
54
- if (t && _.label < t[2]) { _.label = t[2]; _.ops.push(op); break; }
55
- if (t[2]) _.ops.pop();
56
- _.trys.pop(); continue;
57
- }
58
- op = body.call(thisArg, _);
59
- } catch (e) { op = [6, e]; y = 0; } finally { f = t = 0; }
60
- if (op[0] & 5) throw op[1]; return { value: op[0] ? op[1] : void 0, done: true };
61
- }
62
- };
63
- import { _GenericClient } from '../shared/BaseClient';
64
- var DiscoveryClient = /** @class */ (function (_super) {
65
- __extends(DiscoveryClient, _super);
66
- function DiscoveryClient(config) {
67
- return _super.call(this, __assign(__assign({}, config), { service_name: 'Discovery' })) || this;
68
- }
69
- DiscoveryClient.prototype.Insert = function (input, options) {
70
- return __awaiter(this, void 0, void 0, function () {
71
- return __generator(this, function (_a) {
72
- return [2 /*return*/, this.SendRequest({
73
- input: input,
74
- method: 'post',
75
- path: '/datasets/{dataset_id}/documents/insert',
76
- options: options
77
- })];
78
- });
79
- });
80
- };
81
- DiscoveryClient.prototype.BulkInsert = function (input, options) {
82
- return __awaiter(this, void 0, void 0, function () {
83
- return __generator(this, function (_a) {
84
- return [2 /*return*/, this.SendRequest({
85
- input: input,
86
- method: 'post',
87
- path: '/datasets/{dataset_id}/documents/bulk_insert',
88
- options: options
89
- })];
90
- });
91
- });
92
- };
93
- DiscoveryClient.prototype.BlobAccessURLs = function (input, options) {
94
- return __awaiter(this, void 0, void 0, function () {
95
- return __generator(this, function (_a) {
96
- return [2 /*return*/, this.SendRequest({
97
- input: input,
98
- method: 'post',
99
- path: '/datasets/{dataset_id}/blob_access_urls',
100
- options: options
101
- })];
102
- });
103
- });
104
- };
105
- DiscoveryClient.prototype.ParseBlob = function (input, options) {
106
- return __awaiter(this, void 0, void 0, function () {
107
- return __generator(this, function (_a) {
108
- return [2 /*return*/, this.SendRequest({
109
- input: input,
110
- method: 'post',
111
- path: '/datasets/{dataset_id}/parse_blob',
112
- options: options
113
- })];
114
- });
115
- });
116
- };
117
- DiscoveryClient.prototype.Update = function (input, options) {
118
- return __awaiter(this, void 0, void 0, function () {
119
- return __generator(this, function (_a) {
120
- return [2 /*return*/, this.SendRequest({
121
- input: input,
122
- method: 'post',
123
- path: '/datasets/{dataset_id}/documents/update',
124
- options: options
125
- })];
126
- });
127
- });
128
- };
129
- DiscoveryClient.prototype.BulkUpdate = function (input, options) {
130
- return __awaiter(this, void 0, void 0, function () {
131
- return __generator(this, function (_a) {
132
- return [2 /*return*/, this.SendRequest({
133
- input: input,
134
- method: 'post',
135
- path: '/datasets/{dataset_id}/documents/bulk_update',
136
- options: options
137
- })];
138
- });
139
- });
140
- };
141
- DiscoveryClient.prototype.UpdateWhere = function (input, options) {
142
- return __awaiter(this, void 0, void 0, function () {
143
- return __generator(this, function (_a) {
144
- return [2 /*return*/, this.SendRequest({
145
- input: input,
146
- method: 'post',
147
- path: '/datasets/{dataset_id}/documents/update_where',
148
- options: options
149
- })];
150
- });
151
- });
152
- };
153
- DiscoveryClient.prototype.SimpleSearchPost = function (input, options) {
154
- return __awaiter(this, void 0, void 0, function () {
155
- return __generator(this, function (_a) {
156
- return [2 /*return*/, this.SendRequest({
157
- input: input,
158
- method: 'post',
159
- path: '/datasets/{dataset_id}/simple_search',
160
- options: options
161
- })];
162
- });
163
- });
164
- };
165
- DiscoveryClient.prototype.SimpleSearchGet = function (input, options) {
166
- return __awaiter(this, void 0, void 0, function () {
167
- return __generator(this, function (_a) {
168
- return [2 /*return*/, this.SendRequest({
169
- input: input,
170
- method: 'get',
171
- path: '/datasets/{dataset_id}/simple_search',
172
- options: options
173
- })];
174
- });
175
- });
176
- };
177
- return DiscoveryClient;
178
- }(_GenericClient));
179
- export { DiscoveryClient };