Skip to main content

Terminal Assistant

Project description

# Terma Short for Terminal Asistant, Terma is An NLP based CLI application that takes in input from the user in plain language, converts that into an appropriate bash command and finally displays this generated command along with follow up actions that the user can take.

# Setup ## Pre-requisite In this primitive version of terma, the queries typed out are sent directly to an [OpenAI](https://openai.com/) model. In order to use the openaI models you would have to [Sign up](https://platform.openai.com/signup) and get a token.

Once you have obtained a token, you can either set it as an environment variable before you start as shown below. ` export OPENAI_TOKEN=<your_token_here> ` The other option you have is to create a .terma file in your home directory and then just add the token there. This approach has the added advantage that you don’t have to remember to set the environment variable every time you want to use terma.

# Usage After installing terma it can be used just by specifying the command terma in the envrionment in which the package was installed. This starts an interactive CLI session. In the session you can type in the query you have in plain english and the application would generate a CLI query based on that.

![terma example](https://media.giphy.com/media/v1.Y2lkPTc5MGI3NjExMzhiNDYxODRkMDAzNTFiNjFjZWUxMGNiM2UxNDc0NzlkODMwNjNmMCZjdD1n/fLIHvZfthjK3GYSxJx/giphy.gif)

As seen in the above image, along with the generated comand terma also gives you choices on what to do with it. You can execute it in the session directly, copy it to the clipboard (for running in another terminal tab or sharing somewhere else) or you can just choose to continue with the conversation.

To exit press ctrl-D or just type exit() or quit().

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

terma-1.0.1.tar.gz (5.8 kB view details)

Uploaded Source

File details

Details for the file terma-1.0.1.tar.gz.

File metadata

  • Download URL: terma-1.0.1.tar.gz
  • Upload date:
  • Size: 5.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.16

File hashes

Hashes for terma-1.0.1.tar.gz
Algorithm Hash digest
SHA256 23087d59eb5533047b24d0d265ce4d34807f5328d836dc831f148832ce60fdd9
MD5 48e7e196081e6b9d29fc6a92f9a7e78b
BLAKE2b-256 befc1486c41c8f2bf5e291290c5488b35a3ad3b987de42aad779700d9b787bcd

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page