adding timings for cold start

This commit is contained in:
Colter Downing
2025-10-26 18:44:23 -07:00
parent bcecd6df40
commit 5d5bc197d7
3 changed files with 39 additions and 51 deletions
+4 -1
View File
@@ -6,10 +6,13 @@ from typing import Union, Type, Dict, Any, Optional
from aiohttp import web, ClientResponse
import nltk
import logging
import time
log = logging.getLogger(__name__)
t0 = time.time()
nltk.download("words")
WORD_LIST = nltk.corpus.words.words()
log = logging.getLogger(__name__)
print(f"{time.strftime('%Y-%m-%d %H:%M:%S')} NLTK words download+load took {time.time()-t0:.2f}s")
"""
Generic dataclass accepts any dictionary in input.