{"id":26936260,"url":"https://github.com/soanguy/t-basicexam","last_synced_at":"2026-05-03T08:01:30.097Z","repository":{"id":242985035,"uuid":"811136642","full_name":"Soanguy/t-basicexam","owner":"Soanguy","description":"ConTeXt module used for typesetting exams","archived":false,"fork":false,"pushed_at":"2026-04-07T18:14:50.000Z","size":21632,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-04-07T19:27:07.926Z","etag":null,"topics":["context","exam","module","tex"],"latest_commit_sha":null,"homepage":"","language":"TeX","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Soanguy.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-06-06T02:26:28.000Z","updated_at":"2026-04-07T18:14:55.000Z","dependencies_parsed_at":"2024-10-26T15:22:01.745Z","dependency_job_id":"bed08be0-82e6-45ee-95fb-31177c6118dd","html_url":"https://github.com/Soanguy/t-basicexam","commit_stats":null,"previous_names":["soanguy/t-basicexam"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Soanguy/t-basicexam","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Soanguy%2Ft-basicexam","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Soanguy%2Ft-basicexam/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Soanguy%2Ft-basicexam/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Soanguy%2Ft-basicexam/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Soanguy","download_url":"https://codeload.github.com/Soanguy/t-basicexam/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Soanguy%2Ft-basicexam/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32315712,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-26T21:09:39.134Z","status":"ssl_error","status_checked_at":"2026-04-26T21:09:21.240Z","response_time":129,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["context","exam","module","tex"],"created_at":"2025-04-02T12:33:07.202Z","updated_at":"2026-05-03T08:01:30.088Z","avatar_url":"https://github.com/Soanguy.png","language":"TeX","funding_links":[],"categories":[],"sub_categories":[],"readme":"# t-basicexam Project\n\nA ConTeXt Chinese typesetting toolkit featuring three core modules: exam generation, document layout, and style customization.\n\n[![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/Soanguy/t-basicexam)\n\n[![zread](https://img.shields.io/badge/Ask_Zread-_.svg)](https://zread.ai/Soanguy/t-basicexam)\n\n\u003e **Chinese Version**: [README_CN.md](doc/context/third/basicexam/README_CN.md)\n\n---\n\n## Modules Overview\n\n| Module | Type | Description |\n|--------|------|-------------|\n| **t-basicexam** | Exam Generation | Multiple choice, fill-in-the-blank, reading comprehension, essay questions, cloze tests, etc. |\n| **t-memos** | Document Layout | Multi-theme, multi-style document formatting solution with zhnumber and zhindex |\n| **s-poriginal** | Style Module | Custom slide-like presentation styles similar to PowerPoint requiring visualcounter module |\n\n---\n\n## t-basicexam - Exam Generation Module\n\n\u003cimg style=\"box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);\" src=\"https://files.seeusercontent.com/2026/05/02/icF6/260502200738.png\"\u003e\n\n### Features\n\n- **Multiple Choice Questions** - Support for single and multiple selections with automatic grading\n- **Fill-in-the-Blank** - Flexible answer formats\n- **Reading Comprehension** - Support for long text material references\n- **Essay Questions** - Free response spaces\n- **Cloze Tests** - Text gap-filling with answer matching\n- **Answer Control** - Centralized answer management\n- **Score Control** - Flexible point configuration\n- **Question Header Control** - Custom question numbering and formatting\n\n### Usage Examples\n\n#### Full Command Syntax\n\n```tex\n\\usemodule[basicexam][mode=teacher]\n\n\\startquestion[point=4,showanswer=true,answer=B]\n  This is the question stem.\n  \\startchoice\n    \\startcitem Option A \\stopcitem\n    \\startcitem[*] Option B (Correct Answer) \\stopcitem\n    \\startcitem Option C \\stopcitem\n    \\startcitem Option D \\stopcitem\n  \\stopchoice\n  \\startanswer\n    This is the explanation.\n  \\stopanswer\n\\stopquestion\n```\n\n#### Quick Command Syntax\n\n```tex\n\\question[point=4,showanswer=true]{Question stem.\\choice{Option A,{[*]Option B},Option C,Option D}}\n```\n\n#### Fill-in-the-Blank\n\n```tex\n\\startquestion\n  The capital of China is \\fillin{Beijing}.\n\\stopquestion\n```\n\n#### Cloze Test\n\n```tex\n\\startclose[showanswer=true,point=10]\nIn spring, the season of \\closechoice[flowers,leaves,birds,rain],\nwe \\closechoice[walk,run,jump,fly] in the park.\n\\stopclose\n```\n\n#### Essay Writing\n\n```tex\n\\startwriting[point=20]\n  Write an essay about environmental protection (at least 300 words).\n  \\startanswer\n    Reference essay...\n  \\stopanswer\n\\stopwriting\n```\n\n---\n\n## t-memos - Document Layout Module\n\nIncludes `pinyin` (Pinyin annotation), `bihua` (Stroke display), `zhnumber` (Chinese numerals), and `zhindex` (Chinese index) functionality.\n\n\u003cimg style=\"box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);\" src=\"https://files.seeusercontent.com/2026/05/02/6Owk/260502200601.png\"\u003e\n\u003cimg style=\"box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);\" src=\"https://files.seeusercontent.com/2026/05/02/g4fD/260502200410.png\"\u003e\n\u003cimg style=\"box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);\" src=\"https://files.seeusercontent.com/2026/05/02/el4P/260502200631.png\"\u003e\n\u003cimg style=\"box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);\" src=\"https://files.seeusercontent.com/2026/05/02/7Twl/260502200523.png\"\u003e\n\n### Features\n\n- **Multiple Modes**: print, kindle, draft, moresize\n- **Color Themes**: red, blue, yellow, green, black, cyan, orange, purple, pink, gray, white\n- **Chapter Styles**: default, simple, classics, classicnovel, colorful, line, rocket, hexa, madsen, kaolike, publish, artical\n- **TOC Styles**: default, simple, classics, classicnovel, colorful, line, rocket, hexa, madsen\n- **Header Styles**: book, novel, colorful, hctext, fctext, foemargin, foemarginalt, hoemargin\n- **Font Size System**: Complete font sizes from 42pt to 3pt\n- **Multi-language Support**: Chinese Simplified (hans), Traditional (hant), Japanese, English\n\n### Loading Extension Features\n\n```tex\n% Load specific extension\n\\usemodule[memos][extra=pinyin]\n\\usemodule[memos][extra=bihua]\n\\usemodule[memos][extra=zhnumber]\n\\usemodule[memos][extra=index]\n\n% Or load all extensions\n\\usemodule[memos][extra=all]\n```\n\n### pinyin - Pinyin Annotation\n\n**Purpose**: Automatically or manually adds pinyin (romanization) to Chinese characters for educational materials and language learning.\n\n**Main Commands**:\n\n| Command | Description | Example |\n|---------|-------------|---------|\n| `\\startpinyinscope ... \\stoppinyinscope` | Automatic pinyin annotation environment | See example below |\n| `\\xpinyin{text}` | Manual pinyin annotation | `\\xpinyin{汉字}` → hànzì |\n| `\\xpinyin[pinyin]{char}` | Specify pinyin for polyphonic characters | `\\xpinyin[chong2]{重}` |\n| `\\setuppinyin[...]` | Configure pinyin parameters | Set vsep, hsep, ratio, etc. |\n\n**Usage**:\n```tex\n\\usemodule[memos][extra=pinyin]\n\n% Automatic annotation\n\\startpinyinscope\n汉语拼音自动注音测试。\n\\stoppinyinscope\n\n% Manual annotation\n汉字：\\xpinyin{手动注音测试}\n\n% Polyphonic character\n\\xpinyin[chong2]{重}庆是一座美丽的城市。\n```\n\n### bihua - Stroke Display\n\n**Purpose**: Shows the stroke order and structure of Chinese characters for character teaching and calligraphy practice.\n\n**Main Commands**:\n\n| Command | Description | Example |\n|---------|-------------|---------|\n| `\\bihuaload{chars}` | Load character data | `\\bihuaload{好学习}` |\n| `\\bihuashow{char}{n}` | Display the nth stroke | `\\bihuashow{好}{3}` |\n| `\\bihuashowall{char}` | Display all strokes | `\\bihuashowall{好}` |\n| `\\definebihua[style][...]` | Define custom stroke style | Configure colors, frame, etc. |\n\n**Frame Types**:\n- **outer**: Outer frame only\n- **tian**: Tian character grid (cross lines)\n- **mi**: Mi character grid (cross + diagonal lines)\n- **x**: Diagonal lines only\n- **none**: No frame\n\n**Usage**:\n```tex\n\\usemodule[memos][extra=bihua]\n\n\\bihuaload{好学习}\n\n% Display specific stroke\n\\bihuashow{好}{3}\n\n% Display with frame\n\\bihuashow[frame=tian]{好}{3}\n\n% Display all strokes\n\\bihuashowall{好学习}\n```\n\n### zhnumber - Chinese Numeral Conversion\n\n**Purpose**: Converts Arabic numerals to Chinese numeral expressions, supporting integers, decimals, fractions, dates, and Ganzhi (sexagenary cycle).\n\n**Main Commands**:\n\n| Command | Description | Example |\n|---------|-------------|---------|\n| `\\zhnumber{num}` | Integer conversion | `\\zhnumber{12345}` → 一万二千三百四十五 |\n| `\\zhnumber{decimal}` | Decimal conversion | `\\zhnumber{3.14}` → 三点一四 |\n| `\\zhnumber{fraction}` | Fraction conversion | `\\zhnumber{1/2}` → 二分之一 |\n| `\\zhdate{date}` | Date conversion | `\\zhdate{2024/1/1}` → 二〇二四年一月一日 |\n| `\\zhtime{time}` | Time conversion | `\\zhtime{14:30}` → 十四点三十分 |\n| `\\zhtiangan{n}` | Heavenly Stems | `\\zhtiangan{1}` → 甲 |\n| `\\zhdizhi{n}` | Earthly Branches | `\\zhdizhi{1}` → 子 |\n| `\\zhganzhinian{year}` | Ganzhi Year | `\\zhganzhinian{2024}` → 甲辰年 |\n\n### zhindex - Chinese Index Sorting\n\n**Purpose**: Provides intelligent Chinese index sorting with three sorting methods.\n\n**Sorting Methods**:\n- **zh-pinyin**: Sort by Pinyin pronunciation\n- **zh-alpha**: Sort by alphabetical order\n- **zh-stroke**: Sort by stroke count\n\n**Usage**:\n```tex\n\\usemodule[memos][extra=index]\n\n\\index{Peking University}\n\\index{Tsinghua University}\n\n\\setupregister[index][language=zh-pinyin]\n\\placeindex\n```\n\n---\n\n## s-poriginal - Style Module\n\nProvides custom slide-like presentation styles similar to PowerPoint. Requires the `visualcounter` module.\n\n### Install visualcounter Dependency\n\n```bash\nmtxrun --script install-modules --install visualcounter\n```\n\n---\n\n## Installation\n\n1. Download the project files\n2. Place files in `tex/texmf-local/` under your ConTeXt installation\n3. Run `mtxrun --generate` to refresh file index\n4. Use modules in your TeX files:\n   - `\\usemodule[basicexam]`\n   - `\\usemodule[memos]`\n   - `\\usemodule[poriginal]`\n\n---\n\n## Documentation \u0026 Examples\n\n- **[Chinese README](doc/context/third/basicexam/README_CN.md)** - Complete documentation in Chinese\n- **[basicexam Manual](doc/context/third/basicexam/basicexam-manual.tex)** - Detailed usage guide\n- **[memos Manual](doc/context/third/basicexam/memos-manual-en.tex)** - Document layout documentation (English)\n- **[memos Manual (Chinese)](doc/context/third/basicexam/memos-manual.tex)** - Document layout documentation (Chinese)\n- **[Test Files](doc/context/third/basicexam/)**:\n  - **[test-exam.tex](doc/context/third/basicexam/test-exam.tex)** - Exam generation tests\n  - **[test-frame.tex](doc/context/third/basicexam/test-frame.tex)** - Frame tests\n  - **[test-poriginal.tex](doc/context/third/basicexam/test-poriginal.tex)** - Style module tests\n  - **[test-zhnumber.tex](doc/context/third/basicexam/test-zhnumber.tex)** - Chinese numeral tests\n  - **[test-zhindex.tex](doc/context/third/basicexam/test-zhindex.tex)** - Chinese index tests\n  - **[test-pinyin.tex](doc/context/third/basicexam/test-pinyin.tex)** - Pinyin annotation tests\n  - **[test-bihua.tex](doc/context/third/basicexam/test-bihua.tex)** - Stroke display tests","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsoanguy%2Ft-basicexam","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsoanguy%2Ft-basicexam","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsoanguy%2Ft-basicexam/lists"}