Saravanan666/pypi-org huggingface dataset:
Package: k-general-kit
K-General-Kit 🛠️This project aims to provide a rich set of useful general functions frequently needed and frequent objects.Features 💡It contains a general library, for general functions on containiers, string, a bit of mathematicsWe also find a search_sort library, with powerful search and sort algorithms going from the sequential search to the exponential search and from the select sort to the merge sort.We also have the gen_obj library for frequents objects like math constants with the ability to ameliorate their precisionsWe also have eval_sequence, which gives powerful functions to evaluate recursive functions, bypassing the recursivity.Thera are also an interesting set of datas going from prime numbers collections to txt dictionnaries (for words counting functions).Examples of use 📝fromk_general_kit.gen_funcimportallprint(nel(45))# prints "quarante cinq"print(words_sentence("Hello, everyone!",'en'))# prints "['Hello', 'everyone']"For more tests, use in the project directory the command python -m tests.eval_func or the built-in command in .vscodeAuthor ✍️This project was created by KpihX. You can contact me atkapoivha@gmail.comfor any questions or suggestions.License 📄This project is licensed under the MIT license - see the LICENSE file for more details.:https://github.com/KpihX
Package: kgexplore
Knowledge ExploreKGExplore: 通用领域知识图谱XiuShang 嗅商: 商业知识图谱VisionWE ARE DOING IT! FOR REAL! 我们是真的在做! 这是我们眼中的知识图谱现状:every body talks about it: 欢迎了解一下各家科技公司的技术宣传稿 :)nobody really knows how to do it: 别说do it, 什么是知识图谱, 每行每业的定义都不尽相同. 至于怎么做?做什么?, 以后再说; PPT先画, 牛X先吹.everyone thinks everyone else is doing it, so everyone claims they are doing it: 这年头, ppt上没提到"知识图谱"概念的, 都不好意思说自己是AI公司.我们团队一直相信, 人类积累的很多知识其实一直就在文字中(为啥有文化的人都写书呢, 文字传播知识呗!). 而作为一个专业的NLP团队,
我们一直将我们的核心研发集中在了"无监督学习"和"NLP技术的大规模工程化"上. 在经过一年多的研发&开发后, 我们做出了一套可在大规模文本上抽取的"文字对象间关系"的技术框架,
虽然结果还有不断完善的空间, 但是既然是知识,就值得被分享安装https://github.com/smoothnlp/KGExplore.gitcdKGExplore
pythonsetup.pyinstall使用介绍知识图谱N元组的搜索与可视化身份验证请将您的身份/就职公司/业务场景/联系方式等电邮到business@smoothnlp.com; 我们对科研工作者提供免费的服务调用!importkgexploreaskgekge.config.setApiKey(YOUR_API_KEY)通用领域知识图谱rels=[]rels+=kge.search_bigram("瑞幸咖啡",limit=10)kge.visualize(rels)嗅商 - 商业知识图谱rels=[]rels+=kge.get_xiushang_ngram(target="董明珠",source_type='企业')rels+=kge.get_xiushang_ngram(source="珠海格力电器股份有限公司",target_type="人物")kge.visualize(rels)请我们喝咖啡如果你是科研人员:Free请算法工程师喝咖啡(28元): 5K次调用请整个团队喝咖啡(128元): 5万次调用有意包养我们(我们在找融资): 心诚即可,请电邮business@smoothnlp.com请使用下方的二维码进行付款, 然后将支付凭证截图电邮到business@smoothnlp.com; 我们会在24小时内回复apikey. 谢谢大家支持
Package: kgextension
Knowledge Graph Extension for PythonThekgextensionpackage allows to access and use Linked Open Data to
augment existing datasets. It enables to incorporate knowledge graph
information inpandas.DataFramesand can be used within thescikit-learn
pipeline.Its functionality includes:Linking datasets to any Linked Open Data (LOD) Source such asDBpedia,WikiDataor theEU Open Data PortalGeneration of new features from the LOD SourcesHierarchy-based feature selection algorithmsData Integration of features from different sourcesThe project started in March 2020 as a Masters Team Project at the
University of Mannheim.InstallationThe newest stable release can be found on thePython Package Index
(PyPi).pipinstallkgextensionDocumentation and UsageDetailed documentation and usage instructions can be found in thekgextension
documentation.CommunicationThe contributors can be reached by email:kgproject20@gmail.com.
Package: kgforge
Library to extract Knowledge Graphs from scholarly textkgforge DocumentationWhat is it?•Features•Installation•Usage•ContributingWhat is it?kgforgeis a library which automates the generation of knowledge graphs from scholarly text.Features:TODO: TODO: Description.Installation:PoetrypoetryaddkgforgePippipinstallkgforgeSetup your local environment:Any necessary environment variables description:exportSAMPLE_ENV_VARIABLE=${VALUE}UsageNow thatkgforgeis installed, you're ready to start using it!It's time to point you to the officialDocumentation Websitefor more information on how to usekgforgeContributingIf you'd like to contribute, be sure to check out ourcontributing guide! If you'd like to work on any outstanding items, check out theroadmapsection in the docs and get started :smiley:Thanks goes to these incredible people.
Package: kgheartbeat
KGHeartbeat APILibrary that allows you to perform Knowledge Graph (Linked Open Data) quality analysis.Installationpip install kgheartbeatGet startedHow check SPARQL endpoint availability with this library:fromkgheartbeatimportKnowledgeGraph# Instanziate a KnowledgeGraph class, passing the id of the kg to be analyzedkg=KnowledgeGraph('dbpedia')# Call the check availability enpoint methodresult=kg.checkEndpointAv()
Package: kgiapp
kgiapp凱基證券程式下單API整合了.net framework 4.5架構下的交易介面，讓使用者可以輕鬆的運用python執行快速下單。kgiapp is a securities, futures, option API, which send orders to Concord Securities Group.
This package integrated with .net framework 4.5, and is compatible with Python 3.5+.
It is distributed under the MIT license.InstallationPreinstallBinariesQuick StartsLoginPlace OrderStockFuturesForeign FuturesRegister EventQuoteReferenceInstallationPreinstallAPI usage needs application in advance. In order to use this package, please contact us.Binariessimply use pip to installpip install kgiappQuick StartsLoginfromkgiappimportTradeAPIagent=TradeAPI(debug=False)agent.login("YOUR_PERSON_ID","YOUR_PASSWORD")Place OrderStockfromkgiapp.Tradeimportconstantagent.stock_order(action=SecurityAction.NEW_ORDER,broker_no='YOUR_BROKER_NO',account_no='YOUR_ACCOUNT',lot_type=LotType.ROUND_LOT,order_type=OrderType.ORDINARY,side=Side.BUY,symbol='2330',quantity=1,price=570,price_flag=SecurityPriceFlag.FIX,time_in_force=TimeInForce.ROD,sub_account_no='',agent_id='',order_id='')Futuresagent.futures_order(action=Action.NEW_ORDER,branch_no='YOUR_BROKER_NO',account_no='YOUR_ACCOUNT',sub_account_no='',market_type=Market.FUTURES,tb_20_code='MXFB1',time_in_force=TimeInForce.ROD,writeoff=WriteOff.OPEN,order_type=PriceFlag.LIMIT,side=Side.BUY,quantity=1,price=15100,web_id='',orig_net_no='',order_id='')Reference
Package: kg-ingressnginx
KubraGen Builder: Ingress NGINXkg_ingressnginx is a builder forKubraGenthat deploys
aIngress NGINXserver in Kubernetes.KubraGenis a Kubernetes YAML generator library that makes it possible to generate
configurations using the full power of the Python programming language.Website:https://github.com/RangelReale/kg_ingressnginxRepository:https://github.com/RangelReale/kg_ingressnginx.gitDocumentation:https://kg_ingressnginx.readthedocs.org/PyPI:https://pypi.python.org/pypi/kg_ingressnginxExamplefromkubragenimportKubraGenfromkubragen.constsimportPROVIDER_GOOGLE,PROVIDERSVC_GOOGLE_GKEfromkubragen.objectimportObjectfromkubragen.optionsimportOptionsfromkubragen.outputimportOutputProject,OD_FileTemplate,OutputFile_ShellScript,OutputFile_Kubernetes,\OutputDriver_Printfromkubragen.providerimportProviderfromkg_ingressnginximportIngressNGINXBuilder,IngressNGINXOptionskg=KubraGen(provider=Provider(PROVIDER_GOOGLE,PROVIDERSVC_GOOGLE_GKE),options=Options({'namespaces':{'mon':'app-monitoring',},}))out=OutputProject(kg)shell_script=OutputFile_ShellScript('create_gke.sh')out.append(shell_script)shell_script.append('set -e')## OUTPUTFILE: app-namespace.yaml#file=OutputFile_Kubernetes('app-namespace.yaml')file.append([Object({'apiVersion':'v1','kind':'Namespace','metadata':{'name':'app-monitoring',},},name='ns-monitoring',source='app',instance='app')])out.append(file)shell_script.append(OD_FileTemplate(f'kubectl apply -f ${{FILE_{file.fileid}}}'))shell_script.append(f'kubectl config set-context --current --namespace=app-monitoring')## SETUP: ingressnginx#ingressnginx_config=IngressNGINXBuilder(kubragen=kg,options=IngressNGINXOptions({}))ingressnginx_config.ensure_build_names(ingressnginx_config.BUILD_INGRESS)## OUTPUTFILE: ingressnginx.yaml#file=OutputFile_Kubernetes('ingressnginx.yaml')out.append(file)file.append(ingressnginx_config.build(ingressnginx_config.BUILD_INGRESS))shell_script.append(OD_FileTemplate(f'kubectl apply -f ${{FILE_{file.fileid}}}'))## Write files#out.output(OutputDriver_Print())# out.output(OutputDriver_Directory('/tmp/build-gke'))Output:****** BEGIN FILE: 001-app-namespace.yaml ********
apiVersion: v1
kind: Namespace
metadata:
  name: app-monitoring

