HermitCrab: do literal-identity and natural-class restoration on hc.dll match the port's fixes? (unmeasured)
维护者通常 1 天内回复
还没有人认领这个 Issue。
评估
调研方向
Read PanGloss CHANGELOG origin/main lines 202–230 and docs/hermitcrab-2026-10-21-search-cost-round.md lines 59–113, then inspect the C# implementation in hc.dll for the two described identity/restoration patterns. Replay both patterns and count steps; add conformance cases to #480 for any divergence, or record that C# already matches. The issue does not name a specific test or code entry point.
由索引模型根据 Issue 内容生成。
描述
Claude-drafted.
Two identity fixes cut the PanGloss port's work sharply, and nobody has replayed them on hc.dll. Affix literal segments match only themselves on large featureless inventories: 98.5% less work on 7 spot words. Deleted natural-class members restore only their class: 94.7% less work on a 7,206-word list. Both were measured on the port (HC-Rust) only, in its own work units.
What we know:
- The port's changelog says the literal fix matches HermitCrab ("as in HermitCrab", 0.9.0, line 233). The class fix cites divergence entry 103 and makes no such claim (line 209).
- The ledger says C# gives a featureless segment a
StrRepEqualToconstraint, so its literal matches only itself. That is in the code atCharacterDefinitionTable.cs#L73-L74. For the class case the ledger says C# unifies against the class'sStrRepunion, with no code reference (inferred). - The port ran 18 lookups on the slowest word on C#'s own export, against 49 for C# and 1,655 on its own snapshot. That gap is what led to both fixes.
Not known: whether hc.dll's work steps match the port's after the fixes, for either pattern.
Proposed change (C#): replay the two patterns on hc.dll and count steps. Add conformance cases to the conformance suite for any divergence. If C# already behaves this way, record that.
Related: #480 (closed; its fixtures are now in the conformance suite). PanGloss: sillsdev/PanGloss#111 (the pointer issue for this one, open); the fixes are in PanGloss CHANGELOG 0.9.0 (divergence entries 090 and 103).
Next: replay both patterns on hc.dll and count work steps.
Evidence -- the port-side measurements
- Literal identity (ledger row 24): 7 spot words 98.5% less work (2,365,602 to 35,913); worst variant 99.8% less (50,778,583 to 83,677); steps on full lists fell 46-55x. Parses identical on three private lists and on Amharic, Sena and Indonesian.
- Natural-class restoration (ledger row 25): held list of 7,206 words 94.7% less work (303,966,311 to 16,220,190); the 16 words that hit a 1 s limit 99.9% less. Parses identical everywhere.
- Cause of A: above 64 character definitions the port lost the literal's identity, so an enclitic matched any final segment. Cause of B: the port's re-inserted class node matched any segment and its root trie ignored the member set.
- The three lookup counts (49, 18, 1,655) were supplied to that round and not reproduced by it.
Method rule -- how the bugs were found
Run the port on the oracle's own export of the same grammar and compare a cheap count, such as lookups per word. A large gap between the port's two inputs is a port bug. The round's rule: do this before measuring any algorithmic lead on a port.
Sources -- pinned
- Search-cost round, "The lesson" (lines 59-113)
- Ledger rows 24 and 25: lines 129-130
- PanGloss CHANGELOG on
origin/main, section 0.9.0 (starts line 175): class fix heading line 202, entry 103 at line 209; literal fix heading line 230, "as in HermitCrab" at line 233.
- 主要语言
- C#
- 星标
- 29
- 派生
- 16
- 平均合并
- 6 天 7 小时
- 30 天内合并 PR
- 14
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 没有贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
sillsdev/machine 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 68/100
维护者通常 1 天内回复
-
Hermit Crab
难度 2/5 1-3 小时 新手友好度 45/100
维护者通常 1 天内回复
-
porting
难度 3/5 半天 新手友好度 25/100
sillsdev/machine#617 · 1 条评论 ·
维护者通常 1 天内回复
-
Hermit Crab
难度 4/5 3-5 天 新手友好度 18/100
维护者通常 1 天内回复
-
难度 3/5 1-2 天 新手友好度 62/100
维护者通常 1 天内回复
相似的 Issue
-
难度 1/5 1 小时以内 新手友好度 80/100
Unity-Technologies/unity-agent-plugin#118 ·
维护者通常 1 天内回复
-
The Recommended preset turns on Import Uno DSP, which only works with the Material theme可能已有人在做 @agneszitte 今天认领。 未关闭
难度 1/5 1 小时以内 新手友好度 92/100
unoplatform/uno.templates#2388 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 77/100
eyalgolan/statecraft-israel#2732 ·
维护者通常 1 天内回复
-
要トリアージ
难度 2/5 1-3 小时 新手友好度 64/100
维护者通常 1 天内回复
-
kind/chore status/draft
难度 2/5 1-3 小时 新手友好度 65/100
Altinn/altinn-events#1158 ·
维护者通常 1 天内回复