Skip to main content

peek demo — htop for codebases (code-generated, 800x450, ~15s)

Demo by code — python -m peek.tools.gen_demo • also assets/demo.svg + assets/demo.html

peek — htop for codebases

Understand any codebase in 5 seconds. pip install peek-code && peek .

PyPI Python tests themes Rich+Textual Good First Issues

5 seconds → polyglot graph, languages, stack, Start Here. Every output is a screenshot.


Install

pip install peek-code
pipx install peek-code          # or: uv tool install peek-code
pip install -e "peek[dev]" # dev — pyproject is at peek/pyproject.toml

Requires Python 3.11+. Deps: typer, rich, textual, pathspec.

Full install → docs.md

Quick Start

peek                      # TUI — q quit, / filter, j/k nav, o open, t cycle, w watch
peek --no-tui             # static Rich (CI / screenshot)
peek --theme dracula --html -o map.html && open map.html
peek graph --format svg -o graph.svg  # polyglot import graph → DOT/SVG/HTML
peek find "auth token" --semantic     # semantic BM25 (+ fastembed) — multi-word = intent
peek mcp                  # MCP server for Claude Code / any MCP client

Keys: q quit • j/k nav • o open $EDITOR • / filter • enter details • esc clear • ? help • t theme • w watch

peek wtf                  # paste traceback → explain with Start Here hint
peek watch .              # live rescan on file change (polling, Ctrl+C)
peek config set theme dracula  # persists

Full CLI → docs.md#cli-reference · TUI → docs.md#tui-guide · Semantic → docs.md#semantic

Demo (by code)

python -m peek.tools.gen_demo        # → peek/assets/demo.gif (800×450, <3MB) + demo.svg
peek --html -o peek/assets/demo.html
pytest peek/tests/test_demo_assets.py -v

How it works → docs.md#demo-video

Features

What you get Where
.gitignore-aware walk, languages/LOC, tech stack, entry points, polyglot graph (Python + JavaScript/TypeScript), PageRank peek scan / peek analyze / peek (TUI)
TUI 10 themes, filter, open, HTML export, token-aware pack, ranked find (keyword + semantic) peek / --html / --pack / find
graph DOT/SVG/HTML, symbols index (AST + JS regex), semantic BM25/fastembed, index cache peek graph --format svg / peek find "auth token" --semantic
pack 3.0: tiktoken, --clip, --dry-run, --diff/--staged, URL https:// peek --pack --clip --dry-run --diff HEAD
wtf/watch/config/mcp server, never crashes, <1s for 500 files, offline peek wtf / peek watch . / peek mcp

Full table → docs.md#features

10 Themes

peek --theme dracula
peek --theme-list  # anthropic-pro (default), cinematic, dracula, nord, catppuccin-mocha, tokyo-night, solarized-dark, github-dark, monokai, minimal-mono

Warm clay anthropic-pro → neon cinematic → dracula → nord. 15 tokens #RRGGBB, precedence cli > PEEK_THEME > config > anthropic-pro.

Full table + previews → docs.md#10-themes

Documentation

  • Full manual: docs.md — Install, Demo, Features, Themes, CLI, TUI, Symbols, Semantic, Graph, Git, MCP, WTF, Watch, Config

v3 Highlights

  • polyglot graph — Python AST + JavaScript/TypeScript import/require regex, peek graph --format svg
  • semantic BM25 (peek/embeddings.py) + fastembed, peek find "auth token" --semantic, peek --pack --ask "auth token" --semantic
  • pack 3.0 — --clip/--dry-run/--diff HEAD/--staged, URL fetch, tiktoken; peek mcp stdio server for Claude Code

v2 Highlights

  • peek wtf / peek pack v2 --format xml --budget 4000 / peek config set theme dracula / peek watch . (w toggle) / t theme cycle

Development

git clone https://github.com/hariomlohardev/peek && cd peek
pip install -e "peek[dev]"
pytest -q          # 146 passed, 1 skipped
peek --no-tui && peek  # static + TUI

See CONTRIBUTING.md. ruff + pytest before PR. Branch v3.

Contributing — Good First Issues

New to open source? Start here — 20 good first issues, each ~30 min, one file, copy-paste steps:

Good First Issues

Browse: https://github.com/hariomlohardev/peek/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22

  • Beginner (30 min): docstrings, typo fixes, --help examples, peek --version test — pick any, no setup beyond pip install -e peek[dev]
  • Intermediate (60-90 min): tiktoken tokens, peek diff, peek serve, symbol index
  • Complex (1-2 days): peek-mcp for Claude Code, polyglot tree-sitter, semantic embeddings, peek-vscode

Every issue has exact file, acceptance checkboxes, and pytest -q gate. PRs with good first issue label get priority review.

See CONTRIBUTING.md for ruff + pytest workflow. Branch v3 is the big upshift (polyglot + semantic + MCP).

Why peek?

Every output is a screenshot. Every repo is a new demo. pip install peek-code is zero friction — unlike gitingest (no ranking) or pydeps (no TUI).

License

MIT — LICENSE · Built by Hariom Lohar — hariomlohar.new@gmail.com

Metadata

Release files for peek-code 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for peek-code 0.3.0
File Size Uploaded
peek_code-0.3.0.tar.gz 796.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for peek-code 0.3.0
File Interpreter ABI Platform
peek_code-0.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 878.8 kB

Release files / peek_code-0.3.0.tar.gz

Download URL peek_code-0.3.0.tar.gz
Size 796.0 kB
Tags Source
SHA-256 checksum
How to use checksums
67a577d60c69f9b3a364e08ae9653d3fc6786afccab766b86159f086c13bd18d
BLAKE2b-256 checksum
How to use checksums
e2bd08bf4bedf43ae814d91259dc33447b0c602ecbad47474147497adcb840f3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release files / peek_code-0.3.0-py3-none-any.whl

Download URL peek_code-0.3.0-py3-none-any.whl
Size 82.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
fa012370930ade3340b9d2e16275cb86421247d716acb7d57b207c72d0f375e0
BLAKE2b-256 checksum
How to use checksums
2023f95a077834902a70148e836717cfb13ccc0dbcac606b89b9f42686c54793
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.14

Release history Release notifications | RSS feed

0.6.1

2 release files

0.5.0

2 release files

0.4.0

2 release files

This release

0.3.0 This release

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page