Separate the faces and identify which faces have coating

I would appreciate it if you could help me.
I need a script where I can identify the walls of my project, then identify which walls and which sides of these walls have coverings or skirting boards. Because when I look for materials, etc., they show me the wall and sometimes I have finishing on one side of the wall but not on the other. And these finishes are made with onion walls and not in a single family, how could this data be collected? Separate the faces and identify which faces have coating?