-
Notifications
You must be signed in to change notification settings - Fork 254
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using GPTeam with gpt4all or llama-cpp-python openai-compatible API endpoint #63
Comments
This is the patch I used to point GPTeam at GPT4all. Note that you also have to enable the openai endpoint specifically in GPT4all, in the Settings->Application->Enable Web Server. |
I tried to apply the patch but no cigar... |
I see the requests in the server window of gpt4all, but it never generates a response. I suspect we might be exceeding the context window of the models it has. There is also the problem with the smaller models not responding in JSON, apparently: #75 (comment) So this might be a long road. I think the prompt might need to be trimmed, and possibly also not ask the model to respond in JSON, but in some kind of well-formed dialog format? That, or we need to wait for bigger version of MPT (since it has large context windows, but is currently only available as a 7B model that probably also can't do JSON well enough). P.S. I also tried using llama-cpp-python, but it died because gpt4all sends "null" as a |
Hi!
I got GPTeam to connect to the GPT4all local chat server mode by hacking the openai.api_base url to point at the localhost API endpoint provided by GPT4all, as per https://docs.gpt4all.io/gpt4all_chat.html#gpt4all-chat-server-mode
I also had to hack all of the constructors of ChatModel() in src/agent/base.py to specify a large request_timeout value (otherwise the local model kept hitting request timeouts).
This seems to be almost working. In the GPT4all server window, I can see the requests coming in, but the agents are not generating responses or making progress. (I tried both the MPT-7b-Chat and MPT-7b-Instruct models).
I think getting this working would be a very fun use case of this tool, as it does not require OpenAI in the loop. I would be quite satisfied even if this means it takes quite a while to wait for the scenario to run.
Is this some limitation of the API exposed by GPT4all? I can provide a branch with my hacks, if that helps make progress. The GPT4all project is quite active; if we can point out why their API is incomplete, they will probably patch it for us.
The text was updated successfully, but these errors were encountered: