Take a look at how Nushell does this, it's quite neat: https://www.nushell.sh/book/custom_commands.html#documenting...

That's excellent. Somewhat similar to the syntax I went with, but most likely much better implemented. I'm going to give it a go. Thank you!