Automatically rewrites the websites into markdown optimised for viewing in the terminal. Read intro blog post here
This is a proof-of-concept, bugs are to be expected but feel free to raise an issue or pull request.
Sometimes you don't want to read through someone's life story just to get to a recipe
Requires Python 3.11+
pip install spegel
or clone the repo and install it editable mode
# Clone and enter the directory
$ git clone <repo-url>
$ cd spegel
# Install dependencies and the CLI
$ pip install -e .
Spegel is currently only support Gemini 2.5 Flash, to use it you need to provide your API key in the env
GEMINI_API_KEY=...
spegel # Start with welcome screen
spegel bbc.com # Open a URL immediately
Or, equivalently:
python -m spegel # Start with welcome screen
python -m spegel bbc.com
/
– Open URL inputTab
/Shift+Tab
– Cycle linksEnter
– Open selected linke
– Edit LLM prompt for current viewb
– Go backq
– Quit
Spegel loads settings from a TOML config file. You can customize views, prompts, and UI options.
Config file search order:
./.spegel.toml
(current directory)~/.spegel.toml
~/.config/spegel/config.toml
To edit settings:
- Copy the example config:
cp example_config.toml .spegel.toml # or create ~/.spegel.toml
- Edit
.spegel.toml
in your favorite editor.
Example snippet:
[settings]
default_view = "terminal"
app_title = "Spegel"
[[views]]
id = "raw"
name = "Raw View"
prompt = ""
[[views]]
id = "terminal"
name = "Terminal"
prompt = "Transform this webpage into the perfect terminal browsing experience! ..."
For more, see the code or open an issue!