bib-search-citation — Claude Code skill: search and cite from .bib
Pulls matching entries out of a local BibTeX or BibLaTeX library, Zotero exports included, and turns them into LaTeX or Typst citation snippets.
npx skills add bahayonghang/academic-writing-skills --skill bib-search-citation -a claude-codeWhat bib-search-citation does
The skill reads one .bib file on disk. You hand it a compact filter string through --query, a JSON search spec through --spec-json, or a saved spec through --spec-file for searches you run again and again. Two scripts sit behind it: search_bib.py parses, filters, scores and emits citations, while preview_bib_search.py only renders a short readable summary from the JSON it already produced.
Filters cover year ranges, author substrings, entry types, presence of specific fields and text found in fields such as keywords, abstract or annotation. Results can be sorted by relevance, year or title, and citation output comes as LaTeX, Typst or both. Raw BibTeX stays out of the way until you ask for it, which matters for exact exports or checking an entry by hand.
The claim_support block is the part to read carefully. Matching words between your sentence and an abstract do not prove the paper backs your point, and the skill says so every time it shows that block. Validating citations already sitting in a .tex or .typ project is a different module's job. Budget for uv on the machine, since the scripts run through it.
What it helps with
- locate topical papers in references.bib within a year range
- produce \cite{} snippets for a shortlist of entries
- narrow a Zotero export by annotation or keyword
- confirm which entries carry a DOI or arXiv ID
- pull the original BibTeX for one entry to inspect
Example prompts for the agent
- Search
references.bibfor mamba forecasting work from 2024 onward, give me 5 entries with LaTeX and Typst citations - Filter the Zotero export for entries whose
annotationmentions available code and show me the preview - Show the raw BibTeX of the best match from
references.bib
How to install bib-search-citation
1Skills CLI (Vercel)
npx skills add bahayonghang/academic-writing-skills --skill bib-search-citation -a claude-code2Manually: put the files in place
~/.claude/skills/bib-search-citation/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/bib-search-citation/
1Skills CLI (Vercel)
npx skills add bahayonghang/academic-writing-skills --skill bib-search-citation -a codex2Manually: put the files in place
.agents/skills/bib-search-citation/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add bahayonghang/academic-writing-skills --skill bib-search-citation -a cursor2Manually: put the files in place
.cursor/skills/bib-search-citation/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install bahayonghang/academic-writing-skills bib-search-citation2Manually: put the files in place
.github/skills/bib-search-citation/SKILL.md1Skills CLI (Vercel)
npx skills add bahayonghang/academic-writing-skills --skill bib-search-citation -a gemini-cli2Platform CLI
gemini skills install https://github.com/bahayonghang/academic-writing-skills --path academic-writing-skills/bib-search-citationManually: put the files in place
.devin/skills/bib-search-citation/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add bahayonghang/academic-writing-skills --skill bib-search-citation -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about bib-search-citation
How do I install bib-search-citation in Claude Code?
Run npx skills add bahayonghang/academic-writing-skills --skill bib-search-citation -a claude-code. The skill file then lands at ~/.claude/skills/bib-search-citation/SKILL.md.
What does bib-search-citation do?
It searches and filters records in a local .bib file, returning stable JSON, a compact preview and citation snippets for LaTeX or Typst.
Does bib-search-citation check whether a paper supports my claim?
No. Its claim_support block reports word overlap only, and the skill warns that such overlap does not establish support. Judging the argument stays with you.