See Cap'n Proto homepage for more details about the data format.
The compiler requires the capnp tool in your PATH.
It can be run with:
java -jar capnpc-scala.jar file1.capnp file2.capnp
You need to add the package and module annotations from scala.capnp to your schema.