Comments (8)
This line is printed to STDERR, which may also be the file descriptor of curl to get the returned data
Ah, good to know. I think I can separate STDERR from STDOUT in the Curl output to fix this. Let me make sure this doesn't break any other edge case first.
from gptel.
Can you run (setq gptel--debug t)
and then try? This should open up a buffer with the response that we can examine.
from gptel.
After eval (setq gptel--debug t)
by C-x C-e
in scratch buffer, I see the following with the test above:
[proxychains] DLL init: proxychains-ng 4.16-git-14-g42d2d95
HTTP/2 200
date: Sat, 20 May 2023 01:19:13 GMT
content-type: text/event-stream
access-control-allow-origin: *
cache-control: no-cache, must-revalidate
openai-model: gpt-3.5-turbo-0301
openai-organization: user-cycirv7tg3umtkc0ijlplsz5
openai-processing-ms: 338
openai-version: 2020-10-01
strict-transport-security: max-age=15724800; includeSubDomains
x-ratelimit-limit-requests: 3
x-ratelimit-limit-tokens: 40000
x-ratelimit-remaining-requests: 2
x-ratelimit-remaining-tokens: 39952
x-ratelimit-reset-requests: 20s
x-ratelimit-reset-tokens: 72ms
x-request-id: e0f1074224be0836107634c744c7191a
cf-cache-status: DYNAMIC
server: cloudflare
cf-ray: 7ca0c0078f88108e-HKG
alt-svc: h3=":443"; ma=86400, h3-29=":443"; ma=86400
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"role":"assistant"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"Hello"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"!"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" \n\n"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"It"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" looks"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" like"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" you"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"'re"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" setting"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" the"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" `"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"g"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"pt"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"el"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"--"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"debug"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"`"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" variable"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" to"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" `"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"t"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"`."},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" This"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" might"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" enable"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" debug"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" output"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" for"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" some"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" package"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" or"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" code"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" that"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" you"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"'re"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" working"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":" with"},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{"content":"."},"index":0,"finish_reason":null}]}
data: {"id":"chatcmpl-7I5XVnlHGQY1TT3CYDVU0HrWoYpuP","object":"chat.completion.chunk","created":1684545553,"model":"gpt-3.5-turbo-0301","choices":[{"delta":{},"index":0,"finish_reason":"stop"}]}
data: [DONE]
(7065e6b16c203dc9a71131adce8ab501 . 743)
from gptel.
I see the problem -- it's the first line about proxychains. Could you explain your proxy setup?
I'm not sure why Curl is producing that first line.
from gptel.
I see the problem -- it's the first line about proxychains. Could you explain your proxy setup?
It's a line generated by the proxychains-ng
wrapper, as the issue here indicated. This problem occurred after I updated proxychains-ng
to its latest git master version. The culprit information is defined here.
I use Emacs with the proxychains-ng
, so the issue appears here, but I don't know how to disable this information.
I'm not sure why Curl is producing that first line.
This line is printed to STDERR, which may also be the file descriptor of curl to get the returned data.
from gptel.
It looks like using a separate STDERR buffer will make Emacs create two processes per invocation of Curl, which I'd like to avoid. Ideally this problem can be fixed by proxychains-ng.
from gptel.
The author of proxychain-ng
has not replied yet, but the simplest solution is to comment out this line and recompile it, which will solve the problem:
from gptel.
Have a similar problem:
HTTP/2 200
date: Fri, 14 Jul 2023 10:33:08 GMT
content-type: text/event-stream
access-control-allow-origin: *
cache-control: no-cache, must-revalidate
openai-processing-ms: 186
openai-version: 2020-10-01
strict-transport-security: max-age=15724800; includeSubDomains
x-ratelimit-limit-requests: 3500
x-ratelimit-limit-tokens: 90000
x-ratelimit-remaining-requests: 3499
x-ratelimit-remaining-tokens: 89958
x-ratelimit-reset-requests: 17ms
x-ratelimit-reset-tokens: 28ms
x-request-id: 8f37fcfcbf110572648f215a54cd0dfb
cf-cache-status: DYNAMIC
server: cloudflare
cf-ray: 7e691b123ae5d6be-CDG
alt-svc: h3=":443"; ma=86400
data: {"id":"chatcmpl-7cAOi13xRPzImdBuQMExTnEvXUjyx","object":"chat.completion.chunk","created":1689330788,"model":"gpt-3.5-turbo-0613","choices":[{"index":0,"delta":{"role":"assistant","content":""},"finish_reason":null}]}
data: {"id":"chatcmpl-7cAOi13xRPzImdBuQMExTnEvXUjyx","object":"chat.completion.chunk","created":1689330788,"model":"gpt-3.5-turbo-0613","choices":[{"index":0,"delta":{"content":"Hello"},"finish_reason":null}]}
data: {"id":"chatcmpl-7cAOi13xRPzImdBuQMExTnEvXUjyx","object":"chat.completion.chunk","created":1689330788,"model":"gpt-3.5-turbo-0613","choices":[{"index":0,"delta":{"content":"!"},"finish_reason":null}]}
data: {"id":"chatcmpl-7cAOi13xRPzImdBuQMExTnEvXUjyx","object":"chat.completion.chunk","created":1689330788,"model":"gpt-3.5-turbo-0613","choices":[{"index":0,"delta":{"content":" How"},"finish_reason":null}]}
data: {"id":"chatcmpl-7cAOi13xRPzImdBuQMExTnEvXUjyx","object":"chat.completion.chunk","created":1689330788,"model":"gpt-3.5-turbo-0613","choices":[{"index":0,"delta":{"content":" can"},"finish_reason":null}]}
data: {"id":"chatcmpl-7cAOi13xRPzImdBuQMExTnEvXUjyx","object":"chat.completion.chunk","created":1689330788,"model":"gpt-3.5-turbo-0613","choices":[{"index":0,"delta":{"content":" I"},"finish_reason":null}]}
data: {"id":"chatcmpl-7cAOi13xRPzImdBuQMExTnEvXUjyx","object":"chat.completion.chunk","created":1689330788,"model":"gpt-3.5-turbo-0613","choices":[{"index":0,"delta":{"content":" assist"},"finish_reason":null}]}
data: {"id":"chatcmpl-7cAOi13xRPzImdBuQMExTnEvXUjyx","object":"chat.completion.chunk","created":1689330788,"model":"gpt-3.5-turbo-0613","choices":[{"index":0,"delta":{"content":" you"},"finish_reason":null}]}
data: {"id":"chatcmpl-7cAOi13xRPzImdBuQMExTnEvXUjyx","object":"chat.completion.chunk","created":1689330788,"model":"gpt-3.5-turbo-0613","choices":[{"index":0,"delta":{"content":" today"},"finish_reason":null}]}
data: {"id":"chatcmpl-7cAOi13xRPzImdBuQMExTnEvXUjyx","object":"chat.completion.chunk","created":1689330788,"model":"gpt-3.5-turbo-0613","choices":[{"index":0,"delta":{"content":"?"},"finish_reason":null}]}
data: {"id":"chatcmpl-7cAOi13xRPzImdBuQMExTnEvXUjyx","object":"chat.completion.chunk","created":1689330788,"model":"gpt-3.5-turbo-0613","choices":[{"index":0,"delta":{},"finish_reason":"stop"}]}
data: [DONE]
(4cd44fc400ed1e411711ea2a71648be2 . 692)
I'm on Aquamacs 3.6 GNU Emacs 25.3.50.1 (x86_64-apple-darwin20.6.0, NS appkit-2022.60 Version 11.6 (Build 20G165))
I had to add text-property-search.el
from a newer Emacs and also add the new string-trim*
functions that support an optional regex argument.
Have no idea how to fix the JSON error though.
from gptel.
Related Issues (20)
- gptel-org-branching-context requires Org 9.7 (unreleased) HOT 6
- Watermarking / inline annotation of LLM generated content vs prompt content HOT 2
- Org mode response formatting HOT 8
- Ollama as default backend HOT 1
- Perplexity: citations HOT 14
- Different results between gptel+ChatGPT and chat.openai.com HOT 2
- Auto Fill mode should be respected HOT 4
- Wrong language in the source block header HOT 4
- Help using local backends HOT 2
- Interacting with privateGPT (specifically for RAG) HOT 10
- Is it possible to interact with LLMs provided by an Open WebUI? HOT 1
- Error with the local LLM scripts in init file HOT 5
- How to disable the highlight after its done generating HOT 9
- How to register additional backends in doom emacs? HOT 5
- Enhance `gptel` to allow selecting from list of existing gptel buffers, when called interactively HOT 1
- [enhancement] Provide information about the different models HOT 1
- Updating `DoomEmacs`/`gptel` and chaing lightly configuration => only garbage generated now... HOT 8
- (gptel-menu) Truncated width of system message is wrong
- Better prefix-arg behavior for M-x gptel
- gptel-request wrong type argument HOT 7
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 gptel.