AskAI - CLI Assistant

Tech Stack: Go · MySQL

Built a CLI assistant using local LLMs (Gemma 2B via Ollama) to convert natural language into secure Bash commands. The tool enables safe shell command generation for developers who prefer describing tasks in plain English.

Developed a Go-based interface to interact with the LLM and implemented safety features such as command validation, [y/N] execution confirmation, and support for flags like --help, --dry-run, and --history.

Used Go routines to provide a smooth user experience with non-blocking input/output and loading animations while the AI processes the prompt.

Command history is logged to a MySQL database using Go’s database/sql package and the official Go MySQL driver, enabling persistent session tracking and analytics.

Demo:

🔗 View GitHub Repo