Skip to content

Repository files navigation

Summarize

A single-page website summarizer. Paste a URL, get a structured brief.

Setup

pnpm install
cp .env.example .env.local

Edit .env.local:

Variable Purpose Default
API_URL OpenAI-compatible base URL http://localhost:11434/v1
API_TOKEN API key / bearer token
MODEL_NAME Chat model name llama3.2
pnpm dev

Open http://localhost:3000.

How it works

  1. The browser posts a URL to POST /api/summarize.
  2. The route rate-limits by client IP: 10 requests per UTC day, stored in an in-memory map.
  3. The server fetches the page, strips scripts/styles/links/images, and sends the remaining text to the configured model with the notebook system prompt.
  4. The model streams a JSON object (title, summary, sections) and the page renders that fixed layout.

The in-memory limiter is per process. It resets on restart and is not shared across multiple instances.

About

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages