gpt4all integration
ProxyAyush opened this issue · comments
ProxyAyush commented
so I use gpt4all which gets imported as
from langchain.llms import GPT4All
I want to know if I can import from TOT as
from tree_of_thoughts import GPT4ALL
as i use models from GPT4ALL pipeline
williamchai commented
You could rename the package: “from … import ABC as ABC_1”
Eternal Reclaimer commented
Hey @ProxyAyush can you explain deeper?
If you want you can use GPT4ALL by defining an custom abstract language class that adheres to the following guidelines:
class CustomLanguageModel(AbstractLanguageModel):
def __init__(self, model):
self.model = model
def generate_thoughts(self, state, k):
#implement the thought generation logic using self.model
pass
def evaluate_states(self, states):
#implement state evaluation logic using self.model
pass