I've got a couple questions:
Can it parse the document and generate a list of completions based on what you've typed? (Thomas' completion command does this very well.)
Can it do this on unsaved documents?
How are these rules defined? (the easier this is the better)