citation-assistant
БесплатноЗапускает вложенные скриптыНе проверенAutomatic citation insertion for LaTeX manuscripts. Parses LaTeX source to find uncited statements (factual claims, method comparisons, background assertions…
Об этом скилле
Overview
The citation-assistant skill automatically finds uncited claims in LaTeX manuscripts, searches for the right papers, fetches official BibTeX entries (never fabricates), and inserts \cite{} commands at the right locations. This eliminates the manual process of hunting down citations for statements, methods, datasets, and claims that lack proper attribution.
The skill uses a multi-stage pipeline:
- Parse the LaTeX source to extract text content and existing citations
- Identify statements that need citations but lack them
- Generate targeted search queries for each identified location
- Search academic databases (Semantic Scholar, DBLP, arXiv)
- Fetch official BibTeX entries for the best-matching papers
- Insert citations into the .tex files using the appropriate commands
- Merge all BibTeX entries into a unified references file
Input
One or more .tex file paths provided as arguments. The skill automatically:
- Detects existing
.bibfiles in the same directory as the.texfiles - Parses
\bibliography{}and\addbibresource{}commands to locate referenced bibliography files - Reads all provided
.texfiles and any detected.bibfiles to understand the current citation state
Setup
Install required dependencies using:
pip install -r BASE_DIR/scripts/requirements.txt
Ensure the following Python scripts are available in the BASE_DIR/scripts/ directory:
paper_search.py— searches Semantic Scholar and DBLPbibtex_utils.py— fetches and merges BibTeX entries
Workflow
Step 1: Parse LaTeX
Read all provided .tex files using the Read tool. Extract:
- All existing
\cite{},\citep{}, and\citet{}commands and their citation keys - All
\bibliography{}and\addbibresource{}references to locate bibliography files - The full text content with LaTeX commands stripped for analysis
- Note the citation command style used in the document (to match in subsequent insertions)
Step 2: Identify Uncited Statements
Scan the stripped text for statements that need citations but don't have them. Look for these patterns:
- Related work indicators: Sentences starting with "Recent work...", "Prior studies...", "It has been shown...", "Previous research...", "Earlier work...", "Other approaches..."
- Comparison statements: "X outperforms Y", "unlike previous methods", "compared to existing approaches", "superior to", "more effective than"
- Dataset/benchmark mentions: Explicit mentions without citations (e.g., "ImageNet", "GLUE", "MMLU", "MS COCO", "WikiText", "SQuAD")
- Numerical claims: "achieves X% accuracy on Y", "improves by X%", "reduces computational cost by", "Y% faster than"
- Method names (proper nouns): "ResNet", "BERT", "GPT", "ViT", "CLIP", "Transformer", "ConvNet", "RNN", "LSTM" (if not already cited nearby)
- Background assertions: "Transformers have revolutionized...", "Attention mechanisms enable...", "Deep learning has become...", "Neural networks are known to..."
Skip logic: Do not flag locations that already have \cite{} within 2 sentences (they may be adequately cited).
Step 3: Generate Search Queries
For each identified uncited location, construct a search query from the surrounding context (2-3 sentences). Focus on extracting:
- The specific claim or method name that needs a citation
- Key terms that would help identify the original paper
- The domain or field context if relevant
Example: For "ResNet has become the standard backbone for computer vision", generate query: "ResNet residual networks computer vision deep learning"
Step 4: Search for Papers
For each query, run:
python "BASE_DIR/scripts/paper_search.py" --query "QUERY" --max-results 5 --sort citations
Parse the JSON output and select the most relevant paper based on:
- Title relevance to the claim (highest priority)
- Citation count (prefer well-established, widely-cited papers)
- Venue quality (prefer top-tier venues: NeurIPS, ICML, ICCV, ICLR, ACL, etc.)
- Recency (for "recent work" claims, prefer papers from last 3-5 years; for foundational work, recency is less important)
Step 5: Fetch BibTeX
For each selected paper, run:
python "BASE_DIR/scripts/bibtex_utils.py" fetch --title "PAPER TITLE"
This fetches official BibTeX from Semantic Scholar → DBLP → arXiv in that order of preference. Never fabricate or manually construct BibTeX entries; if official sources fail, flag the entry as unconfirmed.
Step 6: Insert Citations
For each identified uncited location:
- Insert
\cite{key}at the appropriate position in the.texfile - If multiple papers are needed for one statement, use
\cite{key1, key2}or adapt to the document's citation style - Match citation style to existing usage in the document:
\cite{}for basic citations\citep{}for parenthetical citations (natbib style)\citet{}for textual citations (natbib style)
- Write the modified
.texfiles to the outp
Установить citation-assistant в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
FAQ
Что делает скилл citation-assistant?
Automatic citation insertion for LaTeX manuscripts. Parses LaTeX source to find uncited statements (factual claims, method comparisons, background assertions, dataset references, numerical claims), searches for the correct papers via Semantic Scholar and DBLP, fetches official BibTeX (never fabricates), and inserts \cite{} commands. Returns modified .tex files and updated .bib file. Inspired by github.com/ZhangNy301/citation-assistant. Use when the user says "add citations", "find references for", "cite this", "my paper needs citations", or provides LaTeX files needing references.
Как установить скилл citation-assistant?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл citation-assistant запускает скрипты?
Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.
Похожие скиллы
agent-skill-stack
Find, evaluate, and assemble the smallest compatible set of AI Agent Skills for an end-to-end natural-language goal. Use when a user wants Skills for a…
от GitHubbuild-evidence-map
Build an auditable evidence map for a contested technical choice, research synthesis, proposal review, or consequential decision. Use when Copilot must…
от GitHubpinecone-rag
Build production RAG pipelines and persistent agent memory using Pinecone as the vector database backend. ALWAYS USE THIS SKILL when the user mentions…
от GitHubqdrant-monitoring-debugging
Diagnoses Qdrant production issues using metrics and observability tools. Use when someone reports 'optimizer stuck', 'indexing too slow', 'memory too high'…
от GitHub