Skip to main content

Scrape framework/package documentation and generate an AGENTS.md knowledge file.

Project description

doc-scraper

Scrape the full documentation of any framework or package and generate an AGENTS.md file that gives an AI agent comprehensive knowledge of its features.

Quick start

# Install
pip install -e ".[dev]"

# Scrape a documentation site
doc-scrape https://docs.agno.com/introduction

# Custom output path and package name
doc-scrape https://docs.agno.com/introduction -o agno_AGENTS.md -n "Agno Framework"

CLI options

Flag Default Description
url (required) Entry‑point URL of the documentation
-o / --output AGENTS.md Output file path
-n / --name auto‑detect Human‑friendly package name
--max-pages 500 Maximum pages to scrape
--delay 0.25 Seconds between HTTP requests
-v / --verbose off Enable debug logging

How it works

  1. Crawl – starting from the given URL, the scraper follows internal navigation links (sidebar, next/prev, etc.) and collects all reachable documentation pages under the same domain‑path scope.
  2. Extract – for each page it extracts headings, body text, and code examples while discarding chrome (nav, footer, scripts).
  3. Generate – the collected content is assembled into a structured AGENTS.md with a table of contents, per‑page sections, and inline code blocks.

Development

pip install -e ".[dev]"
pytest -q

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

kgrab-0.1.0.tar.gz (15.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

kgrab-0.1.0-py3-none-any.whl (14.9 kB view details)

Uploaded Python 3

File details

Details for the file kgrab-0.1.0.tar.gz.

File metadata

  • Download URL: kgrab-0.1.0.tar.gz
  • Upload date:
  • Size: 15.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for kgrab-0.1.0.tar.gz
Algorithm Hash digest
SHA256 c4e4639dff9d056694a2964f2b2f00c434963a92a125f6fe8f8549b9e27e5fe4
MD5 d087297d88a8c172ac284180833dc6ae
BLAKE2b-256 fb5b6ec62fe0dfd3ec693f5f7c832237da01836cd15872293b4f17503fb3aa88

See more details on using hashes here.

File details

Details for the file kgrab-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: kgrab-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 14.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.2

File hashes

Hashes for kgrab-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6652e0bb7347746c50698b1953efd397a9d12f68e8b26ce5cbd735d7eb489f59
MD5 f010a3fe08be1162e9681f1d52c6df52
BLAKE2b-256 7a95261210fa8292dff5903a207b8a2094a76ab4c6a410779354f67741542118

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page