From c657731955e4f559ca706e98ef41dda81576de32 Mon Sep 17 00:00:00 2001 From: Hashem Al-Qurashi Date: Wed, 18 Feb 2026 10:04:52 +0200 Subject: [PATCH] fix: use pre-built wheel for llama-cpp-python on Colab The CMAKE build-from-source install fails on Colab because the required build tools are not available in the environment. Replaced with pre-built wheel from the llama-cpp-python wheel index, pinned to 0.2.78 with CUDA 12.4 support. Fixes #16 --- chapter06/Chapter 6 - Prompt Engineering.ipynb | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/chapter06/Chapter 6 - Prompt Engineering.ipynb b/chapter06/Chapter 6 - Prompt Engineering.ipynb index be82822..54f5cdf 100644 --- a/chapter06/Chapter 6 - Prompt Engineering.ipynb +++ b/chapter06/Chapter 6 - Prompt Engineering.ipynb @@ -45,11 +45,7 @@ "execution_count": null, "metadata": {}, "outputs": [], - "source": [ - "# %%capture\n", - "# !pip install langchain>=0.1.17 openai>=1.13.3 langchain_openai>=0.1.6 transformers>=4.40.1 datasets>=2.18.0 accelerate>=0.27.2 sentence-transformers>=2.5.1 duckduckgo-search>=5.2.2\n", - "# !CMAKE_ARGS=\"-DLLAMA_CUBLAS=on\" pip install llama-cpp-python" - ] + "source": "# %%capture\n# !pip install langchain>=0.1.17 openai>=1.13.3 langchain_openai>=0.1.6 transformers>=4.40.1 datasets>=2.18.0 accelerate>=0.27.2 sentence-transformers>=2.5.1 duckduckgo-search>=5.2.2\n# !pip install llama-cpp-python==0.2.78 --extra-index-url https://abetlen.github.io/llama-cpp-python/whl/cu124" }, { "cell_type": "markdown", @@ -1296,4 +1292,4 @@ }, "nbformat": 4, "nbformat_minor": 4 -} +} \ No newline at end of file