mirror of
https://github.com/harvard-edge/cs249r_book.git
synced 2026-05-05 17:18:48 -05:00
Add two complementary spell checking tools for content validation: - check_tikz_spelling.py: Extracts and validates all visible text from TikZ diagrams including node labels, inline annotations, custom pics, foreach loops, legends, and comments. Uses pattern-based matching for common typos with optional aspell integration. - check_prose_spelling.py: Intelligently parses QMD structure to check only actual prose content while excluding YAML frontmatter, code blocks, TikZ diagrams, inline code, math expressions, and URLs. Uses aspell with comprehensive ignore list of 500+ technical terms and acronyms. Both tools provide detailed output with file paths, line numbers, and context for identified spelling errors. The TikZ checker found and enabled fixing of typos like 'gatewey', 'poihnts', and 'Intellignet' across the codebase.
Content Management Scripts
Tools for managing, editing, and validating book content.
Key Scripts
manage_section_ids.py- Manage section IDs and cross-referencesimprove_figure_captions.py- Enhance figure captions using AIfind_unreferenced_labels.py- Find unused labels and referencesfind_duplicate_labels.py- Detect duplicate labelsfix_bibliography.py- Fix bibliography formatting
Common Usage
# Improve figure captions
python improve_figure_captions.py
# Find content issues
python find_unreferenced_labels.py
python find_duplicate_labels.py
# Clean up formatting
python collapse_blank_lines.py