Use AI to generate shell input

Good Question!

© Photo by Vadim Bogulov on Unsplash

© Photo by Vadim Bogulov on Unsplash

Article from Issue 280/2024
Author(s):

Shell Genie uses artificial intelligence to convert your questions into commands in the terminal.

Artificial intelligence (AI) has dominated the IT world and the media for months. The tone of the reporting has ranged from "benefactor of mankind" to "threat to humanity." To keep the ball rolling, this article covers the MIT-licensed Shell Genie [1] Python tool, which uses AI to try to make life with the shell easier for users.

The Shell Genie command-line tool answers your questions in the shell with commands that can be executed immediately. You can use two different AI models with Shell Genie: GPT-3.5 or Free Genie. GPT-3.5 by OpenAI is the basis for the current version of ChatGPT. You will need an API key (which costs around $20 and includes ChatGPT) to use it as a back end. As an alternative, you can use Free Genie, a free model maintained by Dylan Castillo, the developer of Shell Genie. Shell Genie can be trained by user input with your permission.

Installation

The easiest way to install Shell Genie is to use pipx, an installer for the Python Package Index that evolved from pip. First you use your distribution's package manager to install the pipx package. Then you can set up Shell Genie with:

[...]

Use Express-Checkout link below to read the full article (PDF).

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy Linux Magazine

SINGLE ISSUES
 
SUBSCRIPTIONS
 
TABLET & SMARTPHONE APPS
Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

  • Systemd GUIs

    Graphical frontends make it easier to take full advantage of the Systemd process manager. We examine some leading tools for the KDE environment.

  • Systemd Graphical Tools

    Systemd has won the race, as indicated by the several tools that already offer a service just a mouse click away. We look at six of these tools.

  • Bash PaLM Shell

    The PaLMShell.bash script lets you connect to the Google Pathways API Large Language Model (PaLM) from the command line.

  • ChatGPT Clients

    Do you think ChatGPT only works in your web browser? You can also access the global chat phenomenon from your desktop – or even from the Linux command line.

  • Welcome

    I feel like we entered a new era earlier this year when Google scientist Blake Lemoine declared that he thought Google's LaMDA artificial intelligence is "sentient," and that the company should probably be asking LaMDA's permission before studying it.

comments powered by Disqus
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters

Support Our Work

Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.

Learn More

News