I'll be blunt: I think that this is an absolutely awful idea. But if you really want to do it, don't reinvent the wheel. There is already a Markdown extension that does all of what you want: maruku with the itex library for mathematics. That's the input format for the instiki wiki (which is what http://ncatlab.org
runs on) and I'd love to hear of a feature that was missing from that!
Why I think it is an awful idea is that it mixes up input
formats and transition
formats. An input format is whatever I use to directly write a document. I personally use LaTeX. This should be as rich
as possible to ensure that it has maximum ability for an author to write what they mean to write. Of course, not everyone takes advantage of this but when someone does it makes it easier to translate it to another format. Such as a transition
format. This is a format that the input is converted to for storage or transmission. This should still be rich
but now flexibility becomes a disadvantage. A transition format will likely be retranslated to an output
format before being shown to the reader but the key is that this might happen at some time or location unbeknownst to the original author and in a manner that they didn't anticipate. So the transition format needs to be rigid in that it must be as difficult as possible to misunderstand something. XML is a reasonable transition format.
Markdown is very definitely an input format. It does not have the richness to be a transition format. When I convert stuff from LaTeX to Markdown (as I do when I write blog posts on Wordpress installations) then I very definitely lose semantic information.
What seems to be the proposal here is to convert Markdown into a transition format because it is easier to write
. But that is precisely why it shouldn't be such! By making it a transition format you kill off the only good thing about it: that it is easy to write. Yes, when writing comments on StackOverflow then it's great to use Markdown. But when writing articles then it is a pain and I switch to LaTeX readily.
But note that I'm not proposing XML for an input
format either. It is a transition format.
In summary, in an ideal world an author could select whichever
input format they liked, be it LaTeX, Word, or Markdown. That would then get translated to an open standard transition format, such as XML, for storage. Then that transition format could be transformed into any suitable output format: PDF, display on screen, read by a screen reader, braille, ...