Switch to StringBuilder for filter creation