RegBot4.0 / models /llms.py
Zwea Htet
updated docker file and llms
b38954e
raw
history blame
1.31 kB
from llama_index.llms.huggingface import HuggingFaceLLM
from llama_index.llms.openai import OpenAI
# from llama_index.llms.replicate import Replicate
from dotenv import load_dotenv
import os
load_dotenv()
# llm_mixtral_8x7b = HuggingFaceInferenceAPI(
# model_name="mistralai/Mixtral-8x7B-Instruct-v0.1",
# token=os.getenv("HUGGINGFACE_API_TOKEN"),
# )
# download the model from the Hugging Face Hub and run it locally
# llm_mixtral_8x7b = HuggingFaceLLM(model_name="mistralai/Mixtral-8x7B-Instruct-v0.1")
# llm_llama_2_7b_chat = HuggingFaceInferenceAPI(
# model_name="meta-llama/Llama-2-7b-chat-hf",
# token=os.getenv("HUGGINGFACE_API_TOKEN"),
# )
# llm_bloomz_560m = HuggingFaceInferenceAPI(
# model_name="bigscience/bloomz-560m",
# token=os.getenv("HUGGINGFACE_API_TOKEN"),
# )
llm_bloomz_560m = HuggingFaceLLM(model_name="bigscience/bloomz-560m")
# llm_gpt_3_5_turbo = OpenAI(
# api_key=os.getenv("OPENAI_API_KEY"),
# )
llm_gpt_3_5_turbo_0125 = OpenAI(
model="gpt-3.5-turbo-0125",
api_key=os.getenv("OPENAI_API_KEY"),
)
# llm_gpt_4_0125 = OpenAI(
# model="gpt-4-0125-preview",
# api_key=os.getenv("OPENAI_API_KEY"),
# )
# llm_llama_13b_v2_replicate = Replicate(
# model="meta/llama-2-13b-chat",
# prompt_key=os.getenv("REPLICATE_API_KEY"),
# )