Filter and manipulate bibliography entries by criteria (author, year, keyword, entry type). Parse, search, extract entries, and format/pretty-print files. Use when the user asks to search, filter, extract, parse, or format bibliography files.
Install
npx skillscat add mearman/marketplace/plugins-bib-skills-bib-filter Install via the SkillsCat registry.
SKILL.md
bib-filter
Filter bibliography entries by various criteria.
Usage
npx tsx ${CLAUDE_PLUGIN_ROOT}/scripts/filter.ts input.bib [criteria] --output=filtered.bibFilter Criteria
--id=<string>- Filter by entry ID (exact match)--author=<string>- Filter by author name (substring match)--year=<number>- Filter by publication year--type=<string>- Filter by entry type (article, book, etc.)--keyword=<string>- Filter by keyword (substring match)
Multiple criteria are combined with AND logic.
Options
--output=<file>- Output file (prints to stdout if omitted)--sort- Sort filtered results
Examples
Find all papers by Smith:
npx tsx ${CLAUDE_PLUGIN_ROOT}/scripts/filter.ts refs.bib --author=SmithFind papers from 2024:
npx tsx ${CLAUDE_PLUGIN_ROOT}/scripts/filter.ts refs.bib --year=2024 --output=2024-papers.bibFind articles about machine learning:
npx tsx ${CLAUDE_PLUGIN_ROOT}/scripts/filter.ts refs.bib --keyword="machine learning"Filter by type:
npx tsx ${CLAUDE_PLUGIN_ROOT}/scripts/filter.ts refs.bib --type=article-journalCombine multiple criteria:
npx tsx ${CLAUDE_PLUGIN_ROOT}/scripts/filter.ts refs.bib --author=Smith --year=2024 --type=articleOutput
Total entries: 150
Filtered entries: 12
[Filtered bibliography output...]Matching Behavior
- ID: Exact match
- Author: Case-insensitive substring match (checks all authors)
- Year: Exact year match
- Type: Exact type match (e.g., "article-journal")
- Keyword: Case-insensitive substring match
Use Cases
Extract subset for a specific paper:
npx tsx ${CLAUDE_PLUGIN_ROOT}/scripts/filter.ts main.bib --keyword="neural networks" --output=nn-refs.bibFind all books:
npx tsx ${CLAUDE_PLUGIN_ROOT}/scripts/filter.ts refs.bib --type=bookGet recent publications:
npx tsx ${CLAUDE_PLUGIN_ROOT}/scripts/filter.ts refs.bib --year=2024Notes
- Format is auto-detected
- Output uses same format as input
- Empty results return empty bibliography file
- Can be combined with
--sortfor ordered output