1. A method for converting a first document to a second document, the method comprising the steps of: specifying the first document in terms of a first extended attribute grammar; specifying the second document in terms of a second extended attribute grammar; specifying an extended attribute coupling grammar of the first and second extended attribute grammars; and transforming the first document into the second document based on the extended attribute coupling grammar.