This repository has been archived by the owner on Sep 16, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 65
add option to increase token size; closes #246 #248
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
bertybuttface
approved these changes
Nov 8, 2023
spantaleev
added a commit
to spantaleev/matrix-docker-ansible-deploy
that referenced
this pull request
Feb 22, 2024
The new version is very broken. It has at least 2 issues. The first one is: ``` Error: maxPromptTokens + max_tokens (3097 + 1024 = 4121) must be less than or equal to maxContextTokens (4097) at ChatGPTClient.setOptions (file:///usr/src/app/node_modules/@waylaidwanderer/chatgpt-api/src/ChatGPTClient.js:72:19) at new ChatGPTClient (file:///usr/src/app/node_modules/@waylaidwanderer/chatgpt-api/src/ChatGPTClient.js:23:14) at main (file:///usr/src/app/dist/index.js:62:21) at file:///usr/src/app/dist/index.js:94:1 at ModuleJob.run (node:internal/modules/esm/module_job:218:25) at async ModuleLoader.import (node:internal/modules/esm/loader:329:24) at async loadESM (node:internal/process/esm_loader:28:7) at async handleMainPromise (node:internal/modules/run_main:113:12) ``` Likely related to: - matrixgpt/matrix-chatgpt-bot#246 - matrixgpt/matrix-chatgpt-bot#248 It can be tweaked around by overriding some default environment variables (`roles/custom/matrix-bot-chatgpt/templates/env.j2`) in order to tweak them: ``` CHATGPT_MAX_CONTEXT_TOKENS=4097 CHATGPT_MAX_PROMPT_TOKENS=2500 ``` This leads us to another issue: ``` node:internal/process/promises:289 triggerUncaughtException(err, true /* fromPromise */); ^ [Error: Failed to deserialize or serialize a JSON value missing field `version` at line 1 column 6704] { code: 'GenericFailure' } Node.js v20.11.1 error Command failed with exit code 1. ``` ... whatever that means.
KarolosLykos
pushed a commit
to KarolosLykos/matrix-docker-ansible-deploy
that referenced
this pull request
Mar 5, 2024
The new version is very broken. It has at least 2 issues. The first one is: ``` Error: maxPromptTokens + max_tokens (3097 + 1024 = 4121) must be less than or equal to maxContextTokens (4097) at ChatGPTClient.setOptions (file:///usr/src/app/node_modules/@waylaidwanderer/chatgpt-api/src/ChatGPTClient.js:72:19) at new ChatGPTClient (file:///usr/src/app/node_modules/@waylaidwanderer/chatgpt-api/src/ChatGPTClient.js:23:14) at main (file:///usr/src/app/dist/index.js:62:21) at file:///usr/src/app/dist/index.js:94:1 at ModuleJob.run (node:internal/modules/esm/module_job:218:25) at async ModuleLoader.import (node:internal/modules/esm/loader:329:24) at async loadESM (node:internal/process/esm_loader:28:7) at async handleMainPromise (node:internal/modules/run_main:113:12) ``` Likely related to: - matrixgpt/matrix-chatgpt-bot#246 - matrixgpt/matrix-chatgpt-bot#248 It can be tweaked around by overriding some default environment variables (`roles/custom/matrix-bot-chatgpt/templates/env.j2`) in order to tweak them: ``` CHATGPT_MAX_CONTEXT_TOKENS=4097 CHATGPT_MAX_PROMPT_TOKENS=2500 ``` This leads us to another issue: ``` node:internal/process/promises:289 triggerUncaughtException(err, true /* fromPromise */); ^ [Error: Failed to deserialize or serialize a JSON value missing field `version` at line 1 column 6704] { code: 'GenericFailure' } Node.js v20.11.1 error Command failed with exit code 1. ``` ... whatever that means.
ignyx
pushed a commit
to Tawkie/matrix-docker-ansible-deploy
that referenced
this pull request
Jun 20, 2024
The new version is very broken. It has at least 2 issues. The first one is: ``` Error: maxPromptTokens + max_tokens (3097 + 1024 = 4121) must be less than or equal to maxContextTokens (4097) at ChatGPTClient.setOptions (file:///usr/src/app/node_modules/@waylaidwanderer/chatgpt-api/src/ChatGPTClient.js:72:19) at new ChatGPTClient (file:///usr/src/app/node_modules/@waylaidwanderer/chatgpt-api/src/ChatGPTClient.js:23:14) at main (file:///usr/src/app/dist/index.js:62:21) at file:///usr/src/app/dist/index.js:94:1 at ModuleJob.run (node:internal/modules/esm/module_job:218:25) at async ModuleLoader.import (node:internal/modules/esm/loader:329:24) at async loadESM (node:internal/process/esm_loader:28:7) at async handleMainPromise (node:internal/modules/run_main:113:12) ``` Likely related to: - matrixgpt/matrix-chatgpt-bot#246 - matrixgpt/matrix-chatgpt-bot#248 It can be tweaked around by overriding some default environment variables (`roles/custom/matrix-bot-chatgpt/templates/env.j2`) in order to tweak them: ``` CHATGPT_MAX_CONTEXT_TOKENS=4097 CHATGPT_MAX_PROMPT_TOKENS=2500 ``` This leads us to another issue: ``` node:internal/process/promises:289 triggerUncaughtException(err, true /* fromPromise */); ^ [Error: Failed to deserialize or serialize a JSON value missing field `version` at line 1 column 6704] { code: 'GenericFailure' } Node.js v20.11.1 error Command failed with exit code 1. ``` ... whatever that means.
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
adds two new parameters to env in order to close #246