Efficient search of relevant structures in complex systems