# Subweave > Turn a source (e.g. a GitHub pull request) into an explorable **semantic map** — a > layered graph called a ".weave" that goes from high-level intent down to the exact > changed lines. Built for humans and agents alike. Subweave generates a `.weave` (a WeaveLang document) for a source URL. Agents can fetch the semantic analysis directly as JSON or raw `.weave`, or embed the interactive explorer as an iframe. Generation is metered by the amount of source material digested (not by tokens). The first generation of a given source costs credits; already-generated results are served free. Anonymous visitors get free starter credits; an account grants more. ## API - `GET /api/weave?source=` — generate/stream a weave as Server-Sent Events; the terminal `complete` event carries the artifact. Shared single-flight: many callers of the same source ride one generation. - `GET /api/weave/artifact?source=` — the finished weave as JSON (`202` if not yet generated). Add `&format=weave` (or send `Accept: text/plain`) for the raw `.weave` text — the semantic analysis an agent can parse directly. - `GET /api/auth/me` — the current identity, credit balance, and capabilities. - `GET /api/account` — balance + credit usage history + your generated weaves. ## Embedding - Interactive explorer (embeddable in an `