kenly
A terminal "lite IDE" for exploring codebases — a fast, keyboard- and
mouse-driven code explorer in the spirit of lazygit, k9s and yazi.
The base explorer (kenly) is standalone and read-only — no AI, no
network. An opt-in AI walkthrough (kenly kt, Phase 2)
layers on top of it.
kenly # explore the current directory
kenly /path/to/repo # explore any repo
kenly file.py # open a file directly
What it does
- File-tree sidebar with lazy expansion (large repos stay instant)
- Code pane with syntax highlighting and line numbers (~500 languages via Pygments)
- Tabs for multiple open files
- Navigation: scroll, page, jump-to-line, top/bottom, in-file search
- Fuzzy file finder (
Ctrl+P) - Breadcrumb + status bar, responsive layout, mouse support
It never writes to your files. It never opens a socket.
Install (development)
python3.11 -m venv .venv
source .venv/bin/activate
pip install -e ".[dev]"
kenly .
Tests
pytest
Engine tests are pure and terminal-free. UI tests drive the real app headlessly
with Textual's Pilot and assert real outcomes.
Layout
src/kenly/
├── cli.py # argparse entry point → kenly console script
├── driver.py # THE DRIVER API contract (typing.Protocol)
├── engine/ # pure, UI-free logic — imports no Textual
│ ├── models.py # DirEntry, LoadedFile, SearchMatch, FuzzyResult
│ ├── paths.py # normalisation + root-containment guard
│ ├── ignore.py # what the tree and index skip
│ ├── tree.py # lazy directory listing
│ ├── syntax.py # language detection
│ ├── loader.py # safe file reading (caps, binary sniff, encodings)
│ └── workspace.py # the facade the TUI holds
└── tui/ # Textual app, widgets, layout, bindings
├── app.py # KenlyApp — implements the driver API
├── kenly.tcss # stylesheet
└── widgets/ # file_tree, code_pane, status_bar
See docs/architecture.md and
docs/driver-api.md.
Phase 2 — kenly kt (AI knowledge transfer)
kenly kt [PATH] layers a live, interruptible AI walkthrough on top of the
exact same read-only explorer. Claude Code drives the screen — opening files,
highlighting the lines it's talking about, scrolling to them — while it explains
the codebase in the narration panel. You can cut in with a question mid-sentence,
tell it to go deeper or skip, or take the wheel and explore on your own, then
resume from wherever you're looking.
Setup
# The Claude Agent SDK ships with kenly, so a plain `pip install kenly`
# already includes the AI walkthrough. You only need two more things:
npm i -g @anthropic-ai/claude-code # the CLI the SDK drives (Node 18+)
echo 'ANTHROPIC_API_KEY=sk-…' > .env # gitignored; .env and .env.* never commit
kenly kt . # real, live AI walkthrough
kenly kt . --focus "the auth flow" # steer it (also offered in-UI at start)
kenly kt . --offline # scripted demo: no key, no network, $0
With no key, kenly kt doesn't fail — it drops into a clearly-badged
OFFLINE DEMO (a scripted, deterministic tour that exercises the same UI path)
and tells you, in-panel, exactly how to enable the real thing.
Keys
| Key | Action |
|---|---|
Ctrl+J |
ask a question — pre-empts the guide mid-sentence |
Ctrl+N |
next step |
Ctrl+G |
go deeper on what's on screen |
Ctrl+S |
skip this step |
Ctrl+E |
explore on your own — you take the wheel |
Ctrl+R |
resume the guide from where you're looking |
Ctrl+T |
stop and wrap up |
Every Phase-1 key (tree navigation, tabs, / search, Ctrl+P finder, ? help)
still works during a KT. Press ? for the full cheat-sheet.
Cost
The Anthropic key is the only thing in kenly that ever costs money. A short
session is a few cents; TurnComplete surfaces the real cumulative spend live in
the panel header, --max-turns N caps a runaway session, and --offline is
always free. CI runs entirely on the offline brain — no key, no network, no cost.
License
MIT
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file kenly-0.1.0.tar.gz.
File metadata
- Download URL: kenly-0.1.0.tar.gz
- Upload date:
- Size: 2.1 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/7.0.0 CPython/3.11.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
17ebae3a5dc84308f3f889ddd3c710fe44d54defb8411f2fe9a8e7d75a6bd688
|
|
| MD5 |
3d9b5cacbeb9e3cc06f6720b024276a9
|
|
| BLAKE2b-256 |
77e6e182a3c0fac9147eee62c7e7ca7760770a19ef718afedc006d94e90001a3
|
File details
Details for the file kenly-0.1.0-py3-none-any.whl.
File metadata
- Download URL: kenly-0.1.0-py3-none-any.whl
- Upload date:
- Size: 133.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/7.0.0 CPython/3.11.15
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5dc0d26c030d79a014af15e5d58f1ce80a16d6fcfd812c85a9c1ab05f7320711
|
|
| MD5 |
9c34861eda423a33dc7ce5be045bc6ea
|
|
| BLAKE2b-256 |
c52db3cc5db2f9d1d5117cb14a448bbbebcfd732bfbdb70f832d255bc563dbe2
|