One of the greatest advantages of using the Builder pattern is giving names to arguments in languages without support for named parameters. Here’s a builder example in Java.

Foo foo = new FooBuilder()
  .withId("abc")
  .withName("Some meaningful name")
  .build();

A constructor can be used to build the same object, but parameter meanings are disguised. In this case, the design also suffers from parameters sharing the same type (both are Strings), which makes it easy to accidentally put arguments in the wrong order.

Foo foo = new Foo("abc", "Some meaningful name");

Some languages (e.g. Scala) let us specify parameters by name. Using named parameters is a great way to make the verbose Builder pattern obsolete while retaining the same level of readability.

val foo = Foo(id = "abc", name = "Some meaningful name")

But what if only some of the parameters need to be specified while others can stay as is? Scala supports default parameter values.

class Foo(id: String, name: String = "Some meaningful name")

val foo = new Foo(id = "abc")

So if you work with a modern language, consider ditching the verbose Builder pattern in favor of your language’s features.

Scala has a copy method on case classes which can be used as a replacement for a Builder, but I find its name very low-level, and most of the time it communicates the wrong message to the reader.

// BAD: I need a foo with a specific name, but the code 
//      communicates copying
val foo = foo.copy(name = "New Name")

// GOOD: method name communicates intention - reader does not know 
//       how the object is constructed
val foo = aFooWith(name = "New Name")