Serialize value parameter indices on JVM

This will help to load annotations on value parameters
Deserialize annotations on value parameters of functions