add module definition in codegenProgram
- fix type errors for params creation
correct types for param list