feat: support env var LLM_DUMP_RESULTS (#144)

This commit is contained in:
sigoden
2024-12-12 12:22:51 +08:00
committed by GitHub
parent 2fc9b47690
commit 3584b5c31f
9 changed files with 129 additions and 197 deletions
+3 -3
View File
@@ -28,7 +28,7 @@ run@tool() {
fi
lang="${argc_tool##*.}"
cmd="$(_lang_to_cmd "$lang")"
run_tool_script="$PWD/scripts/run-tool.$lang"
run_tool_script="scripts/run-tool.$lang"
[[ -n "$argc_cwd" ]] && cd "$argc_cwd"
exec "$cmd" "$run_tool_script" "$argc_tool" "$argc_json"
}
@@ -52,7 +52,7 @@ run@agent() {
tools_path="$(_get_agent_tools_path "$argc_agent")"
lang="${tools_path##*.}"
cmd="$(_lang_to_cmd "$lang")"
run_agent_script="$PWD/scripts/run-agent.$lang"
run_agent_script="scripts/run-agent.$lang"
[[ -n "$argc_cwd" ]] && cd "$argc_cwd"
exec "$cmd" "$run_agent_script" "$argc_agent" "$argc_action" "$argc_json"
}
@@ -163,7 +163,7 @@ build-declarations@tool() {
build_failed_tools+=("$name")
}
if [[ "$json_data" == "null" ]]; then
_die "error: failed to build declartions for tool $name"
_die "error: failed to build declarations for tool $name"
fi
json_list+=("$json_data")
done