Commit Graph

69 Commits

Author SHA1 Message Date
Nicholas Albion
4f54e96f4e improved logging 2023-10-06 18:26:48 +11:00
Nicholas Albion
44cdea0381 renamed wrapper() retry_wrapper() so that it's more obvious in logs 2023-10-06 14:21:56 +11:00
Nicholas Albion
f7cf358648 resolved TODO 2023-10-06 14:08:45 +11:00
Nicholas Albion
a6a1476066 "Expecting value" thrown in 2 scenarios:
- expecting more value (send me the rest)
- expecting valid value (`True` is not a value)
2023-10-06 14:01:20 +11:00
Nicholas Albion
5ef248ff5f #132 clean_json_response() fix case of booleans in JSON 2023-10-06 09:03:45 +11:00
Nicholas Albion
29739df59b #132 handle "Invalid" errors in JSONDecodeError - more work needed 2023-10-05 20:42:08 +11:00
Nicholas Albion
a38c35fafa #131 if process_name is specified to execute_command() keep the process alive 2023-10-05 20:39:01 +11:00
Nicholas Albion
1bc25c331c e.msg may also be 'Unterminated string starting at' or other values 2023-10-05 12:47:40 +11:00
Nicholas Albion
908fec154e tidy up 2023-10-04 16:18:05 +11:00
Nicholas Albion
c1e47ceb8b testing new ApiKeyNotDefinedError in CI 2023-10-04 16:06:47 +11:00
Nicholas Albion
9251c1831e model = os.getenv('MODEL_NAME', 'gpt-4') - which makes sense as CI doesn't have my env 2023-10-04 15:50:45 +11:00
Nicholas Albion
366e88dc4d more debug 2023-10-04 15:47:47 +11:00
Nicholas Albion
11da00605a more logging 2023-10-04 15:42:50 +11:00
Nicholas Albion
8914bb438e added debuggin logs for CI 2023-10-04 15:39:11 +11:00
Nicholas Albion
cbac991bd9 avoid getting stuck in a loop if LLM can't conform to schema. 2023-10-04 15:23:36 +11:00
Nicholas Albion
0d8a4c7fee try without logger.error(str, e) 2023-10-04 14:56:16 +11:00
Nicholas Albion
a63aedb2b1 fix for #130 2023-10-04 14:53:22 +11:00
Nicholas Albion
8c26ce7674 logger.warn() is deprecated 2023-10-04 13:17:21 +11:00
LeonOstrez
d6a677c35a enable retrying request for extension if API call fails 2023-10-02 18:28:13 +01:00
Nicholas Albion
1376c11647 added logging 2023-10-02 20:08:15 +11:00
Nicholas Albion
5fdc853768 GPT4 responded with a JSON object != schema.
Retry the request, advising what the issue was
2023-10-02 18:59:38 +11:00
LeonOstrez
4c1fe834a8 fix getting args.root, ask feedback only on success and keyboard interrupt (not on exceptions), fix terminal width and erasing old logs 2023-09-29 13:31:11 +01:00
Nicholas Albion
7bf5de8861 Improved logging 2023-09-29 18:18:55 +10:00
Nicholas Albion
2aaa914c26 Merge branch 'main' into debugging_ipc
# Conflicts:
#	README.md
#	pilot/helpers/agents/CodeMonkey.py
#	pilot/helpers/agents/Developer.py
#	pilot/prompts/system_messages/architect.prompt
#	pilot/utils/arguments.py
#	pilot/utils/llm_connection.py
#	pilot/utils/utils.py
2023-09-28 13:53:49 +10:00
Nicholas Albion
108271f28a ignore ': OPENROUTER PROCESSING' 2023-09-27 13:10:52 +10:00
Nicholas Albion
6dd5a032fa Improved JSON prompting for GPT-4 and recover incomplete JSON responses from Code Llama 2023-09-27 10:53:44 +10:00
Nicholas Albion
e5e0f56d2e JSON validation working 2023-09-26 19:38:24 +10:00
Nicholas Albion
8a024c2ff2 rejecting responses that are not JSON.
Need to fix prompts for GPT-4
2023-09-26 17:27:54 +10:00
Nicholas Albion
b317f58550 clean up 2023-09-23 16:27:02 +10:00
Nicholas Albion
156b361263 function_call-style JSON response from gpt-4, gpt-3_5, codellama, palm-2-chat-bison 2023-09-23 00:45:23 +10:00
Nicholas Albion
d4879a04b7 ARCHITECTURE function_calls works on meta-llama/codellama-34b-instruct 2023-09-21 23:05:37 +10:00
Nicholas Albion
2b4186a4f8 test_chat_completion_Architect passes 2023-09-20 23:15:37 +10:00
Nicholas Albion
4b7aa2df22 get_prompt() moved from llm_connection to utils and works from unit tests 2023-09-20 22:17:37 +10:00
Nicholas Albion
0660244017 fabulous does not work on Windows 2023-09-20 22:14:59 +10:00
Zvonimir Sabljic
ffe4fbeba9 Enabled catching of max token limit errors from OpenAI's response 2023-09-18 19:18:54 -07:00
LeonOstrez
67209b5b27 merge master into debugging_ipc branch 2023-09-18 19:09:37 -07:00
Zvonimir Sabljic
65135344ab Converted colored leftovers 2023-09-15 09:43:30 +02:00
Zvonimir Sabljic
9a7c15e0c5 Merge branch 'ipc' into debugging_ipc 2023-09-14 09:40:36 +02:00
Zvonimir Sabljic
151aa051e2 Improved debugging process and enabled splitting of app development into tasks and then into steps
- split step implementation into different functions
- standardized the return value in the implementation process - { "success": True }
- added propagation of errors back to the recursion level 0 with TooDeepRecursionError and TokenLimitError
- created new class Debugger and moved debugging in it
2023-09-12 21:32:56 +02:00
Zvonimir Sabljic
19ac692509 Don't send max_tokens to openai api so we can use as much context as possible 2023-09-12 21:28:01 +02:00
Nicholas Albion
54bee95a8c Merge remote-tracking branch 'origin/main'
# Conflicts:
#	README.md
#	pilot/helpers/AgentConvo.py
#	pilot/utils/llm_connection.py
2023-09-12 22:57:48 +10:00
LeonOstrez
b023205a53 Merge pull request #85 from alter123/patch-1
Add check when the response is empty
2023-09-12 08:40:07 +02:00
LeonOstrez
9ffcdf79bb Merge pull request #82 from nalbion/feature/test_CodeMonkey
Feature/test code monkey
2023-09-12 08:09:12 +02:00
Jay
74cbe33421 Add check when the response is empty
{
  "id": "",
  "object": "",
  "created": 0,
  "model": "",
  "prompt_annotations": [
    {
      "prompt_index": 0,
      "content_filter_results": {
        "hate": { "filtered": false, "severity": "safe" },
        "self_harm": { "filtered": false, "severity": "safe" },
        "sexual": { "filtered": false, "severity": "safe" },
        "violence": { "filtered": false, "severity": "safe" }
      }
    }
  ],
  "choices": [],
  "usage": null
}


In newer versions of models, at times choices array can be empty
2023-09-12 00:01:13 +05:30
Nicholas Albion
a94cbf9209 added documentation 2023-09-11 22:15:26 +10:00
Nicholas Albion
a8008b263e Merge branch 'feature/prompts_and_agents_documentation' 2023-09-11 14:18:10 +10:00
Nicholas Albion
578a665f19 Merge remote-tracking branch 'origin/main'
# Conflicts:
#	pilot/helpers/agents/Developer.py
#	pilot/utils/arguments.py
#	pilot/utils/llm_connection.py
2023-09-11 14:15:11 +10:00
Goon
3b207987aa Merge remote-tracking branch 'upstream/main' 2023-09-11 10:26:05 +07:00
Goon
c39346868a fix(gitignore): rm cache 2023-09-11 10:08:57 +07:00
Goon
367caa1797 fix(gitignore): rm pilot-env and cache 2023-09-11 10:08:42 +07:00