Title: Page 24 – Alex Kirk

---

 * October 21, 2023
 * Reblog via [Walter Ebert](https://social.walterebert.com/@walterebert/111273332360946091)
 * ActivityPub at WordCamp Germany with [@pfefferle](https://mastodon.social/@pfefferle)
   and [@alex](https://alex.kirk.at/author/alex/)
 * [#WCDE](https://social.walterebert.com/tags/WCDE) [#activitypub](https://social.walterebert.com/tags/activitypub)
 * ![](https://social.walterebert.com/system/media_attachments/files/111/273/318/
   828/044/342/original/c0a43e2940ac92e3.jpg)
 * [Web](https://alex.kirk.at/category/web/)
 * 
   ## 󠀁[chat-cli: renamed and added Ollama support](https://alex.kirk.at/2023/10/20/chat-cli-renamed-and-added-ollama-support/)󠁿
   
 * October 20, 2023
 * I have added support for [Ollama](https://github.com/jmorganca/ollama) to my 
   [chat-cli tool](https://github.com/akirk/chat-cli) (formerly named cli-chatgpt,
   see [previous posts](https://alex.kirk.at/2023/09/25/resuming-chatgpt-chats-in-cli/)).
   Ollama is a very easy way to run `llama2` locally; it runs a local HTTP server
   and this will be used.
 * Depending on whether an OpenAI key or Ollama are available, the models will be
   made available and you can see this in `cgt -h`. (Using `cgt` as a command here
   is based on my recommendation of using an alias in your shell.)
 * When you’re offline, OpenAI is deemed unavailable, thus–if it is installed and
   active–Ollama/llama2 will be used automatically. While it currently doesn’t switch
   between models during a conversation (because of your online state), you can 
   simply exit and re-continue the conversation with another model using `cgt -l`.
 * Both models show their responses in a streaming way.
 *     ```wp-block-code
       ❯ cgt where is gerolstein
       Model: gpt-3.5-turbo
       > where is gerolstein
   
       Gerolstein is a town in the Bitburg-Prüm district in Rhineland-Palatinate, Germany. It is located in the Eifel mountain range, approximately 15 kilometers southeast of Bitburg.
       > ^c
   
       ### Went offline here.
       ❯ cgt where is gerolstein
       Model: llama2:latest
       > where is gerolstein
   
        Gerolstein is a town located in the state of Rhineland-Palatinate, Germany. It is situated in the northern part of the state, approximately 20 kilometers (12 miles) northwest of the city of Mainz. The exact address of Gerolstein is:
   
       Gerolstein, Germany
   
       If you are planning to visit Gerolstein or need more detailed information, please let me know and I will be happy to help.
       > 
       ```
   
 * While there is no config available, you can [change the priority of models in the source](https://github.com/akirk/chat-cli/blob/ce91064d4fa3464bab2eaace12c88f41351f2876/chat.php#L28).
 * 
   ###### Fediverse Reactions
   
    -  [ ⌊anonymous⌉ ](https://cagrimmett.com/likes/6bf6795456/)
    -  [ ⌊anonymous⌉ ](https://cagrimmett.com/likes/6bf6795456/)
 * [AI](https://alex.kirk.at/category/ai/), [Explorations](https://alex.kirk.at/category/explorations/)
 * [ChatGPT](https://alex.kirk.at/tag/chatgpt/), [Llama2](https://alex.kirk.at/tag/llama2/),
   [LLMs](https://alex.kirk.at/tag/llms/), [Ollama](https://alex.kirk.at/tag/ollama/)

 [Previous Page](https://alex.kirk.at/page/23/?output_format=md&term_id=44051) [Next Page](https://alex.kirk.at/page/25/?output_format=md&term_id=44051)