SnapShell is a powerful command-line utility designed to enhance your Linux terminal experience by auto-completing commands using a Language Learning Model (LLM). SnapShell intelligently suggests commands based on your input, maintains a history of suggested commands, and allows you to manage your command history with ease.
pip
package managerInstall SnapShell with the following command:
pip install snapshell
SnapShell requires your Groq Api key during installation. Follow the on-screen instructions after installation
The installation will automatically store the key in ~/.snapshell_config.json
file.
OR
git clone https://github.com/KTS-o7/snapshell.git cd snapshell python -m venv env source env/bin/activate pip install -r requirements.txt python setup.py install
SnapShell requires the following libraries:
argparse
: For parsing command-line arguments.sqlite3
: For local database operations.os
: To interact with your operating system.To use SnapShell, you need to provide GROQ_API_KEY
when prompted for the first time.
For any changes in the key you can edit ~/.snapshell_config.json
file and add the appropriate key.
Run SnapShell in your terminal using:
snapshell
SnapShell supports the following arguments:
--update-db
: Updates the database with currently installed packages.--view-history
: Displays the command suggestion history.--clear-history
: Clears all entries from the command history.Example usage:
snapshell --update-db snapshell --view-history snapshell --clear-history
SnapShell is intuitive and primitive to use. It suggests commands based on your input and maintains a history of suggestions. You can view or clear the command history at any time.
SnapShell leverages a Language Learning Model to suggest relevant Linux commands based on user input. It keeps a local history of suggestions that can be reviewed or cleared at your discretion. Upon installation, SnapShell can update its internal database with packages installed on your system, ensuring up-to-date suggestions.
view_history()
: Fetch and display the command history from the local database.clear_history()
: Clear the command history in the local database.main()
: The primary function that handles user input, command-line arguments, and interaction.SnapShell does not directly expose API endpoints, but it interacts with the GROQ API under the hood. Here’s a brief overview:
We welcome contributions! If you'd like to contribute, please follow these steps:
git checkout -b feature/new-feature
We currently need help to integrate SnapShell with more shells and support more platforms like windows.
pip install --upgrade pip
cat ~/.snapshell_config.json
sudo
or ensure you have the necessary file permissions.rm ~/.snapshell/system_info.db
If you encounter other issues, feel free to open an issue in the GitHub repository or contact us.
SnapShell is licensed under the MIT License. For more details, see the LICENSE file.
For any questions, issues, or feature requests, please reach out to:
Krishnatejaswi S
shentharkrishnatejaswi@gmail.com
There are no datasets linked
There are no datasets linked