Skip to content

fix: batch semantic link apply checkpoints - #281

Merged
acidkill merged 1 commit into
mainfrom
fix/semantic-apply-checkpoint-batch
Sep 25, 2026
Merged

acidkill merged 1 commit into
mainfrom
fix/semantic-apply-checkpoint-batch

Conversation

@acidkill

Copy link
Copy Markdown
Owner

Summary

  • Checkpoint semantic-link synapse application in groups of at most 50 candidates.
  • Flush partial groups before budget pauses and retain resumable cursor/counters.
  • Add interruption, payload-size, lease-loss, and changed-row regression coverage.

Why

The apply stage rewrote the full pending manifest after each synapse, amplifying checkpoint traffic for large candidate sets. Bounded groups reduce repeated payload writes while preserving the per-candidate budget check and the existing idempotent replay/source-fence protections.

Test plan

  • pytest tests/ -m "not stress" against disposable local SurrealDB 3.2.4: 7,867 passed, 50 skipped, 32 deselected, 1 xfailed.
  • ruff check src/ tests/ clean.
  • ruff format --check src/ tests/ clean.
  • mypy src/ --ignore-missing-imports clean.
  • Focused semantic-link resume module: 38 passed.
  • Disposable database and sanitized environment; no production endpoint used.

Verified by

@acidkill.

@acidkill
acidkill merged commit 74580b9 into main Sep 25, 2026
9 checks passed
@acidkill
acidkill deleted the fix/semantic-apply-checkpoint-batch branch September 25, 2026 07:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant