I have considered similar tools that make use of MarkDown syntax, I feel that there are many tools waiting to be written here.
[1] https://github.com/yshavit/mdq
Based on documentation, you can mdq for the chapter whose heading is "## Foobar"; or extract all lists in chapter "### Xyzzy".
Thanks, abound!
Update: mdq discussion https://news.ycombinator.com/item?id=43152704
[1] https://github.com/yshavit/mdq