1. Home
  2. Linux
  3. How to interact with chatgpt on the linux desktop

How to interact with ChatGPT on the Linux desktop

OpenAI’s ChatGPT is all the rage right now, but they don’t have a native Linux app that users can use to interact with their large language model. Thankfully, Bavarder exists. It’s a native Linux app that users can use to interact with GPT models 3.5, 4.0, 2, and others from the convenience of the desktop. Here’s how to use it on your system.

How to install Bavarder on Linux

The Bavarder app is available to Linux users via the Arch Linux AUR and the Flathub app store as a Flatpak. In this guide, we’ll go over both installation methods. To start the installation process, open up a terminal window.

You can open up a terminal window on the Linux desktop by pressing Ctrl + Alt + T on the keyboard. Alternatively, search for “Terminal” in the app menu, and launch it that way.

Once the terminal window is open, the installation is ready to begin. Follow the installation instructions down below that correspond to the Linux OS you use.

How to install Bavarder on Arch Linux

The Bavarder application is available in the Arch Linux AUR, so if you’re using Arch Linux, you’ll be able to install the software using the Trizen AUR helper. To start, use the Pacman -S command and install the “git” and “base-devel” packages on your computer.

sudo pacman -S base-devel git

With the two packages installed, use the git clone command to download the latest version of the Trizen AUR helper to your computer. This program will make it easier to set up the Barvarder application on Arch.

git clone https://aur.archlinux.org/trizen.git
cd trizen/

Install the Trizen application on your Arch Linux system with the makepkg command below.

makepkg -sri

With the Trizen app installed, you can build and install the Bavarder application on your computer using the trizen -S command.

trizen -S bavarder

How to install Bavarder on Flatpak

By far the quickest and easiest way to get the Bavarder application working on your computer is by way of the Flathub app store. However, before interacting with the Flathub store, you need to set up the Flatpak runtime. To set up the Flatpak runtime on your system, please follow our setup guide.

After installing the Flatpak runtime, you can use the two commands below to install the Flathub app store and Bavarder.

flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo
flatpak install flathub io.github.Bavarder.Bavarder

Getting an OpenAI API key

Barvarder requires an OpenAI API key to work with the GPT 3.5 and GPT 4 large language models. Thankfully, API keys don’t cost money, so you can generate one for free to use.

Note: although API keys for OpenAI are free, usage quotas are not. You’ll need a paid plan to get unlimited use out of your key in the Barvardar app. For more information, check out the OpenAI pricing page.

To generate a new OpenAI API key, do the following. First, head to the following page. Once you are on the API key page, find “Default organization,” and change it to personal.

After changing things under “Default organization,” find the “Create a new secret key” button, and select it with the mouse. Once you’ve selected this button, you’ll be asked to name the key. This step is optional, however, you should still name it. Enter “Barvarder” in the text box, and then select the “create secret key” button to continue.

With your key created, copy it to a text file, and save it for later.

How to interact with ChatGPT from the Linux desktop

To interact with ChatGPT from the Linux desktop, start by launching Bavarder. You can find it in the application menu on your computer. Once it is open, click on the menu, select providers, and choose “OpenAI GPT 3.5 turbo” or “OpenAI GPT 4” if you have a paid account.

Next, select the “Preferences” option in the menu. After that, scroll down to providers and locate “OpenAI GPT 3.5 turbo” or “OpenAI GPT 4”. Then, select the drop-down arrow next to “OpenAI GPT 3.5 turbo” or “OpenAI GPT 4” to reveal the options available.

Paste your API key into either “OpenAI GPT 3.5 turbo” or “OpenAI GPT 4” and click the checkmark button. Then, close the preferences window, and find the “Message” box.

Inside the message box, enter a query, and press the send button to get a response. Please keep in mind, the GPT large language model is useful, but often gets facts wrong. It can also get confused. It’s best to use it as a utility to do research or to ask questions, while heavily fact-checking its responses.