Skip to content

Commit f2d88f7

Browse files
committed
🎨 style: run black to format the code
1 parent 48a4804 commit f2d88f7

File tree

4 files changed

+13
-7
lines changed

4 files changed

+13
-7
lines changed

DAIA_GPT4V/Thinker/thinking.py

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626

2727
from .. import prompts
2828

29+
2930
class Think:
3031
"""
3132
The main class for operations involving the GPT for the DAIA
@@ -121,19 +122,23 @@ def action(
121122
screen_data=screen_data,
122123
suggestion=suggestion,
123124
),
124-
125125
}
126126
],
127-
response_format={"type": "json"}
127+
response_format={"type": "json"},
128128
)
129129
executable = executable.choices[0].message.content
130130
executable = orjson.loads(executable)
131131
# Check if the response returns commands or just 'Not specific'
132132
if executable.get("status") == "impossible":
133133
return "Not specific"
134134
else:
135-
#TODO: Make this clean, changing where the function is called than making some string manipulation magic here
136-
return "\n".join([f"{i}. {command.get('command')} {command.get('parameter')} ({command.get('expected_outcome')})" for i, command in enumerate(executable.get("commands"))])
135+
# TODO: Make this clean, changing where the function is called than making some string manipulation magic here
136+
return "\n".join(
137+
[
138+
f"{i}. {command.get('command')} {command.get('parameter')} ({command.get('expected_outcome')})"
139+
for i, command in enumerate(executable.get("commands"))
140+
]
141+
)
137142

138143
def suggestion_explainer(self, suggestion: str):
139144
"""

DAIA_GPT4V/prompts/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
from .prompts1 import *
1+
from .prompts1 import *

DAIA_GPT4V/prompts/prompts1.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,4 @@
2626
If the suggestion is not specific enough for execution:
2727
- Provide a response in JSON format with a reason for the impossibility:
2828
{"status": "impossible", "commands": [], "reason": "Not specific enough due to [brief explanation]"}
29-
"""
29+
"""

DAIA_GPT4V/run.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
from openai import OpenAI
1919
from . import prompts
2020

21+
2122
def run(api_key):
2223
goal = input("Please enter your goal for the DAIA here: ")
2324

@@ -86,7 +87,7 @@ def run(api_key):
8687
while True:
8788
print(
8889
"(Press ENTER to skip) WARNING: if you skip, the suggestions will be accepted. This is the LAST MANUAL step, everything from here on is automated"
89-
) # TODO: Use ANSI escape codes to make this text red
90+
) # TODO: Use ANSI escape codes to make this text red
9091
agree = input(
9192
"Do you agree with the current suggestions/processes for your goal? (Y/N)"
9293
)

0 commit comments

Comments
 (0)