Skip to content

[ponytail] Remove unreachable adaptive chunking #117

Description

@devinmlowe

Cut

Remove adaptive chunking. It is unreachable: no caller sets chunkingStrategy: "adaptive", the daemon passes {tier: "auto"}, smoke and the CLI pass "fixed", and config.dream.chunkingStrategy (from ENGRAM_CHUNKING_STRATEGY) is loaded but never threaded into extractFromConversation.

Findings

  • delete src/semantic/adaptive-chunker.ts (~245 lines with the items below)
  • delete the two cfg.chunkingStrategy === "adaptive" ternaries in src/semantic/extractor.ts:541
  • delete chunkingStrategy from ExtractionConfig, src/_core/types/index.ts:132 and src/_core/config/index.ts:129
  • drop ENGRAM_CHUNKING_STRATEGY from CLAUDE.md, README.md, .env templates and ensureServiceEnvFile
  • delete tests/contracts/chunking-contract.test.ts cases that only cover the adaptive path

Verification

npm run build and npm run test:run green before and after. engram extract on a real conversation still produces the same fixed chunks.

Activity

  1. devinmlowe commented on Sep 21, 2026

    @devinmlowe
    OwnerAuthor

    PR: #128

    Tests: 137 files / 1798 tests before → 136 files / 1780 tests after. Removed: tests/semantic/adaptive-chunker.test.ts (18 cases, all on the deleted module). Build green both sides. Real-DB check: fixed 25/5 boundaries identical to the persisted chunk_metadata rows for 8/8 conversations; all 1,322 stored rows already had NULL avg_density.

    Skipped (nothing to do): chunking-contract.test.ts has no adaptive-only cases (kept all five); ENGRAM_CHUNKING_STRATEGY was never in the env templates or ensureServiceEnvFile; no --chunking flag or chunkingStrategy pass-through existed in src/interfaces/cli or src/dream beyond smoke.ts; no ADR in decisions/ mentions adaptive chunking (plans/ got the superseded note instead).

  2. devinmlowe commented on Sep 21, 2026

    @devinmlowe
    OwnerAuthor

    Merged PR #128 into main with --no-ff (commit 0a5ed06). Post-merge on main: build clean, 136 test files / 1780 tests passing (was 137 / 1798; the 18 removed cases were the deleted adaptive-chunker suite).

  3. added a commit that references this issue on Sep 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    ponytailOver-engineering audit cut (2026-09-20)sub-issueChild task of a parent issue

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions