update: look at todo

main
Thamognya Kodi 2022-12-30 12:40:40 +07:00
parent 71e7a3c3ec
commit 7c858b2005
2 changed files with 4 additions and 7 deletions

View File

@ -22,14 +22,11 @@ sys.path.append(str(Path(__file__).parent.parent.parent) + "/utils")
import config
import internet
GOOGLE_SEARCH_API_KEY = str(os.environ["INTERNET_ML_GOOGLE_API"])
GOOGLE_SEARCH_ENGINE_ID = str(os.environ["INTERNET_ML_GOOGLE_SEARCH_ENGINE_ID"])
QA_MODEL: Any = pipeline("question-answering")
def answer(query: str) -> tuple[Any, list[str]]:
global QA_MODEL
QA_MODEL: Any = pipeline("question-answering")
GOOGLE_SEARCH_API_KEY = str(os.environ["INTERNET_ML_GOOGLE_API"])
GOOGLE_SEARCH_ENGINE_ID = str(os.environ["INTERNET_ML_GOOGLE_SEARCH_ENGINE_ID"])
results: tuple[list[str], list[str]] = internet.Google(
query, GOOGLE_SEARCH_API_KEY, GOOGLE_SEARCH_ENGINE_ID
).google()

View File

@ -5,7 +5,7 @@ build-backend = "poetry.core.masonry.api"
[tool.poetry]
name = "internet-ml"
version = "1.0.0"
version = "1.0.1"
description = "Internet-ML: Allowing ML to connect to the internet"
readme = "./.github/README.md"
authors = ["Thamognya Kodi <contact@thamognya.com>"]