UNPKG

scai

Version:

> AI-powered CLI tools for smart commit messages, auto generated comments, and readme files — all powered by local models.

134 lines (88 loc) 3.35 kB
# ⚙️ scai — Smart Commit AI ✨ > AI-powered CLI tools for smart commit messages, auto generated comments, and readme files all powered by local models. **scai** (Smart Commit AI) is a lightweight, privacy-focused CLI tool that uses local AI models (via [Ollama](https://ollama.com)) to help developers work faster and cleaner: - 🤖 Suggest high-quality Git commit messages - Comments your code automatically - 🧠 Get a summary of any code file directly to the terminal - 🔒 100% local no API keys, no cloud, no telemetry --- ## 🚀 Features - ⚡️ Powered by open local Ollama models like `mistral` and new `commentModule` - 🛠️ CLI built with Node.js + TypeScript - 🔒 No external services, full privacy by design - Now supports global options for model and language settings ### 📦 Recent Additions * **Summary Command**: Print a summary of the given file to the terminal (e.g., `scai summ <file>`) --- ## ❤️ Philosophy: Why Local AI? We believe your code and your workflow should stay **yours**. scai runs entirely on your machine using open-source models and tools. No internet connection. No vendor lock-in. Just local, private, AI-enhanced developer experience. Works entirely offline No API keys, cloud accounts, or telemetry Backed by open-source models Designed for CLI-first devs and scriptable workflows **scai** follows the Unix philosophy small, composable tools with powerful output. --- ## 📦 Installation 1. **Install [Ollama](https://ollama.com)** - On **Windows**: [Download Ollama](https://ollama.com/download) - On **macOS**: - Install via Homebrew: ```bash brew install ollama ``` - Or download directly from the [Ollama website](https://ollama.com/download) - Ensure it’s added to your system `PATH` 2. **Install scai globally via npm:** ```bash npm install -g scai ``` 3. **Run the initialization step to start Ollama and install models:** ```bash scai init ``` This will: - Launch the Ollama background server (if not running) - Pull the required models (`llama3`, `mistral`) if they aren’t present --- ## 🧪 Usage Examples ### 💬 Suggest a commit message ```bash # Stage your changes git add . # Let scai suggest a commit message scai sugg ``` > Example output: ``` feat(api): add error handling to user service ``` To automatically commit with the suggested message: ```bash scai sugg --commit ``` --- ### 🛠 Comment a code file ```bash scai comment <file> ``` Write comments for the given file. Optional flags: - `-a, --apply` - Apply the refactored version to the original file --- ### 🔍 Code summary ```bash scai summ <file> ``` Create a quick summary of the file your working on to gain fast insights. --- ## 🔐 License & Fair Use **scai is free to use** for individuals, teams, and companies including in commercial work. You may: - Use it internally in your projects - Use it at work or in commercial software development - Share and recommend it to colleagues However: - You may not **resell**, repackage, or redistribute **scai** as a commercial product or SaaS offering - You may not claim ownership or original authorship For full terms, see the [LICENSE](./LICENSE) file. ---