kyegomez / tree-of-thoughts

Plug in and Play Implementation of Tree of Thoughts: Deliberate Problem Solving with Large Language Models that Elevates Model Reasoning by atleast 70%
https://discord.gg/qUtxnK2NMf
Apache License 2.0
4.16k stars 350 forks source link

module abstractLanguageModel not found #79

Closed aibarito-ua closed 7 months ago

aibarito-ua commented 11 months ago

Hello! I am getting ModuleNotFoundError when trying to run example.py. Do you know how can I solve it? Error: Traceback (most recent call last): File "tree_of_thoughts/example.py", line 2, in from tree_of_thoughts.models.openai_models import OpenAILanguageModel File "/app/tree-of-thoughts/tree_of_thoughts/init.py", line 2, in from tree_of_thoughts.treeofthoughts import TreeofThoughts, MonteCarloTreeofThoughts, TreeofThoughtsBFS, TreeofThoughtsDFS, TreeofThoughtsBEST, TreeofThoughtsASearch File "/app/tree-of-thoughts/tree_of_thoughts/treeofthoughts.py", line 16, in from abstractLanguageModel import AbstractLanguageModel ModuleNotFoundError: No module named 'abstractLanguageModel'

Upvote & Fund

Fund with Polar

kyegomez commented 11 months ago

@aibarito-ua yes try importing like this,

treeofthoughts.models.abstract_language_model

Ecocytus commented 11 months ago

Line from abstractLanguageModel import AbstractLanguageModel should be changed to from .models.abstract_language_model import AbstractLanguageModel

thiswillbeyourgithub commented 7 months ago

It seems this was not pushed to PyPI.

It would be nice to add to the README that we can install the latest github version using pip via python -m pip install git+https://github.com/kyegomez/tree-of-thoughts

kyegomez commented 7 months ago

@thiswillbeyourgithub please excuse me for this error, I have pushed the updates!