validate-bib
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChineseValidate Bibliography
验证参考文献
Cross-reference all citations in lecture files against bibliography entries.
将讲义文件中的所有引用与参考文献条目进行交叉比对。
Steps
步骤
-
Read the bibliography file and extract all citation keys
-
Scan all lecture files for citation keys:
- files: look for
.tex,\cite{,\citet{,\citep{,\citeauthor{\citeyear{ - files: look for
.qmd,@key,[@key][@key1; @key2] - Extract all unique citation keys used
-
Cross-reference:
- Missing entries: Citations used in lectures but NOT in bibliography
- Unused entries: Entries in bibliography not cited anywhere
- Potential typos: Similar-but-not-matching keys
-
Check entry quality for each bib entry:
- Required fields present (author, title, year, journal/booktitle)
- Author field properly formatted
- Year is reasonable
- No malformed characters or encoding issues
-
Report findings:
- List of missing bibliography entries (CRITICAL)
- List of unused entries (informational)
- List of potential typos in citation keys
- List of quality issues
-
读取参考文献文件并提取所有引用键
-
扫描所有讲义文件中的引用键:
- 文件:查找
.tex,\cite{,\citet{,\citep{,\citeauthor{\citeyear{ - 文件:查找
.qmd,@key,[@key][@key1; @key2] - 提取所有使用过的唯一引用键
-
交叉比对:
- 缺失条目: 讲义中使用但参考文献中没有的引用
- 未使用条目: 参考文献中存在但未在任何地方引用的条目
- 潜在拼写错误: 相似但不匹配的键
-
检查每个bib条目的质量:
- 必要字段是否存在(作者、标题、年份、期刊/书名)
- 作者字段格式是否正确
- 年份是否合理
- 无格式错误的字符或编码问题
-
生成结果报告:
- 缺失的参考文献条目列表(严重问题)
- 未使用的条目列表(信息性内容)
- 引用键的潜在拼写错误列表
- 质量问题列表
Files to scan:
待扫描文件:
Slides/*.tex
Quarto/*.qmdSlides/*.tex
Quarto/*.qmdBibliography location:
参考文献位置:
Bibliography_base.bib (repo root)Bibliography_base.bib (repo root)