Scripts2026年4月1日·1 分钟阅读

LLM — CLI Tool for 100+ Language Models

LLM is a CLI and Python library for accessing 100+ LLMs via APIs or locally. 11.5K+ stars. SQLite logging, embeddings, structured data. Apache 2.0.

TO
TokRepo精选 · Community
快速使用

先拿来用,再决定要不要深挖

这里应该同时让用户和 Agent 知道第一步该复制什么、安装什么、落到哪里。

# Install
pip install llm
# Or: brew install llm

# Set API key
llm keys set openai

# Run a prompt
llm "Explain quantum computing in one sentence"

# Chat mode
llm chat -m claude-4-sonnet

# Extract structured data
llm "List 3 fruits" --schema name:str,color:str

# All prompts logged to SQLite
llm logs

介绍

LLM is a command-line tool and Python library for accessing OpenAI, Claude, Gemini, Llama, and dozens of other LLMs through APIs or locally-installed models. With 11,500+ GitHub stars and Apache 2.0 license, it stores all prompts and responses in SQLite for logging and analysis, generates embeddings, extracts structured data using schemas, supports tool execution, interactive chat mode, and multi-modal inputs (images, audio, video) via plugins.

Best for: Developers who want quick LLM access from the terminal with full logging Works with: Claude Code, OpenAI Codex, Cursor, Gemini CLI, Windsurf


Key Features

  • 100+ models via plugins (cloud + local)
  • SQLite logging of all prompts/responses
  • Structured data extraction with schemas
  • Embeddings generation
  • Tool execution support
  • Multi-modal (images, audio, video)
  • Interactive chat mode

FAQ

Q: What is LLM? A: CLI tool with 11.5K+ stars for 100+ language models. SQLite logging, embeddings, structured data, chat mode. Apache 2.0.

Q: How do I install LLM? A: pip install llm or brew install llm. Then llm "your prompt".


🙏

来源与感谢

Created by Simon Willison. Apache 2.0. simonw/llm — 11,500+ GitHub stars

相关资产