Skip to content

Commit b050038

Browse files
authored
init (#26)
1 parent bfc256b commit b050038

12 files changed

+15
-15
lines changed

configs/main.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -35,5 +35,5 @@ plugins:
3535
auth:
3636
OPENAI_API_KEY: !file /home/billxbf/Documents/myks/openai.key
3737
WOLFRAM_ALPHA_APPID: !file /home/billxbf/Documents/myks/wolfram.key
38-
WEATHER_API_KEY: null
39-
BING_API_KEY: null
38+
# WEATHER_API_KEY: null
39+
# BING_API_KEY: null

configs/mathria.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -35,5 +35,5 @@ plugins:
3535

3636

3737
auth:
38-
OPENAI_API_KEY: !file /home/api.key
39-
WOLFRAM_ALPHA_APPID: !file /home/wolfram.key
38+
OPENAI_API_KEY: !file /home/billxbf/Documents/myks/openai.key
39+
WOLFRAM_ALPHA_APPID: !file /home/billxbf/Documents/myks/wolfram.key

gentopia/llm/client/huggingface.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ class HuggingfaceLLMClient(BaseLLM, BaseModel):
117117
Huggingface LLM client
118118
"""
119119
model_name: str
120-
params: HuggingfaceParamModel
120+
params: HuggingfaceParamModel = HuggingfaceParamModel()
121121
device: str # cpu, mps, gpu, gpu-8bit, gpu-4bit
122122
model: Optional[BaseLLM] = None
123123

gentopia/llm/client/openai.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
class OpenAIGPTClient(BaseLLM, BaseModel):
1515
model_name: str
16-
params: OpenAIParamModel
16+
params: OpenAIParamModel = OpenAIParamModel()
1717

1818
def __init__(self, **data):
1919
super().__init__(**data)

gentopia/model/param_model.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ class OpenAIParamModel(BaseModel):
1313
"""
1414
OpenAI API parameters
1515
"""
16-
max_tokens: int = 4032
17-
temperature: float = 0.0
16+
max_tokens: int = 2048
17+
temperature: float = 0.2
1818
top_p: float = 1.0
1919
presence_penalty: float = 0.0
2020
frequency_penalty: float = 0.0

gentopia/tools/arxiv_search.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
from typing import AnyStr, Any
22
import arxiv
3-
from basetool import *
3+
from .basetool import *
44

55

66
class ArxivSearch(BaseTool):

gentopia/tools/bing_search.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
# from ..tool import Tool
66
from enum import Enum
77
from typing import Tuple
8-
from basetool import *
8+
from .basetool import *
99
import os
1010

1111

gentopia/tools/code_interpreter.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
from typing import AnyStr
2-
from basetool import *
2+
from .basetool import *
33

44

55
# Jerry: This tool can be dangerous

gentopia/tools/file_operation.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
from pathlib import Path
22
from typing import AnyStr, Any
33
import arxiv
4-
from basetool import *
4+
from .basetool import *
55

66

77
class WriteFileArgs(BaseModel):

gentopia/tools/gradio.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
from typing import AnyStr
22
from langchain import OpenAI, LLMMathChain
3-
from basetool import *
3+
from .basetool import *
44
from xml.dom.pulldom import SAX2DOM
55
from gradio_tools.tools import BarkTextToSpeechTool,StableDiffusionTool,DocQueryDocumentAnsweringTool,ImageCaptioningTool,StableDiffusionPromptGeneratorTool,TextToVideoTool,ImageToMusicTool,WhisperAudioTranscriptionTool,ClipInterrogatorTool
66
from gradio_client.client import Job

gentopia/tools/shell.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
import pexpect
1313
from typing import AnyStr
14-
from basetool import *
14+
from .basetool import *
1515

1616
# Revised from the Contributor: [Sihan Zhao](https://github.com/Sarah816)
1717

gentopia/tools/weather.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import json
33
import os
44
from typing import AnyStr, Any
5-
from basetool import *
5+
from .basetool import *
66

77

88
class Weather(BaseTool):

0 commit comments

Comments
 (0)