Feature/save patterns