This should work. Drush bootstraps Drupal before discovering module commands, so the first step is to make sure your commands are defined in a
drush.services.yml file as usual.
From there, you should be able to define dynamic options using hook options. Since Drush bootstraps Drupal prior to discovering module commands, you should find that the Drupal site is always bootstrapped when your hook is called. You can inject the services you need through your
EDIT When I read through the comments I thought that you said this was working when you were using
hook_drush_command, so I answered as if you were asking how to convert and do the same thing in Drush 9. I don't remember the internals of the convoluted Drush 8 bootstrap very well, but I'm not sure this is possible in Drush 8.