From 6aebb612f09c5294dc414942c4dcaebbfba050e0 Mon Sep 17 00:00:00 2001 From: Elad Ben-Israel Date: Tue, 19 Mar 2024 11:56:06 +0200 Subject: [PATCH] tweaks --- openai/README.md | 54 +++++++++++++++++++++++++++++++-------- openai/api.w | 2 +- openai/example.main.w | 12 +++++++++ openai/openai.extern.d.ts | 10 ++++++++ openai/openai.js | 10 +++----- openai/openai.test.w | 30 ++++++++++------------ openai/openai.w | 53 ++++++++++++++++++++++++-------------- openai/package-lock.json | 48 +++++++++++++++++++++++++++------- openai/package.json | 2 +- 9 files changed, 158 insertions(+), 63 deletions(-) create mode 100644 openai/example.main.w create mode 100644 openai/openai.extern.d.ts diff --git a/openai/README.md b/openai/README.md index 36bdc3d7..83533ef5 100644 --- a/openai/README.md +++ b/openai/README.md @@ -1,38 +1,72 @@ # openai +An [OpenAI](https://openai.com) library for Winglang. + +> This is an initial version of this library which currently exposes a very small subset of the +> OpenAI API. + ## Prerequisites * [winglang](https://winglang.io). ## Installation -`sh +```sh npm i @winglibs/openai -` +``` ## Example -`js +```js +bring cloud; bring openai; -let openAIService = new openai.OpenAI("your-api-key"); +let key = new cloud.Secret(name: "OAIApiKey"); +let oai = new openai.OpenAI(apiKeySecret: key); new cloud.Function(inflight () => { - let joke = openAIService.createCompletion("tell me a short joke"); + let joke = oai.createCompletion("tell me a short joke", model: "gpt-3.5-turbo", max_tokens: 2048); log(joke); }); -` +``` + +When running in a `test` context, the `createCompletion` method will return a JSON object which +echos the request under the `mock` key: + +```js +bring expect; + +test "create completion test" { + let r = oai.createCompletion("tell me a short joke"); + expect.equal(r, Json.stringify({ + mock: { + prompt:"tell me a short joke", + params:{"model":"gpt-3.5-turbo","max_tokens":2048} + } + })); +} +``` ## Usage -The `openai.OpenAI` resource provides the following inflight methods: -* `createCompletion` - Gets an answer to a prompt. +```js +new openai.OpenAI(); +``` + +* `apiKeySecret` - a `cloud.Secret` with the OpenAI API key (required). +* `orgSecret` - a `cloud.Secret` with the OpenAI organization ID (not required). + +You can also specify clear text values through `apiKey` and `org`, but make sure not to commit these +values to a repository :warning:. + +Methods: -The preflight constructor requires an api key in the form of either a secret or a string. +* `inflight createCompletion()` - requests a completion from a model. Options are `model` (defaults + to `gpt-3.5.turbo`) and `max_tokens` (defaults to 2048). ## Roadmap -* [x] Support the rest of the openai API +* [ ] Support the rest of the OpenAI API * [ ] Add more examples * [ ] Add more tests diff --git a/openai/api.w b/openai/api.w index 8a61690e..9ea0c07e 100644 --- a/openai/api.w +++ b/openai/api.w @@ -4,6 +4,6 @@ pub struct CompletionParams { } // TODO: need to recreate the openai interface with higher fidelity -pub interface IOpenAI extends std.IResource { +pub interface IOpenAI { inflight createCompletion(prompt: str, params: CompletionParams?): str; } diff --git a/openai/example.main.w b/openai/example.main.w new file mode 100644 index 00000000..e42c3ae7 --- /dev/null +++ b/openai/example.main.w @@ -0,0 +1,12 @@ +bring expect; +bring "./openai.w" as openai; + +bring cloud; + +let key = new cloud.Secret(name: "my-openai-key"); +let oai = new openai.OpenAI(apiKeySecret: key); + +new cloud.Function(inflight () => { + let answer = oai.createCompletion("tell me a short joke", model: "gpt-3.5-turbo", max_tokens: 2048); + log(answer); +}) as "tell me a joke"; diff --git a/openai/openai.extern.d.ts b/openai/openai.extern.d.ts new file mode 100644 index 00000000..ddb1e323 --- /dev/null +++ b/openai/openai.extern.d.ts @@ -0,0 +1,10 @@ +export default interface extern { + createNewInflightClient: (apiKey: string, org?: (string) | undefined) => Promise, +} +export interface CompletionParams { + readonly max_tokens: number; + readonly model: string; +} +export interface IOpenAI$Inflight { + readonly createCompletion: (prompt: string, params?: (CompletionParams) | undefined) => Promise; +} \ No newline at end of file diff --git a/openai/openai.js b/openai/openai.js index 25eda35d..0f6c0298 100644 --- a/openai/openai.js +++ b/openai/openai.js @@ -1,9 +1,7 @@ const openai = require('openai'); exports.createNewInflightClient = (apiKey, org) => { - const config = { - apiKey: apiKey - }; + const config = { apiKey }; if (org) { config.organization = org; @@ -14,7 +12,7 @@ exports.createNewInflightClient = (apiKey, org) => { // TODO: this is a hack for now, we should model the openai api in the api.w file with more fidelity // and then we can just return the client itself, like we do in redis return { - createCompletion: async (prompt, params = { model: "gpt-3.5-turbo", max_tokens: 2048 }) => { + createCompletion: async (prompt, params = {}) => { if (!prompt) { throw new Error("Prompt is required"); }; @@ -31,12 +29,10 @@ exports.createNewInflightClient = (apiKey, org) => { params.max_tokens = 2048; } - params.messages = [{role: 'user', content: prompt}]; + params.messages = [ { role: 'user', content: prompt } ]; const response = await client.chat.completions.create(params); - return response.choices[0]?.message?.content; } }; }; - diff --git a/openai/openai.test.w b/openai/openai.test.w index bbf2628c..21299d4a 100644 --- a/openai/openai.test.w +++ b/openai/openai.test.w @@ -1,21 +1,19 @@ bring expect; bring "./openai.w" as openai; -let client = new openai.OpenAI(); +bring cloud; -// This test currently doesn't pass because of issue https://github.com/winglang/wing/issues/5948 -// test "cant create client without key" { -// let var errorMessage = ""; -// try { -// let answer = client.createCompletion("tell me a short joke"); -// } catch e { -// errorMessage = e; -// } -// expect.equal(errorMessage, "OpenAI API key is required"); -// } +let key = new cloud.Secret(name: "my-openai-key"); +let oai = new openai.OpenAI(apiKeySecret: key); -// This test currently cannot pass because we can't pass credentials to it in the test runner -// test "basic completion" { -// let answer = client.createCompletion("tell me a short joke"); -// expect.notNil(answer); -// } +test "basic completion" { + let answer = oai.createCompletion("tell me a short joke", model: "gpt-3.5-turbo", max_tokens: 2048); + + // in tests, the response is just an echo of the request + expect.equal(answer, Json.stringify({ + mock: { + prompt:"tell me a short joke", + params:{"model":"gpt-3.5-turbo","max_tokens":2048} + } + })); +} diff --git a/openai/openai.w b/openai/openai.w index 58433b17..be6a4737 100644 --- a/openai/openai.w +++ b/openai/openai.w @@ -3,40 +3,55 @@ bring "./api.w" as api; bring "./utils.w" as utils; bring cloud; +pub struct OpenAIProps { + apiKey: str?; + org: str?; + apiKeySecret: cloud.Secret?; + orgSecret: cloud.Secret?; +} + +inflight class Sim impl api.IOpenAI { + pub createCompletion(prompt: str, params: api.CompletionParams?): str { + return Json.stringify({ mock: { prompt: prompt, params: params } }); + } +} + pub class OpenAI impl api.IOpenAI { apiKey: cloud.Secret?; org: cloud.Secret?; keyOverride: str?; orgOverride: str?; + mock: bool; + inflight openai: api.IOpenAI; - new (apiKey: str?, org: str?, apiKeySecret: cloud.Secret?, orgSecret: cloud.Secret?) { - this.apiKey = apiKeySecret; - this.org = orgSecret; - this.keyOverride = apiKey; - this.orgOverride = org; + new(props: OpenAIProps?) { + this.apiKey = props?.apiKeySecret; + this.org = props?.orgSecret; + this.keyOverride = props?.apiKey; + this.orgOverride = props?.org; + this.mock = util.env("WING_TARGET") == "sim" && nodeof(this).app.isTestEnvironment; } inflight new() { - // I wanted to write this thing like this: - // let apiKey: str? = this.keyOverride ?? this.apiKey?.value(); - // I was even willing to settle for this: - // let apiKey: str? = this.keyOverride ?? this.apiKey?.value(); - // But neither of those work. So I'm doing this instead after opening issue https://github.com/winglang/wing/issues/5944: - let var apiKey = this.keyOverride; - if (apiKey == nil){ - apiKey = this.apiKey?.value(); - } - if (apiKey == nil || apiKey == ""){ - throw "OpenAI API key is required"; + // TODO: https://github.com/winglang/wing/issues/5944 + let UNDEFINED = ""; + let apiKey = this.keyOverride ?? this.apiKey?.value() ?? UNDEFINED; + if apiKey == UNDEFINED { + throw "Either `apiKeySecret` or `apiKey` are required"; } + let var org: str? = this.orgOverride; - if (org == nil){ + if org == nil { org = this.org?.value(); } - - this.openai = utils.createNewInflightClient(apiKey!, org); + + if this.mock { + this.openai = new Sim(); + } else { + this.openai = utils.createNewInflightClient(apiKey, org); + } } pub inflight createCompletion(prompt: str, params: api.CompletionParams?): str { diff --git a/openai/package-lock.json b/openai/package-lock.json index 0a52ec44..ea549f32 100644 --- a/openai/package-lock.json +++ b/openai/package-lock.json @@ -8,7 +8,7 @@ "name": "@winglibs/openai", "version": "0.0.1", "license": "MIT", - "dependencies": { + "peerDependencies": { "openai": "^4.28.4" } }, @@ -16,6 +16,7 @@ "version": "18.19.24", "resolved": "https://registry.npmjs.org/@types/node/-/node-18.19.24.tgz", "integrity": "sha512-eghAz3gnbQbvnHqB+mgB2ZR3aH6RhdEmHGS48BnV75KceQPHqabkxKI0BbUSsqhqy2Ddhc2xD/VAR9ySZd57Lw==", + "peer": true, "dependencies": { "undici-types": "~5.26.4" } @@ -24,6 +25,7 @@ "version": "2.6.11", "resolved": "https://registry.npmjs.org/@types/node-fetch/-/node-fetch-2.6.11.tgz", "integrity": "sha512-24xFj9R5+rfQJLRyM56qh+wnVSYhyXC2tkoBndtY0U+vubqNsYXGjufB2nn8Q6gt0LrARwL6UBtMCSVCwl4B1g==", + "peer": true, "dependencies": { "@types/node": "*", "form-data": "^4.0.0" @@ -33,6 +35,7 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/abort-controller/-/abort-controller-3.0.0.tgz", "integrity": "sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==", + "peer": true, "dependencies": { "event-target-shim": "^5.0.0" }, @@ -44,6 +47,7 @@ "version": "4.5.0", "resolved": "https://registry.npmjs.org/agentkeepalive/-/agentkeepalive-4.5.0.tgz", "integrity": "sha512-5GG/5IbQQpC9FpkRGsSvZI5QYeSCzlJHdpBQntCsuTOxhKD8lqKhrleg2Yi7yvMIf82Ycmmqln9U8V9qwEiJew==", + "peer": true, "dependencies": { "humanize-ms": "^1.2.1" }, @@ -54,17 +58,20 @@ "node_modules/asynckit": { "version": "0.4.0", "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", - "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==" + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", + "peer": true }, "node_modules/base-64": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/base-64/-/base-64-0.1.0.tgz", - "integrity": "sha512-Y5gU45svrR5tI2Vt/X9GPd3L0HNIKzGu202EjxrXMpuc2V2CiKgemAbUUsqYmZJvPtCXoUKjNZwBJzsNScUbXA==" + "integrity": "sha512-Y5gU45svrR5tI2Vt/X9GPd3L0HNIKzGu202EjxrXMpuc2V2CiKgemAbUUsqYmZJvPtCXoUKjNZwBJzsNScUbXA==", + "peer": true }, "node_modules/charenc": { "version": "0.0.2", "resolved": "https://registry.npmjs.org/charenc/-/charenc-0.0.2.tgz", "integrity": "sha512-yrLQ/yVUFXkzg7EDQsPieE/53+0RlaWTs+wBrvW36cyilJ2SaDWfl4Yj7MtLTXleV9uEKefbAGUPv2/iWSooRA==", + "peer": true, "engines": { "node": "*" } @@ -73,6 +80,7 @@ "version": "1.0.8", "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "peer": true, "dependencies": { "delayed-stream": "~1.0.0" }, @@ -84,6 +92,7 @@ "version": "0.0.2", "resolved": "https://registry.npmjs.org/crypt/-/crypt-0.0.2.tgz", "integrity": "sha512-mCxBlsHFYh9C+HVpiEacem8FEBnMXgU9gy4zmNC+SXAZNB/1idgp/aulFJ4FgCi7GPEVbfyng092GqL2k2rmow==", + "peer": true, "engines": { "node": "*" } @@ -92,6 +101,7 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", + "peer": true, "engines": { "node": ">=0.4.0" } @@ -100,6 +110,7 @@ "version": "1.3.0", "resolved": "https://registry.npmjs.org/digest-fetch/-/digest-fetch-1.3.0.tgz", "integrity": "sha512-CGJuv6iKNM7QyZlM2T3sPAdZWd/p9zQiRNS9G+9COUCwzWFTs0Xp8NF5iePx7wtvhDykReiRRrSeNb4oMmB8lA==", + "peer": true, "dependencies": { "base-64": "^0.1.0", "md5": "^2.3.0" @@ -109,6 +120,7 @@ "version": "5.0.1", "resolved": "https://registry.npmjs.org/event-target-shim/-/event-target-shim-5.0.1.tgz", "integrity": "sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ==", + "peer": true, "engines": { "node": ">=6" } @@ -117,6 +129,7 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", + "peer": true, "dependencies": { "asynckit": "^0.4.0", "combined-stream": "^1.0.8", @@ -129,12 +142,14 @@ "node_modules/form-data-encoder": { "version": "1.7.2", "resolved": "https://registry.npmjs.org/form-data-encoder/-/form-data-encoder-1.7.2.tgz", - "integrity": "sha512-qfqtYan3rxrnCk1VYaA4H+Ms9xdpPqvLZa6xmMgFvhO32x7/3J/ExcTd6qpxM0vH2GdMI+poehyBZvqfMTto8A==" + "integrity": "sha512-qfqtYan3rxrnCk1VYaA4H+Ms9xdpPqvLZa6xmMgFvhO32x7/3J/ExcTd6qpxM0vH2GdMI+poehyBZvqfMTto8A==", + "peer": true }, "node_modules/formdata-node": { "version": "4.4.1", "resolved": "https://registry.npmjs.org/formdata-node/-/formdata-node-4.4.1.tgz", "integrity": "sha512-0iirZp3uVDjVGt9p49aTaqjk84TrglENEDuqfdlZQ1roC9CWlPk6Avf8EEnZNcAqPonwkG35x4n3ww/1THYAeQ==", + "peer": true, "dependencies": { "node-domexception": "1.0.0", "web-streams-polyfill": "4.0.0-beta.3" @@ -147,6 +162,7 @@ "version": "4.0.0-beta.3", "resolved": "https://registry.npmjs.org/web-streams-polyfill/-/web-streams-polyfill-4.0.0-beta.3.tgz", "integrity": "sha512-QW95TCTaHmsYfHDybGMwO5IJIM93I/6vTRk+daHTWFPhwh+C8Cg7j7XyKrwrj8Ib6vYXe0ocYNrmzY4xAAN6ug==", + "peer": true, "engines": { "node": ">= 14" } @@ -155,6 +171,7 @@ "version": "1.2.1", "resolved": "https://registry.npmjs.org/humanize-ms/-/humanize-ms-1.2.1.tgz", "integrity": "sha512-Fl70vYtsAFb/C06PTS9dZBo7ihau+Tu/DNCk/OyHhea07S+aeMWpFFkUaXRa8fI+ScZbEI8dfSxwY7gxZ9SAVQ==", + "peer": true, "dependencies": { "ms": "^2.0.0" } @@ -162,12 +179,14 @@ "node_modules/is-buffer": { "version": "1.1.6", "resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz", - "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==" + "integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==", + "peer": true }, "node_modules/md5": { "version": "2.3.0", "resolved": "https://registry.npmjs.org/md5/-/md5-2.3.0.tgz", "integrity": "sha512-T1GITYmFaKuO91vxyoQMFETst+O71VUPEU3ze5GNzDm0OWdP8v1ziTaAEPUr/3kLsY3Sftgz242A1SetQiDL7g==", + "peer": true, "dependencies": { "charenc": "0.0.2", "crypt": "0.0.2", @@ -178,6 +197,7 @@ "version": "1.52.0", "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "peer": true, "engines": { "node": ">= 0.6" } @@ -186,6 +206,7 @@ "version": "2.1.35", "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "peer": true, "dependencies": { "mime-db": "1.52.0" }, @@ -196,7 +217,8 @@ "node_modules/ms": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", - "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==" + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", + "peer": true }, "node_modules/node-domexception": { "version": "1.0.0", @@ -212,6 +234,7 @@ "url": "https://paypal.me/jimmywarting" } ], + "peer": true, "engines": { "node": ">=10.5.0" } @@ -220,6 +243,7 @@ "version": "2.7.0", "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", + "peer": true, "dependencies": { "whatwg-url": "^5.0.0" }, @@ -239,6 +263,7 @@ "version": "4.28.4", "resolved": "https://registry.npmjs.org/openai/-/openai-4.28.4.tgz", "integrity": "sha512-RNIwx4MT/F0zyizGcwS+bXKLzJ8QE9IOyigDG/ttnwB220d58bYjYFp0qjvGwEFBO6+pvFVIDABZPGDl46RFsg==", + "peer": true, "dependencies": { "@types/node": "^18.11.18", "@types/node-fetch": "^2.6.4", @@ -257,17 +282,20 @@ "node_modules/tr46": { "version": "0.0.3", "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", - "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" + "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==", + "peer": true }, "node_modules/undici-types": { "version": "5.26.5", "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-5.26.5.tgz", - "integrity": "sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==" + "integrity": "sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==", + "peer": true }, "node_modules/web-streams-polyfill": { "version": "3.3.3", "resolved": "https://registry.npmjs.org/web-streams-polyfill/-/web-streams-polyfill-3.3.3.tgz", "integrity": "sha512-d2JWLCivmZYTSIoge9MsgFCZrt571BikcWGYkjC1khllbTeDlGqZ2D8vD8E/lJa8WGWbb7Plm8/XJYV7IJHZZw==", + "peer": true, "engines": { "node": ">= 8" } @@ -275,12 +303,14 @@ "node_modules/webidl-conversions": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", - "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==" + "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==", + "peer": true }, "node_modules/whatwg-url": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", + "peer": true, "dependencies": { "tr46": "~0.0.3", "webidl-conversions": "^3.0.0" diff --git a/openai/package.json b/openai/package.json index 9ddb2708..3319e2da 100644 --- a/openai/package.json +++ b/openai/package.json @@ -1,6 +1,6 @@ { "name": "@winglibs/openai", - "description": "openai library for Wing", + "description": "OpenAI library for Wing", "version": "0.0.1", "repository": { "type": "git",