That filter can be generated a number of ways, but here's an example in power-shell:
The member field of the GADS group rule looking at your target ou should be populated with the attribute which is storing filter information (In our above script, we used the attribute info). Also ensure that the "Dynamic (query-based) group" checkbox is checked.
More on LDAP Queries and GADS config