generate type info dynamically