HansBug's picture
dev(hansbug): init code
2c2e788
raw
history blame
249 Bytes
from typing import Callable, Dict
_LLMS: Dict[str, Callable[[str], str]] = {}
def register_llm(name: str, llm_ask_fn: Callable[[str], str]):
_LLMS[name] = llm_ask_fn
def get_llm_fn(name: str) -> Callable[[str], str]:
return _LLMS[name]