Skip to content

Conversation

stanfea
Copy link

@stanfea stanfea commented Nov 2, 2023

MultiLLM.model_registry was empty in the process scope need to share it with the worker processes

Fixes:

multiprocessing.pool.RemoteTraceback: 
"""
Traceback (most recent call last):
  File "/opt/homebrew/Cellar/[email protected]/3.11.6/Frameworks/Python.framework/Versions/3.11/lib/python3.11/multiprocessing/pool.py", line 125, in worker
    result = (True, func(*args, **kwds))
                    ^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/[email protected]/3.11.6/Frameworks/Python.framework/Versions/3.11/lib/python3.11/multiprocessing/pool.py", line 51, in starmapstar
    return list(itertools.starmap(args[0], args[1]))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/stan/Library/Caches/pypoetry/virtualenvs/freedo-pitch-bot-server-_WifoDOq-py3.11/lib/python3.11/site-packages/multillm/MultiLLM.py", line 45, in task
    model = MultiLLM.model_registry[model_name]
            ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^
KeyError: 'BARD'
"""

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 this pull request may close these issues.

1 participant