code: func (n *NodeAbstractResourceInstance) ProvidedBy() (addrs.AbsProviderConfig, bool) {
  	// If we have a config we prefer that above all else
  	if n.Config != nil {
  		relAddr := n.Config.ProviderConfigAddr()
  		return relAddr.Absolute(n.Path()), false
  	}
  
  	// If we have state, then we will use the provider from there
  	if n.ResourceState != nil {
  		// An address from the state must match exactly, since we must ensure
  		// we refresh/destroy a resource with the same provider configuration
  		// that created it.
  		return n.ResourceState.ProviderConfig, true
  	}
  
  	// Use our type and containing module path to guess a provider configuration address
  	return n.Addr.Resource.DefaultProviderConfig().Absolute(n.Path()), false
  }
docs: // GraphNodeProviderConsumer