modules¶
geometor.etc¶
Tools for processing the Encyclopedia of Triangle Centers (ETC).
Key Components:¶
Ingest: Tools (
ingest_folder()) to split and organize the raw HTML source.Parser: Tools (
parse_center()) to extract center data from HTML.Transform: Tools (
generate_rst_files()) to generate ReStructuredText documentation.Glossary: Tools (
extract_glossary_terms()) to handle glossary terms.
Usage:¶
Use the main function in __main__.py or the individual modules to process ETC data.
Submodules¶
Functions¶
|
Ingest all HTML files in the input folder by splitting them. |
|
Parse a center's HTML content into a structured dictionary. |
|
Generate RST files for a list of centers. |
|
Extract glossary terms and definitions from the HTML content. |
|
Generate the content for glossary.rst. |
Package Contents¶
- geometor.etc.ingest_folder(input_folder: str, output_folder: str) None¶
Ingest all HTML files in the input folder by splitting them.
- geometor.etc.parse_center(html_content: str) dict | None¶
Parse a center’s HTML content into a structured dictionary.
- geometor.etc.generate_rst_files(centers: list[dict], output_dir: str, glossary_terms: list[str] | None = None) None¶
Generate RST files for a list of centers.