cat docs/libraries.md
All docs

Libraries and sources

A library is a collection of your content that one or more agents can answer from. When an agent is attached to a library it retrieves the most relevant passages for each question and grounds its answer in them — with citations back to the source.

Creating a library

Open Libraries, choose New library, and give it a name. A library starts empty; you fill it with sources.

Adding sources

A source is one body of content. Two kinds are supported:

  • PDF upload — upload a document and Oshu extracts its text (including scanned pages) into searchable Markdown.
  • GitHub repository — point at a public repository of Markdown files and Oshu syncs them. Private repositories work too if you add an access token.

Each source shows its status: indexing, ready, or an error you can act on. You can re-sync an individual source at any time with Sync now — useful after you update a repository or replace a document.

How grounding works

When a visitor asks a question, the agent searches the attached library, pulls the passages most likely to answer it, and writes a reply grounded in them. If citations are enabled on the agent, each answer lists the sources it drew from, and a PDF citation links back to the exact document.

If the library has nothing relevant, the agent says so rather than inventing an answer.

Page limits

Library size is measured in pages (roughly one A4 page of text each). PDF sources count their real page count; Markdown files count by length. Your plan sets how many pages you can store; the BYOK plan removes that limit because you supply your own model key and pay your provider directly for indexing.

Tips

  • Keep each source focused — a well-scoped document retrieves better than one giant file.
  • Re-sync after edits so answers reflect your latest content.
  • Attach the same library to several agents to share one knowledge base.

See also: Agents and Plans and billing.