DeSOTA Tools Package
Project description
DeSOTA Preferred Installer Program
pip install desota
Packages
detools
from desota import detools
detools.get_model_req
Convert model request, from DeSOTA API the converted to YAML file in DeRunner, into python dictionary format
def get_model_req(req_path: str) -> dict:
"""
:param req_path: path to model request YAML file
:return: model request arguments in dictionary format
"""
detools.get_request_text
Get Text Arguments from DeSOTA Model request
def get_request_text(model_request_dict) -> list:
"""
:param model_request_dict: model request retrieved from `detools.get_model_req`
:return: List with text arguments from model request
"""
detools.get_request_audio
Get (download) Audio Arguments from DeSOTA Model request
def get_request_audio(model_request_dict: dict) -> list:
"""
:param model_request_dict: model request retrieved from `detools.get_model_req`
:return: List with audio file paths downloaded from model request
"""
detools.get_request_qa
Get Question-Answer Arguments from DeSOTA Model request
def get_request_qa(model_request_dict: dict) -> (list, list):
"""
:param model_request_dict: model request retrieved from `detools.get_model_req`
:return: Tuple with model request `context` and `questions`, respectivaly
"""
detools.get_request_url
Get URL Arguments from DeSOTA Model request
def get_request_url(model_request_dict: dict) -> list:
"""
:param model_request_dict: model request retrieved from `detools.get_model_req`
:return: List with URL arguments from model request
"""
detools.get_request_html
Get HTML Files from DeSOTA Model request
def get_request_html(model_request_dict: dict, from_url: bool = False) -> list((str, str)):
"""
:param model_request_dict: model request retrieved from `detools.get_model_req`
:param from_url: [OPTIONAL] Get HTLM file from URL
:return: List with html arguments from model request as tuple (html_path, html_encoding)
"""
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
desota-0.0.1.tar.gz
(5.7 kB
view details)
Built Distribution
File details
Details for the file desota-0.0.1.tar.gz
.
File metadata
- Download URL: desota-0.0.1.tar.gz
- Upload date:
- Size: 5.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.2 CPython/3.11.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 23e5e5bcb98d4d2a3c124b8b5a68509a9d00dd9053039cb6ea509346a32ac58a |
|
MD5 | 1803c434ed6daf415857d8d6cf448380 |
|
BLAKE2b-256 | e423df7302defe21b2ba622eb49f75616f467612ff79c855450dd8aac7f5cfa0 |
File details
Details for the file desota-0.0.1-py3-none-any.whl
.
File metadata
- Download URL: desota-0.0.1-py3-none-any.whl
- Upload date:
- Size: 6.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/4.0.2 CPython/3.11.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e2964d04c8525fa347d16f2a58d8b6bfcf2924e501d972b088297ef636d503e6 |
|
MD5 | 1792237648ee6415e8b480660a5e121b |
|
BLAKE2b-256 | a6c333579d0b27cff7170ef843fd839cffa5020a08465fb4a0e1fbdb36ed25e1 |