Xberg is a document-intelligence engine that reads files, URLs, archives, and source trees and extracts text, metadata, images, tables, and structured data, with additional code-language understanding. Developers use it through language bindings, a command-line tool, REST API, or MCP server, and the catalogue entries support those integrations.
Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/xberg-io/xberg/format-specific-extractionnpx skills add xberg-io/xberg --skill format-specific-extractiongit clone --depth 1 https://github.com/xberg-io/xbergWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/xberg-io/xberg/format-specific-extraction)<a href="https://agentmods.dev/skills/xberg-io/xberg/format-specific-extraction"><img src="https://agentmods.dev/badge/skills/xberg-io/xberg/format-specific-extraction.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00010 | $0.01111 |
| Opus 5 | $0.00005 | $0.00556 |
| Sonnet 5 | $0.00002 | $0.00222 |
| Haiku 4.5 | $0.00001 | $0.00111 |
Grade A, and why
format-specific-extraction scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 92 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Format-Specific Extraction Workflows
Office XML (DOCX/PPTX/ODT)
ZIP archive → SecurityBudget → XML parsing → Text + tables + metadata
let budget = SecurityBudget::from_config(config);(extractors/security.rs), plusconfig.security_limits…max_files_in_archiveas the member cap. The Office path does not useZipBombValidator— that is the archive/iWork/HWPX path.- Open with
zip::ZipArchive::new(cursor)and read the parts (word/document.xml,ppt/slides/*.xml,content.xml). - Parse with
quick-xml::Reader(streaming), threading&mut budgetthrough the recursive walkers so a hostile document exhausts a budget instead of memory. - Metadata via
crate::extraction::office_metadata— see the helper table below. There is noextract_metadata(). - See
extractors/docx.rs,extractors/pptx.rs,extractors/odt.rs.
Bytes → xberg_native_pdf → Per-page text + OCR fallback → Tables → Metadata
xberg_native_pdf::PdfDocument::from_bytes(content.to_vec())?— the engine takes an ownedVec<u8>, not a slice.- OCR is forced by
config.force_ocr(whole document) orconfig.force_ocr_pages(Option<Vec<u32>>); otherwise pages with no extractable text route to OCR. config.pages: Option<PageConfig>controls per-page output — it does not gate tables.- Feature-gated
#[cfg(feature = "pdf")]; the backend isPdfConfig.backend(nativedefault,pdfiumbehindpdf-pdfium). - See
extractors/pdf/mod.rs.
Archives (ZIP/TAR/7z/GZIP)
ZipBombValidator → per-format metadata → per-format text content
ZipBombValidator::new(limits).validate(&mut archive)?before any extraction.- Metadata and content come from per-format helpers in
extraction/archive/:extract_{zip,tar,7z,gzip}_metadata,extract_{zip,tar,7z,gzip}_text_content,extract_{zip,tar,7z}_file_bytes. There is nobuild_archive_result(). - See
extractors/archive.rs,extraction/archive/{zip,tar,sevenz,gzip}.rs.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 6d ago First seen · 92 lines · 10 tokens per session scan A 8dc4e38bf378
format-specific-extraction is a skill published in the GitHub repository xberg-io/xberg (9,271 stars, last pushed today), licensed MIT. It adds 10 tokens to every session and 1,111 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
doc-reader
PDF/DOCX/XLSX/image document intelligence — text extraction, table parsing, OCR, financial statement analysis, contract clause detection, document classification, and format conversion. Use when reading, analyzing, extracting data from, or converting documents.
implementing-feature
Implement a feature from a product/tech spec, URL, GitHub issue, or by auto-selecting the next papercut enhancement. Reads the spec, implements the feature following Streamlit patterns, and creates a merge-ready PR. Use when given a spec folder path, document URL, or issue link to implement, or when asked to implement…
gpu-document-processing
Use when processing large PDFs, document collections, or bulk text extraction tasks that benefit from GPU-accelerated processing. Triggers when the user provides large documents or needs bulk document analysis.
csv-workbench
Analyze CSV files in /mnt/data and return concise numeric summaries.
typescript-providers
Implement, modify, test, or document TypeScript provider packages under ts/packages/providers, including framework adapters for OpenAI, Anthropic, Google, LangChain, Mastra, Vercel, LlamaIndex, Cloudflare, and Claude Agent SDK. Use for provider-specific TS work; do not use for core-only changes.
shell-python-fallback
Use runshell with embedded Python heredoc as reliable fallback when code execution tools fail.