are regular ZIP archives, extra information gets stored as regular
files inside archive's "extra/" directory.
There's also a global hook allowing to attach extra files to any
TorchScript archive produced in the current process. It might be
useful to tag models with producer metadata, akin to JPEG metadata
produced by digital cameras. Example usage might look like:
SetExportModuleExtraFilesHook( {
       ExtraFilesMap files;
       files["producer_info.json"] = "{\"user\": \"" + getenv("USER") + "\"}";
       return files;
   });
Build environment considerations
TorchScript's compilation needs to have access to the original python
files as it uses python's "inspect.getsource" call. In certain
production environments it might require explicitly deploying ".py"
files along with precompiled ".pyc".
Common extension points
PyTorch APIs are generally loosely coupled and it's easy to replace a