Unfortunately, it won't work for text-formatted line items.
But, you can make a dynamic line item filter for number formatted items with Line Item subsets. When filetering your actual line items would respect a filter condition that you could build in the LI subsets.
Depending on how you have built the module you might want to try a list with items Comment 1, 2, 3 ... In that case, you would be able to build a filter based on the list that holds comments, in addition, you could enable the users to add additional comment items if necessary.