How to detect when a string has a common business suffix (e.g. "Inc.",
"LLC', "GmbH") in Ruby
I would like to find a library (Ruby GEM) to detect when a string contains
the common suffixes used in business names (e.g. Inc, LLC, LLP, GmbH, PC,
etc). My goal is to detect when we have a business name versus a human
name - specifically, we don't want to treat a business name "Company, Inc"
the same as human name "Last, First", e.g. we don't want to reverse a
business name to "Inc Company".
I've found a Wikipedia page that seems to document the various types of
companies but I haven't found any GEMs or just a simple list. Certainly,
this isn't a unique issue. Perhaps, I'm just not constructing my queries
correctly.
First choice would be finding a GEM, second would be a set of Regex
strings, and last just a list of suffixes.
No comments:
Post a Comment