factor out spelling tools