refactor silhouette logic