feat: glob-based overlay discovery via OVERLAY_PATTERN#28
Open
feat: glob-based overlay discovery via OVERLAY_PATTERN#28
Conversation
Allow overlays to live in arbitrary nested directory structures (e.g. cell_masks/<cohort>/<slide>.svs/cell_masks.bin) by specifying a glob pattern. The server scans at startup, builds a slide_id → path index, and strips known slide extensions (.svs, .ndpi, etc.) so overlay IDs match slide IDs. When OVERLAY_PATTERN is unset, existing OVERLAY_DIR behavior is preserved unchanged. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
OVERLAY_PATTERNenv var to discover overlay files across arbitrary nested directory structures using glob patternsHashMap<String, PathBuf>index (slide ID → overlay file path).svs,.ndpi, etc.) from parent directory names so overlay IDs match slide IDsOVERLAY_PATTERNis unset, existingOVERLAY_DIRbehavior is preserved unchangedUsage
Test plan
cargo checkcompilescargo test— all 65 tests pass (28 unit + 37 integration)🤖 Generated with Claude Code