DEV Community

Cover image for Helpline: Local AI That Turns Plain English into Cross-Platform Shell Commands
Adarsh Sriuma
Adarsh Sriuma

Posted on

Helpline: Local AI That Turns Plain English into Cross-Platform Shell Commands

Hacktoberfest Open-Source AI Challenge Week 2: Side Hustle Submission 💸

This is a submission for the Hacktoberfest Open-Source AI Challenge Week 2: Side Hustle

What I Built

helpline turns a plain-English request into a shell command tailored to your operating system. Ask it to find files, search their contents, or inspect directories without having to remember the exact command or platform-specific flags.

It is for freelancers, small-business operators, and other people who work with files but do not want to keep a shell-command cheat sheet handy. A local IT helper or technically inclined small-business owner could also use it to make routine support tasks easier to explain and repeat.

For example, helpline list all files in my home dir generates and runs the corresponding command. Use --print to inspect the command without running it, or --json to get structured output.

Demo

helpline is a command-line tool, so there is no hosted demo. Try it on macOS, Linux, or Windows with Python 3.10+ and Ollama installed:

python3 -m pip install -e .
ollama pull qwen2.5-coder:3b
helpline --print find files containing foobar
Enter fullscreen mode Exit fullscreen mode

The first command installs helpline from the cloned repository; Ollama must be running locally. The model download requires an internet connection, but after it is downloaded, inference can run locally without one.

Code

github.com/tsadarsh/helpline

How I Built It

helpline is a Python CLI. It detects the operating system and shell, builds a prompt with platform-specific rules and examples, and sends the request to Ollama's local chat API. The model returns JSON containing a command and optional notes. By default, helpline runs the command; --print and --json let you inspect the result instead.

The default is the open-weight qwen2.5-coder:3b model. You can choose another Ollama model with --model or the HELPLINE_MODEL environment variable. The CLI supports macOS, Linux, and Windows PowerShell, with separate guidance for each platform.

Why Does Open Innovation Matter?

The model runs through Ollama on the user's machine. Requests are sent to the local Ollama server rather than a hosted AI API, which keeps shell requests and potentially sensitive file paths off a third-party model service. Once the model is downloaded, helpline can work without an internet connection and does not have per-request API charges.

The local setup also gives users control: they can swap the model, keep inference on their own hardware, and inspect or change the prompts that shape its behavior. That matters for a tool whose inputs can reveal personal files, client work, or business operations. The --print option provides a way to review a generated command before execution.

Top comments (0)