ollama-python icon indicating copy to clipboard operation
ollama-python copied to clipboard

custom client seems working not as expected with apple silicon mac

Open zhengxinMLOG opened this issue 1 month ago • 2 comments

I am trying ollama.Client to connect a remote server for chat.

server A: http://192.168.0.123:11434, ollama installed with docker, ollama-python v0.2.0 local machine: m1 max macbook pro, ollama installed with docker, ollama-python v0.2.0

when using default ollama.chat, i can connect in both environment; then i tried to connect to server from local machine using

ollama.Client(host='http://192.168.0.123:11434')

and i received 503 error with '' message when commiting code

_client.chat(model="svjack/qwen1_5_14b:latest",
        messages=[
            {"role": "user", "content": prompt},
        ],
    ).

At first, i thought it might has something todo with nerwork, so i did some test. i tried same script directly on server A, and it runs ok. then i tried ollama webui on local machine, and i changed default url to server A, and it runs ok.(local machine and server A has a different model list, and it changes properly with config change, it proves.) then it occurs to me that maybe it has something with mac develop envs. and i tried the same script on the 3rd machine, it also runs ok.

right now i cant say for sure that the issues has something to do with apple silicon, but it is the best guess i can make.

zhengxinMLOG avatar May 20 '24 07:05 zhengxinMLOG