Skip to content

init can generate room names that mine then misroutes #108

@bernatfortet

Description

@bernatfortet

Summary

mempalace init can generate a mempalace.yaml from folder structure that looks reasonable, but mempalace mine later routes files into the wrong rooms when using that saved config.

I ran into this on a real repo (dreambooks-v2) and it looks like the generated room names are not stable with the miner's router.

What init generated

Running:

mempalace init ~/Dev/dreambooks-v2

produced auto-detected rooms like:

  • configuration
  • testing
  • documentation
  • frontend
  • backend
  • scripts
  • lib
  • convex
  • app
  • general

Repro / observed behavior

Using the auto-generated room set, these files were routed unexpectedly:

  • components/ui/button.tsx -> lib
  • docs/book-scrape-queue-lifecycle.md -> general
  • tests/queue-lease.test.ts -> scripts
  • components/books/BookPageClient.tsx -> convex

Some routes looked fine:

  • convex/books/queries.ts -> convex
  • app/api/search/books/route.ts -> app

But overall the generated taxonomy was not usable because several obvious path-based files landed in unrelated rooms.

Expected

If init generates rooms from folder structure, I would expect those same folders to route predictably during mine.

Examples:

  • docs/... should not fall into general when documentation was generated from docs/
  • tests/... should not route to scripts
  • components/... should not route to convex or lib

Actual

The saved room config and the miner seem to disagree about how room matching should work, so a config generated by init is not reliably consumed by mine.

Why I think this is happening

From local inspection, it looks like:

  1. init detects rooms from folder names and also generates useful keywords/descriptions.
  2. mempalace.yaml only saves name + description.
  3. mine then routes based mostly on fuzzy matching against the saved room names, not the original folder-derived keywords.

That makes auto-renamed rooms like docs -> documentation and components -> frontend especially fragile.

Request

It would help if one of these were true:

  • init saved the routing keywords it used to detect the room
  • mine used exact folder-origin metadata from the generated config
  • auto-generated room names stayed path-stable (docs, tests, components, etc.) unless the router can honor aliases safely

Happy to provide the generated mempalace.yaml or help test a fix.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions