ollama / ollama-python

Ollama Python library
https://ollama.com
MIT License
4.04k stars 339 forks source link

Command Line Interface #183

Closed p-vdp closed 1 month ago

p-vdp commented 3 months ago

I'm running ollama on a remote server and would like to interact with it from another machine via CLI and the REST API.

This should be pretty straightforward to do with a custom Client object in __main__.py. Usage from a terminal would be something like this:

python -m ollama --endpoint http://remotehost:11434 --model llama3 --message "Why is the sky blue?"

I'm interested in implementing this. Do folks have a preference for CLI parameter handling? I prefer absl.

synacktraa commented 2 months ago

I prefer Cyclopts

mxyng commented 1 month ago

As mentioned in #185, a CLI is be out of scope of this repo. You are however free to implement your a CLI in your own repo