<PackageReference Include="Microsoft.Extensions.ObjectPool" Version="10.0.9" />

Microsoft.Extensions.ObjectPool.StringBuilderPooledObjectPolicy

A policy for pooling StringBuilder instances.
public int InitialCapacity { get; set; }

Gets or sets the initial capacity of pooled StringBuilder instances.

public int MaximumRetainedCapacity { get; set; }

Gets or sets the maximum value for Capacity that is allowed to be retained, when Return is invoked.