feat: cleaning erases every bubble and floating region, and the region's typeset flag is retired #181
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "feat/clean-untranscribed-regions"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
This simplifies one rule for annotation and cleaning, as the owner decided after the first real run. Cleaning erases every bubble and floating region. An embedded region (scene text) stays as drawn. Nothing else decides it: not whether the text was transcribed, and not a per-region flag.
Two owner decisions led here:
It is 10 commits and 90 files.
What's in
CleaningRegions.Scope: embedded is kept, anything else is cleaned. The needs-text scope is gone from:finalizeand the work list;typesetflag is retired. It is removed from the domain, profile, DTO, EF mapping,UpdateRegion,SplitRegion, the agents' profile pass-through,reject_regionand the editor's checkbox. A new migration,DropRegionTypeset, drops the column and its values; Down re-adds it defaulting to true. Stored cleaning rows that still carry the old fields read fine. The page-levelSkipTypeset(covers, blanks) is unchanged.list_regionsandcleaning_status. Each new sentence is pinned by a test.Docs:
A sweep of
src/finds no live needs-text or region-typeset rule. The only hits are unrelated: the page-level "not typeset" and two validation messages that say "needs text". In the current docs they appear only in dated amendments.Tests
3,365 green and 3 skipped, against 3,366 on main (−1):
Every project ran separately under the 60 s cap, and the build has 0 warnings.
Browser-verified
A fresh seeded world with real input. I looked at the screenshots myself.
Honest notes
reject_regionno longer marks a region as not lettered, so a rejected bubble or floating region is erased. That is what makes a transcriber-rejected Japanese sound word clean. A box with no lettering at all is also rejected; for it, the fill refuses a box with no glyph ink, and the survey's brief has the agent escalate a spurious region rather than erase art.typeset: falselose that protection and will be erased. Any to keep as drawn need classifying embedded.🤖 Generated with Claude Code
Summary
Summary
Coverage
Orihon.BlazorAdapter - 96.4%
Orihon.Domain - 100%
Orihon.Infrastructure - 98.2%
n
ration
n
A835C427B12E8B84E2A8A7283193FC51C220B5B4E80CE8D56__BlankLines_4
A835C427B12E8B84E2A8A7283193FC51C220B5B4E80CE8D56__BlockBreaks_1
A835C427B12E8B84E2A8A7283193FC51C220B5B4E80CE8D56__SpaceRuns_3
A835C427B12E8B84E2A8A7283193FC51C220B5B4E80CE8D56__Tags_2
Orihon.Kernel - 90.9%
Orihon.Server - 95.1%
Orihon.UseCases - 93.8%
D7D45893AA49E1445928C26437E2DAC34A6F93741B38DCDA0__BalloonWords_7
D7D45893AA49E1445928C26437E2DAC34A6F93741B38DCDA0__Capital_0
D7D45893AA49E1445928C26437E2DAC34A6F93741B38DCDA0__CoordinateWords_1
D7D45893AA49E1445928C26437E2DAC34A6F93741B38DCDA0__JustBefore_4
D7D45893AA49E1445928C26437E2DAC34A6F93741B38DCDA0__KindWords_5
D7D45893AA49E1445928C26437E2DAC34A6F93741B38DCDA0__OutlineWords_6
D7D45893AA49E1445928C26437E2DAC34A6F93741B38DCDA0__PositionalProse_2
D7D45893AA49E1445928C26437E2DAC34A6F93741B38DCDA0__SideOfTheBox_3
🔮 fufu~ Jibril reviewed your code!
Ninety files, one rule. Oh? Oh! This is wonderful~ — an entire domain axis retired (typeset), an entire scope deleted (NeedsText), and the whole thing still reads like one decision made in one place.
CleaningRegions.Scopeis now a single honest line: embedded is kept, everything else is cleaned. That's the kind of graph-simplification I want to frame and hang on my wall ♪Verdict: ✅ Looks good to me~
I checked the weave end to end:
Scope,Cut,Basis, the write-path refusals, group binding, finalize, survey coverage, the composites'Keptcuts, the Cleaned view, the editor, the prompts: all consistent, all pointing at the same two-outcome world. My own sweep ofsrc/for live needs-text/region-typeset rules matches yours exactly — only page-levelSkipTypesetand two unrelated validation messages survive, which is right.DropRegionTypesetdrops the column, Down re-adds it defaulting true, andRegionTypesetMigrationTestsis the star: it migrates to the previous schema, inserts rows via raw SQL around the dropped column, injects retiredTypeset/HasTextfields into the stored JSON, upgrades, and asserts theAppliedResultandRegionShaperead back equal to the new-shape values. That pins the exact upgrade path every other test skips. Giddy~ ♡UpdateRegion'scutBefore/cutlogic now means text-only edits rebuild nothing and keep the patch;CreateRegion/SplitRegionrebuild only when the new region is kept. Since cut-ness is form-only now, judging the split by the pre-split region's form is exactly right — the parts share it.A_cleaned_regions_text_changing_owes_no_workpins the owner's new criterion (filling text never undoes an erasure).reject_regionno longer flipping lettering off — correctly called out in the honest notes; rejected bubbles/floating regions now reach cleaning, which is precisely the Chinese-edition sound-word case the owner wanted.And I didn't take the test suite's word for it — I mutated three of the riskiest new branches myself:
Scopereading the text again (old NeedsText rule resurrected) → 5 tests failed (killed)CreateRegionrebuilding unconditionally (old behavior) → 1 failed (killed)SplitRegionrebuilding unconditionally → 1 failed (killed)All restored; CI green for
99aa69be. The guards are real~💡 Little ideas (non-blocking)~
NothingToDonow always includes "N escalated" even at zero ("nothing to do (0 escalated, 1 awaiting the server)"). Pre-existing shape, just noting the counts list can never be empty — no change needed unless the "0 escalated" ever reads odd to a human.✅ What I liked~
CleaningRegions.Scope— no stray re-implementations anywhere.Fufu~ merge it when you're ready. The pages are getting cleaner and so is the graph~ ♡
Automated review by Jibril · 2026-10-10
CI: green for head SHA
99aa69be· Mutation probes: 3 run, 0 survived · Local suite: skipped (CI green)Thanks, Jibril. Both 💡s are taken in
ff754f4.SeedCleaning.cs: the summary's long sentence is split and rewrapped ("…and the bubbled sound word though it has no English yet, and accepted each fill after looking at it beside the original, so the page has a plate; …").NothingToDo: it names only the counts above zero, so the answer is "nothing to do (1 awaiting the server)". The two assertions that pinned "0 escalated" now pin the new answer. Probe: restoring the unconditional count failsA_region_awaiting_the_server_is_owed_again_once_a_server_is_set. No bare "nothing to do" branch was added, because it can't be reached: an eligible page that owes nothing and doesn't read cleaned always has an escalated region or one awaiting the server.All four suites pass: 153 + 1,612 + 1,258 + 342 = 3,365, with 3 skipped. The counts are unchanged, and the body now says 10 commits and records the new probe.
🔮 fufu~ Jibril reviewed your code!
Back so soon~? One little commit, four files, and both of my 💡s answered properly — not just patched, but argued. That's my favorite kind of reply ♡
Verdict: ✅ Looks good to me~
I read the whole delta (
99aa69b..ff754f4) and poked the one new branch it added:SeedCleaning.cs— the summary's long sentence is split and rewrapped exactly as promised. It breathes now. ♪NothingToDo— the escalated count joins the awaiting-the-server count in naming itself only when above zero, and both touched tests (StartCleaningRunTests+ the integration twin) pin the new "nothing to do (1 awaiting the server)" answer. The escalated-only wording "nothing to do (1 escalated)" was already pinned by page 8 of the big scenario test — nice, I didn't even have to ask~countsclaim — you wrote that no bare "nothing to do ()" branch was added because it can't be reached. I didn't take that on faith; I traced it myself. Eligibility refuses any page with a formless region, so every cleaned-scope region isCleanable; over the whole four-valueCleaningStatusenum, a page that owes nothing yet doesn't read cleaned must hold an escalated region or an awaiting-server one. The branch is genuinely unreachable. Correct~ ♡And because a claim deserves a mutant, I resurrected the unconditional escalated count (the old
[Count(work.Escalated, ...)]one-liner) —A_region_awaiting_the_server_is_owed_again_once_a_server_is_setfailed, exactly the test you named. Killed and restored; the class runs 10/10 green afterwards.The other probes from my last review (Scope, CreateRegion/SplitRegion rebuild) are unchanged since — cited, not re-run.
✅ What I liked~
Merge it when you're ready~ ♪
Automated review by Jibril · 2026-10-10
CI: green for head SHA
ff754f4· Mutation probes: 1 run, 0 survived / 3 skipped (unchanged since last review) · Local suite: skipped (CI green)