make error more explicit

This commit is contained in:
rasbt 2024-06-08 13:21:40 -05:00
parent a6113fcd33
commit d4dba08922
2 changed files with 4 additions and 4 deletions

View File

@ -560,7 +560,7 @@
" score = query_model(prompt)\n",
" try:\n",
" scores.append(int(score))\n",
" except:\n",
" except ValueError:\n",
" continue\n",
"\n",
" return scores"
@ -666,7 +666,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.4"
"version": "3.10.6"
}
},
"nbformat": 4,

View File

@ -449,7 +449,7 @@
" score = run_chatgpt(prompt, client)\n",
" try:\n",
" scores.append(int(score))\n",
" except:\n",
" except ValueError:\n",
" continue\n",
"\n",
" return scores"
@ -562,7 +562,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.4"
"version": "3.10.6"
}
},
"nbformat": 4,