{"id":16805500,"url":"https://github.com/ylemkimon/hml-equation-parser","last_synced_at":"2025-07-25T11:33:46.956Z","repository":{"id":103581573,"uuid":"116231522","full_name":"ylemkimon/hml-equation-parser","owner":"ylemkimon","description":null,"archived":false,"fork":false,"pushed_at":"2018-01-04T07:54:52.000Z","size":34,"stargazers_count":0,"open_issues_count":5,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-17T07:45:02.776Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ylemkimon.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-01-04T07:53:21.000Z","updated_at":"2018-01-04T07:54:55.000Z","dependencies_parsed_at":null,"dependency_job_id":"86555039-9e6e-4d67-9815-89de6073fbf8","html_url":"https://github.com/ylemkimon/hml-equation-parser","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ylemkimon/hml-equation-parser","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ylemkimon%2Fhml-equation-parser","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ylemkimon%2Fhml-equation-parser/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ylemkimon%2Fhml-equation-parser/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ylemkimon%2Fhml-equation-parser/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ylemkimon","download_url":"https://codeload.github.com/ylemkimon/hml-equation-parser/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ylemkimon%2Fhml-equation-parser/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":266997971,"owners_count":24018949,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-25T02:00:09.625Z","response_time":70,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-13T09:48:26.760Z","updated_at":"2025-07-25T11:33:46.933Z","avatar_url":"https://github.com/ylemkimon.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# hml-equation-parser\n\n## Usage\n\nIf you have `equation string` from `hml` document, you can convert it to latex string by using `eq2latex` function.\n\n```python\n\u003e\u003e\u003e import hml_equation_parser as hp\n\u003e\u003e\u003e hp.eq2latex(\"LEFT ⌊ a+b RIGHT ⌋\")\n'\\\\left \\\\lfloor a+b \\\\right \\\\rfloor'\n```\n\n## Sample code\n\nLet's assume that you have `test.hml` file for converting.\nThere are some sample code to show how to parse hml documents.\nYou can refer to this sample codes in `hmlParser.py`(`parseHmlSample`, `convertEquationSample`, `extract2HtmlStrSample`). \n\n```python\nimport hml_equation_parser as hp\n\ndoc = hp.parseHmlSample(\"test.hml\")  # parse hml document and make ElementTree\n\ndoc = hp.convertEquationSample(doc)  # find equations from ElementTree and convert them to latex string\nstring = hp.extract2HtmlStrSample(doc)  # convert ElementTree to html document with MathJax.\n\nimport codecs\n\nf = codecs.open(\"test.html\", \"w\", \"utf8\")\nf.write(string)\nf.close()\n```\n\n# hml-equation-parser 한글 문서\n\n## 사용법\n\n`hml`문서에서 수식 `string`을 뽑아냈다면 `eq2latex` 함수를 이용하여 `latex` 수식으로 변환할 수 있습니다.\n\n```python\n\u003e\u003e\u003e import hml_equation_parser as hp\n\u003e\u003e\u003e hp.eq2latex(\"LEFT ⌊ a+b RIGHT ⌋\")\n'\\\\left \\\\lfloor a+b \\\\right \\\\rfloor'\n```\n\n## 예제 코드\n\nhml문서를 파싱하여 전체 문서에서 수식을 바꾸고싶다면 다음 코드를 참조하면 됩니다. 예제에서는 `test.hml`을 파싱하여 html문서로 바꿉니다. 파싱에 대한 더 자세한 내용은 library의 `hmlParser.py` 코드를 참조하세요(`parseHmlSample`, `convertEquationSample`, `extract2HtmlStrSample`).\n\n```python\nimport hml_equation_parser as hp\n\ndoc = hp.parseHmlSample(\"test.hml\")  # parse hml document and make ElementTree\n\ndoc = hp.convertEquationSample(doc)  # find equations from ElementTree and convert them to latex string\nstring = hp.extract2HtmlStrSample(doc)  # convert ElementTree to html document with MathJax.\n\nimport codecs\n\nf = codecs.open(\"test.html\", \"w\", \"utf8\")\nf.write(string)\nf.close()\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fylemkimon%2Fhml-equation-parser","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fylemkimon%2Fhml-equation-parser","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fylemkimon%2Fhml-equation-parser/lists"}