Comments (10)
Also, does chatgpt not store the collection on its server somehow? Intuitively, I would have thought we just have to provide the session and a new prompt, and it has all the previous prompts and answers for that session saved. Is this not the case?
No. That's now how it works. Every time you send it a message its completely stateless. Thats just the nature of the large language model. So we provide context ourselves. This is also how openAI does it, each time you add to a conversation on their website it sends the whole thread to the language model.
So if you want to send everything across for context use -S, if not don't.
If you want to check how big your current conversation has gotten, and everything in it, just use -S with -t and no query. It will show you the whole convo, how many tokens, and an estimated cost.
from chatblade.
The only information I have on -e
is:
-e, --extract extract content from response if possible (either json or code block)
I don't see how this help line explains how it fixes the issues I had. And even if you say it does, then maybe you should change this line from the help menu.
from chatblade.
I also just got the error
openai error: This model's maximum context length is 4097 tokens. However, your messages resulted in 4108 tokens. Please reduce the length of the messages.
Is this because openai is always sending back all the previous messages? This seems quite limiting, as I can't continue to have a conversation forever, as I will end up with this error anyways at some point.
from chatblade.
Hi @fritzrehde,
With regards to the 2nd question, that is your choice. If you use sessions then yes it will send everything back to openAI. Thats how the chats work on the website as well. It is the only way the GPT model has a notion of context. The newer model gpt-4 has a larger max context but is also more pricey.
If however you don't care about the context, then don't use the sessions ofc.
The first question I will have a look at, and provide a fix today/tomorrow
from chatblade.
Does the interactive session work differently to using a session throughout multiple chatblade instances? Is there also a "limit" with the session in the interactive mode?
from chatblade.
Also, does chatgpt not store the collection on its server somehow? Intuitively, I would have thought we just have to provide the session and a new prompt, and it has all the previous prompts and answers for that session saved. Is this not the case?
from chatblade.
Actually, this thought just occured to me: Maybe I am getting the openai error because the payload sent to me is too large. I had naively assumed that the payload I was sending to the chatgpt (i.e. all the queries and responses of the specified session) would be sent to the api. If the former is the case, then just fixing that chatblade doesn't send back all previous responses as well might fix this?
from chatblade.
With regards to first question I think -e
actually does what you want
from chatblade.
You're right though, it does fix my issue. I would, however, be curious to understand why it fixes it.
from chatblade.
Actually,
chatblade \
--session "$SESSION_NAME" \
--stream \
--extract \
--raw \
--no-format \
--only \
"$query"
now has a different, maybe related, bug: Now it shows the response stream, but once the stream is done, the first part of the response is no longer visible.
from chatblade.
Related Issues (20)
- Changing model to gpt-4 does not work HOT 4
- Certificate verify failed: self signed certificate in certificate chain HOT 5
- TypeError: __str__ returned non-string (type dict) HOT 2
- Apostrophe's aren't escaped in input HOT 2
- Knowledge cut off September 2021 for GPT4 HOT 2
- feature request: support Creates an image given a prompt
- Add Arch to README.md#install
- API key problems problems (insufficient_quota) HOT 4
- -c 4 indeed does not work HOT 1
- UnicodeEncodeError in NVIM when Running ':! chatblade' Command HOT 1
- looks like -c 4 is not working. HOT 1
- Is clichat a copyleft violation of chatblade? HOT 1
- Azure OpenAI support for preview version fix HOT 1
- Add build instructions using a PEP517 installer HOT 3
- Feature request: Add OPENAI_API_ENDPOINT and --openai-api-endpoint="http://address:port/v1" HOT 2
- Default temperature value
- Support streaming to pipe
- error with version flag
- ChatGPT now insists on providing any formulas as LaTeX.
- Add support for Anthropic API
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from chatblade.