Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/promptops/cli

um is a GPT-powered CLI assistant. Ask questions in plain English, get the perfect shell command.
https://github.com/promptops/cli

cli devops generative-ai shell terminal

Last synced: 2 months ago
JSON representation

um is a GPT-powered CLI assistant. Ask questions in plain English, get the perfect shell command.

Awesome Lists containing this project

README

        

`um` is a GPT-powered CLI assistant. Ask questions in plain English, get the perfect shell command.

# Features

- find the right command without leaving the terminal
- `um` can index your history to find commands you've run before
- `um` instantly learns from your corrections
- simple interface to clarify your question or provide more context
- NEW in 0.1.6: `um recipe` helps you provision infrastructure (currently terraform only, more coming soon)
- NEW in 0.1.7: extended reverse search functionality with fuzzy matching and semantic search
- NEW in 0.1.10: parameterless `um`: suggests next actions based on usage patterns

# Installation

## Linux - Ubuntu
```shell
curl -fsSL -o ubuntu-installer.sh https://raw.githubusercontent.com/promptops/cli/main/ubuntu-installer.sh
chmod 700 ubuntu-installer.sh
./ubuntu-installer.sh
```

## MacOS - Homebrew

```shell
brew install promptops/promptops/promptops-cli
```

## pip

Make sure you have python 3.10 or more recent
[python.org downloads](https://www.python.org/downloads/)

```shell
pip3 install promptops
```

# Configuration

```shell
eval "$(um --install)"
```

## (Optional) Enable extended reverse search (Ctrl+E)

Note: currently works only with Zsh

Add the widget and the key binding to your `.zshrc` file
```shell
cp ~/.zshrc ~/.zshrc.backup
echo 'eval "$(promptops lookup --config)"' >> ~/.zshrc
```

Reload
```shell
source ~/.zshrc
```

## Disable extended reverse search

Remove the eval line from your `.zshrc` file and reload.

# Usage

## um

Suggest next actions based on usage patterns
```shell
um
```

Query for command
```shell
um
```

Create or reuse templates to provision infrastructure (currently terraform only, more coming soon)
```shell
um recipe
```

Add file or website to the index
```shell
um index --source
```

## local runner

```shell
promptops runner
```

# Examples

```shell
um list contents of tar file
um upload file to s3
```

## Screenshots

Semantic search in history

Provide more context flow

Index website

# Development setup

create virtual env

```shell
python3.10 -m venv ./venv
. ./venv/bin/activate
```

install dependencies

```shell
pip install -r requirements.txt
```

install the cli

```shell
make install
```

test with

```shell
um get pods
```

## Publishing pip release

```shell
make publish
```