AI-powered Hacker News digest in your terminal
A terminal UI tool that fetches top Hacker News stories and generates a concise AI digest — so you can catch up on tech news without leaving your terminal.
- AI Digest — AI summarizes the top stories into a scannable, themed overview
- Multi-Provider — Anthropic, OpenAI, Gemini, Ollama, or any OpenAI-compatible API
- Story Browser — Browse and open stories directly from the terminal
- Markdown Rendering — Beautiful terminal-native markdown via Glamour
- Keyboard-Driven — Navigate, refresh, and open links without touching the mouse
- Configurable — Customize story count, model, and theme via config file
brew tap n0an/tap
brew install hackernewsgit clone https://github.com/n0an/hackernewsai-cli.git
cd hackernewsai-cli
go install ./cmd/hackernews/Note: Make sure
~/go/binis in yourPATH. Add this to your~/.zshrc(or~/.bashrc):export PATH="$HOME/go/bin:$PATH"
Set an API key for your preferred provider:
# Pick one:
export ANTHROPIC_API_KEY=your-key # Anthropic (default)
export OPENAI_API_KEY=your-key # OpenAI
export GEMINI_API_KEY=your-key # Google GeminiFor local models (Ollama, LM Studio, etc.), no API key is needed — just configure the endpoint.
hackernews| Key | Action |
|---|---|
tab |
Switch between Digest and Stories views |
j / k |
Scroll down / up |
enter / o |
Open story URL in browser |
c |
Open HN comments page |
r |
Refresh and regenerate digest |
q |
Quit |
Settings are stored in ~/.hackernews-tui.yaml:
# Provider: anthropic, openai, gemini, ollama, openai-compatible
provider: anthropic
model: claude-sonnet-4-6
story_count: 30
theme: autoAnthropic (default):
provider: anthropic
model: claude-sonnet-4-6OpenAI:
provider: openai
model: gpt-4o-mini
# Reasoning models (o1, o3, gpt-5) are also supported
# model: gpt-5.2Gemini:
provider: gemini
model: gemini-2.0-flashOllama (local):
provider: ollama
ollama_model: llama3.2
ollama_endpoint: http://localhost:11434/v1 # optional, this is the defaultOpenAI-compatible (LM Studio, llama.cpp, Jan, etc.):
provider: openai-compatible
local_endpoint: http://localhost:1234/v1
local_model: qwen3-4bcmd/hackernews/ — Entry point
internal/
hackernews/ — HN Firebase API client (concurrent fetching)
digest/ — AI digest generation (prompt + formatting)
provider/ — LLM providers (Anthropic, OpenAI, Gemini, Ollama, OpenAI-compatible)
config/ — YAML config file management
tui/ — Bubble Tea UI (views, styles, key handling)
| Component | Library |
|---|---|
| TUI Framework | Bubble Tea |
| Markdown Rendering | Glamour |
| Styling | Lip Gloss |
| AI (Anthropic) | anthropic-sdk-go |
| AI (OpenAI) | openai-go |
| AI (Gemini) | google genai |
- HackerNewsAI — iOS & macOS app
- HackerNewsAI Telegram Bot — Daily digests via Telegram
MIT License