doc-research-download
Repeatable workflow for domain documentation research WRKs: search for freely-available references, download PDFs via shared bash lib, catalogue into knowledge/seeds/<domain>-resources.yaml. Use when starting any WRK that collects and indexes domain reference documents. type: reference
Best use case
doc-research-download is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Repeatable workflow for domain documentation research WRKs: search for freely-available references, download PDFs via shared bash lib, catalogue into knowledge/seeds/<domain>-resources.yaml. Use when starting any WRK that collects and indexes domain reference documents. type: reference
Teams using doc-research-download should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/doc-research-download/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How doc-research-download Compares
| Feature / Agent | doc-research-download | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Repeatable workflow for domain documentation research WRKs: search for freely-available references, download PDFs via shared bash lib, catalogue into knowledge/seeds/<domain>-resources.yaml. Use when starting any WRK that collects and indexes domain reference documents. type: reference
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
Related Guides
SKILL.md Source
# Doc Research Download Skill
## Overview
Use this skill for any WRK that collects domain reference documents:
naval architecture, electrical engineering, structural analysis, etc.
It establishes where files live, how the download script is structured,
and what the catalogue YAML must contain.
## 6-Step Workflow
1. **Fetch seed URLs** — load each seed URL, extract all linked PDFs and sub-pages;
produce an explicit list of direct download URLs (this is the discovery phase —
output feeds the download script, not the template directly)
2. **Web search for extras** — search OCW, archive.org, standards bodies (IEC, ISO, IEEE,
NFPA, ABS, DNV) for freely-available PDFs; add direct URLs to the list from step 1
3. **Create domain download script** — copy the template below; populate `download` calls
with the URL list from steps 1–2; source `scripts/lib/download-helpers.sh`
4. **Catalogue** — write `knowledge/seeds/<domain>-resources.yaml` per `knowledge/seeds/schema.md`;
validate each saved file is a real PDF (`file <path>` must report `PDF document`);
move HTML/WAF responses to `pending_manual:` with `notes: "WAF — saved HTML, not PDF"`
5. **Regenerate document index** — run `scripts/data/document-index/` pipeline; if the full
run takes >5 min, write `.Codex/work-queue/assets/<WRK-ID>/index-regen-queued.txt`
with the command to run — that file is the verifiable evidence for AC completion
6. **Record WAF-blocked / borrow-only** — add to `pending_manual:` in the YAML;
never silently skip — every attempted resource must appear somewhere
## Script Template
Copy and adapt for each new domain:
```bash
#!/usr/bin/env bash
# ABOUTME: Download open-access <DOMAIN> documents to /mnt/ace/docs/_standards/<DIR>/
# Usage: bash scripts/data/<domain>/download-<domain>-docs.sh [--dry-run]
set -euo pipefail
DEST="/mnt/ace/docs/_standards/<DIR>"
LOG_DIR="$(git rev-parse --show-toplevel)/.Codex/work-queue/assets/<WRK-ID>"
LOG_FILE="${LOG_DIR}/download.log"
DRY_RUN=false
[[ "${1:-}" == "--dry-run" ]] && DRY_RUN=true
mkdir -p "${DEST}/textbooks"
mkdir -p "${LOG_DIR}"
# shellcheck source=scripts/lib/download-helpers.sh
source "$(git rev-parse --show-toplevel)/scripts/lib/download-helpers.sh"
log "=== <DOMAIN> Download — <WRK-ID> ==="
log "Destination: ${DEST}"
log "Dry run: ${DRY_RUN}"
# ─────────────────────────────────
# TEXTBOOKS — direct PDF links
# ─────────────────────────────────
log "--- Textbooks ---"
download \
"https://example.org/book.pdf" \
"${DEST}/textbooks" \
"Descriptive-Filename.pdf"
log "=== Download complete ==="
total=$(find "${DEST}" -name "*.pdf" | wc -l)
log " Total PDFs: ${total}"
```
## Catalogue YAML Template
```yaml
category: <domain-slug>
subcategory: references
created_at: "YYYY-MM-DD"
textbooks:
- title: "Full Book Title"
author: "Author or Organisation"
year: YYYY
local_path: "/mnt/ace/docs/_standards/<DIR>/textbooks/filename.pdf"
source_url: "https://..."
size_mb: N
topics: [topic1, topic2]
online_portals:
- title: "Portal Name"
url: "https://..."
notes: "What is available here"
pending_manual:
- title: "Blocked Book"
url: "https://..."
notes: "Reason: archive.org borrow-only"
```
## AC Checklist
- [ ] All seed URLs fetched and linked PDFs extracted
- [ ] Web search performed for additional freely-available resources
- [ ] All downloadable PDFs saved to `/mnt/ace/docs/_standards/<DOMAIN>/`
- [ ] Catalogue YAML written at `knowledge/seeds/<domain>-resources.yaml`
- [ ] Document index regenerated, or `assets/<WRK-ID>/index-regen-queued.txt` written
- [ ] No paywalled or DRM-protected content downloaded; WAF-blocked items in `pending_manual:`
## Known WAF Patterns
| Site | Behaviour | Workaround |
|------|-----------|------------|
| eagle.org (ABS) | Cloudflare WAF — 403 for wget/curl | Download manually via browser |
| archive.org borrow-only | HTTP 403 — "This item is not available for download" | Add to `pending_manual:`; note borrow URL |
| IEEE Xplore full-text | Paywalled unless institution login | Only download confirmed open-access items |
These patterns were identified during WRK-1151 (naval architecture).
## Web Crawling & MCP Assessment (2026-03-14)
**Decision: No external MCP needed. Use Python scripts (httpx + beautifulsoup4).**
Available built-in tools for web content:
- `WebFetch` — single URL fetch (adequate for known pages)
- `WebSearch` — web search + results
- `Codex-in-chrome` — full browser automation for JS-rendered pages
Assessed and rejected (cost or unnecessary complexity):
- Firecrawl MCP — paid service, rejected
- Crawl4AI MCP — free but adds unnecessary dependency layer
- Playwright MCP — only useful for JS-rendered pages (already covered by Codex-in-chrome)
- Fetch MCP (Anthropic) — minimal gain over WebFetch
**For WRK-1202 Tier 3 scripts**, use `httpx` + `beautifulsoup4` + `robotsparser` directly.
BSEE/EIA/IMO are standard REST APIs and static HTML — no MCP needed.
See also: `web-scraper-energy` skill for existing BOEM/BSEE scraping patterns.Related Skills
tax-pdf-download-workaround
Handle FreeTaxUSA PDF download popups that block automation by capturing structured data and manual download workflow
handle-popup-blocked-pdf-downloads
Recover from automation-blocking PDF popups by capturing page data and escalating to manual download
handle-pdf-download-popups-in-automation
Recover when PDF download buttons open inaccessible popups; fall back to capturing structured data instead
research-literature
Systematize research and literature gathering for engineering categories — queries doc index, capability map, and standards ledger to produce structured research briefs for calculation implementation. type: reference
research-and-literature-gathering
Systematic workflow for finding, downloading, and indexing engineering literature by domain. Covers the full lifecycle: discovery via standards ledger and doc index, web search for open-access PDFs, download script generation, PDF validation, catalogue YAML creation, and handoff to the 7-phase document-index-pipeline for indexing. Use when populating a new engineering domain with reference literature or when a WRK item requires domain-specific standards and textbooks.
tax-e-filing-research
Guide to directly e-filing federal Form 1120 and state franchise tax returns. Covers service comparison, cost analysis, step-by-step filing procedures, and paper filing alternatives for C-Corp entities.
user-research-synthesis
Synthesize qualitative and quantitative user research into structured insights and opportunity areas
customer-research
Investigate customer questions through multi-source research with confidence scoring and citations
mcp-builder-phase-1-deep-research-and-planning
Sub-skill of mcp-builder: Phase 1: Deep Research and Planning (+3).
xlsx-to-python-research-finding-no-existing-library-does-this
Sub-skill of xlsx-to-python: Research Finding: No Existing Library Does This (+5).
social-media-research-process
Sub-skill of social-media: Research Process (+1).
competitive-analysis-research-sources
Sub-skill of competitive-analysis: Research Sources (+2).