...
In the future, attribute descriptors may be used for other purposes besides metadata sharing. For instance, the Html Form Entry Designer module could use the descriptors to determine the valid attributes for a tag.
Custom Content for Velocity Context
If your module instantiates a Spring bean that implements org.openmrs.module.htmlformentry.velocity.VelocityContextContentProvider then your bean's populateContext() method will be called each time a new HTML Form is opened (for entry, view, or edit).
See an example from the Kenya EMR module on github.