mudler / LocalAGI

100% Local AGI with LocalAI
MIT License
384 stars 60 forks source link

Docker Compose run: /dev/snd no such file or directory on MacOs #7

Open warnyul opened 10 months ago

warnyul commented 10 months ago

I tried to run the following command on MacOS:

docker-compose run -i --rm localagi

I returned the following error: [+] Building 0.0s (0/0) docker:desktop-linux [+] Creating 1/0 ✔ Container localagi-api-1 Running 0.0s [+] Building 0.0s (0/0) docker:desktop-linux Error response from daemon: error gathering device information while adding custom device "/dev/snd": no such file or directory

System Information

MacOs Ventura 13.2.1 (22D68) Docker Compose v2.23.0-desktop.1 Docker 24.0.6, build ed223bc

SuperQuoc commented 10 months ago

I have the same issue. Did you find any solution ?

richardtape commented 9 months ago

Yeah I'm running into the same issue. MacOS Ventura 13.6.1 on Docker Desktop 4.25.2

I commented out

#devices:
    # - /dev/snd

in the docker-compose.yml file which helped. But then running

docker-compose run -i --rm localagi \
  --skip-avatar \
  --subtask-context \
  --postprocess \
  --search-results 3 \
  --prompt "prepare a plan for my roadtrip to san francisco"

lead to a different error (which I'm unsure if it's related)

You tried to access openai.ChatCompletion, but this is no longer supported in openai>=1.0.0 - see the README at https://github.com/openai/openai-python for the API.

You can run `openai migrate` to automatically upgrade your codebase to use the 1.0.0 interface.

Alternatively, you can pin your installation to the old version, e.g. `pip install openai==0.28`

A detailed migration guide is available here: https://github.com/openai/openai-python/discussions/742

(I don't think it's related but will comment here as this is how I stumbled into this)

richardtape commented 9 months ago

In line with my message above, changing requirements.txt line 2 to be openai==0.28 fixes that issue and things...sort of work! There's still issues with audio, but with the tweaks above, it works on a mac.