Skip to content

fix: room detection checks keywords against folder paths#145

Merged
bensig merged 1 commit intomainfrom
fix/room-keyword-path-matching
Apr 7, 2026
Merged

fix: room detection checks keywords against folder paths#145
bensig merged 1 commit intomainfrom
fix/room-keyword-path-matching

Conversation

@bensig
Copy link
Copy Markdown
Collaborator

@bensig bensig commented Apr 7, 2026

Summary

detect_room() now matches folder path parts against room keywords, not just the room name. Previously, files in docs/ would route to general instead of documentation because "docs" is not a substring of "documentation".

Now the keywords list (persisted in mempalace.yaml since #119) is checked during path matching: docs/ matches keyword "docs" → routes to room "documentation".

Found during end-to-end testing after merging the keyword persistence fix.

Test plan

  • ruff check . / ruff format --check . pass
  • pytest tests/ -v — 27/27 pass
  • Manual: mempalace init --yes + mempalace mine correctly routes docs/ files to documentation room

detect_room() now matches folder path parts against room keywords,
not just the room name. Fixes docs/ files routing to general instead
of documentation room — "docs" wasn't a substring of "documentation"
but is now matched via the persisted keywords list.

Found during end-to-end testing after merging #108 keyword persistence.
@bensig bensig merged commit 559417e into main Apr 7, 2026
4 checks passed
@bensig bensig deleted the fix/room-keyword-path-matching branch April 10, 2026 16:26
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