Gregory Bolshakov has released Peekme, a lightweight utility that integrates directly into terminal-based AI coding agents like Claude Code, Codex CLI, GitHub Copilot CLI, and Kiro CLI. The tool addresses a common friction point in AI-assisted coding: the need to constantly prompt for clarifications on generated code. By allowing users to simply select text and press Alt+P (or Option+P on macOS), Peekme injects an explanation box directly into the terminal output, mimicking the 'Peek' definition experience found in VS Code but within the raw CLI environment.

How It Works and Why It Matters

The core innovation here is context preservation without conversation pollution. When a user selects a snippetβ€”say, a complex function or a configuration lineβ€”and triggers the peek command, Peekme uses the agent's existing chat model to generate a concise explanation. Crucially, it leverages the current conversation context, so ambiguous terms are resolved based on the active session. For deeper queries, Alt+Q allows users to type custom questions that are sent to the model with the full conversation history attached. These explanations appear in nested boxes that expand the terminal view, and users can even select text within an explanation to trigger another layer of detail. The tool is distributed via npm, Homebrew, and Cargo, ensuring broad accessibility for developers across Linux and macOS environments. It requires no separate API keys or accounts, piggybacking on the authenticated session of the underlying AI agent. This design choice minimizes setup overhead and ensures that cost metrics remain transparent within the user's existing AI subscription or credit plan. Saved answers are cached with dotted underlines, allowing instant retrieval of previous explanations without re-querying the model, which is a thoughtful touch for iterative debugging sessions.

Key Takeaways

  • Peekme supports major AI CLIs including Claude Code, Codex, Pi, GitHub Copilot, and Kiro CLI.
  • Inline explanations are triggered via hotkeys (Alt+P/Option+P) without leaving the terminal interface.
  • The tool uses the agent's existing login and model, requiring no separate API keys or accounts.
  • Nested explanations allow users to drill down into specific parts of a generated answer.
  • Released under MIT or Apache-2.0 licenses, it is fully open-source and community-driven.

The Bottom Line

Peekme is a brilliant example of 'invisible AI'β€”it doesn't try to replace the chat interface but enhances it by reducing the cognitive load of constant prompting. For developers who live in the terminal, this is a quality-of-life upgrade that makes AI-assisted coding significantly more fluid and less disruptive.