HermitCrab analysis: port the edge-segment prefilter (time-only, 0 steps)
メンテナーはふだん 1 日以内に返信
評価
調査の方向性
Read docs/optimizations/edge-segment-prefilter.md and inspect AnalysisAffixProcessRule; then compare the current rules with #561 and #562 if either has landed. Reproduce the archived parity and conformance checks, and run the same-binary A/B measurement on the 45 Sena words and conformance suite. Done means verdicts and trace events match, traversal and arc-check counts are reported, and step count is unchanged; close the issue if the owner rules out time-only work.
索引モデルが issue の本文から書いたものです。
説明
Port ledger row 22's edge-segment prefilter to master, only if the owner wants a time-only gain. HermitCrab analysis spends 70-91% of its events on attempts that do not unapply; each attempt runs a full FST traversal even when the word's edge segment cannot match. The prefilter makes each attempt cheaper but removes no step, so under the owner's step metric its value is 0.
Problem (steps and cost)
Census: not-unapplied attempts are 70-91% of analysis events. Ledger row 7 ("count is not cost") and row 30 (time-only work is outside the owner's metric) apply. The archived record (origin/perf/hc-optimization-archive, docs/optimizations/edge-segment-prefilter.md) measured parity on 45 Sena words and 464 conformance words, FST traversals -87% and arc checks -54%, trace events unchanged. Steps saved: 0%. Arc checks and traversals are different units and are not steps.
Proposed change
Re-apply the archived prefilter to current master in AnalysisAffixProcessRule (check the first or last segment of the word against the literal edge of the affix pattern before running the traversal). No behaviour change; no new parses.
Soundness
Argued in the archive record; it was sound on the parity sets above. Must be re-argued against current master and against #561 or #562 if they land, since they touch the same rules.
Memory bound
Per-rule edge segment sets sized to the grammar, bytes to KB. No cache.
Expected value (low)
0% in steps by definition. Worth doing only as a wall-time improvement and only if the owner decides time-only work is acceptable. This issue is filed so that decision is recorded, not as a recommendation.
Measurement plan
Same-binary A/B on the 45 Sena words and the conformance suite: verdicts and trace events identical, report traversals and arc checks beside a step count that must not change.
Kill criterion
Close if the owner rules time-only work out of scope (ledger row 30), or if any trace event or parse differs.
Dependencies
None. Interacts with #561 in that it removes whole partial subtrees before their attempts run, which reduces the attempts this prefilter would make cheaper.
Related
- PR #490: HermitCrab optimization round record (ledger rows cited above are in it).
- PR #480: HermitCrab conformance suite. Conformance per-fixture verdicts must be identical with and without the change.
- Units: deterministic analysis events and synthesis steps, never ms. "% less work" = (off - on) / off per grammar, never pooled. Census figures are ceilings unless stated. Ranges marked "est." are estimates that the shadow phase replaces with measurements.
- Owner constraint: no memo or cache; any new structure must be grammar-sized and at most a few MB.
🤖 Generated with Claude Code
- 主要言語
- C#
- スター
- 29
- フォーク
- 16
- 平均マージ
- 6日 13時間
- マージ済み PR(30日)
- 12
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドなし
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
sillsdev/machine のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
メンテナーはふだん 1 日以内に返信
-
enhancement Hermit Crab
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
メンテナーはふだん 1 日以内に返信
-
HermitCrab analysis: ordered and anchored required-slot look-ahead (v2)対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープンenhancement Hermit Crab
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
メンテナーはふだん 1 日以内に返信
-
HermitCrab analysis: measure required-slot look-ahead on the #546 shared walk対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープンenhancement Hermit Crab
難易度 5/5 1週間以上 初心者へのやさしさ 20/100
メンテナーはふだん 1 日以内に返信
-
enhancement Hermit Crab
難易度 5/5 1週間以上 初心者へのやさしさ 30/100
sillsdev/machine#565 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
sillsdev/machine の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
Live-Charts/LiveCharts2#2403 ·
-
Rework budget never counts Claude review rounds: review comments lack the claude-code-review markerオープンbug
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
thomhurst/AsyncSemaphore#618 ·
メンテナーはふだん 1 日以内に返信
-
Importer: an empty or non-numeric Error cell is imported as 0 instead of missing対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
Open-Systems-Pharmacology/OSPSuite.Core#3049 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
-
ORMオープンBackend SW VTA
難易度 2/5 1〜3時間 初心者へのやさしさ 61/100
aau-giraf/visual-tangible-artefacts#376 ·
メンテナーはふだん 1 日以内に返信