제11항 두 칸 경계 — 대문자 짝을 단서 없이 수식으로 보지 않는다 - #197
Merged
Merged
Conversation
Article 11 writes two blanks around an expression inside Korean prose, so the boundary says the word is an expression. A run of consecutive capitals was taken as proof on its own, which made ordinary abbreviations into expressions: `GH의` came out with the two-blank boundary although no reference in the five corpus editions writes one there. Require the same cue the lowercase branch already required — a following `값`/`곱`, or a preceding product — and let that search step over further identifier words, so a list keeps its members together (`AB와 CD의 값을`). The rule example `행렬 A와 B에 대하여 AB의 값을` carries the cue and is unchanged. Corpus 454,990 -> 455,024.
Codecov Report✅ All modified and coverable lines are covered by tests.
🚀 New features to boost your workflow:
|
Contributor
Braillify testcase report
Command: |
added 4 commits
September 11, 2026 23:26
The boundary says the word is an expression, so anything it wraps is read as one. Four more shapes were being wrapped although no corpus reference writes the boundary there. - A number written with separators is Rule 40 notation, not an expression: a clock (22:00), a ratio (16:9), a resolution (1280x720), a range (150~200). A letter touching a digit marks a unit or a model (5G, F1.2), while a letter standing apart from the digits is a variable, so it keeps the boundary (2x+3). - An expression closes every bracket it opens; a lone one belongs to the prose around it (LTE), S(PLAN). - A Roman word joined by a hyphen is Rule 37 text, not subtraction (know-how, well-made). - Rule 34's person label carries a Korean note inside the parenthesis (A(37세)씨, A(27·스리랑카)씨). The following person marker still separates it from function notation, so A(14)는 stays an expression. Corpus 455,024 -> 455,083; the two-blank excess falls from 1,243 sentences to 755.
A Korean word followed by nothing but a sign and digits (아세안+3, 리오+20, 스포츠+) is the place where Article 46 puts an operator between Korean and a number, and that article already sets its one blank. Wrapping it in the Article 11 boundary wrote two instead, against every corpus reference. Corpus 455,083 -> 455,112.
A number written with separators was still handed to the math engine, which drops the number sign the colon requires: 7:30, came out with one sign where Rule 40 writes two. Route those words to the Korean rules instead. Three shapes stay with the math engine because they are expressions: a function name (log2, sin3x), a middle dot between digits (6·9), and a run of variables after a digit (3ab). Corpus 455,112 -> 455,395.
CI enforces full line coverage; the arm that refuses the boundary when a pre-encoded fragment precedes the identifier had no test.
Contributor
Changepacksbraillify@2.1.2 → 2.2.0 - libs/braillify/Cargo.tomlMinor
Patch
braillify-c@0.1.2 → 0.2.0 - packages/c/Cargo.tomlMinor
Patch
Braillify@2.1.2 → 2.2.0 - packages/dotnet/Braillify/Braillify.csprojMinor
Patch
BraillifyNet@2.1.2 → 2.2.0 - packages/dotnet/BraillifyNet/BraillifyNet.csprojMinor
Patch
braillify@2.1.2 → 2.2.0 - packages/node/package.jsonMinor
Patch
braillify@2.1.2 → 2.2.0 - packages/python/pyproject.tomlMinor
Patch
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
요약
수학 제11항의 두 칸 경계가 수식이 아닌 어절에도 붙던 것을 좁혔습니다.
규정 fixture 는 5,141 / 5,141 그대로입니다.
무엇이 문제였나
제11항은 국어 문장 안의 수식 앞뒤를 두 칸씩 띄우라고 합니다. 그러므로 그 두 칸은
"이 어절은 수식이다"라는 선언입니다. 그런데 알파벳이 이어지는 대문자 짝이면
그것만으로 수학 식별자로 보고 있었습니다.
GH,AB처럼 알파벳이 이어지는 짝은 산문의 약어에도 흔합니다. 소문자 쪽은이미 문장이 주는 수학 단서(
값,곱)를 요구하고 있었는데, 대문자 쪽만 그 요구가빠져 있었습니다.
근거
다섯 판본을 전수 대조하면 우리가 두 칸을 더 넣은 문장이 1,243건, 반대 방향은
0건입니다. 그 가운데 대문자+
의꼴만 따로 세면 2024 판본 495문장 전부가 참조에두 칸이 없습니다(있음 0 : 없음 495).
규정 fixture 에서 이 경로로 두 칸을 받는 유일한 예는 다음이며, 뒤에
값을이라는단서가 있습니다.
고친 방법
대문자에도 소문자와 같은 단서를 요구하고, 그 단서 탐색이 식별자를 나열한 어절을
건너뛰도록 했습니다. 나열은 단서를 뒤로 미룰 뿐이므로
AB와 CD의 값을은 두 항이함께 수식으로 남고, 나열이 끝나도록 단서가 없으면 수식이 아닙니다.
기존 단위 테스트 세 건은 단서 없이도 수식이 되던 옛 동작을 담고 있어 새 근거에
맞추어 갱신했습니다.
남은 같은 계열
이번에 고친 것은 1,243건 가운데 대문자 식별자 갈래입니다. 같은 성격의 오탐이 남아
있고, 모양별로 분류해 두었습니다.
HD(1280×800),A(9.77)mg/dl,km/h,-49kgA(45.여),C(33·국악인)씨를[3],22:00,1-①검증
cargo test --release -p braillify— 4,939 + 541 통과, 실패 0cargo clippy --release -p braillify --all-targets -- -D warnings통과