diff --git a/ch07/03_model-evaluation/llm-instruction-eval-ollama.ipynb b/ch07/03_model-evaluation/llm-instruction-eval-ollama.ipynb index 68f6d67..23c255d 100644 --- a/ch07/03_model-evaluation/llm-instruction-eval-ollama.ipynb +++ b/ch07/03_model-evaluation/llm-instruction-eval-ollama.ipynb @@ -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, diff --git a/ch07/03_model-evaluation/llm-instruction-eval-openai.ipynb b/ch07/03_model-evaluation/llm-instruction-eval-openai.ipynb index 60d3a09..a957e4d 100644 --- a/ch07/03_model-evaluation/llm-instruction-eval-openai.ipynb +++ b/ch07/03_model-evaluation/llm-instruction-eval-openai.ipynb @@ -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,