Back to all projects
CLI ToolActive

q

A fast, minimal CLI for getting AI answers directly in your terminal, with provider auto-detection and a local Ollama fallback.

Ongoing
Solo project
Ongoing
q

Living experiment

A living experiment, not a finished product. q is small enough to be a good testbed, so I run different coding agents and approaches through it against the same tool — which means it's updated most days, largely by the agents themselves. Expect the details here to keep shifting.

0
Config Needed
4+
Providers
TypeScript
Language

1Overview

q is a small command-line tool for getting AI answers without leaving the terminal. Ask it a question and it streams the response inline. When running interactively it shows a tidy ASCII loading indicator on stderr while it waits for the first chunk of text, so you always know it's working.

2The Challenge

Most terminal AI tools demand setup before they're useful — config files, provider selection, API key wiring. I wanted something that worked the moment it was installed, regardless of which provider's key happened to be in the environment, and that could fall back to a free local model when no cloud key was present.

3The Solution

q works with no config file at all. It auto-detects common provider keys (Gemini, Groq, Anthropic, OpenAI) from the environment and falls back to local Ollama when one is available. You can pin a provider and model explicitly, or let it choose.

It's written in TypeScript and built with Bun, shipping as an npm package and as standalone binaries on the releases page. Small conveniences like a --copy flag and a streaming response make it pleasant for everyday terminal use.

4Results

  • Zero-config — works the moment it's installed
  • Auto-detects Gemini, Groq, Anthropic and OpenAI keys
  • Falls back to free local Ollama models when no cloud key is present
  • Streams answers with an ASCII loading indicator in interactive shells
  • Distributed via npm and as standalone binaries

Technologies used

TypeScriptBunOllamaGeminiOpenAI