Flexible semantic form framework