# simonw/llm

Access large language models from the command-line

Repository: https://github.com/simonw/llm
Canonical: https://ross.abutalabs.com/products/llm
Homepage: https://llm.datasette.io
Language: Python
License: Apache-2.0
License Family: permissive
Topics: llms, openai, ai
Last push: 2026-08-22T17:01:27+00:00

## Health v2 (maintenance only)
Score: 97/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 99, release rhythm 99, longevity 89
- inputs: {"age_days": 1250, "days_push": 11, "days_rel": 11, "gap_med": 16.5, "n_releases_24m": 25}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 12412, forks 963 (observed 2026-08-28T04:10:52.650652+00:00)

## What it is
A CLI tool and Python library for running prompts against large language models from OpenAI, Anthropic, Google, and many other providers, including locally installed models. It logs prompts and responses to SQLite, supports embeddings, structured extraction, tool execution, and is extensible via a plugin system.

## Use cases
- run llm prompts from the terminal
- chat with gpt or claude from the command line
- query local models like gpt4all from cli
- store llm prompt history in sqlite
- generate text embeddings for a collection of documents
- extract structured  from text with an llm
- script llm calls in python

## When to choose
- you want a unified CLI over many LLM providers and local models
- you need logged, reproducible prompt/response history
- you want a scriptable Python API plus plugin extensibility

## When to avoid
- you need a graphical chat interface
- you need fine-grained training or fine-tuning tooling
- you need a hosted service with team management

## Facets
- artifact type: cli-tool
- maturity: stable
- function: llm-inference, cli, rag, plugin-system, sdk
- domain: large-language-models, developer-tools, artificial-intelligence
- platform: cli, python, cross-platform, windows
- tags: openai, anthropic, gemini, local-models, embeddings, sqlite-logging, prompt-templates, command-line, macos, linux

## Member repositories
- simonw/llm (main) score 97

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:10:52.650652+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T17:14:05.743786+00:00, confidence not recorded.
  - readme: https://github.com/simonw/llm (fetched 2026-08-28T04:10:52.650652+00:00, sha 1d074b9673e1)
  - homepage: https://llm.datasette.io (fetched 2026-08-29T08:11:07.311919+00:00, sha a3d73bdfeed4)
  - site_page: https://llm.datasette.io/en/stable/plugins/installing-plugins.html (fetched 2026-08-29T08:11:07.315507+00:00, sha 8ae93941f771)
  - registry_pypi: https://pypi.org/pypi/llm/json (fetched 2026-08-29T08:11:07.335514+00:00, sha 5be25c5bf536)
  - site_page: https://llm.datasette.io/en/stable/changelog.html (fetched 2026-08-29T08:11:07.317490+00:00, sha c16533107ea7)
  - site_page: https://llm.datasette.io/en/stable/setup.html (fetched 2026-08-29T08:11:07.322258+00:00, sha 283419182f56)
  - site_page: https://llm.datasette.io/en/stable/openai-models.html (fetched 2026-08-29T08:11:07.324253+00:00, sha e24a8755e9de)
  - site_page: https://llm.datasette.io/en/stable/other-models.html (fetched 2026-08-29T08:11:07.326200+00:00, sha 2e3e2c964df3)
  - site_page: https://llm.datasette.io/en/stable/plugins/tutorial-model-plugin.html (fetched 2026-08-29T08:11:07.327962+00:00, sha 5011db46990b)
  - site_page: https://llm.datasette.io/en/stable/help.html (fetched 2026-08-29T08:11:07.330244+00:00, sha 75e321d99d93)
- Data as of 2026-08-30T08:39:29.467469+00:00.
