Both partition_field_name and by_field_name cause a "split" to the analysis (creates separate baseline statistical models). Either can be used (or both can be used to effectively create a "double-split").
Some nuances to their differences: ML What is the difference between by_field_name and partition_field_name