mirror of
https://github.com/Significant-Gravitas/AutoGPT.git
synced 2026-04-08 03:00:28 -04:00
linitng fixes
This commit is contained in:
@@ -29,11 +29,6 @@ def save_combined_radar_chart(
|
||||
ax.set_theta_direction(-1) # type: ignore
|
||||
ax.spines["polar"].set_visible(False) # Remove border
|
||||
|
||||
# Define a custom normalization to start the color from the middle
|
||||
norm = Normalize(
|
||||
vmin=0, vmax=max([max(val.values()) for val in categories.values()])
|
||||
) # We use the maximum of all categories for normalization
|
||||
|
||||
cmap = plt.cm.get_cmap("nipy_spectral", len(categories)) # type: ignore
|
||||
|
||||
colors = [cmap(i) for i in range(len(categories))]
|
||||
@@ -57,7 +52,7 @@ def save_combined_radar_chart(
|
||||
) # Draw points
|
||||
|
||||
# Draw legend
|
||||
legend = ax.legend(
|
||||
ax.legend(
|
||||
handles=[
|
||||
mpatches.Patch(color=color, label=cat_name, alpha=0.25)
|
||||
for cat_name, color in zip(categories.keys(), colors)
|
||||
|
||||
@@ -21,7 +21,8 @@ def get_reports_data(report_path: str) -> dict[str, Any]:
|
||||
if latest_files is None:
|
||||
raise Exception("No files found in the reports directory")
|
||||
|
||||
# This will print the latest file in each subdirectory and add to the files_data dictionary
|
||||
# This will print the latest file in each s
|
||||
# ubdirectory and add to the files_data dictionary
|
||||
for subdir, file in latest_files:
|
||||
subdir_name = os.path.basename(os.path.normpath(subdir))
|
||||
with open(Path(subdir) / file, "r") as f:
|
||||
|
||||
@@ -172,7 +172,8 @@ class ForgeAgent(ProtocolAgent, BaseAgent):
|
||||
|
||||
# Call the LLM and parse result
|
||||
# THIS NEEDS TO BE REPLACED WITH YOUR LLM CALL/LOGIC
|
||||
# Have a look at classic/original_autogpt/agents/agent.py for an example (complete_and_parse)
|
||||
# Have a look at classic/original_autogpt/agents/agent.py
|
||||
# for an example (complete_and_parse)
|
||||
proposal = ActionProposal(
|
||||
thoughts="I cannot solve the task!",
|
||||
use_tool=AssistantFunctionCall(
|
||||
|
||||
@@ -176,8 +176,8 @@ async def assert_config_has_required_llm_api_keys(config: AppConfig) -> None:
|
||||
|
||||
logger.error("Set your Groq API key in .env or as an environment variable")
|
||||
logger.info(
|
||||
"For further instructions: " +
|
||||
"https://docs.agpt.co/classic/original_autogpt/setup/#groq"
|
||||
"For further instructions: "
|
||||
+ "https://docs.agpt.co/classic/original_autogpt/setup/#groq"
|
||||
)
|
||||
raise ValueError("Groq is unavailable: can't load credentials")
|
||||
except AuthenticationError as e:
|
||||
@@ -203,8 +203,8 @@ async def assert_config_has_required_llm_api_keys(config: AppConfig) -> None:
|
||||
"Set your OpenAI API key in .env or as an environment variable"
|
||||
)
|
||||
logger.info(
|
||||
"For further instructions: " +
|
||||
"https://docs.agpt.co/classic/original_autogpt/setup/#openai"
|
||||
"For further instructions: "
|
||||
+ "https://docs.agpt.co/classic/original_autogpt/setup/#openai"
|
||||
)
|
||||
raise ValueError("OpenAI is unavailable: can't load credentials")
|
||||
except AuthenticationError as e:
|
||||
|
||||
Reference in New Issue
Block a user