Instead of adding custom fields to the device model, you can create a new model that models host software version.
I do something similar with ACL to interface assignments. It is not 100% like your model because I have an ACL linked to only 1 host(vm, device, virtual_cluster), and than that said ACL can be assigned any interface assigned to that "host"
https://github.com/ryanmerolle/netbox-acls/blob/dev/netbox_acls/models/access_lists.py#L90-L155
Instead of adding custom fields to the device model, you can create a new model that models host software version.
I do something similar with ACL to interface assignments. It is not 100% like your model because I have an ACL linked to only 1 host(vm, device, virtual_cluster), and than that said ACL can be assigned any interface assigned to that "host"
https://github.com/ryanmerolle/netbox-acls/blob/dev/netbox_acls/models/access_lists.py#L90-L155