Skip to content

Commit

Permalink
add code trans, refactor code pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
ConorOBrien-Foxx committed Jun 1, 2024
1 parent f36982d commit 796c4da
Show file tree
Hide file tree
Showing 22 changed files with 1,843 additions and 163 deletions.
14 changes: 7 additions & 7 deletions bugs2fix.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,7 @@
"\n",
"prompt_family_answers = []\n",
"for prompt_index in range(len(BUGS2FIX_PROMPTS)):\n",
" output_dir = f\"./data/output/bugs2fix/prompt{prompt_index}\"\n",
" output_dir = f\"./output/bugs2fix/prompt{prompt_index}\"\n",
" family_answers = {}\n",
" for key, model_name in ModelFamily.CodeGen1.multi.items():\n",
" output_path = os.path.join(output_dir, f\"codegen1-multi-{key}.output\")\n",
Expand Down Expand Up @@ -494,7 +494,7 @@
},
{
"cell_type": "code",
"execution_count": 10,
"execution_count": 14,
"id": "febd5f59-0989-46b1-8763-ec72e848e184",
"metadata": {},
"outputs": [
Expand All @@ -510,12 +510,12 @@
}
],
"source": [
"bugs2fix_renderer_em = OutputRenderer(\n",
"bugs2fix_renderer_bleu = OutputRenderer(\n",
" baseline=bleu_baseline,\n",
" metric=\"BLEU\",\n",
")\n",
"\n",
"bugs2fix_renderer_em.render(ys=bleu_metrics)"
"bugs2fix_renderer_bleu.render(ys=bleu_metrics)"
]
},
{
Expand Down Expand Up @@ -570,7 +570,7 @@
},
{
"cell_type": "code",
"execution_count": 13,
"execution_count": 15,
"id": "d47d82e4-4533-4c4c-a749-8b2cf0f5c582",
"metadata": {},
"outputs": [
Expand All @@ -586,12 +586,12 @@
}
],
"source": [
"bugs2fix_renderer_em = OutputRenderer(\n",
"bugs2fix_renderer_codebleu = OutputRenderer(\n",
" baseline=codebleu_baseline,\n",
" metric=\"CodeBLEU\",\n",
")\n",
"\n",
"bugs2fix_renderer_em.render(ys=codebleu_metrics)"
"bugs2fix_renderer_codebleu.render(ys=codebleu_metrics)"
]
},
{
Expand Down
Loading

0 comments on commit 796c4da

Please sign in to comment.