Yes, but not neatly. We can go back through visited, which has all the plugin instances. From the plugin instances we could figure out the file the plugin is defined in by the (file, instance) pairs in v6_dependency_solver.

We could also store (file, instance) pairs in attribute[:providers], or add a source() method to the Plugin class that might look like:

def source(path='')
  if path.empty?
    @path
  else
    @path = path
  end
end

so Ohai::Loader can set plugin.source(plugin_path) and Ohai::System can get plugin.source. Could also separate out into set_source() and get_source().

Just some ideas...