gragland / chatgpt-chrome-extension Goto Github PK
View Code? Open in Web Editor NEWA ChatGPT Chrome extension. Integrates ChatGPT into every text box on the internet.
License: MIT License
A ChatGPT Chrome extension. Integrates ChatGPT into every text box on the internet.
License: MIT License
but it can be fixed though
Being thrown this error, not sure if it is to do with new Cloudflare protections.
Error. Make sure you're running the server by following the instructions on https://github.com/gragland/chatgpt-everywhere. Also make sure you don't have an adblocker preventing requests to localhost:3000.
In the terminal I still see
Please sign in to ChatGPT using the Chromium browser window and dismiss the welcome modal...
Please sign in to ChatGPT using the Chromium browser window and dismiss the welcome modal...
Please sign in to ChatGPT using the Chromium browser window and dismiss the welcome modal...
system used:
Macosx
unable to set to login with google
The latest version on https://github.com/transitive-bullshit/chatgpt-api uses a captcha solver to get around Cloudflare protection and make requests to ChatGPT. If anyone wants to tackle this a pull request is greatly appreciated.
I am receiving both of these errors in my chrome extension. The app runs after node server.js. Shows
✔Training ChatGPT (1 plugin rules)
✔ You may now use the extension
but when I run ask gpt, the extension shows the below two errors:
Uncaught (in promise) Error: Could not establish connection. Receiving end does not exist.
Unchecked runtime.lastError: Cannot create item with duplicate id ask-chatgpt
✖ Training ChatGPT (1 plugin rules)
file:///D:/chatgpt-chrome-extension-main/chatgpt-chrome-extension-main/node_modules/chatgpt/build/index.js:202
const error = new ChatGPTError(msg, { cause: res });
^
ChatGPTError: ChatGPT error 404: {
"error": {
"message": "The model text-chat-davinci-002-20221122
does not exist",
"type": "invalid_request_error",
"param": null,
"code": "model_not_found"
}
}
Hello, I am looking for a little help when creating the .env file. I did all the correct installs with npm
yet I did not get a .env-example file in the install. And MacOS is not allowing me to create a .env file using TextEdit and the markdown(?) information provided in here: https://github.com/gragland/chatgpt-chrome-extension/blob/main/.env.example
I am not really great at coding-related things and would like some help in the right direction. Thanks!
I saw several extension like this one , typist AI and others , is it possible to run this with a server running in background .
Thank you
Getting this error after adding API key and installing chatgpt
ChatGPTError: ChatGPT error 429: {
"error": {
"message": "You exceeded your current quota, please check your plan and billing details.",
"type": "insufficient_quota",
"param": null,
"code": null
}
}
full error
at file:///C:/Users/samri/Documents/chatgpt-chrome-extension/node_modules/chatgpt/build/index.js:242:29
at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
statusCode: 429,
statusText: 'Too Many Requests',
[cause]: Response {
[Symbol(realm)]: null,
[Symbol(state)]: {
aborted: false,
rangeRequested: false,
timingAllowPassed: true,
requestIncludesCredentials: true,
type: 'default',
status: 429,
timingInfo: {
startTime: 301.7064999938011,
redirectStartTime: 0,
redirectEndTime: 0,
postRedirectStartTime: 301.7064999938011,
finalServiceWorkerStartTime: 0,
finalNetworkResponseStartTime: 0,
finalNetworkRequestStartTime: 0,
endTime: 0,
encodedBodySize: 0,
decodedBodySize: 0,
finalConnectionTimingInfo: null
},
cacheState: '',
statusText: 'Too Many Requests',
headersList: HeadersList {
cookies: null,
[Symbol(headers map)]: Map(11) {
'date' => { name: 'Date', value: 'Sun, 02 Apr 2023 21:55:56 GMT' },
'content-type' => {
name: 'Content-Type',
value: 'application/json; charset=utf-8'
},
'content-length' => { name: 'Content-Length', value: '206' },
'connection' => { name: 'Connection', value: 'keep-alive' },
'vary' => { name: 'vary', value: 'Origin' },
'x-request-id' => {
name: 'x-request-id',
value: '65596114b624aa7a7a6aa27b0d4ad1d1'
},
'strict-transport-security' => {
name: 'strict-transport-security',
value: 'max-age=15724800; includeSubDomains'
},
'cf-cache-status' => { name: 'CF-Cache-Status', value: 'DYNAMIC' },
'server' => { name: 'Server', value: 'cloudflare' },
'cf-ray' => { name: 'CF-RAY', value: '7b1c51a75c0b61e3-YVR' },
'alt-svc' => {
name: 'alt-svc',
value: 'h3=":443"; ma=86400, h3-29=":443"; ma=86400'
}
},
[Symbol(headers map sorted)]: null
},
urlList: [
<ref *1> URL {
[Symbol(context)]: URLContext {
flags: 400,
scheme: 'https:',
username: '',
password: '',
host: 'api.openai.com',
port: null,
path: [Array],
query: null,
fragment: null
},
[Symbol(query)]: URLSearchParams {
[Symbol(query)]: [],
[Symbol(context)]: [Circular *1]
}
}
],
body: {
stream: ReadableStream {
[Symbol(kType)]: 'ReadableStream',
[Symbol(kState)]: {
disturbed: true,
reader: [ReadableStreamDefaultReader],
state: 'closed',
storedError: undefined,
stream: undefined,
transfer: [Object],
controller: [ReadableStreamDefaultController]
},
[Symbol(nodejs.webstream.isClosedPromise)]: {
promise: [Promise],
resolve: [Function (anonymous)],
reject: [Function (anonymous)]
}
}
}
},
[Symbol(headers)]: Headers {
[Symbol(headers list)]: HeadersList {
cookies: null,
[Symbol(headers map)]: Map(11) {
'date' => { name: 'Date', value: 'Sun, 02 Apr 2023 21:55:56 GMT' },
'content-type' => {
name: 'Content-Type',
value: 'application/json; charset=utf-8'
},
'content-length' => { name: 'Content-Length', value: '206' },
'connection' => { name: 'Connection', value: 'keep-alive' },
'vary' => { name: 'vary', value: 'Origin' },
'x-request-id' => {
name: 'x-request-id',
value: '65596114b624aa7a7a6aa27b0d4ad1d1'
},
'strict-transport-security' => {
name: 'strict-transport-security',
value: 'max-age=15724800; includeSubDomains'
},
'cf-cache-status' => { name: 'CF-Cache-Status', value: 'DYNAMIC' },
'server' => { name: 'Server', value: 'cloudflare' },
'cf-ray' => { name: 'CF-RAY', value: '7b1c51a75c0b61e3-YVR' },
'alt-svc' => {
name: 'alt-svc',
value: 'h3=":443"; ma=86400, h3-29=":443"; ma=86400'
}
},
[Symbol(headers map sorted)]: null
},
[Symbol(guard)]: 'immutable',
[Symbol(realm)]: null
}
}
}
Node.js v18.15.0
Everything else has gone fine up to the point where I run node server.js (.env file has been properly set up and everything). Am I missing something that is causing this error?
...Documents\GitHub\chatgpt-chrome-extension\node_modules\puppeteer-core\lib\cjs\puppeteer\node\BrowserRunner.js:299
reject(new Error([
^
Error: Failed to launch the browser process! spawn C:\Program Files\Google\Chrome\Application\chrome.exe ENOENT
When I added a folder with an extension in the browser.
Manifest file is missing or unreadable
Could not load manifest.
But manifest.json is in the extension folder
My nodejs version: v18.13.0
My operating system: windows
Just a few hours ago, the system was running well, but when I used it again, the system reported this error, as follows:
√ Connecting to ChatGPT
× Training ChatGPT (1 plugin rules)
file:///D:/chatgpt/chatgpt-chrome-extension-main/node_modules/chatgpt/build/index.js:1598
const error = new ChatGPTError(result.error.message);
^ChatGPTError: ChatGPTAPI error 404
at ChatGPTAPIBrowser.sendMessage (file:///D:/chatgpt/chatgpt-chrome-extension-main/node_modules/chatgpt/build/index.js:1598:23)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async Conversation.sendMessage (file:///D:/chatgpt/chatgpt-chrome-extension-main/server.js:28:17)
at async oraPromise (file:///D:/chatgpt/chatgpt-chrome-extension-main/node_modules/ora/index.js:368:18)
at async start (file:///D:/chatgpt/chatgpt-chrome-extension-main/server.js:79:3) {
statusCode: 404,
statusText: ''
}
Node.js v18.13.0
When I read the source code, I found that one of the connections could not be accessed
https://chat.openai.com/backend-api/conversation
When I access this connection through a browser, the response is as follows:
{
"detail": "Method Not Allowed"
}
sorry if this is too beginner but I get the following error when running node server.js
PS C:\Users\Asus\chatgpt-chrome-extension> node server.js
C:\Users\Asus\chatgpt-chrome-extension\node_modules\puppeteer-core\lib\cjs\puppeteer\node\BrowserRunner.js:299
reject(new Error([
^
Error: Failed to launch the browser process! spawn C:\Program Files\Google\Chrome\Application\chrome.exe ENOENT
i tried copying the brave.exe path and pasting it in a few locations but it didnt work
appreciate any advice, thanks
Hello. I am quite new to this, and an old fart. I am trying to follow the instructions for aquiring my session id from Chatgpt, but I simply am getting lost.
I am on Windows 10, and succesfully installed the puppeteer, just stuck on how exaclty to use it to get my session id?
Any help is appreciated.
probably what the extension is operating seems heavy
Hi, I try to get your chrome extension. I got to:
Run the server so the extension can communicate with ChatGPT.
node server.js
and got: Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'dotenv-safe'
How to fix it?
Regards
Can you provide the method of proxy when requesting ChatGPT ? Or Access Token Authentication/Email and password authentication mode ...
-chrome-extension (main)
$ node server.js
× Training ChatGPT (1 plugin rules)
file:///D:/SoftwareDevelopment/GitHub/GPT/chatgpt-chrome-extension/nod
e_modules/chatgpt/build/index.js:202
const error = new ChatGPTError(msg, { cause: res });
^
ChatGPTError: ChatGPT error 404: {
"error": {
"message": "That model does not exist",
"type": "invalid_request_error",
"param": null,
"code": null
}
}
at file:///D:/Workplace/SoftwareDevelopment/GitHub/GPT/chatgpt-chrome-extens
ion/node_modules/chatgpt/build/index.js:202:29
at process.processTicksAndRejections (node:internal/process/task_queues:95:5
) {
statusCode: 404,
statusText: 'Not Found',
[cause]: Response {
[Symbol(realm)]: null,
[Symbol(state)]: {
aborted: false,
rangeRequested: false,
timingAllowPassed: true,
requestIncludesCredentials: true,
type: 'default',
status: 404,
timingInfo: {
startTime: 302.7082999944687,
redirectStartTime: 0,
redirectEndTime: 0,
postRedirectStartTime: 302.7082999944687,
finalServiceWorkerStartTime: 0,
finalNetworkResponseStartTime: 0,
finalNetworkRequestStartTime: 0,
endTime: 0,
encodedBodySize: 0,
decodedBodySize: 0,
finalConnectionTimingInfo: null
},
cacheState: '',
statusText: 'Not Found',
headersList: HeadersList {
cookies: null,
[Symbol(headers map)]: Map(7) {
'date' => { name: 'Date', value: 'Sat, 11 Feb 2023 23:15:54 GMT' },
'content-type' => {
name: 'Content-Type',
value: 'application/json; charset=utf-8'
},
'content-length' => { name: 'Content-Length', value: '158' },
'connection' => { name: 'Connection', value: 'keep-alive' },
'vary' => { name: 'Vary', value: 'Origin' },
'x-request-id' => {
name: 'X-Request-Id',
value: '087313fcbe31bb0e1737046c1af37213'
},
'strict-transport-security' => {
name: 'Strict-Transport-Security',
value: 'max-age=15724800; includeSubDomains'
}
},
[Symbol(headers map sorted)]: null
},
urlList: [
<ref *1> URL {
[Symbol(context)]: URLContext {
flags: 400,
scheme: 'https:',
username: '',
password: '',
host: 'api.openai.com',
port: null,
path: [Array],
query: null,
fragment: null
},
[Symbol(query)]: URLSearchParams {
[Symbol(query)]: [],
[Symbol(context)]: [Circular *1]
}
}
],
body: {
stream: ReadableStream {
[Symbol(kType)]: 'ReadableStream',
[Symbol(kState)]: {
disturbed: true,
reader: [ReadableStreamDefaultReader],
state: 'closed',
storedError: undefined,
stream: undefined,
transfer: [Object],
controller: [ReadableStreamDefaultController]
},
[Symbol(nodejs.webstream.isClosedPromise)]: {
promise: [Promise],
resolve: [Function (anonymous)],
reject: [Function (anonymous)]
}
}
}
},
[Symbol(headers)]: Headers {
[Symbol(headers list)]: HeadersList {
cookies: null,
[Symbol(headers map)]: Map(7) {
'date' => { name: 'Date', value: 'Sat, 11 Feb 2023 23:15:54 GMT' },
'content-type' => {
name: 'Content-Type',
value: 'application/json; charset=utf-8'
},
'content-length' => { name: 'Content-Length', value: '158' },
'connection' => { name: 'Connection', value: 'keep-alive' },
'vary' => { name: 'Vary', value: 'Origin' },
'x-request-id' => {
name: 'X-Request-Id',
value: '087313fcbe31bb0e1737046c1af37213'
},
'strict-transport-security' => {
name: 'Strict-Transport-Security',
value: 'max-age=15724800; includeSubDomains'
}
},
[Symbol(headers map sorted)]: null
},
[Symbol(guard)]: 'immutable',
[Symbol(realm)]: null
}
}
}
Node.js v19.6.0
Can we use log-in session of chatgpt for authorized requests?
Cant install, manifest file is missing and seems to be mandatory
When I try running node server.js
from the Terminal in the folder the extension is unzipped to, I get the following error:
Transcribed messages:
Error. Make sure you're running the server by following the
instructions on https://github.com/gragland/chatgpt-chrome-
extension. Also make sure you don't have an adblocker preventing
requests to localhost:3000.
Cannot GET /
Hey Gabe,
Thanks for the extension! 🙌
After a lot of fiddling (cursed be Windows!) I managed to get the server.js running
✔ Connecting to ChatGPT
✔ Training ChatGPT (5 plugin rules)
✔ You may now use the extension,
and the extension installed, but then when I try using the extension via the right-click, I get the error on the screenshot below. The bottom one on the first run, then the top one on every next one.
Do you know what might be causing it?
Thanks!
Could you provide more details on the first and second step of getting this extension to work it would be helpful for non technical folks as i am struggling.
When trying to run the server, I get the following error:
$ node server.js
✖ Training ChatGPT (1 plugin rules)
file:///Users/user/chatgpt-chrome-extension/node_modules/chatgpt/build/index.js:202
const error = new ChatGPTError(msg, { cause: res });
^
ChatGPTError: ChatGPT error 404: {
"error": {
"message": "That model does not exist",
"type": "invalid_request_error",
"param": null,
"code": null
}
}
at file:///Users/user/chatgpt-chrome-extension/node_modules/chatgpt/build/index.js:202:29
at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
statusCode: 404,
statusText: 'Not Found',
[cause]: Response {
[Symbol(realm)]: null,
[Symbol(state)]: {
aborted: false,
rangeRequested: false,
timingAllowPassed: true,
requestIncludesCredentials: true,
type: 'default',
status: 404,
...
For those of us who don't use chromium based browsers :)
Clicking Ask ChatGPT result in the following error:
Error. Make sure you're running the server by following the instructions on https://github.com/gragland/chatgpt-chrome-extension. Also make sure you don't have an adblocker preventing requests to localhost:3000.
Yes, running the server, logged in, and Ask ChatGPT is in the context menu.
rt
https://github.com/gragland/chatgpt-everywhere can be replaced with https://github.com/gragland/chatgpt-chrome-extension as i thought there is another repo while reading the code:
I followed the install instructions, npm install gave no errors, but node server.js returned:
node:internal/process/esm_loader:97
internalBinding('errors').triggerUncaughtException(
^
Error [ERR_MODULE_NOT_FOUND]: Cannot find module 'eventsource-parser\dist\index.mjs' imported from chatgpt-chrome-extension\node_modules\chatgpt\build\index.js
Did you mean to import eventsource-parser/dist/index.js?
at new NodeError (node:internal/errors:399:5)
at finalizeResolution (node:internal/modules/esm/resolve:326:11)
at moduleResolve (node:internal/modules/esm/resolve:945:10)
at defaultResolve (node:internal/modules/esm/resolve:1153:11)
at nextResolve (node:internal/modules/esm/loader:163:28)
at ESMLoader.resolve (node:internal/modules/esm/loader:838:30)
at ESMLoader.getModuleJob (node:internal/modules/esm/loader:424:18)
at ModuleWrap. (node:internal/modules/esm/module_job:77:40)
at link (node:internal/modules/esm/module_job:76:36) {
code: 'ERR_MODULE_NOT_FOUND'
}
Node.js v18.14.2
Attempted install several times, getting this error on Brave:
Uncaught (in promise) Error: Could not establish connection. Receiving end does not exist.
Context
background.js
Stack Trace
background.js:0 (anonymous function)
Whenever I click on the ask chatgpt , it does not do anything.
OpenAI has API Support where authentication is performed with an API Key. This form of authentication and interaction would actually be better than using Email Address and Password Credentials, especially since OpenAI supports OAuth with Google, thus eliminating users who use this auth method from using this extension.
"error": {
"message": "The model `text-chat-davinci-002-20221122` does not exist",
"type": "invalid_request_error",
"param": null,
"code": null
}
$ node --trace-warnings server.js
ChatGPTError: ChatGPT error 404: {
"error": {
"message": "That model does not exist",
"type": "invalid_request_error",
"param": null,
"code": null
}
}
at file:///C:/Users/Admin/Desktop/chatgpt-extension/chatgpt-chrome-extension/node_modules/chatgpt/build/index.js:202:29
at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
statusCode: 404,
statusText: 'Not Found',
[cause]: Response {
[Symbol(realm)]: null,
[Symbol(state)]: {
aborted: false,
rangeRequested: false,
timingAllowPassed: true,
requestIncludesCredentials: true,
type: 'default',
status: 404,
timingInfo: {
startTime: 366.8491999998223,
redirectStartTime: 0,
redirectEndTime: 0,
postRedirectStartTime: 366.8491999998223,
finalServiceWorkerStartTime: 0,
finalNetworkResponseStartTime: 0,
finalNetworkRequestStartTime: 0,
endTime: 0,
encodedBodySize: 0,
decodedBodySize: 0,
finalConnectionTimingInfo: null
},
cacheState: '',
statusText: 'Not Found',
headersList: HeadersList {
[Symbol(headers map)]: Map(7) {
'date' => 'Thu, 16 Feb 2023 22:35:28 GMT',
'content-type' => 'application/json; charset=utf-8',
'content-length' => '158',
'connection' => 'keep-alive',
'vary' => 'Origin',
'x-request-id' => '4482070b845f8d8f373759baf658719a',
'strict-transport-security' => 'max-age=15724800; includeSubDomains'
},
[Symbol(headers map sorted)]: null
},
urlList: [
<ref *1> URL {
[Symbol(context)]: URLContext {
flags: 400,
scheme: 'https:',
username: '',
password: '',
host: 'api.openai.com',
port: null,
path: [Array],
query: null,
fragment: null
},
[Symbol(query)]: URLSearchParams {
[Symbol(query)]: [],
[Symbol(context)]: [Circular *1]
}
}
],
body: {
stream: ReadableStream {
[Symbol(kType)]: 'ReadableStream',
[Symbol(kState)]: {
disturbed: true,
state: 'closed',
storedError: undefined,
stream: undefined,
transfer: [Object],
controller: [ReadableStreamDefaultController],
reader: undefined
},
[Symbol(used)]: true
}
}
},
[Symbol(headers)]: Headers {
[Symbol(headers list)]: HeadersList {
[Symbol(headers map)]: Map(7) {
'date' => 'Thu, 16 Feb 2023 22:35:28 GMT',
'content-type' => 'application/json; charset=utf-8',
'content-length' => '158',
'connection' => 'keep-alive',
'vary' => 'Origin',
'x-request-id' => '4482070b845f8d8f373759baf658719a',
'strict-transport-security' => 'max-age=15724800; includeSubDomains'
},
[Symbol(headers map sorted)]: null
},
[Symbol(guard)]: 'immutable',
[Symbol(realm)]: null
}
}
}
Node.js v18.8.0
Hello,
I would like to use this extension, however, I am unable to log in to my ChatGPT account using a password as I have set it up with Google Authentication. Could you please advise on what password I should set in the .env file? I have tried using my Google password, but it resulted in a failed authentication process and the headless browser was closed.
Thank you,
Farooq.
There appears to be an issue with the second step of the sever initialization.
const error = new ChatGPTError(msg);
ChatGPTError: ChatGPTAPI error 429
statusCode: 429,
statusText: 'Too Many Requests'
Although I tried implementing a solution found here: Error: ChatGPTAPI error 429, it doesn't seem to fix the issue. Anyone else ran into this?
I also think it's worth mentioning that this error start appearing within the past few days from what I have gathered.
import dotenv from "dotenv-safe";
^^^^^^
SyntaxError: Unexpected identifier
at Module._compile (internal/modules/cjs/loader.js:723:23)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:831:12)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:623:3)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.