Skip to content

feat: mouthfeel map colours, taste namespacing, cross-listed terms, full head coverage - #248

Merged
rvnminers-A-and-N merged 1 commit into
mainfrom
feat/ui-map-mouthfeel-and-cross-listing
Jul 29, 2026
Merged

rvnminers-A-and-N merged 1 commit into
mainfrom
feat/ui-map-mouthfeel-and-cross-listing

Conversation

@rvnminers-A-and-N

Copy link
Copy Markdown
Collaborator

Closes #241. Part of #240. Follows #247.

Five related pieces, each verified against the running app rather than assumed β€” which is how the head-coverage bug below got caught.

Full head coverage β€” three heads were silently invisible. The design index only ever tagged sweet/bitter/umami, so sour, salty and tasteless were trained heads the UI pretended didn't exist. It now iterates every trained taste head, and all six are offered unconditionally (the rule aroma already used, so a head with few confident carriers stays selectable rather than vanishing). Verified live: taste:sour β†’ acetic/citric acid, taste:salty β†’ potassium chloride, taste:tasteless β†’ 138 matches. Audit now reads taste 6/6, aroma 164/164, mouthfeel 5/5.

Tox heads accounted for, in the right role. The 12 Tox21 heads are not design targets β€” nobody formulates for assay activity β€” so making them pickable would be wrong. They surface instead as a "hide tox-flagged" filter plus a per-result ⚠ N tox flags marker, caution-only framing intact. All 187 heads now have a role.

Taste namespacing (taste:sweet), matching mouthfeel. sweet is both a taste head and an aroma head, and a bare tag conflated "tastes sweet" with "smells sweet"; bitter had additionally leaked into the aroma-notes picker. Verified distinct: taste:sweet β†’ citric acid, coumarin Β· aroma sweet β†’ benzaldehyde, butanol.

Map colours by mouthfeel — build_flavor_map labels each molecule with its dominant sensation; new mode beside taste/aroma/both with cool→warm swatches. Rebuilt to 8,834 points, 100 mouthfeel-labelled.

Cross-listing (#241). Rather than blanket-linking (most non-overlap is legitimate β€” there's no aroma head for "bacon", nobody orders "amber flavor"), aliases cover terms that are genuinely the same thing spelled differently: 5 auto-derived by normalisation (black pepper↔blackpepper, bread↔bready, butter↔buttery, cream↔creamy, malt↔malty) so new vocabulary keeps linking itself, plus 10 curated synonyms (blackcurrant↔cassis, tangerine↔mandarin, orange blossom↔neroli, cilantro↔coriander, chocolate↔cocoa, licorice↔anise, cheese↔cheesy, smoke↔smoky, peppermint/spearmint↔minty). Deliberately excludes lemon↔citrus β€” citrus is broader, and equating them would silently widen a search. Verified symmetric: both sides of each pair return identical match counts.

Tingling generalisation (#247). The head was memorising: trained only on Zanthoxylum sanshools it fired on exactly its own training molecules β€” a lookup table wearing a 1.00 AUROC. Broadened with paresthesia amides from other genera (Echinacea, Anacyclus, Heliopsis, Piper) for structural diversity rather than more of the same scaffold: 11 β†’ 18 positives, 0 β†’ 2 novel hits; pungent also improved 5 β†’ 12 novel. docs/MOUTHFEEL.md gains a "Does a head generalize, or is it memorizing?" section with the measured table β€” a high AUROC alone proves nothing. #247 stays open to broaden tingling further; it's still the weakest of the five and the docs say so.

ruff check . clean and 25 unit tests pass.

…ull head coverage

Five related pieces, all verified against the running app rather than assumed.

MAP: build_flavor_map now labels each molecule with its dominant trigeminal sensation, and the
map gains a "mouthfeel" colour mode beside taste/aroma/both (cool-to-warm swatches). Rebuilt:
8,834 points, 100 mouthfeel-labelled.

TASTE NAMESPACING: taste tags are namespaced (taste:sweet) exactly as mouthfeel is, because
`sweet` is both a taste head and an aroma head and a bare tag conflated "tastes sweet" with
"smells sweet" β€” `bitter` had additionally leaked into the aroma-notes picker. Verified distinct:
taste:sweet -> citric acid, coumarin; aroma sweet -> benzaldehyde, butanol. Both pickers gained a
Taste group; the now-redundant "Base taste" note family is gone.

FULL HEAD COVERAGE: the design index only ever tagged sweet/bitter/umami, so sour, salty and
tasteless were silently unselectable β€” three trained heads the UI pretended didn't exist. It now
iterates every trained taste head, and all six are offered unconditionally (the rule aroma already
used, so a head with few confident carriers stays visible). Verified: taste:sour -> acetic/citric
acid, taste:salty -> potassium chloride, taste:tasteless -> 138 matches.

TOX HEADS ACCOUNTED FOR: the 12 Tox21 heads are not design targets β€” nobody formulates *for* assay
activity β€” so they surface instead as a "hide tox-flagged" filter plus a per-result flag marker,
with caution-only framing. All 187 heads now have a role in the UI.

CROSS-LISTING (#241): flavor<->note aliases for terms that are the same thing spelled differently.
Auto-derived by normalisation (black pepper<->blackpepper, bread<->bready, butter<->buttery,
cream<->creamy, malt<->malty) so new vocabulary keeps linking itself, plus ten curated synonyms
(blackcurrant<->cassis, tangerine<->mandarin, orange blossom<->neroli, cilantro<->coriander,
chocolate<->cocoa, licorice<->anise, cheese<->cheesy, smoke<->smoky, pepper/spearmint<->minty).
Deliberately excludes lemon<->citrus: citrus is broader, and equating them would silently widen a
search. Verified symmetric β€” both sides of each pair now return the same match count.

TINGLING GENERALISATION (#247): the head was memorising β€” trained only on Zanthoxylum sanshools it
fired on exactly its training molecules and nothing else, a lookup table wearing a 1.00 AUROC.
Broadened with paresthesia amides from other genera (Echinacea, Anacyclus, Heliopsis, Piper) for
structural diversity rather than more of the same scaffold: 11 -> 18 positives, 0 -> 2 novel hits.
pungent also improved 5 -> 12 novel. docs/MOUTHFEEL.md gains a "Does a head generalize, or is it
memorizing?" section with the measured table; #247 tracks broadening tingling further.

Signed-off-by: Austin L. <86896075+rvnminers-A-and-N@users.noreply.github.com>
@rvnminers-A-and-N
rvnminers-A-and-N merged commit 5318831 into main Jul 29, 2026
4 checks passed
@rvnminers-A-and-N
rvnminers-A-and-N deleted the feat/ui-map-mouthfeel-and-cross-listing branch July 29, 2026 08:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

data(ui): cross-list dual-purpose molecules so every unique flavor/note yields a chip in BOTH menus

1 participant