Skip to content

Commit

Permalink
Merge pull request #14 from F33RNI/next
Browse files Browse the repository at this point in the history
Set API type 1 as default
  • Loading branch information
F33RNI authored Feb 27, 2023
2 parents 31a7390 + 029caa8 commit a20e9f3
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 12 deletions.
13 changes: 7 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,14 +49,15 @@ Support the project by buying and listening to my music 🎵
1. Install Python and pip
2. Download source code
3. Install requirements `pip install -r requirements.txt --upgrade`
4. For **API type 0** (Official API, more "stupid" model, uses credits):
4. For **API type 1** (recommended) (revChatGPT API V1, free, uses same model as official website):
1. Create account at OpenAI. Make sure you have access to https://chat.openai.com/
2. Open https://chat.openai.com/api/auth/session
3. Copy value of `accessToken` into `access_token` in `chatgpt_auth` in `chatgpt_api_1` in `settings.json` file
4. If you have conversation id you can specify it in `conversation_id` in `chatgpt_dialog` in `chatgpt_api_1` in `settings.json` file
5. Configure proxy if needed
5. For **API type 0** (Official API, more "stupid" model, uses credits):
1. Generate API Key https://platform.openai.com/account/api-keys and paste it into `open_ai_api_key` in `chatgpt_api_0` in `settings.json` file
2. If you have conversation id you can specify it in `existing_conversation_id` in `chatgpt_api_0` in `settings.json` file
5. For **API type 1** (revChatGPT API V1, free, uses same model as official website):
1. Create account at OpenAI using email and password
2. Type OpenAI account email and password into `email` and `password` in `chatgpt_auth` in `chatgpt_api_1` in `settings.json` file
3. If you have conversation id you can specify it in `conversation_id` in `chatgpt_dialog` in `chatgpt_api_1` in `settings.json` file
4. Configure proxy if needed
6. For DALL-E, generate API Key https://platform.openai.com/account/api-keys
7. Type Generated OpenAI API Key into `open_ai_api_key` in `dalle` in `settings.json` file
8. Create bot at https://t.me/BotFather
Expand Down
2 changes: 1 addition & 1 deletion main.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
import Authenticator
import BotHandler

TELEGRAMUS_VERSION = 'beta_1.7.1'
TELEGRAMUS_VERSION = 'beta_1.7.2'

# Logging level (INFO for debug, WARN for release)
LOGGING_LEVEL = logging.INFO
Expand Down
10 changes: 5 additions & 5 deletions settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"__comment02__": "SPECIFY revChatGPT API TYPE: 0 USES OPENAI API KEY, 1 USES EMAIL/PASS BUT BETTER AND FREE",
"modules": {
"chatgpt": true,
"chatgpt_api_type": 0,
"chatgpt_api_type": 1,
"dalle": true
},

Expand All @@ -19,10 +19,10 @@
"__comment05__": "API TYPE 1 USES revChatGPT TO ACCESS SAME MODEL AS OFFICIAL WEBSITE AND ALSO IT'S FREE",
"chatgpt_api_1": {
"__comment06__": "PROVIDE YOUR OPENAI ACCOUNT DETAILS BELOW TO USE CHATGPT (IF ENABLED)",
"__comment07__": "YOU CAN USE EMAIL/PASSWORD",
"__comment07__": "GO TO https://chat.openai.com/api/auth/session AND PASTE accessToken BELOW",
"__comment08__": "OR SESSION_TOKEN (FROM COOKIES ON chat.openai.com AS __Secure-next-auth.session-token)",
"__comment09__": "OR ACCESS_TOKEN (https://chat.openai.com/api/auth/session)",
"__comment10__": "PROVIDE PROXY BASE URL (LEAVE EMPTY FOR DEFAULT VALUE OR TRY https://apps.openai.com/)",
"__comment09__": "OR YOU CAN USE EMAIL/PASSWORD (MAY NOT WORKING)",
"__comment10__": "PROVIDE BASE URL (LEAVE EMPTY FOR DEFAULT VALUE OR TRY https://apps.openai.com/)",
"chatgpt_auth": {
"email": "",
"password": "",
Expand Down Expand Up @@ -74,4 +74,4 @@
"queue_max": 5,
"show_queue_message": true
}
}
}

0 comments on commit a20e9f3

Please sign in to comment.