Skip to content
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

ModuleNotFoundError: No module named 'outlines.text' #440

Open
cerealceec opened this issue Feb 24, 2024 · 3 comments
Open

ModuleNotFoundError: No module named 'outlines.text' #440

cerealceec opened this issue Feb 24, 2024 · 3 comments

Comments

@cerealceec
Copy link

Describe the bug
ModuleNotFoundError when importing client:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/cecil/repos/anarchy/LLM-VM/src/llm_vm/client.py", line 6, in <module>
    from llm_vm.completion.optimize import LocalOptimizer
  File "/Users/cecil/repos/anarchy/LLM-VM/src/llm_vm/completion/optimize.py", line 14, in <module>
    from llm_vm.guided_completion import Completion
  File "/Users/cecil/repos/anarchy/LLM-VM/src/llm_vm/guided_completion.py", line 2, in <module>
    import outlines.text.generate as generate
ModuleNotFoundError: No module named 'outlines.text'

To Reproduce
Steps to reproduce the behavior:

  1. Install LLM-VM
  2. Open python3 in shell
  3. Import client using from llm_vm.client import Client

Expected behavior
Client imports successfully.

Desktop (please complete the following information):

  • OS: macOS Monterey 12.7.1
@ZigTheUltimate
Copy link

I am facing the same issue while running the project for the first time. The linked PR is not the solution.

We need to change line 2 in guided_completions.py from: import outlines.text.generate as generate to import outlines.generate as generate

@cerealceec
Copy link
Author

I am facing the same issue while running the project for the first time. The linked PR is not the solution.

We need to change line 2 in guided_completions.py from: import outlines.text.generate as generate to import outlines.generate as generate

Can I ask why the linked PR is not the solution?

@ZigTheUltimate
Copy link

The PR changes the import statement to import outlines.generate.text. That is not correct. It should be import outlines.generate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants