semvec/pypi-packages huggingface dataset:
kitsu.py-extended 1.0.4
kitsu.py_extened is an asynchronous API wrapper for Kitsu written in Python. (Extend kitsu.py)
License: MIT
Requires Python: >=3.8,<4.0
Keywords: kitsu,async kitsu,kitsu.py,kitsu api wrapper

<h1 align="center">Kitsu.py_extended</h1>

## Important:
This is a fork of [MrArkon/kitsu.py](https://github.com/MrArkon/kitsu.py)

## Key Features
* Simple and modern Pythonic API using `async/await`
* Fully typed

## Requirements

Python 3.8+
* [aiohttp](https://pypi.org/project/aiohttp/)
* [python-dateutil](https://pypi.org/project/python-dateutil)

## Installing
To install the library, run the following commands:
```shell
# Linux/MacOS
python3 -m pip install -U kitsu_extended.py_extended

# Windows
py -3 -m pip install -U kitsu_extended.py_extended
```

## Usage

Search for an anime:

```python
import kitsu_extended
import asyncio

client = kitsu_extended.Client()


async def main():
    anime = await client.search_anime("jujutsu kaisen", limit=1)

    print("Canonical Title: " + anime.canonical_title)
    print("Average Rating: " + str(anime.average_rating))

    # Close the internal aiohttp ClientSession
    await client.close()


loop = asyncio.get_event_loop()
loop.run_until_complete(main())
```
This prints:
```
Canonical Title: Jujutsu Kaisen
Average Rating: 85.98
```
You can find more examples in the [examples](https://github.com/MrArkon/kitsu.py/tree/master/examples/) directory.

## License

This project is distributed under the [MIT](https://github.com/MrArkon/kitsu.py/blob/master/LICENSE.txt) license.
word-to-pronunciation 0.0.1
Create pronunciations of words with the possibility of ignoring punctuation and splitting on hyphens before lookup.
License: MIT
Requires Python: >=3.6
Keywords: Language,Linguistics

# word-to-pronunciation

[![PyPI](https://img.shields.io/pypi/v/word-to-pronunciation.svg)](https://pypi.python.org/pypi/word-to-pronunciation)
[![PyPI](https://img.shields.io/pypi/pyversions/word-to-pronunciation.svg)](https://pypi.python.org/pypi/word-to-pronunciation)
[![MIT](https://img.shields.io/github/license/stefantaubert/sentence2pronunciation.svg)](LICENSE)

Python library to help with looking up words that contain punctuation and hyphens.

## Installation

```sh
pip install word-to-pronunciation
```

## Usage

```python
>>> from collections import OrderedDict
>>> from pronunciation_dictionary import Pronunciations, Word
>>> from word_to_pronunciation import Options, get_cached_lookup, get_pronunciations_from_word

>>> def lookup(word: Word) -> Pronunciations:
...   print(f"Trying to lookup: '{word}' ...")
...   if word == "test":
...     result = OrderedDict((
...       (("T", "E0", "S", "T"), 0.7),
...       (("T", "E1", "S", "T"), 0.3),
...     ))
...     print("Found pronunciations!")
...     return result
...   print("Found no pronunciations!")
...   return OrderedDict()

>>> options = Options(
...   trim_symbols="\".",
...   split_on_hyphen=True,
...   try_without_trimming=True,
...   try_without_splitting=True,
...   default_weight=1.0
... )

>>> cache = {}
>>> lookup_method = get_cached_lookup(lookup, cache)

>>> word = "\"test-test\"."
>>> result = get_pronunciations_from_word(word, lookup_method, options)
Trying to lookup: '"test-test".' ...
Found no pronunciations!
Trying to lookup: 'test-test' ...
Found no pronunciations!
Trying to lookup: 'test' ...
Found pronunciations!

>>> for pronunciation, weight in result.items():
...   print(f"{word} => /{'|'.join(pronunciation)}/ {weight}")
"test-test". => /"|T|E0|S|T|-|T|E0|S|T|"|./ 0.48999999999999994
"test-test". => /"|T|E0|S|T|-|T|E1|S|T|"|./ 0.21
"test-test". => /"|T|E1|S|T|-|T|E0|S|T|"|./ 0.21
"test-test". => /"|T|E1|S|T|-|T|E1|S|T|"|./ 0.09

>>> print(cache)
{'"test-test".': OrderedDict(), 'test-test': OrderedDict(), 'test': OrderedDict([(('T', 'E0', 'S', 'T'), 0.7), (('T', 'E1', 'S', 'T'), 0.3)])}
```