mirror of
https://github.com/ksyasuda/SubMiner.git
synced 2026-02-27 18:22:41 -08:00
chore(task-85): update launcher workflow and backlog tracking
This commit is contained in:
@@ -4,7 +4,7 @@ title: Refactor large files for maintainability and readability
|
||||
status: In Progress
|
||||
assignee: []
|
||||
created_date: '2026-02-19 09:46'
|
||||
updated_date: '2026-02-19 10:01'
|
||||
updated_date: '2026-02-20 11:42'
|
||||
labels:
|
||||
- architecture
|
||||
- refactor
|
||||
@@ -31,14 +31,24 @@ Several core files are oversized and high-coupling (`src/main.ts`, `src/anki-int
|
||||
|
||||
<!-- SECTION:PLAN:BEGIN -->
|
||||
1. Add file-budget guardrails and baseline report.
|
||||
2. Split `src/main.ts` into runtime domain modules.
|
||||
3. Split `src/anki-integration.ts` into focused collaborators.
|
||||
4. Split `src/config/service.ts` by load/migrate/validate/warn phases.
|
||||
2. Split `src/main.ts` into runtime domain modules (ongoing; major wiring extracted).
|
||||
3. Split `src/anki-integration.ts` into focused collaborators (started; constructor composition decomposed).
|
||||
4. Split `src/config/service.ts` by load/migrate/validate/warn phases (started; load/apply flow decomposition in place).
|
||||
5. Split immersion tracker service by state, persistence, sync responsibilities.
|
||||
6. Clarify generated launcher artifact workflow and docs.
|
||||
7. Run full build/test gate and publish maintainability report.
|
||||
<!-- SECTION:PLAN:END -->
|
||||
|
||||
## Progress Notes
|
||||
|
||||
<!-- SECTION:PROGRESS:BEGIN -->
|
||||
- 2026-02-20: Large `src/main.ts` composition slices extracted into runtime handler modules (startup, CLI, tray/window/bootstrap, shortcuts, OSD/secondary-sub, numeric/overlay shortcut lifecycle, and related seams) with focused parity tests.
|
||||
- 2026-02-20: `src/anki-integration.ts` constructor decomposed into targeted private factory/config methods (`normalizeConfig`, `createKnownWordCache`, `createPollingRunner`, `createCardCreationService`, `createFieldGroupingService`) to reduce orchestration complexity.
|
||||
- 2026-02-20: `src/config/service.ts` load/apply duplication reduced by introducing `applyResolvedConfig`, `resolveExistingConfigPath`, and `parseConfigContent`.
|
||||
- Validation checkpoint: `bun run build` and focused suites (`dist/config/config.test.js`, `dist/anki-integration.test.js`) passing.
|
||||
- Current strategy: prioritize high-ROI extractions (behavioral seams and churn-heavy hotspots) over further low-impact micro-shuffles.
|
||||
<!-- SECTION:PROGRESS:END -->
|
||||
|
||||
## Acceptance Criteria
|
||||
<!-- AC:BEGIN -->
|
||||
- [ ] #1 `src/main.ts` reduced to orchestration-focused module with extracted runtime domains
|
||||
|
||||
@@ -0,0 +1,46 @@
|
||||
---
|
||||
id: TASK-88
|
||||
title: Remove MeCab fallback tokenizer and simplify Yomitan token flow
|
||||
status: To Do
|
||||
assignee: []
|
||||
created_date: '2026-02-20 00:00'
|
||||
labels:
|
||||
- tokenizer
|
||||
- refactor
|
||||
dependencies: []
|
||||
priority: medium
|
||||
---
|
||||
|
||||
## Description
|
||||
|
||||
<!-- SECTION:DESCRIPTION:BEGIN -->
|
||||
Remove the MeCab fallback tokenization path and associated merge-selection complexity in subtitle tokenization. Treat Yomitan parser output as the single source of token boundaries/grouping, and keep only minimal normalization needed for downstream known-word, JLPT, and frequency annotation.
|
||||
<!-- SECTION:DESCRIPTION:END -->
|
||||
|
||||
## Action Steps
|
||||
|
||||
<!-- SECTION:PLAN:BEGIN -->
|
||||
1. Remove MeCab fallback execution from `tokenizeSubtitle` and delete dead fallback-specific branches.
|
||||
2. Remove merge/candidate-selection code that is only needed to reconcile MeCab-vs-Yomitan tokenization strategies.
|
||||
3. Keep Yomitan parsing pipeline with minimal structural token normalization only.
|
||||
4. Update MeCab usage so it is no longer required for tokenization fallback (retain only explicitly needed behavior, if any).
|
||||
5. Update docs/config notes to reflect Yomitan-only tokenization flow.
|
||||
6. Add regression tests for Yomitan-only success/failure paths and token annotation continuity.
|
||||
<!-- SECTION:PLAN:END -->
|
||||
|
||||
## Acceptance Criteria
|
||||
<!-- AC:BEGIN -->
|
||||
- [ ] #1 Subtitle tokenization no longer falls back to MeCab when Yomitan parsing fails.
|
||||
- [ ] #2 Token grouping logic is simplified to rely on Yomitan structure; redundant custom merge-selection logic removed.
|
||||
- [ ] #3 Known-word, JLPT, frequency, and N+1 annotations still work on Yomitan-derived tokens.
|
||||
- [ ] #4 If Yomitan parsing fails, behavior is explicit and tested (for example `tokens: null` without MeCab fallback path).
|
||||
- [ ] #5 Documentation reflects that tokenization flow is Yomitan-first and Yomitan-only.
|
||||
<!-- AC:END -->
|
||||
|
||||
## Definition of Done
|
||||
<!-- DOD:BEGIN -->
|
||||
- [ ] #1 `src/core/services/tokenizer.ts` no longer contains MeCab fallback tokenization branch.
|
||||
- [ ] #2 Tests cover Yomitan-only pipeline and failure behavior regressions.
|
||||
- [ ] #3 Any removed MeCab-only merge helpers are deleted with no unused exports/imports.
|
||||
- [ ] #4 Build and relevant tokenizer/subtitle tests pass.
|
||||
<!-- DOD:END -->
|
||||
Reference in New Issue
Block a user