openpencil/apps/web
Fini e34d491cb4 fix(ai): restore exact-keyword matches lost in word-boundary regex tightening
The previous ranking fix added \b boundaries to fight substring traps
(\"Featured\" → red, \"Healthy\" → wellness in a food category list),
but in the process I dropped several exact domain keywords that were
NOT substring traps and that legitimate briefs use:

- \"code\" (developer brief: \"code editor\", \"VS Code app\") — was
  silently removed; now restored as `\\bcode\\b` so it matches the
  standalone word but still won't trip on \"decoder\" / \"encode\".
- \"health\" / \"healthy\" (wellness brief: \"design a healthy
  lifestyle app\") — was lost; restored as `\\bhealth\\b` /
  `\\bhealthy\\b`. The food-category-list \"Healthy\" still matches
  too, but that's a smaller harm than missing genuine wellness briefs
  — and the rest of the ranking fix (industry tag weight 30, platform
  mismatch -30) keeps mobile food guides above desktop wellness guides
  even when both are tagged.

Also restored derivative forms that earlier substring matches caught
by accident (modern → modernist/contemporary, luxury → luxurious,
brutal → brutalist/brutalism, minimal → minimalist) and broadened
each domain block with common synonyms so we don't regress brief
coverage on real prompts:

- food: + menu, diner, kitchen, dining, eatery, cafe/café
- finance: + trading, wallet, crypto, budget, expense
- developer: + api, engineering, dev (alongside restored code)
- wellness: + wellbeing, spa, gym, exercise, workout (alongside
  restored health/healthy)
- accents: each color block expanded with common synonyms
  (orange→peach/amber/tangerine, blue→navy/sapphire/cobalt,
  green→emerald/sage/mint, gold→golden/brass, red→ruby).

Verified end-to-end with 5 representative briefs:
- Food brief still puts warm-food-mobile-light in top-4
- \"Healthy lifestyle\" wellness brief now picks wellness-green-mobile
- \"code editor\" developer brief picks developer-terminal-dark
- Modernist brand picks ecommerce-modern-light
2026-04-29 09:50:47 +08:00
..
public V0.5.0 (#67) 2026-03-22 09:44:04 +08:00
server feat(element-tools): add 11 v1 tools with theme parameter (P3 batch 9 — FINAL) 2026-04-29 09:50:29 +08:00
src fix(ai): restore exact-keyword matches lost in word-boundary regex tightening 2026-04-29 09:50:47 +08:00
CLAUDE.md V0.7.0 (#95) 2026-04-11 23:25:13 +08:00
components.json V0.7.0 (#95) 2026-04-11 23:25:13 +08:00
dev.ts V0.7.2-bugfix (#109) 2026-04-14 21:42:56 +08:00
package.json chore(release): bump to v0.8.0 2026-04-27 08:20:00 +08:00
tsconfig.json V0.7.2-bugfix (#109) 2026-04-14 21:42:56 +08:00
vite.config.ts feat(ab-corpus): retry transient errors on ark + deepseek 2026-04-29 07:15:00 +08:00