- Drift 21 tables (8 catalog + 11 user + habit_dose_variants + meta_kv) with R1~R10 CHECK constraints and 19 indexes - 8 hand-crafted seed JSON catalogs in app/assets/seed/ (refs 84, protocols 34, methodologies 21, frame_patterns 30, reward_menu_items 30, break_protocols 8, common_frames 5, diet_patterns 5) - 6 domain functions: recommend_variant, compute_streak, validate_frame_level, active_habit_quota, weekly_minimum_ratio, seed_importer (transactional, idempotent) - 4 vertical-slice Riverpod screens: HabitList, HabitCreate, CheckIn, Streak - 31 unit tests passing; flutter analyze clean - OQ-5 streak semantics: missing entry ≠ explicit blank (missing = end of history; only TrackerValue.blank triggers Never-miss-twice) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
66 lines
3.5 KiB
Markdown
66 lines
3.5 KiB
Markdown
# SEED-NOTES — life-helper seed extraction
|
||
|
||
Generated: 2026-06-12. Source-of-Truth files extracted into 8 JSON seeds at `seed-staging/`.
|
||
|
||
## Row counts
|
||
|
||
| File | Entries |
|
||
|---|---|
|
||
| `references.json` | 84 |
|
||
| `protocols.json` | 34 |
|
||
| `break_protocols.json` | 8 |
|
||
| `common_frames.json` | 5 |
|
||
| `methodologies.json` | 21 |
|
||
| `frame_patterns.json` | 30 |
|
||
| `reward_menu_items.json` | 30 |
|
||
| `diet_patterns.json` | 5 |
|
||
|
||
## Validation status
|
||
|
||
- Required-field violations: **0**
|
||
- `additionalProperties: false` violations: **0**
|
||
- Enum violations (RewardTier, FrameDomain, EvidenceStrength, huberman_fit_score 1..5, BreakCategory): **0**
|
||
- Orphaned `reference_ids[]` (pointing to non-existent reference): **0**
|
||
- Orphaned `default_common_frames[]` (break → common): **0**
|
||
- Orphaned `linked_protocol_ids[]` (diet pattern → protocol): **0**
|
||
- Orphaned `applicable_break_categories[]` (common → BreakCategory): **0**
|
||
|
||
## Unused references (5)
|
||
|
||
These references are valid but not yet cited from any entry because their hosting schemas
|
||
(`frame_pattern`, `reward_menu_item`) do not currently expose a `reference_ids[]` field.
|
||
They back the language-framing and reward-system theoretical foundation. Keep them — do
|
||
not prune.
|
||
|
||
- `ref_book_lakoff_elephant` — Lakoff (2004) *Don't Think of an Elephant!* → frame_patterns rationale
|
||
- `ref_doi_10_1037_0022_3514_53_1_5` — Wegner et al. (1987) White Bear / ironic process → frame_patterns + urge_surf
|
||
- `ref_doi_10_1037_0033_2909_125_6_627` — Deci, Koestner & Ryan (1999) overjustification meta → reward_menu_items
|
||
- `ref_doi_10_1146_annurev_psych_122414_033417` — Wood & Rünger (2016) habit conditioning → reward_menu_items
|
||
- `ref_doi_10_1207_s15326985ep3403_3` — Elliot (1999) approach vs avoidance → frame_patterns
|
||
|
||
## Decisions / notes
|
||
|
||
1. **Korean preserved verbatim.** Section symbols (§), em-dashes, full-width punctuation
|
||
left as in source. No translation or normalization of body text.
|
||
2. **`omit` not `null`.** Missing optional fields are absent (not present with `null`).
|
||
3. **Methodology `is_core_engine: true`** applied only to `atomic_habits`,
|
||
`tiny_habits`, `implementation_intentions` per project memory
|
||
(`feedback_sustainable_minimal.md`).
|
||
4. **Break protocols** mapped the 4-week SoT structure into the schema's `phases[]`
|
||
array with `week`, `goal`, `environment_design`, `if_then_examples`.
|
||
5. **`frame_patterns.json`** sourced from the "흔한 끊기 목표 변환 30선" table at
|
||
`habit-todo-methodologies.md` lines 922–955. `domain` enum chosen from
|
||
{food, drink, smoking, screen, porn, sleep, exercise, general}.
|
||
6. **`reward_menu_items.json`** sourced from "권장 리워드 메뉴 30선" lines 804–844.
|
||
`tier_recommended` mapped T0–T4. `avoid_for_break_habits` populated where the
|
||
reward involves caffeine/sugar/alcohol so it can collide with an active break habit.
|
||
7. **`diet_patterns.json`** kept to the 5 patterns explicitly enumerated in
|
||
`diet-protocols.md` §2.1–§2.5. TRE/IF body in source is a stub pointer to §1.5;
|
||
description was reconstructed from that section. `linked_protocol_ids[]` cross-links
|
||
to the six `category: "diet"` protocols in `protocols.json`.
|
||
8. **No sections skipped.** All §1–§5 of every SoT are represented in some entry.
|
||
§6 (한국어 해설자) of `diet-protocols.md` is intentionally not seeded — it is a
|
||
user-fillable slot per project memory (`project_nutrition_module.md`).
|
||
9. **`reference_ids[]` ID style** used: `ref_doi_<doi-with-_>`, `ref_url_<slug>`,
|
||
`ref_book_<author>_<slug>`, `ref_podcast_<show>_<ep>_<slug>`.
|