openlayer 0.1.27 → 0.1.28
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/dist/index.d.ts +2 -2
- package/dist/index.js +2 -2
- package/package.json +2 -1
package/dist/index.d.ts
CHANGED
|
@@ -143,7 +143,6 @@ export declare class OpenlayerClient {
|
|
|
143
143
|
/**
|
|
144
144
|
* Constructs an OpenlayerClient instance.
|
|
145
145
|
* @param {OpenlayerClientConstructorProps} props - The config for the Openlayer client. The API key is required.
|
|
146
|
-
* @throws {Error} Throws an error if the Openlayer API key is not provided.
|
|
147
146
|
*/
|
|
148
147
|
constructor({ openlayerApiKey, openlayerServerUrl, }: OpenlayerClientConstructorProps);
|
|
149
148
|
private resolvedQuery;
|
|
@@ -207,7 +206,7 @@ export declare class OpenAIMonitor {
|
|
|
207
206
|
* @param {ChatCompletionCreateParams} body - The parameters for creating a chat completion.
|
|
208
207
|
* @param {RequestOptions} [options] - Optional request options.
|
|
209
208
|
* @returns {Promise<ChatCompletion | Stream<ChatCompletionChunk>>} Promise of a ChatCompletion or a Stream
|
|
210
|
-
* @throws {Error} Throws
|
|
209
|
+
* @throws {Error} Throws errors from the OpenAI client.
|
|
211
210
|
*/
|
|
212
211
|
createChatCompletion: (body: ChatCompletionCreateParams, options?: RequestOptions, additionalLogs?: StreamingData) => Promise<ChatCompletion | Stream<ChatCompletionChunk>>;
|
|
213
212
|
/**
|
|
@@ -215,6 +214,7 @@ export declare class OpenAIMonitor {
|
|
|
215
214
|
* @param {CompletionCreateParams} body - The parameters for creating a completion.
|
|
216
215
|
* @param {RequestOptions} [options] - Optional request options.
|
|
217
216
|
* @returns {Promise<Completion | Stream<Completion>>} Promise that resolves to a Completion or a Stream.
|
|
217
|
+
* @throws {Error} Throws errors from the OpenAI client.
|
|
218
218
|
*/
|
|
219
219
|
createCompletion: (body: CompletionCreateParams, options?: RequestOptions, additionalLogs?: StreamingData) => Promise<Completion | Stream<Completion>>;
|
|
220
220
|
/**
|
package/dist/index.js
CHANGED
|
@@ -98,7 +98,6 @@ class OpenlayerClient {
|
|
|
98
98
|
/**
|
|
99
99
|
* Constructs an OpenlayerClient instance.
|
|
100
100
|
* @param {OpenlayerClientConstructorProps} props - The config for the Openlayer client. The API key is required.
|
|
101
|
-
* @throws {Error} Throws an error if the Openlayer API key is not provided.
|
|
102
101
|
*/
|
|
103
102
|
constructor({ openlayerApiKey, openlayerServerUrl, }) {
|
|
104
103
|
this.defaultConfig = {
|
|
@@ -320,7 +319,7 @@ class OpenAIMonitor {
|
|
|
320
319
|
* @param {ChatCompletionCreateParams} body - The parameters for creating a chat completion.
|
|
321
320
|
* @param {RequestOptions} [options] - Optional request options.
|
|
322
321
|
* @returns {Promise<ChatCompletion | Stream<ChatCompletionChunk>>} Promise of a ChatCompletion or a Stream
|
|
323
|
-
* @throws {Error} Throws
|
|
322
|
+
* @throws {Error} Throws errors from the OpenAI client.
|
|
324
323
|
*/
|
|
325
324
|
this.createChatCompletion = (body, options, additionalLogs) => __awaiter(this, void 0, void 0, function* () {
|
|
326
325
|
var _a, e_1, _b, _c;
|
|
@@ -401,6 +400,7 @@ class OpenAIMonitor {
|
|
|
401
400
|
* @param {CompletionCreateParams} body - The parameters for creating a completion.
|
|
402
401
|
* @param {RequestOptions} [options] - Optional request options.
|
|
403
402
|
* @returns {Promise<Completion | Stream<Completion>>} Promise that resolves to a Completion or a Stream.
|
|
403
|
+
* @throws {Error} Throws errors from the OpenAI client.
|
|
404
404
|
*/
|
|
405
405
|
this.createCompletion = (body, options, additionalLogs) => __awaiter(this, void 0, void 0, function* () {
|
|
406
406
|
var _m, e_2, _o, _p;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "openlayer",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.28",
|
|
4
4
|
"description": "The Openlayer TypeScript client",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"types": "dist/index.d.ts",
|
|
@@ -20,6 +20,7 @@
|
|
|
20
20
|
"eslint-plugin-typescript-sort-keys": "^3.1.0",
|
|
21
21
|
"node-fetch": "^3.3.2",
|
|
22
22
|
"openai": "^4.19.0",
|
|
23
|
+
"openlayer": "^0.1.27",
|
|
23
24
|
"uuid": "^9.0.1"
|
|
24
25
|
},
|
|
25
26
|
"devDependencies": {
|