Downloads, splits, and deeply reads academic PDFs with adaptive chunking. Prevents prompt-overflow errors by reading papers in controlled batches.
Ships in ai-asset-pricing. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
CRITICAL RULE: Never read a full PDF in one pass. Only read the split files, and only one batch at a time. Reading a full PDF will either crash the session with an unrecoverable "prompt too long" error -- destroying all context -- or produce shallow, hallucinated output where Claude skims the abstract, gets fuzzy on methodology, and fabricates details from results sections.
The user wants to read, review, or summarize an academic paper. The input is either:
./articles/smith_2024.pdf)"Bai Bali Wen 2019 corporate bond factors")You must know what paper to read. If the user invokes this skill without specifying a paper, ask them. Do not guess.
If a local file path is provided:
./articles/, copy it there (preserve original)If a search query is provided:
perplexity_search)./articles/ (create directory if needed)CRITICAL: Always preserve the original PDF. The original in articles/ must NEVER be deleted, moved, or overwritten. Split files are derivatives.
Before splitting, determine total page count and select the optimal chunking strategy:
from PyPDF2 import PdfReader
import os
reader = PdfReader(input_path)
total_pages = len(reader.pages)
Chunking strategy by paper length:
| Paper Length | Action | Chunk Size | Batch Size | Pages/Batch |
|---|---|---|---|---|
| < 12 pages | Read directly (no splitting) | -- | -- | -- |
| 12-25 pages | Light splitting | 8 pages | 2 chunks | ~16 pages |
| 25-45 pages | Standard splitting | 6 pages | 3 chunks | ~18 pages |
| 45-80 pages | Dense splitting | 5 pages | 3 chunks | ~15 pages |
| > 80 pages | Heavy splitting | 4 pages | 3 chunks | ~12 pages |
Rationale: Shorter papers have lower total token load, so larger chunks are safe. Longer papers (monographs, dissertations, papers with extensive appendices) need smaller chunks to maintain attention quality. The batch size controls how much you read before writing notes and pausing.
Override: If the user specifies a chunk size, use it. The adaptive sizing is a default, not a mandate.
Create a subdirectory and split:
from PyPDF2 import PdfReader, PdfWriter
import os
def split_pdf(input_path, output_dir, pages_per_chunk):
os.makedirs(output_dir, exist_ok=True)
reader = PdfReader(input_path)
total = len(reader.pages)
prefix = os.path.splitext(os.path.basename(input_path))[0]
for start in range(0, total, pages_per_chunk):
end = min(start + pages_per_chunk, total)
writer = PdfWriter()
for i in range(start, end):
writer.add_page(reader.pages[i])
out_name = f"{prefix}_pp{start+1}-{end}.pdf"
out_path = os.path.join(output_dir, out_name)
with open(out_path, "wb") as f:
writer.write(f)
print(f"Split {total} pages into {-(-total // pages_per_chunk)} chunks of {pages_per_chunk} pages in {output_dir}")
Directory convention:
articles/
+-- bai_bali_wen_2019.pdf # original -- NEVER DELETE
+-- split_bai_bali_wen_2019/ # split subdirectory
+-- bai_bali_wen_2019_pp1-6.pdf
+-- bai_bali_wen_2019_pp7-12.pdf
+-- ...
+-- notes.md # structured extraction
If PyPDF2 is not installed: pip install PyPDF2
Read exactly one batch at a time (see table above for batch sizes). After each batch:
notes.md in the split subdirectory)"Finished reading pages X-Y (batch N of M). Notes updated. N chunks remaining. Continue?"
Do NOT read ahead. Do NOT read all splits at once. The pause-and-confirm protocol is mandatory.
As you read, extract information along these dimensions and write into notes.md. The dimensions are ordered by priority -- the first four are always populated; the rest are populated as information becomes available.
Research question & motivation -- What is the paper asking? What gap does it fill? Why does it matter?
Data & sample construction -- What data sources? Sample period? Universe (bonds, stocks, firms)? Filters applied? Number of observations? Unit of analysis? How are returns computed?
Methodology -- Econometric approach? Identification strategy? Portfolio sorts vs. Fama-MacBeth vs. factor models? Key specifications? How are standard errors computed?
Key results -- Main coefficient estimates, t-statistics, economic magnitudes (basis points, Sharpe ratios). Be specific: "long-short return of 45bp/month (t=2.87)" not "significant positive return."
Factor/signal definitions -- For asset pricing papers: How are sorting variables constructed? What price data is used? Holding period? Rebalancing frequency? Breakpoints (NYSE, full sample)?
Robustness & alternatives -- Subperiods? Alternative specifications? Placebo tests? What survives and what doesn't?
Relevance to our work -- How does this paper relate to our replication crisis paper? Does it use standard or adjusted approaches? Does it address measurement error? Is it in our factor zoo? What can we learn or cite?
Replication feasibility -- Is data publicly available? Replication archive? Code repository? Enough detail to reproduce Table 1?
Output: articles/split_<name>/notes.md
Structure with clear headers for each dimension. Update incrementally after each batch -- do not rewrite from scratch. By completion, the notes should contain specific data sources, variable definitions, equation references, sample sizes, and coefficient estimates. Not a summary -- a structured extraction.
Header format:
# Reading Notes: [Paper Title]
**Authors**: [Authors]
**Journal/Year**: [Journal, Year]
**Pages**: [Total pages] | **Chunks**: [N] | **Strategy**: [chunk size]pp x [batch size] batches
---
## 1. Research Question & Motivation
[Updated incrementally]
## 2. Data & Sample Construction
[Updated incrementally]
## 3. Methodology
[Updated incrementally]
## 4. Key Results
[Updated incrementally]
## 5. Factor/Signal Definitions
[Updated incrementally]
## 6. Robustness & Alternatives
[Updated incrementally]
## 7. Relevance to Our Work
[Updated incrementally]
## 8. Replication Feasibility
[Updated incrementally]
---
*Last updated after batch N (pages X-Y)*
For quick relevance assessment, read only the first chunk (abstract + introduction). Report:
Invoke triage mode: /split-pdf --triage <path-or-query>
| Step | Action |
|---|---|
| Acquire | Download to ./articles/ or use existing local file |
| Size | Count pages, select chunk size from table |
| Split | PyPDF2 chunks into ./articles/split_<name>/ |
| Read | One batch at a time, pause after each |
| Extract | Update notes.md with structured information |
| Confirm | Ask user before continuing to next batch |
Why adaptive chunks instead of fixed 4-page? Academic papers vary enormously in density. A 20-page empirical paper with large tables can be read in bigger chunks than a 60-page theory paper with dense proofs. The adaptive strategy matches chunk size to cognitive load.
Why these extraction dimensions? They capture what a finance researcher needs to build on, replicate, or cite a paper. Generic "research question + method + findings" misses the specifics that matter: exactly how signals are constructed, what data filters are applied, whether measurement error is addressed.
Why pause between batches? To catch errors before they compound, redirect focus for specific sections, and prevent the notes from drifting. The human checkpoint is not overhead -- it's quality control.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
/ai-asset-pricing:split-pdffrom ai-asset-pricing
ai-asset-pricing@fin-skills is listed by howard-lynn-ye/fin-rsi — review the source before installing
npx claudepluginhub howard-lynn-ye/fin-rsi --plugin ai-asset-pricing38 skills in this plugin
/audit-captionsAudit all table and figure captions for language, notation, and formatting consistency/audit-mathAdversarial audit of mathematical proofs, derivations, and formal environments/audit-sectionDeep audit of a single section -- style, factual accuracy, citations, logical flow/bond-dataReference for the Dickerson corporate bond dataset: column mappings between WRDS and PyBondLab, rating encoding, return definitions, signal clusters, and data gotchas. Auto-apply when loading bond data for PyBondLab analysis./build-contextGenerate guidance/paper-context.md from user-provided .tex, .md, or .pdf files/build-deckCreate and compile Beamer presentations following the Rhetoric of Decks philosophy. Use when making seminar or conference slides.Other plugins' skills for the same job