← Back to PRs

#16634: feat(memory-lancedb): make auto-capture min length configurable

by ciberponk open 2026-02-14 23:49 View on GitHub →
extensions: memory-lancedb size: S
## Summary - feat(memory-lancedb): make auto-capture min length configurable - Split from our `v2026.2.13` patch train as a single-purpose change for easier review. ## Why - Keep the diff focused and low-risk so it can be merged or reverted independently. ## Scope - Branch: `feat/memory-lancedb-configurable-capture-min-en` - Files changed: 4 - Key files: - `extensions/memory-lancedb/config.ts` - `extensions/memory-lancedb/index.test.ts` - `extensions/memory-lancedb/index.ts` - `extensions/memory-lancedb/openclaw.plugin.json` ## Test Plan - Suggested local command: - `./node_modules/.bin/vitest run extensions/memory-lancedb/index.test.ts` - Validation status: - [ ] CI checks pass - [ ] Maintainer re-ran local tests ## Risk & Rollback - Risk: low to medium; impact limited to touched module(s). - Rollback: revert this PR commit(s) cleanly. ## Co-authorship - Co-authored by @ciberponk and Codex (GPT-5). <!-- greptile_comment --> <h3>Greptile Summary</h3> Made the auto-capture minimum message length configurable via the `captureMinChars` parameter (default: 10, range: 1-1000). This allows users to customize when messages are automatically captured to memory based on their length preferences. - Added `captureMinChars` field to `MemoryConfig` type and config schema - Updated `shouldCapture()` function to accept configurable minimum via options parameter - Applied the configuration in the auto-capture hook by passing `cfg.captureMinChars` - Added validation ensuring the value is between 1 and 1000 - Included comprehensive test coverage for validation and functionality - Updated JSON schema and UI hints to expose the setting as an advanced option <h3>Confidence Score: 5/5</h3> - This PR is safe to merge with minimal risk - The changes are well-isolated to a single plugin, follow established patterns, include proper validation, have comprehensive test coverage, and maintain backward compatibility through sensible defaults - No files require special attention <sub>Last reviewed commit: ba0bd86</sub> <!-- greptile_other_comments_section --> <!-- /greptile_comment -->

Most Similar PRs