Alpaca-Turbo icon indicating copy to clipboard operation
Alpaca-Turbo copied to clipboard

Not able to locate model

Open nikunjgoel95 opened this issue 2 years ago • 4 comments

Error Saving Settings
Can't locate the model @ /Users/nikunj.goel/dalai/alpaca/models/7B/ggml-model-q4_0.bin
Set the model path in settings
Running on local URL:  http://127.0.0.1:7860

To create a public link, set `share=True` in `launch()`.
starting with ['bin/mac', '--seed', '888777', '-t', '4', '--top_k', '40', '--top_p', '0.9', '--repeat_last_n', '64', '--repeat_penalty', '1.3', '-m', '/Users/nikunj.goel/dalai/alpaca/models/7B/', '--interactive-start']
Traceback (most recent call last):
  File "/Users/nikunj.goel/anaconda3/lib/python3.8/site-packages/gradio/routes.py", line 393, in run_predict
    output = await app.get_blocks().process_api(
  File "/Users/nikunj.goel/anaconda3/lib/python3.8/site-packages/gradio/blocks.py", line 1069, in process_api
    result = await self.call_function(
  File "/Users/nikunj.goel/anaconda3/lib/python3.8/site-packages/gradio/blocks.py", line 892, in call_function
    prediction = await anyio.to_thread.run_sync(
  File "/Users/nikunj.goel/anaconda3/lib/python3.8/site-packages/anyio/to_thread.py", line 31, in run_sync
    return await get_asynclib().run_sync_in_worker_thread(
  File "/Users/nikunj.goel/anaconda3/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 937, in run_sync_in_worker_thread
    return await future
  File "/Users/nikunj.goel/anaconda3/lib/python3.8/site-packages/anyio/_backends/_asyncio.py", line 867, in run
    result = context.run(func, *args)
  File "/Users/nikunj.goel/anaconda3/lib/python3.8/site-packages/gradio/utils.py", line 549, in async_iteration
    return next(iterator)
  File "webui.py", line 52, in bot
    for out in resp:
  File "/Users/nikunj.goel/Alpaca-Turbo/alpaca_turbo.py", line 213, in ask_bot
    _ = self.prep_model() if not self.is_ready else None
  File "/Users/nikunj.goel/Alpaca-Turbo/alpaca_turbo.py", line 202, in prep_model
    self.program = process(self.command, timeout=600)
  File "/Users/nikunj.goel/Alpaca-Turbo/interact.py", line 26, in __init__
    super().__init__(
  File "/Users/nikunj.goel/anaconda3/lib/python3.8/site-packages/pexpect/popen_spawn.py", line 53, in __init__
    self.proc = subprocess.Popen(cmd, **kwargs)
  File "/Users/nikunj.goel/anaconda3/lib/python3.8/subprocess.py", line 858, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/Users/nikunj.goel/anaconda3/lib/python3.8/subprocess.py", line 1704, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
OSError: [Errno 86] Bad CPU type in executable: 'bin/mac'

I can confirm that model is at that location.

nikunjgoel95 avatar Mar 22 '23 22:03 nikunjgoel95

hey you will need to manually compile for your system it's a easy fix

follow the instructions to build for your system https://github.com/viperx7/alpaca.cpp and then move the file alpaca.cpp/main => Alpaca-Turbo/bin/main

ViperX7 avatar Mar 23 '23 12:03 ViperX7

I will add Instructions to the README

ViperX7 avatar Mar 23 '23 12:03 ViperX7

image

Can't find main! but after following this https://github.com/viperx7/alpaca.cpp I could run ./chat

nikunjgoel95 avatar Mar 23 '23 16:03 nikunjgoel95

in your first error message In the first line it says error saving settings it does that only when the path to the models is incorrect

ViperX7 avatar Mar 24 '23 15:03 ViperX7