Yes what you say there is very much the ethos around comments on StackExchange – that, and preferring to post a comment instead of editing each other’s answers.
This isn’t only an SE clone/replacement though, is it? But more general.
So IMO the use case, people meet online to discuss drafts of a document – and may or may not eventually produce a “final” version.
But, I don’t know, look at Parliament – they pass written legislation eventually after talking about it, but there are wonks (possibly including judges sometimes, I don’t know) who want to look behind the document and see the intent: whose idea was this? what did this bit mean, exactly? was it important, can I change it? and so on.
This functionality might not be for an initial MVP.
I’d like to propose it though as an inherent capability of the software, while we’re “brainstorming”. There might be a simple way to implement it – possibly by version controlling the lot, plus being able to assign moderator-like privileges to some user[s] but limited the scope of that to a specific document (i.e. not site-wide), so they can control the commentary.
Of the first 4 bullet points (i.e. “section headings, anchors, TOC, comment on sections”), the first three might be fairly localised, features of the markdown editor/converter.
It’s the last one – i.e. “comment on sections” – that’s the wildcard in terms of the “database schema” given that we’d also want to be able to edit the document, rearrange its sections. There’s the rub, perhaps, and how obviously to implement that I suppose might depend on what kind of database it is (“relational” or “document-oriented” or some hybrid).