一键导入
lint-paper
Check paper directories for completeness, format compliance, and index consistency. Run on a single paper or --all for the entire collection.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Check paper directories for completeness, format compliance, and index consistency. Run on a single paper or --all for the entire collection.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Credentialed-source backend for retrieving books from Bookshare (bookshare.org) into the papers/ collection. Given a book title or ISBN and a target directory name, it searches Bookshare and downloads the EPUB via the published `bookshare` CLI. Download-only (produces book.epub). Enable only if you have a Bookshare account; requires credentials in a gitignored .secrets/bookshare.json.
Paywalled-access backend for paper-retriever. Retrieves a paywalled paper's PDF through an institutional / library subscription (a library proxy such as EZproxy or OpenAthens, or an institutional login), given an identifier (DOI/URL) and the target paper directory name. Invoked by paper-retriever when open-access channels fail. Enable this skill only if the install has institutional access configured.
Paywalled-access backend for paper-retriever. Retrieves a paywalled paper's PDF via sci-hub browser automation, given an identifier (DOI/URL) and the target paper directory name. Invoked by paper-retriever when open-access channels fail; enabled by default. Disable this skill to remove sci-hub from the retrieval waterfall.
Retrieve a scientific paper PDF given an arxiv URL, DOI, or paper title. Downloads to papers/ directory. Handles open-access retrieval (arxiv direct, Chrome print-to-pdf for publisher-direct HTML, Unpaywall, title-based open-repository search); for paywalled papers it hands off to whichever paper-retriever-* access skill is enabled (sci-hub by default, or institutional).
Read scientific papers and extract implementation-focused notes. Converts PDFs to page images, then reads them. Papers <=300pp are read directly by the assigned worker; papers >300pp use a chapter-aligned chunk protocol (preferred) or 50-page chunks (fallback) and synthesize a master notes.md that links to per-chapter files. Creates structured notes in papers/ directory.
Cross-reference a paper against the collection. Finds which cited papers are already collected, which are new leads, which collection papers cite this one, and reconciles all cross-references bidirectionally. Run on a single paper directory or use --all for the entire collection.
| name | lint-paper |
| description | Check paper directories for completeness, format compliance, and index consistency. Run on a single paper or --all for the entire collection. |
| argument-hint | <papers/Author_Year_Title> or --all |
| disable-model-invocation | false |
| compatibility | Claude Code, Codex CLI, and Gemini CLI. |
Audit paper directories for completeness and format compliance. No AI needed — just file checks and grep.
if [[ "$ARGUMENTS" == "--all" ]]; then
ls -d papers/*/ | grep -v "papers/tagged" | sort
else
paper_dir="$ARGUMENTS"
fi
For each paper directory, run all checks and collect results.
| File | Status |
|---|---|
notes.md | REQUIRED — run paper-reader if missing |
description.md | REQUIRED — run paper-reader if missing |
abstract.md | recommended |
citations.md | recommended |
paper.pdf or pngs/ | REQUIRED — at least one source artifact must exist. Notes without a verifiable source are untrustworthy. |
Notes metadata: Does notes.md have YAML frontmatter with at least title: and year:?
head -8 "$paper_dir/notes.md" | grep -E "^title:|^year:"
Missing → report as NOTES_METADATA_MISSING
Tags: Does description.md have YAML frontmatter with a tags: field?
head -5 "$paper_dir/description.md" | grep "tags:"
Missing → report as UNTAGGED
Markdown link format: Are cross-references in notes.md using real markdown links ([Pretty Title](../Dir/notes.md)) rather than legacy [[wikilinks]]?
# Legacy wikilinks — these don't render on GitHub, must be converted
grep -c '\[\[[A-Z][A-Za-z0-9_-]*_[0-9]\{4\}' "$paper_dir/notes.md"
Found → report as LEGACY_WIKILINKS (convert to [title](../Dir/notes.md) — GitHub does not render [[wikilinks]] in repo files)
Frontmatter validity:
notes.md has --- delimiters, is the YAML valid?description.md has --- delimiters, is the YAML valid?--- appears on lines 1 and 3+ (not empty frontmatter)title: is present in notes.mdtags: value is a list, not empty in description.mdCross-references section: Does notes.md have ## Collection Cross-References?
grep -c "## Collection Cross-References" "$paper_dir/notes.md"
Missing → report as NOT_RECONCILED
In index: Is the paper listed in papers/index.md with a valid linked header?
The header must be a markdown link to the paper's notes.md
(## [Pretty Title](Author_Year_ShortTitle/notes.md)␣␣(tags)), not a bare
directory name. A substring match on the directory name is too weak — it
always matches inside the link target and cannot catch a malformed header,
stale title, wrong link target, or missing two-space gap. Match structurally
on the link target instead:
dir="$(basename "$paper_dir")"
# Linked header whose target resolves to THIS paper's notes.md:
grep -E "^## \[.+\]\(${dir}/notes\.md\)" papers/index.md
NOT_INDEXED (missing, or a malformed/bare-dirname header).test -f "papers/${dir}/notes.md".](...)␣␣(tags)),
not a single space, when tags are present.Index description matches: Does the description in index.md match description.md?
Only check if both exist — flag INDEX_STALE if they differ.
Source artifact: Does the paper have a PDF or page images?
ls "$paper_dir/paper.pdf" "$paper_dir"/pngs/page-*.png 2>/dev/null | wc -l
Zero → report as NO_SOURCE_ARTIFACT (notes without a verifiable source are untrustworthy — retrieve the PDF)
Orphan PDF: Is there a PDF in papers/ root with a name matching this paper?
ls papers/*.pdf 2>/dev/null
Any root-level PDFs → report as ORPHAN_PDF (should have been moved by paper-reader)
Page citations in notes: Do findings in notes.md include page references?
grep -c '(p\.[0-9]' "$paper_dir/notes.md"
Zero → report as NO_PAGE_CITATIONS (re-read paper with updated paper-reader to add page provenance)
Lint: papers/Author_Year_Title/
✓ notes.md
✓ description.md
✓ abstract.md
✗ citations.md — MISSING
✓ paper.pdf
✗ notes metadata — NOTES_METADATA_MISSING
✗ tags — UNTAGGED
✓ markdown-link format
✗ cross-references — NOT_RECONCILED
✓ indexed
Group by status:
Lint: N papers checked
Complete (M papers):
- Paper1, Paper2, ...
Issues found:
MISSING notes.md (need paper-reader):
- Paper3
MISSING description.md (need paper-reader):
- Paper4
NOTES_METADATA_MISSING (need migrate_notes_frontmatter.py or re-run paper-reader):
- Paper4a
UNTAGGED (need tag-papers):
- Paper5, Paper6, Paper7, ...
NOT_RECONCILED (need reconcile):
- Paper8, Paper9
LEGACY_WIKILINKS (convert `[[Dir]]` → `[Pretty Title](../Dir/notes.md)`):
- Paper10
NOT_INDEXED (need generate-paper-index.py):
- Paper11
ORPHAN_PDF (unprocessed PDFs in papers/ root):
- somefile.pdf
Then a summary line:
Summary: M complete, N issues across K papers