nvflare-convert-lightning
NVFLARE Convert PyTorch Lightning
Use When
Use only when the user asks to convert PyTorch Lightning code into an NVFLARE federated training job; require both federation intent and Lightning ownership. Treat requests for multiple sites or institutions to train collaboratively while each site's data remains local as federation intent, even when the request does not say "federated" or "NVFLARE."
Lightning source evidence alone is not sufficient. Relevant source may contain a LightningModule, LightningDataModule, a Trainer fit/validate/test loop,
Lightning callbacks, checkpointing, or loggers.
Supported: the PyTorch recipe family with flare.patch(trainer) as the model
exchange integration, Lightning-native evaluation, custom aggregation through
the same recipe aggregator= hook, and local validation and export.
Standard Path
Always read this converter SKILL.md with
../nvflare-shared/references/conversion-common.md. For an explicit-FedAvg
conversion, load only these references, in workflow order: