lexido

command module
v1.3.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 6, 2024 License: AGPL-3.0 Imports: 18 Imported by: 0

README

lexidoLogo

Badge Build Badge Version Badge License Badge Language

Introduction

Lexido is an innovative assistant for the Linux command line, designed to boost your productivity and efficiency. Powered by Gemini Pro 1.0 and utilizing the free API, Lexido offers smart suggestions for commands based on your prompts and importantly your current environment. Whether you're installing software, managing files, or configuring system settings, Lexido streamlines the process, making it faster and more intuitive.

Examples

First GIF Second GIF

Features

  • Command Suggestions: Simply type lexido [prompt] to get actionable command suggestions.
  • Cross-Platform: Support for both Linux and macOS
  • Continued Conversations: Use lexido -c [prompt] to continue a previous conversation, allowing for context-aware suggestions.
  • Piping Support: Pipe commands into Lexido (e.g., ls | lexido [prompt]) for enhanced command list suggestions.
  • Efficiency: Designed with efficiency in mind, Lexido helps you get things done NOW.

Installation

For Arch Linux:

Lexido is available on the AUR. Install it using the package manager of your choice such as:

yay -S lexido

For others and macOS:

Head to the releases tab to pick up a binary! Once downloaded, you'll want to make Lexido easily accessible from anywhere on your computer. Here's how:

  1. Rename the downloaded file:

    The downloaded file might have a long and specific name, like "v1.0-lexido-linux-amd64". For easier use, consider renaming it to just "lexido".

  2. Make the file executable:

    Open your terminal and navigate to the folder where you downloaded the Lexido binary. Then, run the following command to make the file executable:

    chmod +x ./lexido
    
  3. Move the file to your system's path:

    Why do this? By placing the renamed and executable Lexido file in your system's path, you can run it from any terminal window without needing to specify the full path to the file. It's a shortcut for convenience!

    Here's an example command assuming you downloaded Lexido to your Downloads folder:

    mv ~/Downloads/lexido /usr/local/bin/lexido
    

Compile from source

Ensure you have Go installed on your system. Follow these steps to install Lexido:

  1. Clone the Lexido repository:
git clone https://github.com/micr0-dev/lexido.git
  1. Navigate to the Lexido directory:
cd lexido
  1. Build the project:
go build
  1. Optionally, move the Lexido binary to a location in your PATH for easy access.

Running locally

If you want to run lexido completely locally you can do that as of version 1.3! This is done via Ollama, a tool for easily running large language models locally. It does all the hard work of installing LLMs for you!

You can install Ollama as follows:

Linux:

curl -fsSL https://ollama.com/install.sh | sh

macOS:

Download

After you have installed Ollama

Running lexido locally is as easy as adding the -l flag when you want to run locally, or using --setLocal to run locally by default! You can also select the model you want to run with -m and again set it to be the default with --setModel. Be sure you have the model installed before attempting to run it with lexido however!

Usage

  • To get command suggestions:
lexido "install teamspeak via docker"
  • To continue with a previous prompt:
lexido -c "add more details or follow-up"
  • To use with piping commands:
ls | lexido "what should I do with these files?"

FAQ

Why is the binary so big?

The binary's size mainly consists of the built-in networking and encryption libraries of Go. A quick inspection showcases this:

> goweight
   12 MB runtime
  8.1 MB net/http
  5.3 MB google.golang.org/protobuf/internal/impl
  4.1 MB net
  4.1 MB golang.org/x/net/http2
  3.9 MB golang.org/x/sys/unix
  3.7 MB crypto/tls
  3.3 MB google.golang.org/grpc

How does it know what system I am running?

Before requesting the LLM the program does what is known as prompt building or contextualization, it collects different data about your system and your current scenario to help the LLM more accurately answer. Giving the LLM context about your situation allows it to better understand what you are asking or how to reply.

If you have any more questions feel free to reach out and ask

Contributing

Contributions are what make the open-source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

License

Distributed under the GNU Affero General Public License v3.0. See LICENSE for more information.

Acknowledgements

Made with 💚 by Micr0byte

Stargazers over time

Stargazers over time

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
pkg
io
tea

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL