Operator: new products / edited descriptions should auto-file into the
shop's existing categories without manual tagging.
- lib/tag_suggest.py:auto_hydrate_tags(dbsession, product) — stem-match
title+description against the shop's EXISTING tag names (reuses
tokenize/simple_stem; every stem of the tag name must be in the
product stem set, so unigram 'Holiday' and phrase 'First Grade' both
work). ADDITIVE (never removes), IDEMPOTENT, never CREATES tags
(inventing categories stays suggest-then-approve).
- views/product.py:_auto_hydrate_and_flash wired into product_new
(create), product_edit_description (markup desc editor), and
product_edit (when title/desc changed, AFTER the explicit comma-tag
sync so it's purely additive).
- Tests: TestAutoHydrateTags (3, integration) +
test_new_product_auto_hydrates_existing_tag /
test_edit_description_auto_hydrates_existing_tag (functional).
1145 passed.
- Docs: CLAUDE.md (auto-apply-existing vs never-auto-CREATE
distinction), mps-24.md Phase 2.8n.