Currently, this behavior is embedded in tree build. It should be extracted to avoid broadcasting errors and semantic issues.