@kudoai/chatgpt.js 2.6.7 → 2.6.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.
- package/LICENSE.md +9 -0
- package/README.md +26 -24
- package/chatgpt.js +2056 -2060
- package/dist/chatgpt.min.js +3 -3
- package/docs/README.md +26 -24
- package/docs/SECURITY.md +25 -25
- package/docs/USERGUIDE.md +6 -6
- package/docs/de/LICENSE.md +29 -29
- package/docs/de/README.md +25 -23
- package/docs/de/SECURITY.md +25 -25
- package/docs/es/LICENSE.md +29 -29
- package/docs/es/README.md +25 -23
- package/docs/es/SECURITY.md +25 -25
- package/docs/fr/LICENSE.md +29 -29
- package/docs/fr/README.md +25 -23
- package/docs/fr/SECURITY.md +25 -25
- package/docs/hi/LICENSE.md +29 -29
- package/docs/hi/README.md +25 -23
- package/docs/hi/SECURITY.md +25 -25
- package/docs/it/LICENSE.md +26 -26
- package/docs/it/README.md +25 -23
- package/docs/it/SECURITY.md +25 -25
- package/docs/ja/LICENSE.md +29 -29
- package/docs/ja/README.md +25 -23
- package/docs/ja/SECURITY.md +25 -25
- package/docs/ko/LICENSE.md +32 -32
- package/docs/ko/README.md +25 -23
- package/docs/ko/SECURITY.md +25 -25
- package/docs/ne/LICENSE.md +35 -35
- package/docs/ne/README.md +25 -23
- package/docs/ne/SECURITY.md +25 -25
- package/docs/nl/LICENSE.md +29 -29
- package/docs/nl/README.md +25 -23
- package/docs/nl/SECURITY.md +25 -25
- package/docs/pt/LICENSE.md +28 -28
- package/docs/pt/README.md +25 -23
- package/docs/pt/SECURITY.md +25 -25
- package/docs/vi/LICENSE.md +29 -29
- package/docs/vi/README.md +25 -23
- package/docs/vi/SECURITY.md +25 -25
- package/docs/zh-cn/LICENSE.md +29 -29
- package/docs/zh-cn/README.md +25 -24
- package/docs/zh-cn/SECURITY.md +25 -25
- package/docs/zh-tw/LICENSE.md +29 -29
- package/docs/zh-tw/README.md +26 -24
- package/docs/zh-tw/SECURITY.md +25 -25
- package/package.json +73 -73
- package/starters/chrome/LICENSE.md +31 -43
- package/starters/chrome/docs/README.md +93 -93
- package/starters/chrome/docs/SECURITY.md +17 -17
- package/starters/chrome/docs/de/LICENSE.md +31 -31
- package/starters/chrome/docs/de/README.md +93 -93
- package/starters/chrome/docs/es/LICENSE.md +31 -31
- package/starters/chrome/docs/es/README.md +93 -93
- package/starters/chrome/docs/fr/LICENSE.md +31 -31
- package/starters/chrome/docs/fr/README.md +93 -93
- package/starters/chrome/docs/hi/LICENSE.md +31 -31
- package/starters/chrome/docs/hi/README.md +93 -93
- package/starters/chrome/docs/hi/SECURITY.md +17 -17
- package/starters/chrome/docs/it/LICENSE.md +29 -29
- package/starters/chrome/docs/it/README.md +93 -93
- package/starters/chrome/docs/ja/LICENSE.md +31 -31
- package/starters/chrome/docs/ja/README.md +93 -93
- package/starters/chrome/docs/ko/LICENSE.md +34 -34
- package/starters/chrome/docs/ko/README.md +93 -93
- package/starters/chrome/docs/nl/LICENSE.md +31 -30
- package/starters/chrome/docs/nl/README.md +93 -93
- package/starters/chrome/docs/pt/LICENSE.md +31 -31
- package/starters/chrome/docs/pt/README.md +93 -93
- package/starters/chrome/docs/vi/LICENSE.md +31 -31
- package/starters/chrome/docs/vi/README.md +93 -93
- package/starters/chrome/docs/zh-cn/LICENSE.md +31 -31
- package/starters/chrome/docs/zh-cn/README.md +93 -93
- package/starters/chrome/docs/zh-cn/SECURITY.md +17 -17
- package/starters/chrome/docs/zh-tw/LICENSE.md +31 -31
- package/starters/chrome/docs/zh-tw/README.md +93 -93
- package/starters/chrome/extension/background.js +14 -14
- package/starters/chrome/extension/content.js +62 -62
- package/starters/chrome/extension/lib/chatgpt.js +2057 -2061
- package/starters/chrome/extension/lib/settings-utils.js +24 -24
- package/starters/chrome/extension/manifest.json +24 -24
- package/starters/chrome/extension/popup/index.html +62 -62
- package/starters/chrome/extension/popup/popup.js +92 -92
- package/starters/chrome/extension/popup/style.css +55 -55
- package/starters/docs/LICENSE.md +13 -25
- package/starters/docs/README.md +29 -29
- package/starters/docs/de/LICENSE.md +13 -13
- package/starters/docs/de/README.md +29 -29
- package/starters/docs/es/LICENSE.md +13 -13
- package/starters/docs/es/README.md +29 -29
- package/starters/docs/fr/LICENSE.md +13 -13
- package/starters/docs/fr/README.md +29 -29
- package/starters/docs/hi/LICENSE.md +13 -13
- package/starters/docs/hi/README.md +29 -29
- package/starters/docs/it/LICENSE.md +11 -11
- package/starters/docs/it/README.md +29 -29
- package/starters/docs/ja/LICENSE.md +13 -13
- package/starters/docs/ja/README.md +30 -30
- package/starters/docs/ko/LICENSE.md +16 -16
- package/starters/docs/ko/README.md +29 -29
- package/starters/docs/nl/LICENSE.md +13 -13
- package/starters/docs/nl/README.md +29 -29
- package/starters/docs/pt/LICENSE.md +13 -13
- package/starters/docs/pt/README.md +29 -29
- package/starters/docs/vi/LICENSE.md +13 -13
- package/starters/docs/vi/README.md +29 -29
- package/starters/docs/zh-cn/LICENSE.md +13 -13
- package/starters/docs/zh-cn/README.md +30 -30
- package/starters/docs/zh-tw/LICENSE.md +13 -13
- package/starters/docs/zh-tw/README.md +29 -29
- package/starters/greasemonkey/LICENSE.md +31 -43
- package/starters/greasemonkey/chatgpt.js-greasemonkey-starter.user.js +5 -5
- package/starters/greasemonkey/docs/README.md +7 -7
- package/starters/greasemonkey/docs/SECURITY.md +17 -17
- package/starters/greasemonkey/docs/de/LICENSE.md +31 -31
- package/starters/greasemonkey/docs/es/LICENSE.md +31 -31
- package/starters/greasemonkey/docs/fr/LICENSE.md +31 -31
- package/starters/greasemonkey/docs/hi/LICENSE.md +31 -31
- package/starters/greasemonkey/docs/hi/SECURITY.md +17 -17
- package/starters/greasemonkey/docs/it/LICENSE.md +29 -29
- package/starters/greasemonkey/docs/ja/LICENSE.md +31 -31
- package/starters/greasemonkey/docs/ko/LICENSE.md +34 -34
- package/starters/greasemonkey/docs/nl/LICENSE.md +31 -30
- package/starters/greasemonkey/docs/pt/LICENSE.md +31 -31
- package/starters/greasemonkey/docs/vi/LICENSE.md +31 -31
- package/starters/greasemonkey/docs/zh-cn/LICENSE.md +31 -31
- package/starters/greasemonkey/docs/zh-cn/SECURITY.md +17 -17
- package/starters/greasemonkey/docs/zh-tw/LICENSE.md +31 -31
- package/LICENSE +0 -21
package/LICENSE.md
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
# MIT License
|
|
2
|
+
|
|
3
|
+
**Copyright © 2023–2024 [KudoAI](https://github.com/KudoAI) & [contributors](.#-contributors).**
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
|
6
|
+
|
|
7
|
+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
|
8
|
+
|
|
9
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
package/README.md
CHANGED
|
@@ -27,10 +27,12 @@
|
|
|
27
27
|
|
|
28
28
|
<br>
|
|
29
29
|
|
|
30
|
-
<
|
|
31
|
-
<
|
|
32
|
-
|
|
33
|
-
|
|
30
|
+
<a href="https://chatgpt.js.org">
|
|
31
|
+
<picture>
|
|
32
|
+
<source type="image/png" media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/media/images/logos/chatgpt.js/with-reflection/darkmode.png">
|
|
33
|
+
<img width=800 src="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/media/images/logos/chatgpt.js/with-reflection/lightmode.png">
|
|
34
|
+
</picture>
|
|
35
|
+
</a>
|
|
34
36
|
|
|
35
37
|
### 🤖 A powerful client-side JavaScript library for ChatGPT
|
|
36
38
|
|
|
@@ -41,10 +43,10 @@
|
|
|
41
43
|
<div id="shields" align="center">
|
|
42
44
|
|
|
43
45
|
[](https://github.com/KudoAI/chatgpt.js/stargazers)
|
|
44
|
-
[](https://github.com/KudoAI/chatgpt.js/blob/main/LICENSE)
|
|
45
|
-
[](https://github.com/KudoAI/chatgpt.js/blob/main/LICENSE.md)
|
|
47
|
+
[](https://github.com/KudoAI/chatgpt.js/commits/main)
|
|
48
|
+

|
|
49
|
+
[](https://www.codefactor.io/repository/github/kudoai/chatgpt.js)
|
|
48
50
|
[](https://sonarcloud.io/component_measures?metric=new_vulnerabilities&id=kudoai_chatgpt.js)
|
|
49
51
|
[](https://github.com/sindresorhus/awesome-chatgpt#javascript)
|
|
50
52
|
[](https://www.producthunt.com/posts/chatgpt-js)
|
|
@@ -52,7 +54,7 @@
|
|
|
52
54
|
|
|
53
55
|
</div>
|
|
54
56
|
|
|
55
|
-
<img height=8px width="100%" src="https://raw.githubusercontent.com/
|
|
57
|
+
<img height=8px width="100%" src="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/docs/assets/images/aqua-separator.png">
|
|
56
58
|
|
|
57
59
|
<div id="intro">
|
|
58
60
|
|
|
@@ -67,7 +69,7 @@
|
|
|
67
69
|
- Easy-to-use
|
|
68
70
|
- Lightweight (yet optimally performant)
|
|
69
71
|
|
|
70
|
-
<img height=8px width="100%" src="https://raw.githubusercontent.com/
|
|
72
|
+
<img height=8px width="100%" src="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/docs/assets/images/aqua-separator.png">
|
|
71
73
|
|
|
72
74
|
<div id="importing">
|
|
73
75
|
|
|
@@ -81,7 +83,7 @@
|
|
|
81
83
|
|
|
82
84
|
```js
|
|
83
85
|
(async () => {
|
|
84
|
-
await import('https://cdn.jsdelivr.net/npm/@kudoai/chatgpt.js@2.6.
|
|
86
|
+
await import('https://cdn.jsdelivr.net/npm/@kudoai/chatgpt.js@2.6.8/dist/chatgpt.min.js');
|
|
85
87
|
// Your code here...
|
|
86
88
|
})();
|
|
87
89
|
```
|
|
@@ -90,7 +92,7 @@
|
|
|
90
92
|
|
|
91
93
|
```js
|
|
92
94
|
var xhr = new XMLHttpRequest();
|
|
93
|
-
xhr.open('GET', 'https://cdn.jsdelivr.net/npm/@kudoai/chatgpt.js@2.6.
|
|
95
|
+
xhr.open('GET', 'https://cdn.jsdelivr.net/npm/@kudoai/chatgpt.js@2.6.8/dist/chatgpt.min.js');
|
|
94
96
|
xhr.onload = function () {
|
|
95
97
|
if (xhr.status === 200) {
|
|
96
98
|
var chatgptJS = document.createElement('script');
|
|
@@ -106,13 +108,13 @@ function yourCode() {
|
|
|
106
108
|
}
|
|
107
109
|
```
|
|
108
110
|
|
|
109
|
-
### <img style="margin: 0 2px -0.065rem 0" height=17 src="https://raw.githubusercontent.com/
|
|
111
|
+
### <img style="margin: 0 2px -0.065rem 0" height=17 src="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/starters/media/images/icons/tampermonkey-icon28.png"><img style="margin: 0 2px -0.035rem 1px" height=17.5 src="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/starters/media/images/icons/violentmonkey-icon100.png"> Greasemonkey:
|
|
110
112
|
|
|
111
113
|
> **Note** _To use a starter template: [kudoai/chatgpt.js-greasemonkey-starter](https://github.com/KudoAI/chatgpt.js-greasemonkey-starter)_
|
|
112
114
|
|
|
113
115
|
```js
|
|
114
116
|
...
|
|
115
|
-
// @require https://cdn.jsdelivr.net/npm/@kudoai/chatgpt.js@2.6.
|
|
117
|
+
// @require https://cdn.jsdelivr.net/npm/@kudoai/chatgpt.js@2.6.8/dist/chatgpt.min.js
|
|
116
118
|
// ==/UserScript==
|
|
117
119
|
|
|
118
120
|
// Your code here...
|
|
@@ -124,7 +126,7 @@ function yourCode() {
|
|
|
124
126
|
|
|
125
127
|
Since Google does not allow remote code, importing chatgpt.js locally is required:
|
|
126
128
|
|
|
127
|
-
1. Save https://raw.githubusercontent.com/
|
|
129
|
+
1. Save https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/chatgpt.js to a subdirectory (`lib` in this example)
|
|
128
130
|
|
|
129
131
|
2. Add ES6 export statement to end of `lib/chatgpt.js`
|
|
130
132
|
```js
|
|
@@ -148,7 +150,7 @@ export { chatgpt }
|
|
|
148
150
|
})();
|
|
149
151
|
```
|
|
150
152
|
|
|
151
|
-
<img height=8px width="100%" src="https://raw.githubusercontent.com/
|
|
153
|
+
<img height=8px width="100%" src="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/docs/assets/images/aqua-separator.png">
|
|
152
154
|
|
|
153
155
|
<div id="npm">
|
|
154
156
|
|
|
@@ -166,7 +168,7 @@ After installation, navigate to `node_modules/@kudoai/chatgpt.js` to find the li
|
|
|
166
168
|
|
|
167
169
|
</div>
|
|
168
170
|
|
|
169
|
-
<img height=8px width="100%" src="https://raw.githubusercontent.com/
|
|
171
|
+
<img height=8px width="100%" src="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/docs/assets/images/aqua-separator.png">
|
|
170
172
|
|
|
171
173
|
<div id="usage">
|
|
172
174
|
|
|
@@ -189,7 +191,7 @@ Each call equally fetches the last response. If you think it works, it probably
|
|
|
189
191
|
|
|
190
192
|
If it didn't, check out the extended [userguide](https://github.com/KudoAI/chatgpt.js/blob/main/docs/USERGUIDE.md), or simply submit an [issue](https://github.com/KudoAI/chatgpt.js/issues) or [PR](https://github.com/KudoAI/chatgpt.js/pulls) and it will be integrated, ezpz!
|
|
191
193
|
|
|
192
|
-
<img height=8px width="100%" src="https://raw.githubusercontent.com/
|
|
194
|
+
<img height=8px width="100%" src="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/docs/assets/images/aqua-separator.png">
|
|
193
195
|
|
|
194
196
|
<div id="showcase">
|
|
195
197
|
|
|
@@ -268,7 +270,7 @@ https://github.com/KudoAI/chatgpt.js/assets/10906554/f53c740f-d5e0-49b6-ae02-3b3
|
|
|
268
270
|
If you've made something w/ chatgpt.js you want to share, email <a href="mailto:showcase@chatgptjs.org">showcase@chatgptjs.org</a> or just open a <a href="https://github.com/KudoAI/chatgpt.js/pulls" target="_blank" rel="noopener">pull request</a>!
|
|
269
271
|
</p>
|
|
270
272
|
|
|
271
|
-
<img height=8px width="100%" src="https://raw.githubusercontent.com/
|
|
273
|
+
<img height=8px width="100%" src="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/docs/assets/images/aqua-separator.png">
|
|
272
274
|
|
|
273
275
|
<div id="contributors">
|
|
274
276
|
|
|
@@ -305,12 +307,12 @@ This library exists thanks to code, translations, issues & ideas from the follow
|
|
|
305
307
|
[](https://github.com/Luwa-Tech)
|
|
306
308
|
[](https://github.com/dependabot)
|
|
307
309
|
[](https://chat.openai.com)
|
|
308
|
-
[](https://poe.com)
|
|
309
311
|
[](https://github.com/ImgBotApp)
|
|
310
312
|
|
|
311
313
|
</div><br>
|
|
312
314
|
|
|
313
|
-
<img height=8px width="100%" src="https://raw.githubusercontent.com/
|
|
315
|
+
<img height=8px width="100%" src="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/docs/assets/images/aqua-separator.png">
|
|
314
316
|
|
|
315
317
|
<div id="partners">
|
|
316
318
|
|
|
@@ -323,15 +325,15 @@ This library exists thanks to code, translations, issues & ideas from the follow
|
|
|
323
325
|
<div id="partners-collage" align="center">
|
|
324
326
|
|
|
325
327
|
<picture>
|
|
326
|
-
<source type="image/png" media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/
|
|
327
|
-
<img width=888 src="https://raw.githubusercontent.com/
|
|
328
|
+
<source type="image/png" media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/media/images/logos/partners/collage/white.png">
|
|
329
|
+
<img width=888 src="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/media/images/logos/partners/collage/black.png">
|
|
328
330
|
</picture>
|
|
329
331
|
|
|
330
332
|
</div>
|
|
331
333
|
|
|
332
334
|
<br>
|
|
333
335
|
|
|
334
|
-
<img height=8px width="100%" src="https://raw.githubusercontent.com/
|
|
336
|
+
<img height=8px width="100%" src="https://raw.githubusercontent.com/KudoAI/chatgpt.js/main/docs/assets/images/aqua-separator.png">
|
|
335
337
|
|
|
336
338
|
<div align="center">
|
|
337
339
|
|