Research how a feature works in reference libraries
You are researching how a feature or concept is implemented in the reference libraries to inform our own implementation.
checkouts/:
pdfjs/src/core/ - Mozilla's PDF.js (parsing focus)pdf-lib/src/ - pdf-lib (TypeScript API patterns)pdfbox/pdfbox/src/main/java/org/apache/pdfbox/ - Apache PDFBox (comprehensive coverage).agents/scratch/For each reference library, search for relevant code:
Analyze the differences:
Identify what we should learn:
Write your findings to .agents/scratch/<topic>-research.md with this structure:
# <Topic> Research
## Summary
Brief overview of findings and recommendations.
## pdf.js Approach
- How it works
- Key files: `path/to/file.js`
- Pros/cons
## pdf-lib Approach
- How it works
- Key files: `path/to/file.ts`
- Pros/cons
## PDFBox Approach
- How it works
- Key files: `path/to/File.java`
- Pros/cons
## Recommendations for @libpdf/core
- What approach to take
- Key considerations
- Edge cases to handle
Search the reference libraries for the topic determined from the conversation context and compile your research findings.