Creating Filter Rules - List Manipulation

I have it in my Dynamo 2.0

If it is not in your library, you might have to reinstall Dynamo.

If you are still having problems, please make a new post specific to your problem, and not continuing in this solved thread.

Hi, in Revit 2021, when creating a filter with Dynamo, it seems not very elegant. since it gives a lot of lines filtereing the same parameter and value. See image below.
What am I doing wrong?
Would it be possible to include the AND/OR command improved from Revit 2019?
Thanks in advance.

The Dynamo Script looks like this:

You have a ton of rules. What are you trying to do? You probably want to get the unique values only. Are you trying to make one filter with multiple rules or separate filters for each rule?

Thanks @Nick_Boyts, at a first approach I am trying to create one fister with one rule. And the result shown above is what I got. In a second approach I’d like to get one filter with a couple of rules choosing between the “AND”/“OR” options. Thanks!

Gotcha. As I mentioned before, you have a ton of rules so you’re getting… a ton of rules. You only need one instance of the parameter when creating the rule. Start by providing only one Comments parameter.