HermitCrab analysis: excluded co-occurrence check is sound but cuts 0% of work on real grammars (parked)

Abierto
#602 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
35/100
Tipo de issue
Nueva funcionalidad
Claridad
Bastante claro
Estado de actividad
Activo
Stack tecnológico
csharp
Área
backend

Línea de trabajo

Read docs/hermitcrab-2026-10-27-synthesis-to-analysis-round.md at lines 434 and 627 on branch docs/hc-optimization-ledger, then locate the C# co-occurrence check. Run it behind a flag on a grammar with many exclusions and compare work-step counts; done means a real grammar shows a reduction, otherwise do not merge.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Claude-drafted.

An excluded morpheme co-occurrence check during analysis is sound and cheap, but it cut 0% of total work on all five real grammars measured. It helps only where exclusion rules are dense. Parked, not built in C#.

What we know (candidate E4; total work; parse results identical):

  • Aweti, Mbugwe, Sena, Amharic, Indonesian: 0%. Conformance suite (1,492 words): 0.23%.
  • Synthetic stress fixtures: 3.2% on the brief's fixture (below its 25% kill bar), and 31.3% and 19.8% on two dense-exclusion fixtures added later.
  • It is the only experiment of the round that cuts analysis events, because it prunes an analysis subtree where the forbidden pair completes.
  • It checks Exclude + Anywhere morpheme and allomorph co-occurrence rules, indexed per morpheme when Morpher is built.

Not known: whether any owner grammar has dense exclusions. FieldWorks projects that use ad hoc co-prohibitions to suppress spurious parses are the likely candidates (inferred).

Proposed change: keep the check behind a flag. Run it on any grammar with many exclusions and record the step counts before and after. Do not merge unless a real grammar shows a reduction in work steps.

Related:

  • PanGloss: pointer sillsdev/PanGloss#104 (no port of E4).
  • sillsdev/machine#490 (closed PR, the retired record); #601 (the other rejected candidates).

Next: find a grammar with many exclusion rules and count analysis work with the flag off and on.


Evidence -- E4 results, total work
Corpus Analysis events, off to on Synthesis steps, off to on Less total work
Aweti, Mbugwe, Sena, Amharic, Indonesian unchanged unchanged 0%
Conformance (1,492 words) 27,765 to 27,705 8,246 to 8,223 0.23%
stress-excluded-cooccurrence (the brief's fixture) 4,690 to 4,605 326 to 250 3.2%
stress-athabaskan-prefix-complex 8,937 to 6,347 891 to 404 31.3%
stress-bantu-extension-chain 10,552 to 8,548 515 to 332 19.8%

Hooks: rules that name only affixes are checked after unapplying; rules that name a root are checked per alternative after lookup. Soundness holds under Anywhere (anti-monotone), with these restrictions: an "other" counts only if its recorded allomorph always leaves a morph annotation; Somewhere*, Adjacent* and Require stay late. Landing findings: merged analyses must be filtered per alternative, not on the canonical word; with pruning on, MaxAlternatives counts fewer candidates, so its exception can stop firing; the rule index is read at construction, so a rule added later is not pruned early. Open question: whether synthesis phonological deletion removes morph annotations, which would extend the zero-width restriction.

The code is on an unpushed branch (perf/hc-excluded-cooccurrence at 02873608), not on GitHub.

What would reopen this

A real grammar with dense exclusions in which the flag-on run cuts analysis events plus synthesis steps by a meaningful share, with unchanged parses.

Sources -- pinned, from the closed PR #490
Lenguaje dominante
C#
Estrellas
29
Forks
16
Merge medio
4 d 11 h
PR fusionados (30 d)
14

Preparar el entorno

  • Sin Dockerfile ni archivo de Docker Compose
  • Tiene una plantilla de pull request
  • Sin guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de sillsdev/machine

Todos los issues de sillsdev/machine

Issues similares

Más issues de C#

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.