Skip to content

Commit

Permalink
feat: Remove LLAMA2 provider and related imports
Browse files Browse the repository at this point in the history
fix: Update provider_map to remove LLAMA2
fix: Remove LLAMA2-specific console commands
  • Loading branch information
Simatwa committed Nov 10, 2024
1 parent 2ef4a8d commit 296c972
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 24 deletions.
1 change: 0 additions & 1 deletion src/pytgpt/async_providers.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
"phind": AsyncPHIND,
"opengpt": AsyncOPENGPT,
"koboldai": AsyncKOBOLDAI,
# "gpt4free": AsyncGPT4FREE,
"blackboxai": AsyncBLACKBOXAI,
"yepchat": AsyncYEPCHAT,
}
4 changes: 1 addition & 3 deletions src/pytgpt/auto/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
from pytgpt.opengpt import OPENGPT, AsyncOPENGPT
from pytgpt.koboldai import KOBOLDAI, AsyncKOBOLDAI
from pytgpt.phind import PHIND, AsyncPHIND
from pytgpt.llama2 import LLAMA2, AsyncLLAMA2
from pytgpt.blackboxai import BLACKBOXAI, AsyncBLACKBOXAI
from pytgpt.perplexity import PERPLEXITY
from pytgpt.gpt4free import GPT4FREE, AsyncGPT4FREE
Expand All @@ -18,13 +17,12 @@


provider_map: dict[
str, Union[OPENGPT, KOBOLDAI, PHIND, LLAMA2, BLACKBOXAI, PERPLEXITY, GPT4FREE]
str, Union[OPENGPT, KOBOLDAI, PHIND, BLACKBOXAI, PERPLEXITY, GPT4FREE]
] = {
"phind": PHIND,
"perplexity": PERPLEXITY,
"opengpt": OPENGPT,
"koboldai": KOBOLDAI,
"llama2": LLAMA2,
"blackboxai": BLACKBOXAI,
"gpt4free": GPT4FREE,
}
Expand Down
20 changes: 0 additions & 20 deletions src/pytgpt/console.py
Original file line number Diff line number Diff line change
Expand Up @@ -555,26 +555,6 @@ def __init__(
quiet=quiet,
)

elif provider == "llama2":
import pytgpt.llama2.main as llama2

self.bot = llama2.LLAMA2(
is_conversation=disable_conversation,
max_tokens=max_tokens,
temperature=temperature,
presence_penalty=top_p,
frequency_penalty=top_k,
top_p=top_p,
model=getOr(model, llama2.default_model),
timeout=timeout,
intro=intro,
filepath=filepath,
update_file=update_file,
proxies=proxies,
history_offset=history_offset,
act=awesome_prompt,
)

elif provider == "blackboxai":

from pytgpt.blackboxai import BLACKBOXAI
Expand Down

0 comments on commit 296c972

Please sign in to comment.