Open tkellogg opened 6 months ago
It doesn't work. Here is what I attempted for purely local usage:
OPENAI_KEY=
in my .env
filepoetry run llm install llm-sentence-transformers
and poetry run llm install llm-gpt4all
sentence-transformers/all-mpnet-base-v2
wasn't propagating from the settings into the code correctly, so I manually edited core.py
to have emb_model = llm.get_embedding_model("sentence-transformers/all-mpnet-base-v2")
I cracked open the DB and found that while embeddings were placed into it; the cluster
column was all NULL in the toots
table and algorithm_spec
and algorithm
were both NULL in the sessions
table which explains why nothing was rendered.
I found the bug, you use GPT-3.5 to produce a summary and because I don't have an OpenAPI token it fails. So everything works right up until the end. In both cases of using config....name
the inputs weren't propagated into the code. I changed the model selection line in topic_cluster.py
to model = llm.get_model("gpt4all-falcon-q4_0")
and it seems to be summarizing at about a rate between 10 to 60 seconds per cluster.
that seems like you got it all to work, just that the content was too big for the model, right? If so, that's something we can fix, although llm
doesn't surface the context width, which makes it trickier.
You might have been working off an old commit. I fixed some issues (like still referencing OpenAI for summarizing) on saturday or early sunday. Maybe I'm still missing something.
Send a pull request with what you got, I can take care of merging what you've done. Regardless, you've given me a bit of a step-by-step so i don't have to lookup as much ;)
I used the latest git branch for this. I am not sure what a potential PR would include, but there are small things I noticed while poking around like:
config..
workingpoetry install
step and instructions on how to run purely localI am not sure if the context width is a limitation of llm
or the model.
I am not sure if the context width is a limitation of llm or the model.
I view this as a limitation of llm
because all models have a finite context width and llm
should report what that number is, imo. It's "model" interface should have an abstract method to return that info, so that the llm
app can write guard code to work with this limitation.
I am not sure what a potential PR would include
All that would be valuable. Don't worry about cleaning it up. I'll merge the commit as-is, so you get contributor status, and then clean it up for you.
All the code is in place, although you might have to fix it up.
llm
instructions for installing models./settings
page to select the new modelYou probably don't need to use the same
llm
installation as what fossil uses, since all state and models are written to your $HOME dir.Write about it — here, or even send a pull request updating the README