Skip to content

Commit

Permalink
Merge pull request #78 from codelion/fix-init-py
Browse files Browse the repository at this point in the history
Fix init py
  • Loading branch information
codelion authored Oct 24, 2024
2 parents 65695cc + ba2eebe commit 30e095f
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 2 deletions.
2 changes: 1 addition & 1 deletion optillm.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
from concurrent.futures import ThreadPoolExecutor

# Import the LiteLLM wrapper
from litellm_wrapper import LiteLLMWrapper
from optillm.litellm_wrapper import LiteLLMWrapper

# Import approach modules
from optillm.mcts import chat_with_mcts
Expand Down
13 changes: 13 additions & 0 deletions optillm/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
from importlib import util
import os

# Get the path to the root optillm.py
spec = util.spec_from_file_location(
"optillm.root",
os.path.join(os.path.dirname(os.path.dirname(__file__)), "optillm.py")
)
module = util.module_from_spec(spec)
spec.loader.exec_module(module)

# Export the main function
main = module.main
File renamed without changes.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

setup(
name="optillm",
version="0.0.4",
version="0.0.5",
packages=find_packages(),
py_modules=['optillm'],
install_requires=[
Expand Down

0 comments on commit 30e095f

Please sign in to comment.