OpenWormLLM / test.py
pgleeson's picture
Changes for AI21
cdf7ed2
Raw
History Blame
953 Bytes
from ring import LLM_GPT35
from ring import LLM_GPT4
from ring import LLM_GPT4o
from ring import LLM_LLAMA2
from ring import LLM_GEMINI
from ring import LLM_AI21
from ring import PREF_ORDER_LLMS
from ring import generate_response
import sys
question = "What is the most common type of neuron in the brain?"
llm_ver = LLM_GPT4o
if "-g" in sys.argv:
llm_ver = LLM_GEMINI
if "-l" in sys.argv:
llm_ver = LLM_LLAMA2
if "-a" in sys.argv:
llm_ver = LLM_AI21
print("--------------------------------------------------------")
print("Asking question:\n %s" % question)
print("--------------------------------------------------------")
print(" ... Connecting to: %s" % llm_ver)
response = generate_response(question, llm_ver, temperature=0, only_celegans=False)
print("--------------------------------------------------------")
print("Answer:\n %s" % response)
print("--------------------------------------------------------")
print()