shell_sage  by AnswerDotAI

CLI tool for terminal context analysis using LLMs

created 8 months ago
355 stars

Top 79.7% on sourcepulse

GitHubView on GitHub
Project Summary

ShellSage provides AI-powered assistance for command-line users, particularly sysadmins, by understanding terminal context and leveraging LLMs like Claude or GPT for shell commands, system administration, Git operations, and more. It enhances productivity by offering real-time, context-aware help directly within the terminal.

How It Works

ShellSage integrates with tmux to read terminal context, enabling it to provide responses based on your current shell state. It supports piping input for direct analysis and can target specific tmux panes for focused assistance. This contextual awareness allows for more relevant and accurate suggestions compared to generic AI assistants.

Quick Start & Requirements

  • Install via pip: pip install shell-sage
  • Prerequisites: ANTHROPIC_API_KEY or OPENAI_API_KEY environment variable.
  • Recommended: tmux with specific configuration for pane ID visibility and enhanced navigation.
  • See: Getting Started

Highlighted Details

  • Supports Claude (default) and OpenAI models, with options for local or alternative LLM providers via base_url.
  • Can log queries and responses to a local SQLite database.
  • Offers advanced use cases for Git, log analysis, Docker management, and database operations.
  • Customizable via ~/.config/shell_sage/shell_sage.conf for default model, history, and logging settings.

Maintenance & Community

  • Built using nbdev.
  • Contribution guidelines available in CONTRIBUTING.md.
  • Issue tracking and feature requests: GitHub Issues

Licensing & Compatibility

  • License: Not explicitly stated in the README.
  • Compatibility: Designed for Linux/macOS environments with tmux.

Limitations & Caveats

The project's license is not specified, which may impact commercial use. While it supports various LLMs, optimal functionality relies on a configured tmux environment.

Health Check
Last commit

1 month ago

Responsiveness

1 week

Pull Requests (30d)
0
Issues (30d)
0
Star History
32 stars in the last 90 days

Explore Similar Projects

Starred by Donny Kang Donny Kang(Author of SWC; Maintainer of Turbopack), Chip Huyen Chip Huyen(Author of AI Engineering, Designing Machine Learning Systems), and
2 more.

claude-squad by smtg-ai

6.0%
4k
Terminal app for managing multiple AI agents
created 4 months ago
updated 1 week ago
Starred by Carol Willing Carol Willing(Core Contributor to CPython, Jupyter), Georgios Konstantopoulos Georgios Konstantopoulos(CTO, General Partner at Paradigm), and
13 more.

llm by simonw

1.3%
9k
CLI tool and Python library for LLM interaction
created 2 years ago
updated 1 month ago
Feedback? Help us improve.