{ "info": { "author": "Victor Lin", "author_email": "bornstub@gmail.com", "bugtrack_url": null, "classifiers": [], "description": "======================\nWhat is OpenCC-python?\n======================\n\nOpenCC-Python is a Python wrapper for `Open Chinese Converter`_\n\n.. _`Open Chinese Converter`: http://code.google.com/p/opencc/\n\n============\nInstallation\n============\n\nTo install opencc-python:\n\n::\n\n pip install opencc-python\n\n==============\nHow to use it?\n==============\n\nYou need to install opencc command tool first, if you are using Windows, the\ncommand tool is already attached in the package, you can use it right away.\nFollowing is a simple example\n\n::\n\n # -*- coding: utf8 -*-\n import opencc\n cc = opencc.OpenCC('t2s')\n print cc.convert(u'Open Chinese Convert\uff08OpenCC\uff09\u300c\u958b\u653e\u4e2d\u6587\u8f49\u63db\u300d\uff0c\u662f\u4e00\u500b\u81f4\u529b\u65bc\u4e2d\u6587\u7c21\u7e41\u8f49\u63db\u7684\u9805\u76ee\uff0c\u63d0\u4f9b\u9ad8\u8cea\u91cf\u8a5e\u5eab\u548c\u51fd\u6578\u5eab(libopencc)\u3002')\n\nAnd the output should be\n\n::\n\n Open Chinese Convert\uff08OpenCC\uff09\u300c\u5f00\u653e\u4e2d\u6587\u8f6c\u6362\u300d\uff0c\u662f\u4e00\u4e2a\u81f4\u529b\u4e8e\u4e2d\u6587\u7b80\u7e41\u8f6c\u6362\u7684\u9879\u76ee\uff0c\u63d0\u4f9b\u9ad8\u8d28\u91cf\u8bcd\u5e93\u548c\u51fd\u6570\u5e93(libopencc)\u3002\n\nThere are four build-in configurations in opencc.BUILDIN_CONFIGS, \n\n * t2s - Traditional Chinese to Simplified Chinese\n * s2t - Simplified Chinese to Traditional Chinese\n * mix2t - Mixed to Traditional Chinese\n * mix2s - Mixed to Simplified Chinese\n\nTo use a customized path to opencc command tool, you can pass opencc_path \nparameter like this\n\n::\n\n cc = opencc.OpenCC('t2s', \n opencc_path='/path/to/opencc')\n \nTo use your own configuration, you should change the data_path, too\n\n::\n\n cc = opencc.OpenCC(config='/path/to/my/config', \n opencc_path='/path/to/opencc',\n data_path='/path/to/data/folder')", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "http://bitbucket.org/victorlin/opencc_python", "keywords": null, "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "opencc-python", "package_url": "https://pypi.org/project/opencc-python/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/opencc-python/", "project_urls": { "Download": "UNKNOWN", "Homepage": "http://bitbucket.org/victorlin/opencc_python" }, "release_url": "https://pypi.org/project/opencc-python/0.1/", "requires_dist": null, "requires_python": null, "summary": "A Python wrapper for Open Chinese Convert", "version": "0.1" }, "last_serial": 795758, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "cf0e4fb65ac0b4fe9ee7496a18d62288", "sha256": "3601a2edcaafa7ba17deb5400742bea5450859e61a39ffb105e7c8d01a1ae308" }, "downloads": -1, "filename": "opencc-python-0.1.win32.exe", "has_sig": false, "md5_digest": "cf0e4fb65ac0b4fe9ee7496a18d62288", "packagetype": "bdist_wininst", "python_version": "any", "requires_python": null, "size": 1140414, "upload_time": "2011-07-14T09:58:07", "url": "https://files.pythonhosted.org/packages/f5/68/02c10ef560d65e8e45271aff21f49fdb443f4233e16542ac1c1a182ffab5/opencc-python-0.1.win32.exe" }, { "comment_text": "", "digests": { "md5": "1e028b5bc2ffdac81959849776da4136", "sha256": "f82ebf8cd62ed6377ba49ae34502c389bbaaaa25142b7eda0ffd84462153f223" }, "downloads": -1, "filename": "opencc-python-0.1.zip", "has_sig": false, "md5_digest": "1e028b5bc2ffdac81959849776da4136", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 944270, "upload_time": "2011-07-14T09:58:38", "url": "https://files.pythonhosted.org/packages/2d/35/afa677ced911b672e0f099856a565514a670b505f94d1150c77ce0c73a7a/opencc-python-0.1.zip" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "cf0e4fb65ac0b4fe9ee7496a18d62288", "sha256": "3601a2edcaafa7ba17deb5400742bea5450859e61a39ffb105e7c8d01a1ae308" }, "downloads": -1, "filename": "opencc-python-0.1.win32.exe", "has_sig": false, "md5_digest": "cf0e4fb65ac0b4fe9ee7496a18d62288", "packagetype": "bdist_wininst", "python_version": "any", "requires_python": null, "size": 1140414, "upload_time": "2011-07-14T09:58:07", "url": "https://files.pythonhosted.org/packages/f5/68/02c10ef560d65e8e45271aff21f49fdb443f4233e16542ac1c1a182ffab5/opencc-python-0.1.win32.exe" }, { "comment_text": "", "digests": { "md5": "1e028b5bc2ffdac81959849776da4136", "sha256": "f82ebf8cd62ed6377ba49ae34502c389bbaaaa25142b7eda0ffd84462153f223" }, "downloads": -1, "filename": "opencc-python-0.1.zip", "has_sig": false, "md5_digest": "1e028b5bc2ffdac81959849776da4136", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 944270, "upload_time": "2011-07-14T09:58:38", "url": "https://files.pythonhosted.org/packages/2d/35/afa677ced911b672e0f099856a565514a670b505f94d1150c77ce0c73a7a/opencc-python-0.1.zip" } ] }