DEDUPED Hot AI repos. Real use cases. What people build. Get the Monday 5

How to run prompts from the command line with LLM

Install LLM, store a key and pipe files into a model from your shell.

Short answer: Install with pip install llm; then Store your key with llm keys set openai; run llm "Ten fun names for a pet pelican". All steps.

  • Top pick
  • Software and DevOps
  • Beginner
  • 10 minutes
  • From the README
  • Claude Code
  • Codex
  • Cursor
  • Gemini CLI

cost. Hosted models bill per token on your own API key.

Who it is forA developer who wants quick model answers without leaving the terminal.

The problemOpening a chat UI for every small question breaks the flow.

The outcomePrompts, file input and system prompts running from one command.

What you need first

  • Python with pip, or Homebrew, pipx or uv
  • An API key for a hosted model, or a local model server such as Ollama or LM Studio
  • Plugins for providers such as Gemini

Steps

  1. Install with pip install llm
  2. Store your key with llm keys set openai
  3. Run llm "Ten fun names for a pet pelican"
  4. Pipe a file in with cat myfile.py | llm -s "Explain this code"

Prompt for your agent

Using simonw/llm, install it with `pip install llm`, set my key with `llm keys set openai`, then run `cat myfile.py | llm -s "Explain this code"` on <my file>.

Caveat. The README example names a default model that may change between releases.

Use this in your AI agent

Ask your agent

Using the Deduped MCP, get the setup steps for simonw/llm and "Run prompts from the command line"

Add Deduped to Claude Code once

claude mcp add --transport http deduped https://dedupedai.com/mcp

Cursor, ChatGPT, others

Share: X LinkedIn Hacker News Email Copy link

Third-party repos we don't own. AI-written use cases can be wrong. Disclaimer