{ "info": { "author": "Swoop Search LLC, Josh Gachnang, Rob Jauquet", "author_email": "Josh@SwoopSrch.com", "bugtrack_url": null, "classifiers": [ "License :: OSI Approved :: BSD License", "Natural Language :: English", "Programming Language :: Python :: 2 :: Only", "Topic :: Software Development :: Libraries", "Topic :: Text Processing" ], "description": "address\n=========\n\naddress is an address parsing library, taking the guesswork out of\nusing addresses in your applications. We use it as part of our apartment\nsearch and apartment spider applications.\n\nInstallation\n------------\n\n::\n\n pip install address\n\nExample\n-------\n\nFirst, we create an AddressParser. AddressParser allows us to feed in\nlists of cities, streets, and address suffixes. Then we call\nparse\\_address on our address string, which returns an Address instance\nwith all the attributes filled out. From there, we can print parts of\nthe address, change them, validate them, create a database model to\nstore them, or anything else.\n\n::\n\n from address import AddressParser, Address\n\n ap = AddressParser()\n address = ap.parse_address('123 West Mifflin Street, Madison, WI, 53703')\n print \"Address is: {0} {1} {2} {3}\".format(address.house_number, address.street_prefix, address.street, address.street_suffix)\n\n > Address is: 123 W. Mifflin St.\n\nAddressParser\n-------------\n\n``AddressParser(self, suffixes=None, cities=None, streets=None)``\n\nsuffixes, cities, and streets all accept lists as arguments. If you\nleave them as none, they will read default files from the package,\nnamely suffixes.csv, cities.csv, and streets.csv. Streets is\nintentionally blank.\n\nYou can provide lists of acceptable suffixes, cities, and streets to\nlower your false positives. If you know all the addresses you are\nprocessing are in a small area, you can provide a list of the cities in\nthe area and should get more accurate results. If you are only doing one\ncity, you could provide that single city in a list, and a list of all\nstreets in that city.\n\nAddress\n-------\n\nAddresses get returned by AddressParser.parser\\_address(). They have the\nfollowing attributes:\n\n``house_number``\n\nThe number on a house. This is required for all valid addresses. E.g.\n**123** W. Mifflin St.\n\n``street_prefix``\n\nThe direction before the street name. Always represented as one or two\nletters followed by a period. Not required. E.g. 123 **W.** Mifflin St.\n\n``street``\n\nThe name of the street. Potentially multiple words. This is required for\na valid address. E.g. 123 W. **Mifflin** St.\n\n``street_suffix``\n\nThe ending of a street. This will always be the USPS abbreviation\nfollowed by a period. Not required, but highly recommended. E.g. 123 W.\nMifflin **St.**\n\n``apartment``\n\nApartment number or unit style or any number of things signifying a\nspecific part of an address. Not required. E.g. 123 W. Mifflin St. **Apt\n10**\n\n``buiding``\n\nSometimes addresses are grouped into buildings, or are more commonly\nknown as by building names. Not required, and often in parathenses. E.g.\n123 W. Mifflin St. Apt 10 **(The Estates)**\n\n``city``\n\nThe city part of the address, preferably following a comma. E.g. 123 W.\nMifflin St., **Madison**, WI 53703\n\n``state``\n\nThe state of the address, preferably following the city and a comma.\nAlways two capitalized letters. E.g. 123 W. Mifflin St., Madison, **WI**\n53703\n\n``zip``\n\nThe 5 digit zip code of the address, preferably following the state. 9\ndigit zips not yet supported. E.g. 123 W. Mifflin St., Madison, WI\n**53703**\n\n``full_address()``\n\nReturns a human readable version of the address for display. Follows the\nsame style rules as the above attributes. Example return: (The Estates)\n123 W. Mifflin St. Apt 10, Madison, WI 53703\n\nTodo\n----\n\n- Add verification of an address through Google Maps API, given an API\n key.\n\n- Allow custom validation conditions in AddressParser for what counts\n as a correct address or not.\n\n- Add exceptions for incorrect addresses instead of silent failing and\n letting user validate.\n\nGitHub\n------\n\nFile support requests and obtain the source from\nhttps://github.com/SwoopSearch/pyaddress\n\nAuthors\n-------\n\n- Josh Gachnang\n\n- Rob Jauquet\n\nLicense and Copyright\n---------------------\n\nCopyright (c) 2013 Swoop Search LLC.\n\nThis library is released under the New BSD License.", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/SwoopSearch/pyaddress", "keywords": "example documentation tutorial", "license": "UNKNOWN", "maintainer": null, "maintainer_email": null, "name": "address", "package_url": "https://pypi.org/project/address/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/address/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/SwoopSearch/pyaddress" }, "release_url": "https://pypi.org/project/address/0.1.1/", "requires_dist": null, "requires_python": null, "summary": "address is an address parsing library, taking the guesswork out of using addresses in your applications.", "version": "0.1.1" }, "last_serial": 928690, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "8585e906eeafa3968d04067295b3a198", "sha256": "732383e9c1604dacbda6743ff3b82860a38827d064c20f2bf8149e846bd23ab6" }, "downloads": -1, "filename": "address-0.1.0.tar.gz", "has_sig": false, "md5_digest": "8585e906eeafa3968d04067295b3a198", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 110383, "upload_time": "2013-01-28T18:27:03", "url": "https://files.pythonhosted.org/packages/0d/b9/49995a7d4340e9b72804fb84d968d3c19994cb34267db50f00d80de8ed83/address-0.1.0.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "b42917f44d8a90d08d21a75abf39f33b", "sha256": "53f0660495b31792e2aed6cd8fbfb50cc9194053bd884c6c79f503940ffa10d7" }, "downloads": -1, "filename": "address-0.1.1.tar.gz", "has_sig": false, "md5_digest": "b42917f44d8a90d08d21a75abf39f33b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 110752, "upload_time": "2013-01-29T02:52:21", "url": "https://files.pythonhosted.org/packages/98/f0/c923141f2ef3769fd1060bc561111ca9c43da3e2ba59003881ae3ebed921/address-0.1.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "b42917f44d8a90d08d21a75abf39f33b", "sha256": "53f0660495b31792e2aed6cd8fbfb50cc9194053bd884c6c79f503940ffa10d7" }, "downloads": -1, "filename": "address-0.1.1.tar.gz", "has_sig": false, "md5_digest": "b42917f44d8a90d08d21a75abf39f33b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 110752, "upload_time": "2013-01-29T02:52:21", "url": "https://files.pythonhosted.org/packages/98/f0/c923141f2ef3769fd1060bc561111ca9c43da3e2ba59003881ae3ebed921/address-0.1.1.tar.gz" } ] }