Add types.go under lib/proto