Is using the target value in sample weights target leakage? If I'm training a regression model, and I want to weight the importance of each sample, is using (a function of) the target as the weight considered target leakage?  Does this depend on the particular model and how it uses sample weights?
 A: I would need an exact definition of how you are using the term "sample weights" to answer definitively, but in every example I can think of the answer is No.  The most common application of sample weights I can think of is weighting the loss function of the model.  The loss is already a function of the target value (otherwise how would you measure the error of the model).  For example, Mean Squared Error is:
$MSE=\frac{\sum{(predicted-target)^2}}{num-samples}$
Weighting the samples by the target value just includes the target in additional locations:
$wMSE=\frac{\sum{target*(predicted-target)^2}}{\sum{target}}$
The only other use of the term weighting I can think of in this context is if employing random sampling of your data to select your training set, you might increase or decrease the probability of selecting a sample by some weighting function (e.g. the target value).  This is common practice in applications like under or over sampling and can help avoid bias in your model.
The problem would be if you are including information about your target in the feature inputs for your model.  In this case the model can learn to map between the target in the input to itself in the output.