****** END FILE: 001-app-namespace.yaml ********
****** BEGIN FILE: 002-ingressnginx.yaml ********
apiVersion: v1
kind: Namespace
metadata:
  name: ingress-nginx
  labels:
    app.kubernetes.io/name: ingress-nginx
    app.kubernetes.io/instance: ingress-nginx
---
apiVersion: v1
kind: ServiceAccount
metadata:
  labels:
    helm.sh/chart: ingress-nginx-3.6.0
    app.kubernetes.io/name: ingress-nginx
    app.kubernetes.io/instance: ingress-nginx
    app.kubernetes.io/version: 0.40.2
    app.kubernetes.io/managed-by: Helm
<...more...>
****** END FILE: 002-ingressnginx.yaml ********
****** BEGIN FILE: create_gke.sh ********
#!/bin/bash

set -e
kubectl apply -f 001-app-namespace.yaml
kubectl config set-context --current --namespace=app-monitoring
kubectl apply -f 002-ingressnginx.yaml

****** END FILE: create_gke.sh ********CreditsBased oningress-nginx deploykubernetes/ingress-nginxAuthorRangel Reale (rangelreale@gmail.com)
Package: kglib
Kevin Gullikson’s ScriptsThis is a variety of packages that I use in my research. This package was made as a convenience to anyone interested in my work, and is not very thoroughly tested. The repository that I have been using the last several years in locatedhere, but is much more of a pain to install…If you use this repository in your research, please cite me using the digital object identifier (DOI) above!InstallationIf you use anaconda python, use:condainstallh5pypandasscipymatplotlibbokeh==0.10astropyscikit-learncythonseabornpytablespythonsetup.pyinstall
Package: kgp-configrendertoml
KubraGen Plugin: TOML config rendererkgp_configrendertoml is a config file renderer forKubraGenthat outputs configuration toTOMLformat.KubraGenis a Kubernetes YAML generator library that makes it possible to generate
configurations using the full power of the Python programming language.Website:https://github.com/RangelReale/kgp_configrendertomlRepository:https://github.com/RangelReale/kgp_configrendertoml.gitDocumentation:https://kgp_configrendertoml.readthedocs.org/PyPI:https://pypi.python.org/pypi/kgp_configrendertomlAuthorRangel Reale (rangelreale@gmail.com)
Package: kgpr-core
KubraGen Providers: Corekgpr_core is a collection of core providers forKubraGen.KubraGenis a Kubernetes YAML generator library that makes it possible to generate
configurations using the full power of the Python programming language.Website:https://github.com/RangelReale/kgpr_coreRepository:https://github.com/RangelReale/kgpr_core.gitDocumentation:https://kgpr_core.readthedocs.org/PyPI:https://pypi.python.org/pypi/kgpr_coreProviderGoogle GKE:kgpr_core.google.gke.provider.ProviderGoogleGKEAmazon EKS:kgpr_core.amazon.eks.provider.ProviderAmazonEKSDigitalOcean Kubernetes:kgpr_core.digitalocean.kubernetes.provider.ProviderDigitalOceanKubernetesKIND:kgpr_core.kind.generic.provider.ProviderKINDGenericK3D:kgpr_core.k3d.generic.provider.ProviderK3DGenericAuthorRangel Reale (rangelreale@gmail.com)
Package: kg-qa
KNOWLEDGE-GRAPH-QUALITY-ANALYSIS-APILibrary that allows you to perform Knowledge Graph (Linked Open Data) quality analysis.Installationpip install kg-qaGet startedHow check SPARQL endpoint availability with this library:fromkg_qaimportKnowledgeGraph# Instanziate a KnowledgeGraph object, passing the id of the kg to be analyzedkg=KnowledgeGraph('dbpedia')# Call the check availability enpoint methodresult=kg.checkEndpointAv()
Package: kgraph
# KGraph知识图谱是一种具有多种关系的异构有向网络。在已公开的知识图谱中，收集到的知识通常被定义为事件，以三元组的形式进行存储。每个三元组通常被定义为$(h,r,t)$，其中$h$表示头实体，$t$表示尾实体，$r$表示由头实体到尾实体的链路关系。虽然随着人们日常活动产生了大量的知识，但是收集并存储这些海量的知识事件需要花费巨大的人力和时间成本。因此即便是规模超过亿万级的知识图谱仍然存在着大量的缺失事件。因此利用已有的知识，学习到合理高效的知识补全模型，成为当前知识图谱研究中的一个热点。KGraph旨在帮助研究者快速构建基于数值表示的知识补全模型的工具库。KGraph具有丰富的API，其中包含了当前学术界使用到的主流开源知识图谱数据集，例如FB15k、FB15k-237、WN18、WN18RR、FB13、WN11等，以及高效地评估方法。利用KGraph，知识图谱研究者可以更加专注于对模型本身的研究，而不需要关注繁琐的数据加载、预处理以及评估方法的编写。可以通过pip进行安装。具体安装命令：pip install kgraph
Package: kgt
kgtSome handy tools for theKeygenlicensing service. (This
is a user contribution, not an official Keygen LLC product. For Keygen
software, seehere.)Install withpip install kgtand use asimportsysfromkgtimportget_online_license_info,ValidationErrorinfo=get_online_license_info(account_id="demo",key="DEMO-DAD877-FCBF82-B83D5A-03E644-V3")Theoutobject contains useful information such asout.code
out.timestamp
out.license_creation_time
out.license_expiry_timeThe validation result can also be safely cached withimportsysfromdatetimeimportdatetime,timedeltafromkgtimportget_cached_license_info,ValidationErrorinfi=get_cached_license_info(account_id="your accound id",key="the license key",keygen_verify_key="your Ed25519 128-bit Verify Key",cache_path="/tmp/license-cache.json",refresh_cache_period=timedelta(days=3),)now=datetime.utcnow()cache_age=now-out.timestampifcache_age>timedelta(days=3)andcache_age<timedelta(days=7):print("Warning: Could not validate license. Make sure to get online soon.")elifcache_age>timedelta(days=7):print("Error: Could not validate license. Internet connection needed. Exiting.")sys.exit(1)Foroffline validation, usefromkgtimportget_offline_license_info# or "RSA_2048_PKCS1_SIGN_V2", "RSA_2048_PKCS1_PSS_SIGN_V2":license_scheme="ED25519_SIGN"keygen_verify_key="your public verify key"license_key="your offline license key"info=get_offline_license_info(license_scheme,license_key,keygen_verify_key)print(info)
Package: kgtool
kgtool: toolbox for processing knowledge graph and cnSchemainstall-------------pip install kgtooladditional setup* install graphviz/dot to render schema in imagebrew install graphviz* RDF/JSON-LD processorpip install rdflib-jsonldtools-------------kgtool/core.py* file utilities* json data access* data conversionkgtool/stats.py* table item statisticskgtool cns* cns/cns_model.py    basic cns data model, load/export jsonld* cns/cns_convert.py  convert cns item* cns/cns_validate.py  validate cns item* cns/cns_graphviz.py  visualize cns schemacns* cns/cns_excel.py    load cnSchema schema in excel* cns/schemaorg.py    update schemaorg* cns/cns_schemaorg.py   convert schemaorg to loaded_schema formatcnSchema 201806====================### cns_top源文件https://docs.google.com/spreadsheets/d/1YKtEpHqa2I8LvuNAVDg3uwV6G9b4ZrNJsZdvPMS3_98/edit#gid=175537852./genschema.sh cns_top v2.0### cns_place源文件https://docs.google.com/spreadsheets/d/1aX-_QOj2GQALx-k_dJU-ak5LyvV0iIBaAg6s2N0UNmw/edit#gid=1952900205./genschema.sh cns_place v2.0### cns_organization源文件https://docs.google.com/spreadsheets/d/1qVaBhsbf0RRkrVhG0kkkn79q_fH4s4bV3oO5isGrX8o/edit#gid=659512552./genschema.sh cns_organization v2.0### cns_person源文件https://docs.google.com/spreadsheets/d/1b5DubotKUTU5tvT2pGXztwLpP63Xrc1le-VOuGKqbcw/edit./genschema.sh cns_person v2.0### cns_schemaorg源文件https://docs.google.com/spreadsheets/d/1mpiBxI5rK_qs86IpbXgN1xbhrxS_VYF0XjI_fcRpl00/edit#gid=364353024./genschema.sh cns_schemaorgTODO: super class/property 这一块还没有做TODO: 形成templateTODO: 处理 domain/range### cns_kg4ai源文件https://docs.google.com/spreadsheets/d/1wAM3zoyjFmo0O92-okLHLMXwKNvx_GCWV2eu_AeX3VY/edit#gid=1085464633./genschema.sh cns_kg4ai v20180915
Package: kgym
kgymImplementations for the OpenAI Gym of Kaggle EnvironmentsFree software: Apache Software License 2.0Documentation:https://kgym.readthedocs.io.FeaturesImplementations for the following environmentsEnvironmentIdentifierDoneConnectXconnectxXTic Tac ToetictactoeIdentityidentityCreditsThis package was created withCookiecutterand theaudreyr/cookiecutter-pypackageproject template.History0.0.2 (2020-07-02)Fix opponent always fixed to ‘negamax’.Introduce first test.Fix travis built.0.0.1 (2020-07-01)Add ConnectorX to available environments.First release on PyPI.
Package: kh2lib
KH2LibThis is the repository for a python library to assist with creating mods/codes to Kingdom Hearts 2 Final Mix +Please create a GitHub issue if you have problems, or reach out to me on Discord (I'm in most of the kh2 modding related discords). Pull requests are also welcome!The library can do the following (and more)Extract/Patch/Repack KH2 iso's, (using KH2FM_Toolkit.exe)Extract/Repack BAR files using openKHGiven a memdump of the running game, locate the offset where a given file is locatedGiven a source and modified file, generate codes to perform the changes in memory, without patching (useful for fast prototypes)Provides lookup methods for objects (look up object id/name/mdlx based on just one of those)To install run the followingpip install kh2libThe library is most useful when used in conjunction with some other pieces of software, and detects their presence using the following environment variablesUSE_KH2_EDITORENGINE - Is the path to the directory containing the openkh executablesexample -C:\Users\12sam\Desktop\openkhUSE_KH2_GITPATH - Is the path to an extracted KH2 ISOexample -C:\Users\12sam\Desktop\Kingdom Hearts 2 Modding\ISO\exportUSE_KH2_OUTPATH - Where the library should places created pnach files (usually the cheats folder of pcsx2)example -C:\Users\12sam\Desktop\pcsx\PCSX2 1.6.0\cheats\F266B00B.pnachUSE_KH2_PATCHENGINEDIR - Is the path to a directory containing KH2FM_Toolkit.exeexample -C:\Users\12sam\Desktop\Kingdom Hearts 2 Modding\ISOUsageSee the examples folder for examples on how to perform various tasksUsing KH2Lib- contains examples that demonstrate using various pieces of kh2lib functionalityOther- Other useful scripts I made while researching different things, not exactly related to kh2lib functionalityWIP- Work in Progress examples that may not work, or may be prototyping future features to kh2lib
Package: khadoop
READMEParse and slice hadoop logsYarn RMDatasetfromkhadoop.yarnimportlogrmParse all files that look like a regular Ressource Manager log with default name.logrm.FILEPATTERNis a unix-like pattern file to help glob them.parsed=[]forfileloginLOGFOLDER.glob(logrm.FILEPATTERN):print(filelog)parsed+=logrm.process(filelog.open())logrm.processwill parse each line and produce a list of dict with sensible informationeach dict look like :{'accepted_to_running':6,# nb sec between ACCEPT to RUNNING'id_application':'application_1596547077642_6854','accept_to_running_ts':'2020-08-06 14:59:59,119'# timestamp set for log line 'FROM accepted to RUNNING'}theaccepted_to_runningrepresent here the number between these two timestamps on yarn aggregated RM log:2020-08-06 14:59:52,756 INFO  rmapp.RMAppImpl (RMAppImpl.java:handle(779)) - application_1596547077642_6854 State change from SUBMITTED to ACCEPTED
...
2020-08-06 14:59:59,119 INFO  rmapp.RMAppImpl (RMAppImpl.java:handle(779)) - application_1596547077642_6854 State change from ACCEPTED to RUNNINGRelatedhttps://github.com/etsy/logsterSetup devEnv variables:HIVESERVER_TEST=#raw hiveserver log fileYARNLOG#folder with RM logs
Package: khaki
KhakiKhaki is a Pomodoro timer in Python using the standardcursesmodule and
Pyglet.How to useRunkhaki. Once it is running, usepto toggle the timer. After the
long timer runs out, it is replaced by the rest timer, which needs to be
toggled as well.Pressing+will reset the current timer and add one second to the max
time. Pressing-works the same way, but subtracts a second. The
changes are not yet persistent.Pressingcwill clear the timer. It will keep running if it was running,
and will continue paused if it was paused.You can exit withq.Why "Khaki"It has a nice sound to it, and a Khaki is a great doppelganger for a tomato.
Package: khal
Khalis a standards based CLI and terminal calendar program, able to synchronize
withCalDAVservers throughvdirsyncer.Features(or rather: limitations)khal can read and write events/icalendars tovdir, sovdirsyncercan be
used tosynchronize calendars with a variety of other programs, for
exampleCalDAVservers.fast and easy way to add new eventsikhal (interactive khal) lets you browse and edit calendars and eventsno support for editing the timezones of events yetworks with python 3.8+khal should run on all major operating systems[1][1]except for Microsoft WindowsFeedbackPlease do provide feedback ifkhalworks for you or even more importantly if
it doesn’t. The preferred way to get in contact (especially if something isn’t
working) is via github or via IRC (#pimutils on Libera.Chat).DocumentationFor khal’s documentation have a look atreadthedocs.Installationkhal is packaged for mostoperating systemsand should be installable with
your standard package manager.For some exemplary OS you can find installation instructions below. Otherwise
see thedocumentationfor more information.Debian/Ubuntuapt install khalNixnix-env -i khalArchpacman -S khalBrewbrew install khalFedoradnf install khalFreeBSDpkg install py-khalInstall latest versionpip install git+https://github.com/pimutils/khalAlternativesProjects with similar aims you might want to check out arecalendar-cli(no
offline storage and a bit different scope) andgcalcli(only works with
google’s calendar).ContributingYou want to contribute tokhal? Awesome!The most appreciated way of contributing is by supplying code or documentation,
reporting bugs, creating packages for your favorite operating system, making
khal better known by telling your friends about it, etc.Licensekhal is released under the Expat/MIT License:Copyright (c) 2013-2022 khal contributors

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Package: khanaa
khanaaKhanaa is a tool to make spelling Thai more convenient.InstallationFor Python >=3.7pip install khanaaUsagefromkhanaaimportSpellWord,find_letter_listbasic_example={'onset':'ก',# can be more than one (required)'vowel':'อา',# include vowel with ย, ว coda ex. เอียว (required)'silent_before':'',# silent character before coda'coda':'',# don't put ย, ว here (put them together with vowel)'silent_after':'',# silent character after coda'tone':-1# -1 not specific, 0 สามัญ, 1 เอก, 2 โท, 3 ตรี, 4 จัตวา}spell=SpellWord()spell.spell_out(**basic_example)# => 'กา'# five tones at oncespell.all_tone(**basic_example)# => ['กา', 'ก่า', 'ก้า', 'ก๊า', 'ก๋า']# ย, ว codaspell.spell_out(onset='ล',vowel='อาย')# => 'ลาย'# onset clusterspell.spell_out(onset='กล',vowel='อะ',coda='น',tone=1)# => 'กลั่น'spell.spell_out(onset='สต',vowel='เอะ',coda='ก',tone=3)# => 'สเต๊ก'# silent characterspell.spell_out(onset='ฌ',vowel='อิ',coda='น',silent_after='สก')# => 'ฌินสก์'# can be customised (ex. add phinthu)phinthu_spell=SpellWord(onset_style='phinthu')phinthu_spell.all_tone(onset='ซย',vowel='อา')# => ['ซฺยา', 'สฺย่า', 'ซฺย่า', 'ซฺย้า', 'สฺยา']# use short length for vowelshort_spell=SpellWord(vowel_length='short')short_spell.spell_out(onset='ป',vowel='อาย')# => 'ไป'# find all available consonants, vowels and true clusters in khanaafind_letter_list()LicenseMIT