Skip to content

"AttributeError: module 'numpy' has no attribute 'int8'" on fresh brew install #531

Closed
@jcushman

Description

@jcushman

I just did brew install llm on MacOS Sonoma 14.5 on an Intel Mac. llm --help then fails with a stacktrace:

❯ llm --help
Traceback (most recent call last):
  File "/usr/local/bin/llm", line 5, in <module>
    from llm.cli import cli
  File "/usr/local/Cellar/llm/0.14/libexec/lib/python3.12/site-packages/llm/__init__.py", line 16, in <module>
    from .embeddings import Collection
  File "/usr/local/Cellar/llm/0.14/libexec/lib/python3.12/site-packages/llm/embeddings.py", line 7, in <module>
    from sqlite_utils import Database
  File "/usr/local/Cellar/llm/0.14/libexec/lib/python3.12/site-packages/sqlite_utils/__init__.py", line 4, in <module>
    from .db import Database
  File "/usr/local/Cellar/llm/0.14/libexec/lib/python3.12/site-packages/sqlite_utils/db.py", line 211, in <module>
    np.int8: "INTEGER",
    ^^^^^^^
AttributeError: module 'numpy' has no attribute 'int8'

~ via 🐍 v3.12.4 via S

Not sure if related to this numpy bug about removing type aliases, or something about my Intel platform. Let me know if I can share any more info about my setup to debug.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions