Add extracting sequences in graph. Add singleton class for a few patterns.