Serving markdown content isn't a niche, within the set of what gollum does.
I honestly don't understand what "aggregating/associating" you're talking about, that isn't possible in a regular markdown wiki (eg using gollum, but also several other md based wiki tools).
As for suggestions - if your tool is specifically aiming to be lightweight, use a lightweight db, like SQLite.