Skip to content

Commit e92ff7d

Browse files
committed
Remove unused exception.
A model is always returned in the current configuration. Relate #14.
1 parent 67bf91c commit e92ff7d

3 files changed

Lines changed: 0 additions & 10 deletions

File tree

src/agent.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,6 @@
1212
from binaryninja.settings import Settings
1313
from binaryninja import log
1414

15-
from .exceptions import InvalidEngineException
16-
1715

1816
class Agent:
1917

@@ -31,7 +29,6 @@ class Agent:
3129

3230
def __init__(self,
3331
function: Union[LowLevelILFunction, MediumLevelILFunction, HighLevelILFunction],
34-
engine: str,
3532
path_to_api_key: Optional[Path]=None) -> None:
3633

3734
# Read the API key from the environment variable.
@@ -142,4 +139,3 @@ def send_query(self, query: str) -> str:
142139
max_tokens=2_048
143140
)
144141
return response.choices[0].text
145-

src/entry.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
def check_function(bv: BinaryView, func: Function) -> bool:
1010
agent: Agent = Agent(
1111
function=func,
12-
engine='text-davinci-003',
1312
path_to_api_key=API_KEY_PATH
1413
)
1514
query: str = agent.generate_query(func)

src/exceptions.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,3 @@
1-
from openai.error import OpenAIError
2-
3-
class InvalidEngineException(OpenAIError):
4-
pass
5-
61
class RegisterSettingsGroupException(Exception):
72
pass
83

0 commit comments

Comments
 (0)