惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

罗磊的独立博客
The GitHub Blog
The GitHub Blog
Hugging Face - Blog
Hugging Face - Blog
博客园 - 聂微东
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
IT之家
IT之家
小众软件
小众软件
博客园_首页
G
Google Developers Blog
Apple Machine Learning Research
Apple Machine Learning Research
MyScale Blog
MyScale Blog
Engineering at Meta
Engineering at Meta
Jina AI
Jina AI
酷 壳 – CoolShell
酷 壳 – CoolShell
人人都是产品经理
人人都是产品经理
B
Blog RSS Feed
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
D
Docker
B
Blog
雷峰网
雷峰网
WordPress大学
WordPress大学
Stack Overflow Blog
Stack Overflow Blog
宝玉的分享
宝玉的分享

Hacker News - Newest: "AI"

AI can't read an investor deck AI as an attorney? Student uses ChatGPT, Gemini to sue UW over alleged racial discrimination Hacking MCP Servers in AI Systems – The Rug Pull: Tool Changes After Approval GitHub - MeepCastana/KubeezCut: Free Web based video editor Can AI judge journalism? A Thiel-backed startup says yes, even if it risks chilling whistleblowers Coming soon: 10 Things That Matter in AI Right Now DARPA built an AI to fact-check enemy weapons claims What explains heterogeneity in AI adoption? When AI Meets Muscle: Context-Aware Electrical Stimulation Promises a New Way to Guide Human Movements - Department of Computer Science AI Changed How We Build. It Did Not Change What Matters. Linux rules on using AI-generated code - Copilot is OK, but humans must take 'full responsibility for the… Meta spins up AI version of Mark Zuckerberg to engage with employees Code Mode: Let Your AI Write Programs, Not Just Call Tools | TanStack Blog GitHub - Delavalom/graft: Go framework for building AI agents. Type-safe tools, multi-provider (OpenAI, Anthropic, Gemini, Bedrock), zero vendor SDKs. India's TCS tops estimates, says new AI models did not dent services demand Gen Z's fading AI hype Strong feeling: we are in a folded AI reality GitHub - machinarii/total-recall-catalog: A reference catalog of latest knowledge retrieval, memory & RAG systems GitHub - mensfeld/code-on-incus: Give each AI agent its own isolated machine with root, Docker, and systemd. Active defense detects and stops threats automatically.. Quantization, LoRA, and the 8% Problem: Benchmarking Local LLMs for Production AI Iran war: We spoke to the man making Lego-style AI videos that experts say are powerful propaganda Powell, Bessent discussed Anthropic's Mythos AI cyber threat with major U.S. banks GitHub - immartian/bellamem: Persistent belief-graph memory for AI agents. Retrieves decisive context by importance — not recency, not RAG, not /compact. recursive-mode: The Repo-Native Operating System for AI Engineering After the attack on Sam Altman's home, will AI CEO's go on the offensive? The biggest advance in AI since the LLM Opus 4.6 vs GPT 5.4 One Prompt Unity World Generation Test “AI polls” are fake polls Client Challenge Can AI be a 'child of God'? Inside Anthropic's meeting with Christian leaders
GitHub - derekmpeterson/paige: A spoiler-free AI book cha...
dualarte · 2026-06-29 · via Hacker News - Newest: "AI"

Chat about your books without spoilers.

Paige screenshot

Paige is a web app that lets you discuss any book with AI while respecting exactly how far you've read. Upload an EPUB, set your progress by chapter, and chat freely — Paige will never reveal what happens next.

Features

  • EPUB upload & parsing — drag and drop your book to get started
  • Chapter-level progress tracking — tell Paige how far you've read
  • Spoiler-free AI chat — powered by any model on OpenRouter (or a local server), constrained to only discuss what you've already read
  • Token usage & cost tracking — see per-message and conversation-level token counts and costs
  • Responsive mobile UI — slide-in sidebar and full mobile support

How It Works

When you set your progress, Paige sends the full text of every chapter you've read directly into the LLM's context window. There's no RAG, no embeddings, no chunking — the model sees the complete, unbroken text of everything up to your current chapter.

This is an opinionated choice. The upside is that conversations are richer and more grounded, since the model has full access to every detail, callback, and nuance in what you've read. The tradeoff is that longer books use more tokens (and cost more), and very large books may approach context limits. On the cost side, because the book text is a stable prefix at the start of every request, it's compatible with prompt caching — so after the first message in a conversation, subsequent messages benefit from discounted cached token pricing. The per-message cost shown in the app is the actual amount OpenRouter charges, so that caching discount is reflected automatically (hover a reply to see its cost and how many input tokens were cached).

Getting Started

Prerequisites

  • Node.js 20.9+
  • An OpenRouter API key (or a local OpenAI-compatible server — see Using a local model)

Setup

git clone https://github.com/derekmpeterson/paige.git
cd paige
npm install

Create a .env.local file in the project root:

OPENROUTER_API_KEY=your-openrouter-api-key

Optionally configure the model (default shown):

MODEL_ID is any OpenRouter model ID (Grok is just the default). Pricing for cost tracking is fetched automatically from the OpenRouter API.

Start the dev server:

Open http://localhost:3000 in your browser.

Using a local model

Instead of OpenRouter, you can point Paige at any local OpenAI-compatible server (for example llama.cpp's llama-server). Set LLAMA_SERVER_URL and Paige will use it instead of OpenRouter — no API key required:

LLAMA_SERVER_URL=http://localhost:8080/v1
LLAMA_MODEL_ID=your-local-model-id

When LLAMA_SERVER_URL is set it takes precedence over the OpenRouter configuration. Cost tracking is OpenRouter-specific, so it is disabled for local models.

Limitations & design notes

Paige is built as a single-user, self-hosted app, and a few choices follow from that:

  • In-memory book storage. Parsed books live in server memory, not a database, so they are lost when the server restarts. Re-upload to continue.
  • No authentication or rate limiting. Run it locally or behind your own access controls; it is not hardened for exposure as a public multi-user service.
  • Approximate token counts. Counting uses the GPT-4o tokenizer (js-tiktoken) as a model-agnostic estimate, so numbers may differ slightly from a given model's exact tokenizer.

Tech Stack

Contributing

Contributions are welcome! Please read CONTRIBUTING.md for local setup, the checks to run before opening a pull request, and project conventions. By participating you agree to abide by the Code of Conduct.

Testing

npm test          # run the unit test suite once
npm run test:watch # watch mode

License

MIT