You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
Go to file
Beck LaBash 94e7bf7d46 Prompts 1 year ago
benchmarks sample of 30 1 year ago
executors Prompts 1 year ago
generators Prompts 1 year ago
lazzzy@404c06a5bf . 2 years ago
media media imgs 2 years ago
root Prompts 1 year ago
scratch . 2 years ago
.gitignore Leetcode Hard: Python3 Benchmark 2 years ago
.gitmodules LeetExecutor implementation 2 years ago
2023-04-16_12-09-25 Prompts 1 year ago
LICENSE Initial commit 2 years ago
README.md bold 1 year ago
dataset_random_sample.py dataeset get 1 year ago
generate_dataset.py resume and optz 2 years ago
immediate_refinement.py new scripts 1 year ago
immediate_reflexion.py immediate reflexion 1 year ago
main.py Merge branch 'main' of https://github.com/GammaTauAI/reflexion-human-eval-private 1 year ago
plot.py all 2 years ago
reflexion.py Prompts 1 year ago
reflexion_mbpp_py_logs . 2 years ago
reflexion_mbpp_py_logs2 . 2 years ago
reflexion_ucs.py Fixes 1 year ago
requirements.txt working on ucs version of reflexion 2 years ago
run_immediate_refinement.sh new scripts 1 year ago
run_immediate_reflexion.sh new scripts 1 year ago
run_reflexion.sh . 2 years ago
run_reflexion_py_leet.sh Prompts 1 year ago
run_reflexion_ucs.sh . 2 years ago
run_simple.sh . 2 years ago
run_simple_py_leet.sh Fixes 1 year ago
run_testacc.sh run testacc 1 year ago
simple.py Fixes 1 year ago
simple_mbpp_py2_logs . 2 years ago
simple_mbpp_py_logs . 2 years ago
test_acc.py Fixes 1 year ago
utils.py print only if verbose 2 years ago
validate_py_results.py validate 2 years ago
validate_rs_results.py validate rs 2 years ago

README.md

Mastering HumanEval with Reflexion

This is a spin-off project inspired by the paper: Reflexion: an autonomous agent with dynamic memory and self-reflection. Noah Shinn, Beck Labash, Ashwin Gopinath. Preprint, 2023

Read more about this project in this post.

Check out an interesting type-inference implementation here: OpenTau

Check out the code for the original paper here

If you have any questions, please contact noahshinn024@gmail.com

architecture

result

Cloning The Repository

The repository contains git submodules. To clone the repo with the submodules, run:

git clone --recurse-submodules

Note

Due to the nature of these experiments, it may not be feasible for individual developers to rerun the results due to limited access to GPT-4 and significant API charges. Due to recent requests, both trials have been rerun once more and are dumped in ./root with a script here to validate the solutions with the unit tests provided by HumanEval.

To run the validation on your log files or the provided log files:

python ./validate_py_results.py <path to jsonlines file>

Warning

Please do not run the Reflexion agent in an unsecure environment as the generated code is not validated before execution.

Cite

Note: This is a spin-off implementation that implements a relaxation on the internal success criteria proposed in the original paper.

@article{shinn2023reflexion,
  title={Reflexion: an autonomous agent with dynamic memory and self-reflection},
  author={Shinn, Noah and Labash, Beck and Gopinath, Ashwin},
  journal={arXiv preprint arXiv:2303.11366},
  year={2023}
}