1292 | `;
1293 | el.insertBefore(cdiv_new, el.childNodes[1]);
1294 | } else if ($('.navtitle', el).innerHTML !== title || $('.navdate', el).innerHTML !== formatDate2(update_time) || $('.navlast', el).innerHTML !== last) {
1295 | $('.navtitle', el).innerHTML = title;
1296 | $('.navdate', el).innerHTML = formatDate2(update_time);
1297 | $('.navlast', el).innerHTML = htmlEncode(last);
1298 | }
1299 | });
1300 |
1301 | const sidebar_chat = $("nav.flex div.overflow-y-auto");
1302 | if (sidebar_chat) {
1303 | if (sidebar_chat.scrollHeight > sidebar_chat.clientHeight) {
1304 | sidebar_chat.classList.add("-mr-2");
1305 | } else {
1306 | sidebar_chat.classList.remove("-mr-2");
1307 | }
1308 | }
1309 | };
1310 |
1311 | const verInt = function(vs) {
1312 | const vl = vs.split('.');
1313 | let vi = 0;
1314 | for (let i = 0; i < vl.length && i < 3; i++) {
1315 | vi += parseInt(vl[i]) * (1000 ** (2 - i));
1316 | }
1317 | return vi;
1318 | };
1319 |
1320 | const checkForUpdates = function(action = "click") {
1321 | const downloadURL = `https://raw.githubusercontent.com/xcanwin/KeepChatGPT/main/KeepChatGPT.user.js`;
1322 | const updateURL = downloadURL;
1323 | GM_xmlhttpRequest({
1324 | method: "GET",
1325 | url: `${updateURL}?t=${Date.now()}`,
1326 | onload: function(response) {
1327 | const crv = GM_info.script.version;
1328 | const m = response.responseText.match(/@version\s+(\S+)/);
1329 | const ltv = m && m[1];
1330 | if (ltv && verInt(ltv) > verInt(crv)) {
1331 | ndialog(`${tl("检查更新")}`, `${tl("当前版本")}: ${crv}, ${tl("发现最新版")}: ${ltv}`, `UPDATE`, function(t) {
1332 | window.open(`${downloadURL}?t=${Date.now()}`, '_blank');
1333 | });
1334 | } else {
1335 | if (action === "click") {
1336 | ndialog(`${tl("检查更新")}`, `${tl("当前版本")}: ${crv}, ${tl("已是最新版")}`, `OK`);
1337 | }
1338 | }
1339 | }
1340 | });
1341 | };
1342 |
1343 | /*
1344 | 克隆对话
1345 | */
1346 | const cloneChat = function(action) {
1347 | cloneChat.firstTarget = null;
1348 | if (action === true) {
1349 | window.addEventListener('click', cloneChat.listen_Click);
1350 | } else {
1351 | window.removeEventListener('click', cloneChat.listen_Click);
1352 | }
1353 | };
1354 |
1355 | cloneChat.listen_Click = function(event) {
1356 | event.stopPropagation();
1357 | const clickedElement = document.elementFromPoint(event.clientX, event.clientY);
1358 | if (clickedElement && clickedElement.matches('main div[data-message-author-role="user"]')) {
1359 | // 获取该元素的边界信息
1360 | const rect = clickedElement.getBoundingClientRect();
1361 |
1362 | // 伪元素的宽度和高度是2rem
1363 | const logoWidth = 32;
1364 | const logoHeight = 32;
1365 |
1366 | // 计算伪元素所在区域的边界
1367 | const logoRight = rect.right;
1368 | const logoLeft = rect.right - logoWidth;
1369 | const logoTop = rect.top;
1370 | const logoBottom = rect.top + logoHeight;
1371 |
1372 | // 判断鼠标点击的位置是否在伪元素范围内
1373 | if (event.clientX >= logoLeft && event.clientX <= logoRight && event.clientY >= logoTop && event.clientY <= logoBottom) {
1374 | const content = event.target.innerText.trim();
1375 | $("form.w-full #prompt-textarea").innerHTML = ''
1376 | $("form.w-full #prompt-textarea").focus();
1377 | document.execCommand('insertText', false, content);
1378 | }
1379 | }
1380 | };
1381 |
1382 | /*
1383 | 净化页面
1384 | */
1385 | const purifyPage = function() {
1386 | if (location.href.match(/https:\/\/(chatgpt\.com|chat\.openai\.com)\/\??/)) {
1387 | //添加专属logo
1388 | if ($("main h1") && $("main h1").innerText.match(/^ChatGPT(\nPLUS)?$/)) {
1389 | $("main h1").classList.add('text-gray-200');
1390 | const nSpan = document.createElement('span');
1391 | nSpan.className = 'bg-yellow-200 text-yellow-900 py-0.5 px-1.5 text-xs md:text-sm rounded-md uppercase';
1392 | nSpan.textContent = `KEEP`;
1393 | $("main h1").appendChild(nSpan);
1394 | }
1395 | }
1396 | };
1397 |
1398 | /*
1399 | 言无不尽
1400 | */
1401 | const speakCompletely = function() {
1402 | if (gv("k_speakcompletely", false) === true) {
1403 | const continue_svg_selector = `form.w-full .justify-center svg path[d*="M4.47189 2.5C5.02418 2.5 5.47189 2.94772 5.47189 3.5V5.07196C7.17062 3.47759 9.45672 2.5 11.9719 2.5C17.2186 2.5 21.4719 6.75329 21.4719 12C21.4719 17.2467 17.2186 21.5 11.9719 21.5C7.10259 21.5 3.09017 17.8375 2.53689 13.1164C2.47261 12.5679 2.86517"]:not(.ct_clicked)`;
1404 | if ($(continue_svg_selector)) {
1405 | setTimeout(function() {
1406 | fp(`button`, $(continue_svg_selector))?.click();
1407 | $(continue_svg_selector)?.classList.add('ct_clicked');
1408 | }, 1000);
1409 | }
1410 | }
1411 | };
1412 |
1413 | const dataSec = function() {
1414 | muob("form.w-full #prompt-textarea", $(`body`), () => {
1415 | if (gv("k_datasecblocklist", datasec_blocklist_default)) {
1416 | $("form.w-full #prompt-textarea")?.addEventListener('input', dataSec.listen_input);
1417 | $("form.w-full #prompt-textarea")?.addEventListener('paste', dataSec.listen_input);
1418 | } else {
1419 | $("form.w-full #prompt-textarea")?.removeEventListener('input', dataSec.listen_input);
1420 | $("form.w-full #prompt-textarea")?.removeEventListener('paste', dataSec.listen_input);
1421 | }
1422 | });
1423 | };
1424 |
1425 | dataSec.listen_input = function(event) {
1426 | let ms = [];
1427 | gv("k_datasecblocklist", datasec_blocklist_default).split(`\n`).forEach(e => {
1428 | if (e) {
1429 | const m = $("form.w-full #prompt-textarea").innerHTML.match(e);
1430 | if (m && m[0]) {
1431 | $("form.w-full #prompt-textarea").innerHTML = $("form.w-full #prompt-textarea").innerHTML.replaceAll(m[0], ``);
1432 | ms.push(m[0]);
1433 | }
1434 | }
1435 | });
1436 | if (ms.join(`\n`).trim()) {
1437 | ndialog(`⚠️${tl("警告")}`, `${tl("发现敏感数据")}`, `Thanks`, function(t) {}, `textarea`, ms.join(`\n`));
1438 | }
1439 | };
1440 |
1441 | const supportAuthor = function() {
1442 | ndialog(`${tl("赞赏鼓励")}`, `· 本项目由兴趣驱使,提升自己的体验,并共享世界。
1443 | · 如果你喜欢作者的项目,可以给作者一个免费的Star或者Follow。
1444 | · 如果你希望作者的小猫吃到更好的罐头,欢迎赞赏与激励。`, `更多鼓励方式`, function(t) {
1445 | window.open(`${GM_info.script.namespace}#赞赏`, '_blank');
1446 | }, `img`, `https://github.com/xcanwin/KeepChatGPT/raw/main/assets/appreciate_wechat.png`);
1447 | }
1448 |
1449 | const interceptTracking = function(action) {
1450 | if (action === true) {
1451 | window.addEventListener('beforescriptexecute', interceptTracking.listen_beforescriptexecute);
1452 | } else {
1453 | window.removeEventListener('beforescriptexecute', interceptTracking.listen_beforescriptexecute);
1454 | }
1455 | };
1456 |
1457 | interceptTracking.listen_beforescriptexecute = function(event) {
1458 | const scriptElement = event.target;
1459 | if (scriptElement.src.match('widget\.intercom\.io')) {
1460 | event.preventDefault();
1461 | scriptElement.textContent = ``;
1462 | scriptElement.remove();
1463 | }
1464 | };
1465 |
1466 | /*
1467 | 寻找元素的父元素
1468 | */
1469 | const fp = function(parentSelector, el, level = 5) {
1470 | if (el === null) {
1471 | return null;
1472 | }
1473 | let parent = el.parentNode;
1474 | let count = 1;
1475 | while (parent && count <= level) {
1476 | if (parent && parent.constructor !== HTMLDocument && parent.matches(parentSelector)) {
1477 | return parent;
1478 | }
1479 | parent = parent.parentNode;
1480 | count++;
1481 | }
1482 | return null;
1483 | };
1484 |
1485 | /*
1486 | fix openai bug
1487 | 帮助openai官方修复bug:Alpha语言环境存在bug导致无法发送信息
1488 | */
1489 | const fixOpenaiBUG = function() {
1490 | localStorage.removeItem('oai/apps/locale');
1491 | if (gv("k_lastjob", "") === "") {
1492 | sv("k_lastjob", Date.now().toString() + ",0");
1493 | } else {
1494 | let d, t;
1495 | [d, t] = gv("k_lastjob", "").split(",");
1496 | if (Date.now() - parseInt(d) >= 1000 * 60 * 60 * 24 * 7 && t<=3) {
1497 | t = parseInt(t) + 1;
1498 | sv("k_lastjob", Date.now().toString() + "," +t);
1499 | }
1500 | }
1501 | };
1502 |
1503 | /*
1504 | 绕过一部分CF机器人校验
1505 | */
1506 | const byebyeCF = () => {
1507 | GM_cookie.delete({
1508 | name: "cf_clearance",
1509 | domain: ".chatgpt.com",
1510 | path: "/"
1511 | });
1512 | };
1513 |
1514 | const nInterval1Fun = function() {
1515 | byebyeCF();
1516 | if ($(symbol1_selector) || $(symbol2_selector)) {
1517 | setIfr();
1518 | speakCompletely();
1519 | }
1520 | };
1521 |
1522 | [symbol1_selector, symbol2_selector].forEach(el => {
1523 | muob(el, $(`body`), () => {
1524 | loadKCG();
1525 | setIfr();
1526 | });
1527 | });
1528 |
1529 | const nInterval2Fun = function() {
1530 | if ($(symbol1_selector) || $(symbol2_selector)) {
1531 | keepChat();
1532 | }
1533 | };
1534 |
1535 | hookFetch();
1536 | //fixOpenaiBUG();
1537 | dataSec();
1538 |
1539 | let nInterval1 = setInterval(nInterval1Fun, 300);
1540 | let interval2Time = parseInt(gv("k_interval", 50));
1541 | let nInterval2 = setInterval(nInterval2Fun, 1000 * interval2Time);
1542 |
1543 | })();
1544 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | GNU GENERAL PUBLIC LICENSE
2 | Version 2, June 1991
3 |
4 | Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
5 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
6 | Everyone is permitted to copy and distribute verbatim copies
7 | of this license document, but changing it is not allowed.
8 |
9 | Preamble
10 |
11 | The licenses for most software are designed to take away your
12 | freedom to share and change it. By contrast, the GNU General Public
13 | License is intended to guarantee your freedom to share and change free
14 | software--to make sure the software is free for all its users. This
15 | General Public License applies to most of the Free Software
16 | Foundation's software and to any other program whose authors commit to
17 | using it. (Some other Free Software Foundation software is covered by
18 | the GNU Lesser General Public License instead.) You can apply it to
19 | your programs, too.
20 |
21 | When we speak of free software, we are referring to freedom, not
22 | price. Our General Public Licenses are designed to make sure that you
23 | have the freedom to distribute copies of free software (and charge for
24 | this service if you wish), that you receive source code or can get it
25 | if you want it, that you can change the software or use pieces of it
26 | in new free programs; and that you know you can do these things.
27 |
28 | To protect your rights, we need to make restrictions that forbid
29 | anyone to deny you these rights or to ask you to surrender the rights.
30 | These restrictions translate to certain responsibilities for you if you
31 | distribute copies of the software, or if you modify it.
32 |
33 | For example, if you distribute copies of such a program, whether
34 | gratis or for a fee, you must give the recipients all the rights that
35 | you have. You must make sure that they, too, receive or can get the
36 | source code. And you must show them these terms so they know their
37 | rights.
38 |
39 | We protect your rights with two steps: (1) copyright the software, and
40 | (2) offer you this license which gives you legal permission to copy,
41 | distribute and/or modify the software.
42 |
43 | Also, for each author's protection and ours, we want to make certain
44 | that everyone understands that there is no warranty for this free
45 | software. If the software is modified by someone else and passed on, we
46 | want its recipients to know that what they have is not the original, so
47 | that any problems introduced by others will not reflect on the original
48 | authors' reputations.
49 |
50 | Finally, any free program is threatened constantly by software
51 | patents. We wish to avoid the danger that redistributors of a free
52 | program will individually obtain patent licenses, in effect making the
53 | program proprietary. To prevent this, we have made it clear that any
54 | patent must be licensed for everyone's free use or not licensed at all.
55 |
56 | The precise terms and conditions for copying, distribution and
57 | modification follow.
58 |
59 | GNU GENERAL PUBLIC LICENSE
60 | TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
61 |
62 | 0. This License applies to any program or other work which contains
63 | a notice placed by the copyright holder saying it may be distributed
64 | under the terms of this General Public License. The "Program", below,
65 | refers to any such program or work, and a "work based on the Program"
66 | means either the Program or any derivative work under copyright law:
67 | that is to say, a work containing the Program or a portion of it,
68 | either verbatim or with modifications and/or translated into another
69 | language. (Hereinafter, translation is included without limitation in
70 | the term "modification".) Each licensee is addressed as "you".
71 |
72 | Activities other than copying, distribution and modification are not
73 | covered by this License; they are outside its scope. The act of
74 | running the Program is not restricted, and the output from the Program
75 | is covered only if its contents constitute a work based on the
76 | Program (independent of having been made by running the Program).
77 | Whether that is true depends on what the Program does.
78 |
79 | 1. You may copy and distribute verbatim copies of the Program's
80 | source code as you receive it, in any medium, provided that you
81 | conspicuously and appropriately publish on each copy an appropriate
82 | copyright notice and disclaimer of warranty; keep intact all the
83 | notices that refer to this License and to the absence of any warranty;
84 | and give any other recipients of the Program a copy of this License
85 | along with the Program.
86 |
87 | You may charge a fee for the physical act of transferring a copy, and
88 | you may at your option offer warranty protection in exchange for a fee.
89 |
90 | 2. You may modify your copy or copies of the Program or any portion
91 | of it, thus forming a work based on the Program, and copy and
92 | distribute such modifications or work under the terms of Section 1
93 | above, provided that you also meet all of these conditions:
94 |
95 | a) You must cause the modified files to carry prominent notices
96 | stating that you changed the files and the date of any change.
97 |
98 | b) You must cause any work that you distribute or publish, that in
99 | whole or in part contains or is derived from the Program or any
100 | part thereof, to be licensed as a whole at no charge to all third
101 | parties under the terms of this License.
102 |
103 | c) If the modified program normally reads commands interactively
104 | when run, you must cause it, when started running for such
105 | interactive use in the most ordinary way, to print or display an
106 | announcement including an appropriate copyright notice and a
107 | notice that there is no warranty (or else, saying that you provide
108 | a warranty) and that users may redistribute the program under
109 | these conditions, and telling the user how to view a copy of this
110 | License. (Exception: if the Program itself is interactive but
111 | does not normally print such an announcement, your work based on
112 | the Program is not required to print an announcement.)
113 |
114 | These requirements apply to the modified work as a whole. If
115 | identifiable sections of that work are not derived from the Program,
116 | and can be reasonably considered independent and separate works in
117 | themselves, then this License, and its terms, do not apply to those
118 | sections when you distribute them as separate works. But when you
119 | distribute the same sections as part of a whole which is a work based
120 | on the Program, the distribution of the whole must be on the terms of
121 | this License, whose permissions for other licensees extend to the
122 | entire whole, and thus to each and every part regardless of who wrote it.
123 |
124 | Thus, it is not the intent of this section to claim rights or contest
125 | your rights to work written entirely by you; rather, the intent is to
126 | exercise the right to control the distribution of derivative or
127 | collective works based on the Program.
128 |
129 | In addition, mere aggregation of another work not based on the Program
130 | with the Program (or with a work based on the Program) on a volume of
131 | a storage or distribution medium does not bring the other work under
132 | the scope of this License.
133 |
134 | 3. You may copy and distribute the Program (or a work based on it,
135 | under Section 2) in object code or executable form under the terms of
136 | Sections 1 and 2 above provided that you also do one of the following:
137 |
138 | a) Accompany it with the complete corresponding machine-readable
139 | source code, which must be distributed under the terms of Sections
140 | 1 and 2 above on a medium customarily used for software interchange; or,
141 |
142 | b) Accompany it with a written offer, valid for at least three
143 | years, to give any third party, for a charge no more than your
144 | cost of physically performing source distribution, a complete
145 | machine-readable copy of the corresponding source code, to be
146 | distributed under the terms of Sections 1 and 2 above on a medium
147 | customarily used for software interchange; or,
148 |
149 | c) Accompany it with the information you received as to the offer
150 | to distribute corresponding source code. (This alternative is
151 | allowed only for noncommercial distribution and only if you
152 | received the program in object code or executable form with such
153 | an offer, in accord with Subsection b above.)
154 |
155 | The source code for a work means the preferred form of the work for
156 | making modifications to it. For an executable work, complete source
157 | code means all the source code for all modules it contains, plus any
158 | associated interface definition files, plus the scripts used to
159 | control compilation and installation of the executable. However, as a
160 | special exception, the source code distributed need not include
161 | anything that is normally distributed (in either source or binary
162 | form) with the major components (compiler, kernel, and so on) of the
163 | operating system on which the executable runs, unless that component
164 | itself accompanies the executable.
165 |
166 | If distribution of executable or object code is made by offering
167 | access to copy from a designated place, then offering equivalent
168 | access to copy the source code from the same place counts as
169 | distribution of the source code, even though third parties are not
170 | compelled to copy the source along with the object code.
171 |
172 | 4. You may not copy, modify, sublicense, or distribute the Program
173 | except as expressly provided under this License. Any attempt
174 | otherwise to copy, modify, sublicense or distribute the Program is
175 | void, and will automatically terminate your rights under this License.
176 | However, parties who have received copies, or rights, from you under
177 | this License will not have their licenses terminated so long as such
178 | parties remain in full compliance.
179 |
180 | 5. You are not required to accept this License, since you have not
181 | signed it. However, nothing else grants you permission to modify or
182 | distribute the Program or its derivative works. These actions are
183 | prohibited by law if you do not accept this License. Therefore, by
184 | modifying or distributing the Program (or any work based on the
185 | Program), you indicate your acceptance of this License to do so, and
186 | all its terms and conditions for copying, distributing or modifying
187 | the Program or works based on it.
188 |
189 | 6. Each time you redistribute the Program (or any work based on the
190 | Program), the recipient automatically receives a license from the
191 | original licensor to copy, distribute or modify the Program subject to
192 | these terms and conditions. You may not impose any further
193 | restrictions on the recipients' exercise of the rights granted herein.
194 | You are not responsible for enforcing compliance by third parties to
195 | this License.
196 |
197 | 7. If, as a consequence of a court judgment or allegation of patent
198 | infringement or for any other reason (not limited to patent issues),
199 | conditions are imposed on you (whether by court order, agreement or
200 | otherwise) that contradict the conditions of this License, they do not
201 | excuse you from the conditions of this License. If you cannot
202 | distribute so as to satisfy simultaneously your obligations under this
203 | License and any other pertinent obligations, then as a consequence you
204 | may not distribute the Program at all. For example, if a patent
205 | license would not permit royalty-free redistribution of the Program by
206 | all those who receive copies directly or indirectly through you, then
207 | the only way you could satisfy both it and this License would be to
208 | refrain entirely from distribution of the Program.
209 |
210 | If any portion of this section is held invalid or unenforceable under
211 | any particular circumstance, the balance of the section is intended to
212 | apply and the section as a whole is intended to apply in other
213 | circumstances.
214 |
215 | It is not the purpose of this section to induce you to infringe any
216 | patents or other property right claims or to contest validity of any
217 | such claims; this section has the sole purpose of protecting the
218 | integrity of the free software distribution system, which is
219 | implemented by public license practices. Many people have made
220 | generous contributions to the wide range of software distributed
221 | through that system in reliance on consistent application of that
222 | system; it is up to the author/donor to decide if he or she is willing
223 | to distribute software through any other system and a licensee cannot
224 | impose that choice.
225 |
226 | This section is intended to make thoroughly clear what is believed to
227 | be a consequence of the rest of this License.
228 |
229 | 8. If the distribution and/or use of the Program is restricted in
230 | certain countries either by patents or by copyrighted interfaces, the
231 | original copyright holder who places the Program under this License
232 | may add an explicit geographical distribution limitation excluding
233 | those countries, so that distribution is permitted only in or among
234 | countries not thus excluded. In such case, this License incorporates
235 | the limitation as if written in the body of this License.
236 |
237 | 9. The Free Software Foundation may publish revised and/or new versions
238 | of the General Public License from time to time. Such new versions will
239 | be similar in spirit to the present version, but may differ in detail to
240 | address new problems or concerns.
241 |
242 | Each version is given a distinguishing version number. If the Program
243 | specifies a version number of this License which applies to it and "any
244 | later version", you have the option of following the terms and conditions
245 | either of that version or of any later version published by the Free
246 | Software Foundation. If the Program does not specify a version number of
247 | this License, you may choose any version ever published by the Free Software
248 | Foundation.
249 |
250 | 10. If you wish to incorporate parts of the Program into other free
251 | programs whose distribution conditions are different, write to the author
252 | to ask for permission. For software which is copyrighted by the Free
253 | Software Foundation, write to the Free Software Foundation; we sometimes
254 | make exceptions for this. Our decision will be guided by the two goals
255 | of preserving the free status of all derivatives of our free software and
256 | of promoting the sharing and reuse of software generally.
257 |
258 | NO WARRANTY
259 |
260 | 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
261 | FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
262 | OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
263 | PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
264 | OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
265 | MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
266 | TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
267 | PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
268 | REPAIR OR CORRECTION.
269 |
270 | 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
271 | WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
272 | REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
273 | INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
274 | OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
275 | TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
276 | YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
277 | PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
278 | POSSIBILITY OF SUCH DAMAGES.
279 |
280 | END OF TERMS AND CONDITIONS
281 |
282 | How to Apply These Terms to Your New Programs
283 |
284 | If you develop a new program, and you want it to be of the greatest
285 | possible use to the public, the best way to achieve this is to make it
286 | free software which everyone can redistribute and change under these terms.
287 |
288 | To do so, attach the following notices to the program. It is safest
289 | to attach them to the start of each source file to most effectively
290 | convey the exclusion of warranty; and each file should have at least
291 | the "copyright" line and a pointer to where the full notice is found.
292 |
293 |
294 | Copyright (C)
295 |
296 | This program is free software; you can redistribute it and/or modify
297 | it under the terms of the GNU General Public License as published by
298 | the Free Software Foundation; either version 2 of the License, or
299 | (at your option) any later version.
300 |
301 | This program is distributed in the hope that it will be useful,
302 | but WITHOUT ANY WARRANTY; without even the implied warranty of
303 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
304 | GNU General Public License for more details.
305 |
306 | You should have received a copy of the GNU General Public License along
307 | with this program; if not, write to the Free Software Foundation, Inc.,
308 | 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
309 |
310 | Also add information on how to contact you by electronic and paper mail.
311 |
312 | If the program is interactive, make it output a short notice like this
313 | when it starts in an interactive mode:
314 |
315 | Gnomovision version 69, Copyright (C) year name of author
316 | Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
317 | This is free software, and you are welcome to redistribute it
318 | under certain conditions; type `show c' for details.
319 |
320 | The hypothetical commands `show w' and `show c' should show the appropriate
321 | parts of the General Public License. Of course, the commands you use may
322 | be called something other than `show w' and `show c'; they could even be
323 | mouse-clicks or menu items--whatever suits your program.
324 |
325 | You should also get your employer (if you work as a programmer) or your
326 | school, if any, to sign a "copyright disclaimer" for the program, if
327 | necessary. Here is a sample; alter the names:
328 |
329 | Yoyodyne, Inc., hereby disclaims all copyright interest in the program
330 | `Gnomovision' (which makes passes at compilers) written by James Hacker.
331 |
332 | , 1 April 1989
333 | Ty Coon, President of Vice
334 |
335 | This General Public License does not permit incorporating your program into
336 | proprietary programs. If your program is a subroutine library, you may
337 | consider it more useful to permit linking proprietary applications with the
338 | library. If this is what you want to do, use the GNU Lesser General
339 | Public License instead of this License.
340 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 |
17 |
18 |
19 |
20 | | 中文 | English | Español |
21 | | --- | --- | --- |
22 |
23 | ## Project Introduction
24 |
25 | - Friends who like this plug -in, you can give my GitHub project [KeepChatGPT](https://github.com/xcanwin/KeepChatGPT) ⭐️Star support it.
26 | - This is a plug -in to improve the data security capacity and efficiency of ```ChatGPT```.It can make your chat extremely smooth, eliminating dozens of unnecessary steps, and once and for all, get rid of various ```errors``` and ```warnings```.And freely share a large number of innovative functions, such as: automatic refresh, active, data security, cancellation of audit, cloning dialogue, endless words, purifying pages, displaying large screens, interception tracking, changing with each other, and inspecting.Let our AI experience extremely safe, smooth, silky, efficient, and concise.
27 | - There is no research and development expenses, and use love to generate electricity purely. Welcome to follow.Thank you for [appreciating cat food](#Sponsor).
28 |
29 |
30 | ## Showcase
31 |
32 | | No. | Screenshot |
33 | | --- | --- |
34 | | 1 | Light Theme + Page Purification |
35 | | 2 | Light Theme + Meticulousness + Large Screen Display + Constant Updates |
36 | | 3 | Dark Theme + Meticulousness + Large Screen Display + Constant Updates |
37 | | 4 | Mobile + Page Purification |
38 |
39 | ## Feature introduction
40 |
41 | 1. Support [Modify-interval](#About-Modify-interval)
42 | 2. Support [Data-security](#About-Data-security)
43 | 3. Support [Cancel-audit](#About-Cancel-audit)
44 | 4. Support [Conversation-cloning](#About-Conversation-cloning)
45 | 5. Support [Complete-response](#About-Complete-response)
46 | 6. Support [Purified-page](#About-Purified-page)
47 | 7. Support [Wide-display-mode](#About-Wide-display-mode)
48 | 8. Support [Intercept-tracking](#About-Intercept-tracking)
49 | 9. Support [More-chat-info](#About-More-chat-info)
50 | 10. Support [Keen observation](#About-Keen-observation)
51 | 11. Support multiple languages
52 | 12. Support [PC](#Usage-PC)
53 | 13. Support ([Harmony OS](#Usage-Harmony-OS)、[iOS](#Usage-iOS)、[Android](#Usage-Harmony-OS))
54 | 14. Support [Keep alive](#About-Keep-alive)
55 | 15. Resolve chat interruptions
56 | 16. Resolve frequent refreshes
57 | 17. Resolve messages that could not be sent
58 | 18. Resolve the following errors
59 |
60 | | Serial number | Resolve the following errors |
61 | | --- | --- |
62 | | 1 | NetworkError when attempting to fetch resource. |
63 | | 2 | Something went wrong. If this issue persists please contact us through our help center at help.openai.com. |
64 | | 3 | Conversation not found |
65 | | 4 | This content may violate our content policy. If you believe this to be in error, please submit your feedback — your input will aid our research in this area. |
66 |
67 | ## User feedback
68 |
69 | - There are good and bad
70 | - For the good, thank you for the thumbs up
71 | - The bad ones will be updated continuously
72 |
73 |
74 |
75 |
76 |
77 |
78 | ## Install channels
79 |
80 | Official Channels✅:
81 |
82 | | Serial number | UserScript | Remarks |
83 | | --- | --- | --- |
84 | | 1 | [Github](https://raw.githubusercontent.com/xcanwin/KeepChatGPT/main/KeepChatGPT.user.js) | ✅Recommended |
85 |
86 | ~~Fake channels~~❌:
87 |
88 | | Serial number | UserScript | Remarks |
89 | | --- | --- | --- |
90 | | 1 | [~~Google Play Store~~](https://chrome.google.com/webstore/category/extensions) | ⚠️️Beware, this is not uploaded by the author. Someone copied KeepChatGPT and asked the user to pay for it |
91 | | 2 | [~~Microsoft Store~~](https://microsoftedge.microsoft.com/) | ⚠️️Beware, this is not uploaded by the author. Someone copied KeepChatGPT and asked the user to pay for it |
92 |
93 | ## Usage PC
94 |
95 | 1. Installation ```Tampermonkey```, through the [official website](https://www.tampermonkey.net/);
96 | 2. Installation ```KeepChatGPT```, through the [Install channels](#Install-channels);
97 | 3. Open [ChatGPT](https://chat.openai.com/chat);
98 |
99 | ## Usage Harmony OS
100 |
101 | 1. Browsers ```Firefox```;
102 | 2. Installation ```Firefox```, through the [HUAWEI App Store](https://appgallery.huawei.com/app/C31765) and [official website](https://www.mozilla.org/firefox/browsers/mobile/android/);
103 | 3. Open ```Firefox``` > bottom right corner ```...``` > Add-ons > Add-ons Manager > The one on the right ```+```;
104 | 4. Installation ```KeepChatGPT```, through the [Install channels](#Install-channels);
105 | 5. Open [ChatGPT](https://chat.openai.com/chat);
106 |
107 | ## Usage iOS
108 |
109 | 1. Browsers ```Safari```;
110 | 2. Installation ```Stay```, through the [App Store](https://apps.apple.com/app/id1591620171);
111 | 3. For instructions on use, please refer to [official website](https://github.com/shenruisi/Stay);
112 | 4. Installation ```KeepChatGPT```, through the [Install channels](#Install-channels);
113 | 5. Open [ChatGPT](https://chat.openai.com/chat);
114 |
115 | ## Other Notes
116 |
117 | ### About Keep alive
118 |
119 | - The comparison found that 10 redundant steps were omitted and the chat was smooth
120 |
121 | | Experimental environment | Unuse the KeepChatGPT plugin | Use the KeepChatGPT plugin |
122 | | :------: | :----------------------------------------------: | :--------------------------: |
123 | | phenomenon | Frequent ```NetworkError``` alarm, which causes the web page to be refreshed. | No network error is reported and no refresh is required. |
124 | | Step 1 | Command is issued | Command is issued |
125 | | Step 2 | Wait for the results | Wait for the results |
126 | | Step 3 | A network error message is generated | Get results |
127 | | Step 4 | Try clicking Re-deliver | |
128 | | Step 5 | The network error is reported again | |
129 | | Step 6 | Copy the instruction you just made | |
130 | | Step 7 | Refresh the page | |
131 | | Step 8 | Wait for the page to load | |
132 | | Step 9 | Open the chat session you just | |
133 | | Step 10 | Paste the instruction you just directed | |
134 | | Step 11 | The command is issued again | |
135 | | Step 12 | Wait for the results again | |
136 | | Step 13 | Get results | |
137 |
138 | ### About a large number of user network errors
139 |
140 | 1. Reason: Shortage of computing power, large usage, Cloudflare risk control and manslaughter. Solution: Use this plugin.
141 |
142 | ### About still reporting mistakes
143 |
144 | 1. Reason: Reference [```About a large number of user network errors```](#About-a-large-number-of-user-network-errors). Solution: Replace the network.
145 | 2. Reason: Reference [```About Modify interval```](#About-Modify-interval). Solution: Adjust the interval of Keep moderately.
146 |
147 | ### About Other Errors
148 |
149 | 1. If the following error message appears, please refer to the official solution: [Official - Error Message](https://openai.com/policies/usage-policies)
150 | 2. 401 - Invalid Authentication
151 | 3. 401 - Incorrect API key provided
152 | 4. 401 - You must be a member of an organization to use the API
153 | 5. 429 - Rate limit reached for requests
154 | 6. 429 - You exceeded your current quota, please check your plan and billing details
155 | 7. 429 - The engine is currently overloaded, please try again later
156 | 8. 500 - The server had an error while processing your request
157 |
158 | ### About ERROR429 - Too many requests in 1 hour. Try again later
159 |
160 | 1. Reason: There is no free quota for new registration, please check the [official website - quota](https://platform.openai.com/account/usage). Solution: Change your email address and mobile phone number to register.
161 | 2. Reason: Old users have used up the quota, check the [official website - quota](https://platform.openai.com/account/usage). Solution: Deposit OpenAI.
162 | 3. Reason: Cloudflare's bug. Solution: Privacy mode, clear cookies.
163 | 4. Reason: Risk control is triggered due to network sharing. Solution: Replace the network.
164 |
165 | ### About Cancel audit
166 |
167 | 1. OpenAI [audits](https://platform.openai.com/docs/guides/moderation/overview) all of a user's conversations, which [policy](https://openai.com/policies/usage-policies) can lead to account bans if the policy is frequently violated.
168 | 2. Ticked ```Cancel audit``` In the future, add your clever prompt words (must) to avoid banning to the greatest extent.
169 |
170 | ### About Modify interval
171 |
172 | 1. Refers to the time interval between staying online to OpenAI, in `seconds`.
173 | 2. The larger the time interval, the more relaxed the request and the more stable the account.
174 | 3. The smaller the time interval, the tighter the request and the fewer network errors.
175 | 4. Recommended intervals ```50``` More than a second.
176 | 5. The author usually sets it up ```900``` Second.
177 |
178 | ### About Conversation cloning
179 |
180 | 1. Quickly select, copy, paste, and edit with one click
181 | 2. Ticked ```Conversation cloning``` Later, you can click on the content of the conversation before ```Avatar``` for quick editing.
182 | 3. The comparison found that 5 redundant steps were omitted and the chat was smooth:
183 |
184 | | Experimental environment | Uncheck Conversation cloning | Tick Conversation cloning |
185 | | :------: | :--------------------: | :----------: |
186 | | Step 1 | Command is issued | Command is issued |
187 | | Step 2 | Get results | Get results |
188 | | Step 3 | Not satisfied with the results | Not satisfied with the results |
189 | | Step 4 | Mouse click on the beginning of the command | Click the conversation profile picture |
190 | | Step 5 | Mouse wheel scrolling | Start adjusting the instruction |
191 | | Step 6 | Drag the mouse to the end of the command | |
192 | | Step 7 | Copy the instruction | |
193 | | Step 8 | Mouse click dialog | |
194 | | Step 9 | Paste the instruction | |
195 | | Step 10 | Start adjusting the instruction | |
196 |
197 | ### About Purified page
198 |
199 | 1. Purify excess elements.
200 | 2. Ticked ```Purified page``` In the future, the page will have a new look, enjoy the gold label, and enhance the sense of experience.
201 |
202 | ### About Wide display mode
203 |
204 | 1. Broaden your chatting horizons ```PRO```
205 | 2. Ticked ```Wide display mode``` In the future, mouse scrolling will be greatly reduced, and the dialogue will be clear at a glance, improving the sense of experience.
206 |
207 | ### About Complete response
208 |
209 | 1. Let ChatGPT express itself to its heart's content, without missing anything.
210 | 2. Ticked ```Complete response``` In the future, you can be unattended after asking a question and enjoy ChatGPT to express yourself to your heart's content until everything is replied.
211 | 3. After testing, this feature can make ChatGPT speak for up to 5 minutes and 30 seconds, greatly breaking the original 60-second limit.
212 | 4. The comparison found that 21 redundant steps were omitted and the chat was smooth:
213 |
214 | | Experimental environment | Uncheck Complete response | Tick Complete response |
215 | | :------: | :-----------------: | :------------: |
216 | | Step 1 | Command is issued | Command is issued |
217 | | Step 2 | Wait for the results | Wait for the results |
218 | | Step 3 | Keep an eye on the results | Get full results |
219 | | Step 4 | Incomplete results are obtained | |
220 | | Step 5 | Click ```Continue``` | |
221 | | Step 6~21 | Step 2 ~ 5 Repeat 4 times ... | |
222 | | Step 22 | Wait for the results | |
223 | | Step 23 | Keep an eye on the results | |
224 | | Step 24 | Get full results | |
225 |
226 | ### About Intercept tracking
227 |
228 | 1. Capturing packets shows that the ChatGPT page uploads a lot of user environment information, performing extensive behavior analysis and user tracking.
229 | 2. Enabling ```Tracking Interception``` can block most tracking behaviors, protecting user information and improving page load speed.
230 | 3. Tests show that refreshing the ChatGPT page generates ```50~100``` network requests, with at least ```15~65``` requests tracking and analyzing users!
231 | 4. The author believes these requests are unnecessary! Hence, users concerned about privacy should enable this feature.
232 |
233 | ### About More chat info
234 |
235 | 1. Enhances the sidebar.
236 | 2. Enabling ```Constant Updates``` will display ```titles```, ```latest news```, ```dates```, ```days of the week```, ```conversation models```, etc., in the sidebar, helping users quickly locate high-quality historical chat items.
237 |
238 | | LOGO | Conversation Model |
239 | | --- | --- |
240 | | Black Bubble | GPT3.5 Model |
241 | | Purple Bubble | GPT4 Model |
242 | | Purple Bubble + m | GPT4 Mobile Model |
243 | | Purple Bubble + w | GPT4 Web Browsing Model |
244 | | Purple Bubble + p | GPT4 Plugins Model |
245 | | Purple Bubble + d | GPT4 Code Interpreter Model |
246 |
247 | | Without Constant Updates | With Constant Updates |
248 | | --- | --- |
249 | | | |
250 |
251 | ### About Keen observation
252 |
253 | 1. Mimics chat software styles to enhance the distinction between user and robot chat bubbles.
254 | 2. Enabling ```Keen observation``` refreshes the chat page's appearance, improving the user experience.
255 |
256 | ### About Data security
257 |
258 | 1. Provides data security solutions, helping users intercept sensitive information to prevent data security issues.
259 | 2. Enabling ```Data security``` automatically cleans sensitive information (desensitizes) and provides risk warnings while users compose dialogues.
260 | 3. Please write data security rules according to regular expression syntax, with different rules separated by new lines.
261 | 4. The default data security rules are basic and need to be customized.
262 | 5. You can add your name, ID, computer username, company name, enterprise domain, etc., to the rules.
263 |
264 | Here's a demonstration: If you type or paste this prompt into the chat box:
265 | ```
266 | C:\Users\my-secret-username\Desktop> python login.py
267 | File "C:\Users\my-secret-username\Desktop\login.py", line 4
268 | if Mobile!"18888888888" and Email=="admin@163.com" : print("https://securiy-domain.com/login")
269 | ^
270 | SyntaxError: invalid syntax
271 | ```
272 |
273 | will be immediately corrected to:
274 | ```
275 | C:\Users\\Desktop> python login.py
276 | File "C:\Users\\Desktop\login.py", line 4
277 | if Mobile!"" and Email=="" : print("/login")
278 | ^
279 | SyntaxError: invalid syntax
280 | ```
281 |
282 |
283 |
284 | ## Sponsor
285 |
286 | - This project is driven by interest, elevating one's own experience, and sharing the world.
287 | - If you like the author's project, you can give the author a free Star or Follow.
288 | - If you want the author's kitten to eat better canned food, welcome to appreciate and motivate.
289 | - You can write your ID in the remarks, thank you.
290 |
291 | | From | Thanks |
292 | | --- | --- |
293 | | My cat | |
294 | | buymeacoffee | [](https://www.buymeacoffee.com/xcanwin) Click on the image |
295 | | Love power generation (Support WeChat, Alipay) | [](https://afdian.net/a/xcanwin/plan) Click on the image or scan |
296 | | WeChat | |
297 |
298 |
--------------------------------------------------------------------------------
/docs/README_ES.md:
--------------------------------------------------------------------------------
1 |
12 |
13 |
14 |
15 | ## Descripción del proyecto
16 |
17 | - Si te gusta este script, por favor apoya mi proyecto en GitHub KeepChatGPT dándole una ⭐️.
18 | - Este es un código abierto, gratuito y eficiente script de extensión de usuario para ChatGPT, que puede hacer que tus chats sean extremadamente fluidos y eliminar de una vez por todas varios errores y advertencias. Ahorrarás 10 pasos adicionales completos y te liberarás de la constante necesidad de actualizar la página. Los autores continúan añadiendo más mejoras, incluyendo la cancelación de auditorías, la clonación de conversaciones, la purificación de la página, la visualización en pantallas grandes, la visualización a pantalla completa, entre otras.
19 | - No hay financiación para la investigación y el desarrollo, esto se realiza puramente con el poder del amor. ¡Eres bienvenido/a a hacer una donación! Gracias por tu apoyo Patrocinadores.
20 |
21 | ## Introducción a las características
22 |
23 | 1. Se ha resuelto el error:`NetworkError when attempting to fetch resource.`
24 | 2. Se ha resuelto el error:`Something went wrong. If this issue persists please contact us through our help center at help.OpenAI.com.`
25 | 3. Se ha resuelto el error:`Conversation not found`
26 | 4. Se ha resuelto el error:`This content may violate our content policy. If you believe this to be in error, please submit your feedback — your input will aid our research in this area.`
27 | 5. Se resolvieron las interrupciones frecuentes durante la comunicación
28 | 6. Se resolvió la actualización frecuente de páginas web
29 | 7. Soporte multilingüe
30 | 8. Resuelto el error oficial de que el nombre de usuario en el diálogo se copiaría por error
31 | 9. Soporte gratuito [Cancelar la auditoría de supervisión de backend](#about-cancel-audit-function)
32 | 10. Compatible con dispositivos móviles ([HarmonyOS](#usage-harmonyos-system), [Androide](#usage-android-system), [Ios](#usage-apple-system))
33 | 11. Soporte libre [Ajustar intervalo de tiempo](#about-adjust-interval-feature)
34 | 12. Apoyo [Fácil clonación y edición no destructiva de diálogos especificados](#about-clone-dialogue-function)
35 | 13. Apoyo [Purificar la página](#about-purify-page-features)
36 | 14. Soporte de visualización de pantalla grande
37 | 15. Soporte de visualización de pantalla completa
38 |
39 | Lo anterior es una breve descripción de las funciones, la descripción detallada de las funciones al final de este artículo.
40 |
41 | Y al final de este artículo [Otras instrucciones](#other-instructions), el autor analiza brevemente [Por qué se producen errores de red a gran escala](#about-why-large-scale-network-errors-occur), soluciones comunes de mensajes de error
42 |
43 | | Num | Después de usar `KeepChatGPT`, la siguiente escena nunca volverá a aparecer |
44 | | --- | --- |
45 | | 1 | |
46 | | 2 | |
47 | | 3 | |
48 | | 4 | |
49 |
50 | ## Comentarios de los usuarios
51 |
52 | * Hay buenos y malos
53 | * Gracias por sus elogios
54 | * Seguirá actualizándose para los malos
55 |
56 |
57 |
58 | ## Comparación
59 |
60 | | Entorno experimental | Sin usar `KeepChatGPT` | Usando `KeepChatGPT` |
61 | | :----------------------: | :----------------------------------------------------------: | :----------------------------------------------------------: |
62 | | Fenómeno | Cuadros de advertencia rojos frecuentes NetworkError en el chat, que aparecen cada diez minutos más o menos, que requieren que la página web se actualice | Nunca más habrá errores de red y no es necesario actualizar la página web |
63 | | Paso 1 | Emitir el mensaje | Emitir el mensaje |
64 | | Paso 2 | Espera el resultado | Espera el resultado |
65 | | Paso 3 | Encontrar un error de red | Obtener el resultado |
66 | | Paso 4 | Intentar hacer clic para reenviar | |
67 | | Paso 5 | Volver a encontrar el error de red | |
68 | | Paso 6 | Copiar el mensaje anterior | |
69 | | Paso 7 | Actualizar la página web | |
70 | | Paso 8 | Espere a que la página web termine de cargarse | |
71 | | Paso 9 | Abrir la sesión de chat anterior | |
72 | | Paso 10 | Pegue el mensaje anterior | |
73 | | Paso 11 | Vuelva a emitir el mensaje | |
74 | | Paso 12 | Espera el resultado de nuevo | |
75 | | Paso 13 | Obtener el resultado | |
76 |
77 | * En comparación, se puede ver que ahorra más de 10 pasos innecesarios y permite un chat fluido.
78 |
79 | ## Mostrar
80 |
81 | * Disfrute de la "Etiqueta de oro exclusiva" gratuita, que representa un cambio dramático en su experiencia de IA:
82 | *
83 | * Para los amigos a los que les gustan los tonos oscuros, puede pasar el cursor sobre la "Etiqueta dorada exclusiva" con el mouse y seleccionar "Tema" para cambiarla a "Etiqueta azul exclusiva":
84 | *
85 | * Moblie:
86 | *
87 |
88 | ## Explicación
89 |
90 | * Omita la verificación de araña de Cloudflare durante la apertura de la página usando Headless.
91 | * Omita la verificación aleatoria de la máquina de Cloudflare sin hacer clic.
92 | * Mantener el principio de minimizar el tráfico.
93 | * Mover el ratón sobre `Exclusive Gold Label` y seleccione `Show Debugging` para ver el proceso de omisión.
94 |
95 | ## Uso
96 |
97 | Los navegadores recomendados son `Chrome`, `Firefox`, `Edge` y otros navegadores compatibles con estos tres.
98 |
99 | 1. Instala la extensión del navegador `Tampermonkey` desde el sitio web de [Tampermonkey](https://www.tampermonkey.net/).
100 | 2. Instala `KeepChatGPT` seleccionando uno de los repositorios de [Instalación de repositorios](#install).
101 | 3. Abre [ChatGPT](https://chat.OpenAI.com/chat) y disfruta de una experiencia sin problemas.
102 | 4. Además, hay una forma más inteligente de hacerlo, que es preguntarle a ChatGPT: "¿Cómo instalar la extensión Tampermonkey? ¿Cómo instalar el script de usuario desde Greasy Fork?"
103 |
104 | ## Uso del sistema HarmonyOS
105 |
106 | 1. El navegador preferido es `Firefox`;
107 | 2. Instalar `Firefox` Aplicación del navegador, puede descargarla desde [Galería de aplicaciones de Huawei](https://appgallery.huawei.com/app/C31765)、[Sitio web oficial de Firefox](https://www.mozilla.org/firefox/browsers/mobile/android/);
108 | 3. Abrir `Firefox` Aplicación del navegador > esquina inferior derecha `...` > Complementos > Administrador de complementos > `+` a la derecha de `Tampermonkey`;
109 | 4. Instalar `KeepChatGPT` userscript, puede elegir un canal para instalar [Canal de instalación](#installation-channel);
110 |
111 | ## Uso del sistema Android
112 |
113 | 1. El navegador preferido es `Firefox`;
114 | 2. Instalar `Firefox` Aplicación del navegador, puede descargarla desde [Tienda de juegos](https://play.google.com/store/apps/details?id=org.mozilla.firefox)、[Sitio web oficial de Firefox](https://www.mozilla.org/firefox/browsers/mobile/android/);
115 | 3. Abrir `Firefox` Aplicación del navegador > esquina inferior derecha `...` > Complementos > Administrador de complementos > `+` a la derecha de `Tampermonkey`;
116 | 4. Instalar `KeepChatGPT` userscript, puede elegir un canal para instalar [Canal de instalación](#installation-channel);
117 |
118 | ## Uso del sistema Apple
119 |
120 | 1. El navegador preferido es `Safari`, otros navegadores están limitados por la política de Apple y rara vez admiten complementos JS;
121 | 2. Instale el `Stay` Aplicación de extensión del navegador, que se puede instalar desde [Tienda de aplicaciones](https://apps.apple.com/app/id1591620171);
122 | 3. Consulte \[Sitio web oficial de la estancia] () para instrucciones;
123 | 4. Instalar `KeepChatGPT` plugin, puede elegir un canal para instalar [Canal de instalación](#installation-channel);
124 |
125 | ## Canal de instalación
126 |
127 | | | Origen UserScript |
128 | | --- | --- |
129 | | 1 | [Github](https://raw.githubusercontent.com/xcanwin/KeepChatGPT/main/KeepChatGPT.user.js) |
130 | | 2 | [GreasyFork](https://greasyfork.org/zh-CN/scripts/462804-keepchatgpt) |
131 |
132 | * El autor solo proporciona el método de instalación del script de usuario, y las fuentes oficiales son solo las dos anteriores, busque las fuentes oficiales.
133 | * El autor piensa que los scripts de usuario son mejores que las extensiones. Todos pueden auditar la seguridad en cualquier momento, y todos pueden averiguar si hay datos cargados en secreto.
134 | * ⚠️[Google App Store](https://chrome.google.com/webstore/category/extensions) y ⚠️[Tienda de aplicaciones de Microsoft](https://microsoftedge.microsoft.com/) no son proporcionados por el autor. Y plagió este proyecto, pero también cobró a los usuarios.
135 |
136 | ## Otras instrucciones
137 |
138 | ### Acerca de por qué se producen errores de red a gran escala
139 |
140 | 1. Ha habido una escasez de potencia informática en el mundo debido a la crisis global de chips, y OpenAI también existe.
141 | 2. OpenAI se convirtió en un éxito instantáneo, y el número de usuarios, el tiempo en línea del usuario y la frecuencia del usuario aumentaron considerablemente al mismo tiempo, lo que agravó la escasez de recursos.
142 | 3. Se ha derivado una gran cantidad de productos de IA y bots de IA, todos llamando a la API de ChatGPT y a la versión web de ChatGPT de forma privada, incluso con mucha más frecuencia que la suma de todos los usuarios reales.
143 | 4. OpenAI se conecta a `Cloudflare`Permite `strong protection rules`e intercepta productos de IA y bots de IA que están conectados de forma privada a OpenAI.
144 | 5. Al igual que el CAPTCHA gráfico, la intención era interceptar bots, pero una vez que existía el riesgo de que el CAPTCHA fuera reconocido, los webmasters desarrollaron el CAPTCHA gráfico para que fuera más complejo, afectando a usuarios reales, pero de hecho interceptando bots de manera efectiva.
145 | 6. `Cloudflare` es un servicio público, sirve a todos los sitios web, y sus reglas de protección y estrategias de control de riesgos son comunes. Muchos sitios web que no desean ser accedidos por rastreadores, bots, piratas informáticos o tráfico pesado se conectarán a Cloudflare, por lo que Cloudflare tiene una gran cantidad de estrategias de control de riesgos.
146 | 7. Un gran número de usuarios extranjeros son redes domésticas, y Cloudflare juzga que sus redes no están en riesgo, por lo que apenas informan de errores.
147 | 8. Un gran número de usuarios domésticos en China utilizan diversas técnicas mágicas de desplazamiento (denominadas `666`). Sin embargo, muchos `666` Las IP han sido o están actualmente incluidas en Cloudflare `strong protection rules` Lista de vigilancia prioritaria. Esta situación puede no ser necesariamente causada por los propios usuarios. Podría ser el resultado de acciones previas que afectan a usuarios posteriores, o la activación frecuente de controles de riesgo por parte de muchas IP en el mismo segmento C. También es posible que los propios usuarios no sepan que están utilizando un `666` IP, que activa los controles de riesgo. En consecuencia, Cloudflare identifica un riesgo potencial en su red, lo que lleva a mensajes de error y la necesidad de verificar la autenticidad de los usuarios reales.
148 | 9. Esto es solo la punta del iceberg, y podría haber varias otras razones subyacentes.
149 |
150 | ### Razones y soluciones para los errores de red incluso cuando se usa este complemento
151 |
152 | 1. Motivo: Consulte [*Con respecto a la función Ajustar intervalo*](#about-adjust-interval-feature). Solución: Ajuste el intervalo de mantenimiento moderadamente.
153 | 2. Motivo: Consulte [*Por qué se producen errores de red masiva*](#about-why-large-scale-network-errors-occur). Solución: cambie la IP, el centro de datos, el proveedor de servicios de Internet y el canal del `666`; La configuración más óptima para una sola `666`.
154 |
155 | ### Razones y soluciones para el mensaje de error 429 - Demasiadas solicitudes en 1 hora. Inténtalo de nuevo más tarde
156 |
157 | 1. En primer lugar, hay muchos tipos de errores 429. Confirme si no se menciona en [*Con respecto a otros errores*](#about-other-errors-causes-and-solutions). Si no es así, considere las siguientes posibilidades:
158 | 2. Motivo: Para los usuarios recién registrados o los usuarios que se registraron con el mismo teléfono, OpenAI no proporciona créditos gratuitos. Compruebe la [Página de uso del sitio web oficial de OpenAI](https://platform.OpenAI.com/account/usage) para más detalles. Solución: Regístrese con un correo electrónico y un número de teléfono diferentes.
159 | 3. Motivo: El uso del crédito se ha agotado. Compruebe la [Página de uso del sitio web oficial de OpenAI](https://platform.OpenAI.com/account/usage) para más detalles. Solución: Recarga para obtener más créditos.
160 | 4. Motivo: Error en Cloudflare. Solución: Utilice el modo de privacidad de un navegador o una instancia de ChatGPT. Si el modo de privacidad funciona normalmente, borre todas las cookies y el almacenamiento local relacionados con el dominio y los subdominios de OpenAI.com en el modo de navegación normal.
161 | 5. Motivo: es posible que no sepas que estás usando un `666` IP. Hay un grupo de "vecinos en línea con la misma salida de IP" que constantemente hacen solicitudes frecuentes para diversos fines. Aunque su tráfico es alto, logran mantenerse por debajo del umbral para evitar desencadenar el error 429. Sin embargo, cuando comienzas a usar este complemento, los arrastra hacia abajo y se quedan perplejos por encontrarse repentinamente con el error 429. Solución: cambie la IP, el centro de datos, el proveedor de servicios de Internet y el canal del `666`; La configuración más óptima para una sola `666`.
162 |
163 | ### Acerca de la función Cancelar auditoría
164 |
165 | 1. De forma predeterminada, todas sus conversaciones son auditadas automáticamente por el oficial de OpenAI. [moderación](https://platform.OpenAI.com/docs/guides/moderation/overview) sistema. Si el sistema de moderación de OpenAI detecta violaciones excesivas o violaciones de la [Políticas de uso de OpenAI](https://OpenAI.com/policies/usage-policies) En sus conversaciones, su cuenta corre el riesgo de ser restringida o incluso prohibida.
166 | 2. Por **habilitante** la función "Cancelar auditoría" de este complemento junto con su inteligente elección de palabras, puede minimizar el impacto en gran medida.
167 |
168 | ### Con respecto a la función Ajustar intervalo
169 |
170 | 1. El valor hace referencia al intervalo de tiempo para *guardar* (manteniendo viva la conexión), medido en *sobras*.
171 | 2. Un intervalo de tiempo más grande significa una velocidad de mantenimiento más lenta, menos impacto en el sitio web y una cuenta más segura.
172 | 3. Un intervalo de tiempo más pequeño significa una velocidad de mantenimiento más rápida y menos ocurrencia de errores de red.
173 | 4. Se recomienda tener un intervalo de *30* segundos o más.
174 | 5. El autor generalmente lo establece en *150* sobras.
175 |
176 | ### Acerca de la función Clonar conversación
177 |
178 | 1. ChatGPT pertenece al proyecto AI prompt.
179 | 2. Una de las cosas que más hace la ingeniería rápida es ajustar repetidamente las palabras rápidas hasta que se descubre que el robot realmente entiende y el resultado cumple con sus requisitos.
180 | 3. Una de las cosas más comunes que hace es ajustar repetidamente la redacción del mensaje antes de estar satisfecho con los resultados copiando y pegando lo que ya ha publicado.
181 | 4. Después de comprobar `Clone dialog`, puede hacer clic en el avatar delante del cuadro de diálogo que desea volver a optimizar, y el cuadro de diálogo aparecerá inmediatamente.
182 |
183 | ### Acerca de las características de la página Purify
184 |
185 | 1. Para los usuarios regulares (no Plus), a menudo se ve que la página de inicio de ChatGPT `https://chat.OpenAI.com/` está lleno de indicaciones inútiles.
186 | 2. Después de comprobar `Purify page`, puede hacer que la página de inicio se vea nueva, disfrutar del estándar de oro similar a los usuarios PLUS y mejorar la experiencia.
187 |
188 | ### Causas y soluciones para otros errores
189 |
190 | Si se produce el siguiente mensaje de error, consulte la solución oficial: [Código de error del documento oficial de OpenAI](https://OpenAI.com/policies/usage-policies)
191 | 401 - Autenticación no válida
192 | 401 - Clave API incorrecta proporcionada
193 | 401 - Debe ser miembro de una organización para usar la API
194 | 429 - Límite de tarifa alcanzado para solicitudes
195 | 429 - Excedió su cuota actual, verifique su plan y los detalles de facturación
196 | 429 - El motor está sobrecargado, inténtelo de nuevo más tarde
197 | 500 - El servidor tuvo un error al procesar su solicitud
198 |
199 | ### Acerca de los usuarios de PLUS no reportarán errores
200 |
201 | * Los usuarios PLUS están condenados al igual que los usuarios comunes.
202 |
203 | ## El patrocinador
204 |
205 | * ¡Si lo encuentras útil, increíble, suave o agradable!
206 | * Si deseas que el pequeño gato del autor pueda tener una mejor comida para gatos y comida enlatada.
207 | * Si este proyecto te ha sido útil.
208 | * Si este proyecto ha mejorado la eficiencia de tu trabajo.
209 | * Si deseas que este proyecto se mantenga continuamente para evitar una nueva ronda de mensajes de error de OpenAI.
210 | * Si deseas que este proyecto continúe actualizándose con más funciones.
211 | * Crear no es fácil, mantener un proyecto requiere tiempo, energía y habilidades técnicas. Se agradece el aprecio y el apoyo.
212 | * Puedes dejar tu DNI en la nota, gracias.
213 |
214 | | Desde | Gracias |
215 | | --- | --- |
216 | | Mi gato | |
217 | | Buymeacoffee | [](https://www.buymeacoffee.com/xcanwin) |
218 | | Afdian (Soporte wechat y alipay) | [](https://afdian.net/a/xcanwin/plan) |
219 | | Wechat (A veces no funciona) | |
220 |
--------------------------------------------------------------------------------
/tools/kcg_doc_cdn.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python3
2 | # -*- coding: utf-8 -*-
3 |
4 | """
5 | # 作用:
6 |
7 | 本脚本用于实现自动替换KeepChatGPT说明文档(README.md)里的图片链接
8 |
9 | """
10 |
11 | import os, re
12 |
13 | def save(data, outfile):
14 | if not os.path.exists('test'):
15 | os.mkdir('test')
16 | open(outfile, 'wb').write(data.encode())
17 |
18 | def main():
19 | rm = open('README.md', 'rb').read().decode()
20 | kcg_code = open('KeepChatGPT.user.js', 'rb').read().decode()
21 |
22 | cdn_pre = 'https://hub.gitmirror.com/https://raw.githubusercontent.com/xcanwin/KeepChatGPT/main'
23 | version = re.findall(r'// @version\s+(\S*?)\s', kcg_code)[0]
24 | # version = '24.6'
25 |
26 | rm_new = re.sub(r'src="(/assets/.*?)"', r'src="{}\1?v={}"'.format(cdn_pre, version), rm)
27 | print(rm_new)
28 | save(rm_new, 'test/README_CDN.md')
29 |
30 | main()
31 |
--------------------------------------------------------------------------------
/tools/kcg_i18n.py:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env python3
2 | # -*- coding: utf-8 -*-
3 |
4 | """
5 | # 作用:
6 |
7 | 本脚本用于实现KeepChatGPT多语言化
8 |
9 | # 使用方法:
10 |
11 | ## 第一步、
12 |
13 | 明确想要本地化的词汇,例如:
14 | 建议间隔30秒
15 |
16 | ## 第二步、
17 |
18 | 翻译成各国的临时语言包,向ChatGPT发送以下指令:
19 | ar,bg,cs,da,de,el,en,eo,es,fi,fr,fr-CA,he,hu,id,it,ja,ka,ko,nb,nl,pl,pt-BR,ro,ru,sk,sr,sv,th,tr,uk,ug,vi,zh-CN,zh-TW
20 | 按照上述国家顺序翻译一句话,并且按照我要求的格式逐行输出
21 | 格式要求:国家缩写: 翻译后的文字
22 | 冒号后面首字母需要大写
23 | 例如翻译"显示调试"的结果是: en: Show debug window
24 | 接下来,请翻译: 建议间隔30秒
25 |
26 | ## 第三步、
27 |
28 | 配置本脚本以下几个变量:
29 | lang:将KeepChatGPT中的lang变量值复制粘贴到这里
30 | new_str:填写想要本地化的词汇,例如建议间隔30秒,随意填,如果重复了就会覆盖
31 | new_str_min:填本地化词汇的英文缩写,例如si,随意填,如果重复了就会覆盖
32 | transle_tmp:将ChatGPT翻译的结果复制粘贴到这里
33 |
34 | ## 第四步、
35 |
36 | 运行,并把结果复制粘贴到KeepChatGPT中的lang变量值。
37 |
38 | """
39 |
40 | import json, os
41 |
42 | def lang_add(lang, new_str, new_str_min, transle_tmp):
43 | lang["index"].update({new_str: new_str_min})
44 | transle_tmp = transle_tmp.replace("\r", "")
45 | for t in transle_tmp.split("\n"):
46 | if t.strip():
47 | key = t.split(":")[0].strip()
48 | value = "".join(t.split(":")[1:]).strip()
49 | lang["local"][key].update({new_str_min: value})
50 | return lang
51 |
52 | def lang_del(lang, del_str, del_str_min):
53 | if del_str in lang["index"] and del_str_min == lang["index"][del_str]:
54 | del lang["index"][del_str]
55 | for l in lang["local"]:
56 | if del_str_min in lang["local"][l]:
57 | del lang["local"][l][del_str_min]
58 | return lang
59 |
60 | def format_json(lang):
61 | langStr = ''
62 | langStr += '{' + '\n'
63 | langStr += ' "index": %s,' % (json.dumps(lang['index'], ensure_ascii = False)) + '\n'
64 | langStr += ' "local": {' + '\n'
65 | lj = []
66 | for country, langjson in lang['local'].items():
67 | lj.append('"%s": %s' % (country, json.dumps(langjson, ensure_ascii = False)))
68 | lj = ',\n'.join(lj)
69 | langStr += lj + '\n'
70 | langStr += ' }' + '\n'
71 | langStr += '}'
72 | return langStr
73 |
74 | def save(data, outfile):
75 | if not os.path.exists('test'):
76 | os.mkdir('test')
77 | open(outfile, 'wb').write(data.encode())
78 |
79 | def main():
80 | lang = '''
81 | {
82 | "index": {"暗色主题": "dm", "显示调试": "sd", "取消审计": "cm", "取消动画": "ca", "关于": "ab", "建议间隔50秒": "si", "调整间隔": "mi", "检查更新": "cu", "当前版本": "cv", "发现最新版": "dl", "已是最新版": "lv", "克隆对话": "cc", "净化页面": "pp", "展示大屏": "ls", "言无不尽": "sc", "拦截跟踪": "it", "日新月异": "ec", "赞赏鼓励": "ap", "警告": "wn", "数据安全": "ds", "发现敏感数据": "dd", "使用正则编写规则": "rr", "明察秋毫": "ko"},
83 | "local": {
84 | "ar": {"dm": "الوضع الداكن", "sd": "إظهار التصحيح", "cm": "إلغاء التدقيق", "ca": "إلغاء الرسوم المتحركة", "ab": "حول", "si": "اقتراح فاصل زمني 50 ثانية", "mi": "تعديل الفاصل", "cu": "التحقق من التحديثات", "cv": "الإصدار الحالي", "dl": "اكتشف أحدث إصدار", "lv": "أحدث إصدار", "cc": "استنساخ المحادثة", "pp": "تنقية الصفحة", "ls": "عرض الشاشة الكبيرة", "sc": "تحدث بشكل كامل", "it": "اعتراض التتبع", "ec": "التغير المستمر", "ap": "تقدير", "wn": "تحذير", "ds": "أمان البيانات", "dd": "اكتشف البيانات الحساسة", "rr": "استخدم الريجكس لكتابة القواعد", "ko": "الرصد الدقيق"},
85 | "bg": {"dm": "Тъмна тема", "sd": "Показване на отстраняване на грешки", "cm": "Отказ от одит", "ca": "Отмяна на анимацията", "ab": "За", "si": "Предложете интервал от 50 секунди", "mi": "Промяна на интервала", "cu": "Проверка на актуализации", "cc": "Клониране на разговора", "pp": "Почистване на страницата", "ls": "Показване на голям екран", "sc": "Говорете пълно", "it": "Прихващане на проследяването", "ec": "Непрекъснато променящ се", "ap": "Оценка", "wn": "Предупреждение", "ds": "Сигурност на данните", "dd": "Откриване на чувствителни данни", "rr": "Използвайте регулярни изрази за съставяне на правила", "ko": "Остро наблюдение"},
86 | "cs": {"dm": "Tmavý režim", "sd": "Zobrazit ladění", "cm": "Zrušení auditu", "ca": "Zrušit animaci", "ab": "O", "si": "Navrhnout interval 50 sekund", "mi": "Upravit interval", "cu": "Kontrola aktualizací", "cc": "Klonovat konverzaci", "pp": "Očistit stránku", "ls": "Zobrazení velkého displeje", "sc": "Mluvte úplně", "it": "Zachytávání sledování", "ec": "Neustále se měnící", "ap": "Ocenění", "wn": "Varování", "ds": "Bezpečnost dat", "dd": "Detekce citlivých dat", "rr": "Použijte regulární výrazy pro psaní pravidel", "ko": "Přesné pozorování"},
87 | "da": {"dm": "Mørk tilstand", "sd": "Vis fejlfinding", "cm": "Annuller revision", "ca": "Annuller animation", "ab": "Om", "si": "Forslag interval på 50 sekunder", "mi": "Ændre interval", "cu": "Tjek for opdateringer", "cc": "Klon samtalen", "pp": "Rensning af siden", "ls": "Vis stor skærm", "sc": "Fuldfør udtalelsen", "it": "Interceptor sporing", "ec": "Konstant forandring", "ap": "Værdssættelse", "wn": "Advarsel", "ds": "Datasikkerhed", "dd": "Opdage følsomme data", "rr": "Brug regex til at skrive regler", "ko": "Skarp observation"},
88 | "de": {"dm": "Dunkler Modus", "sd": "Fehlerbehebung anzeigen", "cm": "Prüfung abbrechen", "ca": "Animation abbrechen", "ab": "Über", "si": "Vorschlag für Intervall von 50 Sekunden", "mi": "Intervall bearbeiten", "cu": "Überprüfung auf Updates", "cv": "Aktuelle Version", "dl": "Entdecken Sie die neueste Version", "lv": "ist die neueste Version", "cc": "Konversation klonen", "pp": "Seite bereinigen", "ls": "Großen Bildschirm anzeigen", "sc": "Sprich vollständig", "it": "Tracking abfangen", "ec": "Ständiger Wandel", "ap": "Wertschätzung", "wn": "Warnung", "ds": "Datensicherheit", "dd": "Entdeckung sensibler Daten", "rr": "Verwenden Sie Regex, um Regeln zu schreiben", "ko": "Scharfe Beobachtung"},
89 | "el": {"dm": "Σκοτεινή θεματολογία", "sd": "Εμφάνιση αποσφαλμάτωσης", "cm": "Ακύρωση ελέγχου", "ca": "Ακύρωση κινούμενων σχεδίων", "ab": "Σχετικά με", "si": "Προτείνετε διάστημα 50 δευτερολέπτων", "mi": "Τροποποίηση διαστήματος", "cu": "Έλεγχος ενημερώσεων", "cc": "Κλωνοποίηση συνομιλίας", "pp": "Καθαρισμός σελίδας", "ls": "Εμφάνιση μεγάλης οθόνης", "sc": "Ολοκλήρωσε την ομιλία", "it": "Ανίχνευση παρακολούθησης", "ec": "Αδιάκοπη αλλαγή", "ap": "Εκτίμηση", "wn": "Προειδοποίηση", "ds": "Ασφάλεια δεδομένων", "dd": "Ανακάλυψη ευαίσθητων δεδομένων", "rr": "Χρησιμοποιήστε regex για να γράψετε κανόνες", "ko": "Εξαιρετική παρατήρηση"},
90 | "en": {"dm": "Dark mode", "sd": "Show debugging", "cm": "Cancel audit", "ca": "Cancel animation", "ab": "About", "si": "Suggest interval of 50 seconds; The author usually sets 900", "mi": "Modify interval", "cu": "Check for updates", "cv": "Current version", "dl": "Discover the latest version", "lv": "is the latest version", "cc": "Conversation cloning", "pp": "Purified page", "ls": "Wide display mode", "sc": "Complete response", "it": "Intercept tracking", "ec": "More chat info", "ap": "Sponsor", "wn": "Warning", "ds": "Data security", "dd": "Discover sensitive data", "rr": "Use regex to write rules", "ko": "Keen observation"},
91 | "eo": {"dm": "Malhela moduso", "sd": "Montri depuradon", "cm": "Nuligi kontroli", "ca": "Nuligi animacion", "ab": "Pri", "si": "Sugesti intervalon de 50 sekundoj", "mi": "Modifi intervalon", "cu": "Kontroli ĝisdatigojn", "cc": "Kloni konversacion", "pp": "Pura paĝo", "ls": "Montri grandan ekrane", "sc": "Parolu plene", "it": "Intercepti Trakadon", "ec": "Ĉiam ŝanĝiĝanta", "ap": "Aprobo", "wn": "Averto", "ds": "Datensekureco", "dd": "Malkovru sensitivajn datumojn", "rr": "Uzu regulajn esprimojn por skribi regulojn", "ko": "Akra observado"},
92 | "es": {"dm": "Modo oscuro", "sd": "Mostrar depuración", "cm": "Cancelar auditoría", "ca": "Cancelar animación", "ab": "Acerca de", "si": "Sugerir un intervalo de 50 segundos", "mi": "Modificar intervalo", "cu": "Comprobar actualizaciones", "cv": "Versión actual", "dl": "Descubre la última versión", "lv": "es la última versión", "cc": "Clonar conversación", "pp": "Purificar página", "ls": "Mostrar pantalla grande", "sc": "Termina tu discurso", "it": "Interceptar Rastreo", "ec": "Cambio constante", "ap": "Apreciación", "wn": "Advertencia", "ds": "Seguridad de datos", "dd": "Descubrir datos sensibles", "rr": "Usa regex para escribir reglas", "ko": "Observación aguda"},
93 | "fi": {"dm": "Tumma tila", "sd": "Näytä virheenkorjaus", "cm": "Peruuta tarkistus", "ca": "Peruuta animaatio", "ab": "Tietoa", "si": "Ehdota 50 sekunnin väliaikaa", "mi": "Muokkaa väliä", "cu": "Tarkista päivitykset", "cc": "Kloonaa keskustelu", "pp": "Puhdista sivu", "ls": "Näytä suuri näyttö", "sc": "Puhu loppuun asti", "it": "Sieppaa seuranta", "ec": "Jatkuvasti muuttuva", "ap": "Arvostus", "wn": "Varoitus", "ds": "Tietoturva", "dd": "Löytää arkaluonteista dataa", "rr": "Käytä regexiä sääntöjen kirjoittamiseen", "ko": "Tarkka havainnointi"},
94 | "fr": {"dm": "Mode sombre", "sd": "Afficher le débogage", "cm": "Annuler l'audit", "ca": "Annuler l'animation", "ab": "À propos de", "si": "Suggérer un intervalle de 50 secondes", "mi": "Modifier l'intervalle", "cu": "Vérifier les mises à jour", "cv": "Version actuelle", "dl": "Découvrir la dernière version", "lv": "est la dernière version", "cc": "Cloner la conversation", "pp": "Purifier la page", "ls": "Afficher grand écran", "sc": "Parlez complètement", "it": "Interception de suivi", "ec": "En perpétuelle évolution", "ap": "Appréciation", "wn": "Avertissement", "ds": "Sécurité des données", "dd": "Découvrir des données sensibles", "rr": "Utilisez des regex pour écrire des règles", "ko": "Observation fine"},
95 | "fr-CA": {"dm": "Mode nuit", "sd": "Afficher le débogage", "cm": "Annuler la vérification", "ca": "Annuler l'animation", "ab": "À propos de", "si": "Suggérer un intervalle de 50 secondes", "mi": "Modifier l'intervalle", "cu": "Vérifier les mises à jour", "cv": "Version actuelle", "dl": "Découvrir la dernière version", "lv": "est la dernière version", "cc": "Cloner la conversation", "pp": "Purifier la page", "ls": "Afficher grand écran", "sc": "Parlez complètement", "it": "Intercepter le suivi", "ec": "Évolution constante", "ap": "Appréciation", "wn": "Avertissement", "ds": "Sécurité des données", "dd": "Découvrir des données sensibles", "rr": "Utilisez des regex pour écrire des règles", "ko": "Observation fine"},
96 | "he": {"dm": "מצב כהה", "sd": "הצגת התיקון", "cm": "ביטול ביקורת", "ca": "בטל אנימציה", "ab": "אודות", "si": "הצע מרווח של 50 שניות", "mi": "שינוי מרווח", "cu": "בדיקת עדכונים", "cc": "שכפול שיחה", "pp": "טיהור הדף", "ls": "תצוגת מסך גדול", "sc": "דבר במלואו", "it": "התערבות במעקב", "ec": "שינוי מתמיד", "ap": "הערכה", "wn": "אזהרה", "ds": "אבטחת מידע", "dd": "גילוי נתונים רגישים", "rr": "השתמש בביטויים רגולריים לכתיבת כללים", "ko": "תפיסה חדה"},
97 | "hu": {"dm": "Sötét mód", "sd": "Hibakeresés mutatása", "cm": "Ellenőrzés megszüntetése", "ca": "Animáció törlése", "ab": "Rólunk", "si": "Javaslat 50 másodperces időközre", "mi": "Időköz módosítása", "cu": "Frissítések keresése", "cc": "Beszélgetés klónozása", "pp": "Oldal tisztítása", "ls": "Nagy képernyő megjelenítése", "sc": "Beszélj teljesen", "it": "Követés elfogása", "ec": "Folyamatos változás", "ap": "Elismerés", "wn": "Figyelmeztetés", "ds": "Adatbiztonság", "dd": "Érzékeny adatok felfedezése", "rr": "Használja a regex-et a szabályok írásához", "ko": "Éles megfigyelés"},
98 | "id": {"dm": "Mode gelap", "sd": "Tampilkan debugging", "cm": "Batalkan audit", "ca": "Batalkan animasi", "ab": "Tentang", "si": "Sarankan interval 50 detik", "mi": "Modifikasi interval", "cu": "Periksa Pembaruan", "cc": "Klon percakapan", "pp": "Membersihkan halaman", "ls": "Tampilkan layar besar", "sc": "Berbicara secara lengkap", "it": "Intersepsi Pelacakan", "ec": "Perubahan terus-menerus", "ap": "Penghargaan", "wn": "Peringatan", "ds": "Keamanan data", "dd": "Temukan data sensitif", "rr": "Gunakan regex untuk menulis aturan", "ko": "Pengamatan tajam"},
99 | "it": {"dm": "Modalità scura", "sd": "Mostra debug", "cm": "Annulla verifica", "ca": "Annulla animazione", "ab": "Riguardo a", "si": "Suggerisci un intervallo di 50 secondi", "mi": "Modifica intervallo", "cu": "Verifica aggiornamenti", "cv": "Versione attuale", "dl": "Scopri l'ultima versione", "lv": "è l'ultima versione", "cc": "Clona conversazione", "pp": "Purifica pagina", "ls": "Mostra grande schermo", "sc": "Parla completamente", "it": "Intercettare il tracciamento", "ec": "Cambiamento costante", "ap": "Apprezzamento", "wn": "Avvertimento", "ds": "Sicurezza dei dati", "dd": "Scoprire dati sensibili", "rr": "Usa regex per scrivere regole", "ko": "Osservazione acuta"},
100 | "ja": {"dm": "ダークモード", "sd": "デバッグを表示", "cm": "監査をキャンセル", "ca": "アニメーションのキャンセル", "ab": "について", "si": "50秒間隔を提案する", "mi": "間隔を変更する", "cu": "更新をチェックする", "cv": "現在のバージョン", "dl": "最新バージョンを発見する", "lv": "最新バージョンです", "cc": "会話をクローンする", "pp": "ページを浄化する", "ls": "ビッグスクリーンを表示する", "sc": "完全に話してください", "it": "トラッキングの傍受", "ec": "絶え間ない変化", "ap": "評価", "wn": "警告", "ds": "データセキュリティ", "dd": "機密データを発見する", "rr": "正規表現を使用してルールを書く", "ko": "鋭い観察"},
101 | "ka": {"dm": "ბნელი რეჟიმი", "sd": "გამოჩენა დებაგი", "cm": "ანულირება აუდიტი", "ca": "ანიმაციის გაუქმება", "ab": "შესახებ", "si": "50 წამის ინტერვალის შეტანა", "mi": "ინტერვალის შეცვლა", "cu": "განახლებების შემოწმება", "cc": "კონვერსაციის კლონირება", "pp": "გვერდის გაწმენდა", "ls": "დიდი ეკრანის გამოსახულება", "sc": "სრულად ილაპარაკეთ", "it": "თვალყური მისმართავა", "ec": "მუდმივი ცვლილება", "ap": "შეფასება", "wn": "გაფრთხილება", "ds": "მონაცემთა უსაფრთხოება", "dd": "საკითხავი მონაცემების გამოცნობა", "rr": "გამოიყენეთ regex წესების დაწერად", "ko": "მკრეფად გამოვიდა"},
102 | "ko": {"dm": "다크 모드", "sd": "디버깅 표시", "cm": "감사 취소", "ca": "애니메이션 취소", "ab": "관하여", "si": "50초 간격 건의", "mi": "간격 수정", "cu": "업데이트 확인", "cv": "현재 버전", "dl": "최신 버전 찾기", "lv": "최신 버전입니다.", "cc": "대화 복제", "pp": "페이지 정화", "ls": "큰 화면 표시", "sc": "완전히 말하세요", "it": "추적 가로채기", "ec": "끊임없는 변화", "ap": "감사", "wn": "경고", "ds": "데이터 보안", "dd": "민감한 데이터 발견", "rr": "정규 표현식을 사용하여 규칙 작성", "ko": "예리한 관찰"},
103 | "nb": {"dm": "Mørk modus", "sd": "Vis feilsøking", "cm": "Avbryt revisjonen", "ca": "Avbryt animasjon", "ab": "Om", "si": "Forslag om et intervall på 50 sekunder", "mi": "Endre intervall", "cu": "Sjekk etter oppdateringer", "cc": "Klon samtalen", "pp": "Rens side", "ls": "Vis stor skjerm", "sc": "Snakk fullstendig", "it": "Intercept sporing", "ec": "Kontinuerlig endring", "ap": "Verdsatt", "wn": "Advarsel", "ds": "Datasikkerhet", "dd": "Oppdage sensitiv data", "rr": "Bruk regex for å skrive regler", "ko": "Skarpt observasjon"},
104 | "nl": {"dm": "Donkere modus", "sd": "Foutopsporing weergeven", "cm": "Controle annuleren", "ca": "Animatie annuleren", "ab": "Over", "si": "Stel een interval van 50 seconden voor", "mi": "Interval wijzigen", "cu": "Controleren op updates", "cc": "Gesprek klonen", "pp": "Pagina zuiveren", "ls": "Groot scherm weergeven", "sc": "Spreek volledig uit", "it": "Onderscheppen van tracking", "ec": "Voortdurende verandering", "ap": "Waardering", "wn": "Waarschuwing", "ds": "Gegevensbeveiliging", "dd": "Gevoelige gegevens ontdekken", "rr": "Gebruik regex om regels te schrijven", "ko": "Scherp observeren"},
105 | "pl": {"dm": "Tryb ciemny", "sd": "Pokaż debugowanie", "cm": "Anuluj audyt", "ca": "Anuluj animację", "ab": "O", "si": "Zasugeruj interwał 50 sekund", "mi": "Zmień interwał", "cu": "Sprawdź aktualizacje", "cc": "Klonuj rozmowę", "pp": "Oczyść stronę", "ls": "Wyświetl duży ekran", "sc": "Mów całkowicie", "it": "Przechwytywanie śledzenia", "ec": "Ciągłe zmiany", "ap": "Docenienie", "wn": "Ostrzeżenie", "ds": "Bezpieczeństwo danych", "dd": "Wykrywanie wrażliwych danych", "rr": "Użyj regex do pisania reguł", "ko": "Wnikliwa obserwacja"},
106 | "pt-BR": {"dm": "Modo escuro", "sd": "Mostrar depuração", "cm": "Cancelar auditoria", "ca": "Cancelar animação", "ab": "Sobre", "si": "Sugira um intervalo de 50 segundos", "mi": "Modificar intervalo", "cu": "Verificar atualizações", "cc": "Clonar conversa", "pp": "Purificar página", "ls": "Exibir tela grande", "sc": "Fale completamente", "it": "Interceptar Rastreamento", "ec": "Mudança constante", "ap": "Apreciação", "wn": "Aviso", "ds": "Segurança de dados", "dd": "Descobrir dados sensíveis", "rr": "Use regex para escrever regras", "ko": "Observação aguçada"},
107 | "ro": {"dm": "Mod întunecat", "sd": "Afișare depanare", "cm": "Anulare audit", "ca": "Anulare animație", "ab": "Despre", "si": "Sugerați un interval de 50 secunde", "mi": "Modificați intervalul", "cu": "Verifică actualizări", "cc": "Clonează conversația", "pp": "Purificare pagină", "ls": "Afișare ecran mare", "sc": "Vorbiți complet", "it": "Interceptarea urmăririi", "ec": "Schimbare continuă", "ap": "Apreciere", "wn": "Avertizare", "ds": "Securitatea datelor", "dd": "Descoperirea datelor sensibile", "rr": "Folosiți regex pentru a scrie reguli", "ko": "Observație fină"},
108 | "ru": {"dm": "Темный режим", "sd": "Показать отладку", "cm": "Отменить аудит", "ca": "Отменить анимацию", "ab": "О", "si": "Предложить интервал в 50 секунд", "mi": "Изменить интервал", "cu": "Проверить обновления", "cc": "Клонировать диалог", "pp": "Очистить страницу", "ls": "Показать большой экран", "sc": "Говорите полностью", "it": "Перехват отслеживания", "ec": "Постоянное изменение", "ap": "Признательность", "wn": "Предупреждение", "ds": "Безопасность данных", "dd": "Обнаружение конфиденциальных данных", "rr": "Используйте регулярные выражения для написания правил", "ko": "Точное наблюдение"},
109 | "sk": {"dm": "Tmavý režim", "sd": "Zobraziť ladenie", "cm": "Zrušiť audit", "ca": "Zrušiť animáciu", "ab": "O", "si": "Navrhnúť interval 50 sekúnd", "mi": "Zmena intervalu", "cu": "Kontrola aktualizácií", "cc": "Klonovať konverzáciu", "pp": "Očistiť stránku", "ls": "Zobraziť veľkú obrazovku", "sc": "Hovorte úplne", "it": "Zachytenie sledovania", "ec": "Neustále sa meniace", "ap": "Ocenenie", "wn": "Varovanie", "ds": "Bezpečnosť údajov", "dd": "Objavenie citlivých dát", "rr": "Použite regex na písanie pravidiel", "ko": "Presné pozorovanie"},
110 | "sr": {"dm": "Тамни режим", "sd": "Прикажи отклањање грешака", "cm": "Откажи ревизију", "ca": "Откажи анимацију", "ab": "О", "si": "Predložiti interval od 50 sekundi", "mi": "Измена интервала", "cu": "Provera ažuriranja", "cc": "Клонирај разговор", "pp": "Прочисти страницу", "ls": "Прикажи велики екран", "sc": "Говорите у потпуности", "it": "Пресретање праћења", "ec": "Непрестана промена", "ap": "Поштовање", "wn": "Упозорење", "ds": "Сигурност података", "dd": "Откривање осетљивих података", "rr": "Користите регуларне изразе за писање правила", "ko": "Прецизно набљудавање"},
111 | "sv": {"dm": "Mörkt läge", "sd": "Visa felsökning", "cm": "Avbryt revision", "ca": "Avbryt animation", "ab": "Om", "si": "Föreslå intervall på 50 sekunder", "mi": "Ändra intervall", "cu": "Kontrollera uppdateringar", "cc": "Klonar samtal", "pp": "Rensa sidan", "ls": "Visa stor skärm", "sc": "Tala helt klart", "it": "Interceptera spårning", "ec": "Ständig förändring", "ap": "Uppskattning", "wn": "Varning", "ds": "Datasäkerhet", "dd": "Upptäcka känslig data", "rr": "Använd regex för att skriva regler", "ko": "Skarp observation"},
112 | "th": {"dm": "โหมดมืด", "sd": "แสดงการแก้ไขข้อผิดพลาด", "cm": "ยกเลิกการตรวจสอบ", "ca": "ยกเลิกการเคลื่อนไหว", "ab": "เกี่ยวกับ", "si": "เสนอช่วงเวลา 50 วินาที", "mi": "แก้ไขระยะห่าง", "cu": "ตรวจสอบการอัปเดต", "cc": "โคลนสนทนา", "pp": "ทำความสะอาดหน้า", "ls": "แสดงหน้าจอใหญ่", "sc": "พูดคุยให้เสร็จสิ้น", "it": "การดักจับการติดตาม", "ec": "การเปลี่ยนแปลงตลอดเวลา", "ap": "การประเมินค่า", "wn": "คำเตือน", "ds": "ความปลอดภัยของข้อมูล", "dd": "ค้นพบข้อมูลที่ละเอียดอ่อน", "rr": "ใช้ regex เพื่อเขียนกฎ", "ko": "การสังเกตอย่างชัดเจน"},
113 | "tr": {"dm": "Karanlık mod", "sd": "Hata ayıklama göster", "cm": "Denetimi İptal Et", "ca": "Animasyonu iptal et", "ab": "Hakkında", "si": "50 saniyelik aralık önerin", "mi": "Aralığı değiştir", "cu": "Güncelleştirmeleri kontrol et", "cc": "Sohbeti kopyala", "pp": "Sayfayı temizle", "ls": "Büyük ekranı görüntüle", "sc": "Tamamlayın konuşmayı", "it": "İzlemeyi Engellemek", "ec": "Sürekli değişim", "ap": "Takdir", "wn": "Uyarı", "ds": "Veri güvenliği", "dd": "Hassas verileri keşfetmek", "rr": "Kuralları yazmak için regex kullanın", "ko": "Keskin gözlem"},
114 | "uk": {"dm": "Темний режим", "sd": "Показати налагодження", "cm": "Скасувати аудит", "ca": "Скасувати анімацію", "ab": "Про", "si": "Запропонуйте інтервал у 50 секунд", "mi": "Змінити інтервал", "cu": "Перевірити оновлення", "cc": "Клонувати діалог", "pp": "Очистити сторінку", "ls": "Відобразити великий екран", "sc": "Говоріть повністю", "it": "Перехоплення відстеження", "ec": "Постійна зміна", "ap": "Вдячність", "wn": "Попередження", "ds": "Безпека даних", "dd": "Виявлення конфіденційних даних", "rr": "Використовуйте регулярні вирази для написання правил", "ko": "Точне спостереження"},
115 | "ug": {"dm": "تېما كۆرسىتىش", "sd": "كۆرسەتكەن يۇقىرىلاش", "cm": "ئەمەلدىن قالدۇرۇش", "ca": "ئېنىماتىكىنى بىكار قىلىش", "ab": "ئۇچۇرلىق", "si": "50 سىكونتلىك ئارىلىقنى سۇنۇشتۇرۇش", "mi": "ئارىلىق ئۆزگەرتىش", "cu": "يېڭىلانما كۆزەت", "cc": "كۆپچەي ئىككىلىش", "pp": "چۈشۈرۈش بەت", "ls": "كۆرسىتىش چوڭ ئېكران", "sc": "تاماملا سۆزلىشىڭىز", "it": "قولايلىنىش تىزىتكۈن", "ec": "تەڭشەك ئىستىقامەت", "ap": "قىلىش", "wn": "ئاگاھلاندۇرۇش", "ds": "مەلۇمات بىخەتەرلىكى", "dd": "سىزىقلىق مەلۇماتنى تاپشۇرۇش", "rr": "قائىدىلەرنى يېزىش ئۈچۈن regex نى ئىشلىتىڭ", "ko": "ئاڭلىتىش قىممىتى"},
116 | "vi": {"dm": "Chế độ tối", "sd": "Hiển thị gỡ lỗi", "cm": "Hủy đánh giá", "ca": "Hủy hoạt hình", "ab": "Về", "si": "Đề xuất khoảng thời gian 50 giây", "mi": "Sửa khoảng cách", "cu": "Kiểm tra cập nhật", "cc": "Sao chép cuộc trò chuyện", "pp": "Làm sạch trang", "ls": "Hiển thị màn hình lớn", "sc": "Nói đầy đủ", "it": "Chặn Theo Dõi", "ec": "Luôn thay đổi", "ap": "Đánh giá", "wn": "Cảnh báo", "ds": "Bảo mật dữ liệu", "dd": "Phát hiện dữ liệu nhạy cảm", "rr": "Sử dụng regex để viết quy tắc", "ko": "Quan sát tinh tế"},
117 | "zh-CN": {"dm": "暗色主题", "sd": "显示调试", "cm": "取消审计", "ca": "取消动画", "ab": "关于", "si": "建议间隔50秒以上,作者平时设置的是900秒", "mi": "调整间隔", "cu": "检查更新", "cc": "克隆对话", "pp": "净化页面", "ls": "展示大屏", "sc": "言无不尽", "it": "拦截跟踪", "ec": "日新月异", "ap": "赞赏鼓励", "wn": "警告", "ds": "数据安全", "dd": "你输入的内容里存在以下敏感数据,已为你自动化脱敏", "rr": "本功能会将聊天输入框里的敏感信息进行脱敏和警告 请根据正则表达式语法编写数据安全规则,不同的规则用换行间隔", "ko": "明察秋毫"},
118 | "zh-TW": {"dm": "暗黑模式", "sd": "顯示調試", "cm": "取消稽核", "ca": "取消動畫", "ab": "關於", "si": "建議間隔50秒,作者平時設置的是900秒", "mi": "調整間隔", "cu": "檢查更新", "cc": "複製對話", "pp": "淨化頁面", "ls": "顯示大螢幕", "sc": "言無不盡", "it": "拦截追踪", "ec": "日新月異", "ap": "讚賞鼓勵", "wn": "警告", "ds": "資料安全", "dd": "發現敏感數據", "rr": "使用正則表達式撰寫規則", "ko": "明察秋毫"}
119 | }
120 | }
121 | '''
122 |
123 | lang = json.loads(lang)
124 |
125 | new_str = "明察秋毫"
126 |
127 | new_str_min = "ko"
128 |
129 | transle_tmp = """
130 | ar: الرصد الدقيق
131 | bg: Остро наблюдение
132 | cs: Přesné pozorování
133 | da: Skarp observation
134 | de: Scharfe Beobachtung
135 | el: Εξαιρετική παρατήρηση
136 | en: Keen observation
137 | eo: Akra observado
138 | es: Observación aguda
139 | fi: Tarkka havainnointi
140 | fr: Observation fine
141 | fr-CA: Observation fine
142 | he: תפיסה חדה
143 | hu: Éles megfigyelés
144 | id: Pengamatan tajam
145 | it: Osservazione acuta
146 | ja: 鋭い観察
147 | ka: მკრეფად გამოვიდა
148 | ko: 예리한 관찰
149 | nb: Skarpt observasjon
150 | nl: Scherp observeren
151 | pl: Wnikliwa obserwacja
152 | pt-BR: Observação aguçada
153 | ro: Observație fină
154 | ru: Точное наблюдение
155 | sk: Presné pozorovanie
156 | sr: Прецизно набљудавање
157 | sv: Skarp observation
158 | th: การสังเกตอย่างชัดเจน
159 | tr: Keskin gözlem
160 | uk: Точне спостереження
161 | ug: ئاڭلىتىش قىممىتى
162 | vi: Quan sát tinh tế
163 | zh-CN: 明察秋毫
164 | zh-TW: 明察秋毫
165 | """
166 |
167 | # 删除字段
168 | # del_str = "展示全屏"
169 | # del_str_min = "fs"
170 | # lang = lang_del(lang, del_str, del_str_min)
171 |
172 | # 添加字段
173 | lang = lang_add(lang, new_str, new_str_min, transle_tmp)
174 |
175 | langStr = format_json(lang)
176 | print(langStr)
177 | save(langStr, 'test/lang.txt')
178 |
179 | main()
180 |
--------------------------------------------------------------------------------