Skip to content

The agent engineering platform.

Update llama.cpp and Ollama templates (#12466)

Lance Martin5c2243ee91d2
diff --git a/templates/sql-llamacpp/sql-llamacpp.ipynb b/templates/sql-llamacpp/sql-llamacpp.ipynb
index b3bf2c3e48..412177f9c1 100644
--- a/templates/sql-llamacpp/sql-llamacpp.ipynb
+++ b/templates/sql-llamacpp/sql-llamacpp.ipynb
@@ -19,10 +19,21 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 1,
"id": "ff5869c6-2065-48f3-bb43-52a515968276",
"metadata": {},
- "outputs": [],
+ "outputs": [
+ {
+ "data": {
+ "text/plain": [
+ "'\\nNatural Language Response: Klay Thompson plays for the Golden State Warriors.'"
+ ]
+ },
+ "execution_count": 1,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
"source": [
"from langserve.client import RemoteRunnable\n",
"sql_app = RemoteRunnable('http://0.0.0.0:8001/sql_llamacpp')\n",
diff --git a/templates/sql-ollama/pyproject.toml b/templates/sql-ollama/pyproject.toml
index 0ad5689758..e8ed637ffa 100644
--- a/templates/sql-ollama/pyproject.toml
+++ b/templates/sql-ollama/pyproject.toml
@@ -1,5 +1,5 @@
[tool.poetry]
-name = "sql_ollama"
+name = "sql-ollama"
version = "0.1.0"
description = ""
authors = ["Lance Martin <[email protected]>"]
diff --git a/templates/sql-ollama/sql-ollama.ipynb b/templates/sql-ollama/sql-ollama.ipynb
index e41c07e8fe..6498e051c7 100644
--- a/templates/sql-ollama/sql-ollama.ipynb
+++ b/templates/sql-ollama/sql-ollama.ipynb
@@ -19,10 +19,21 @@
},
{
"cell_type": "code",
- "execution_count": null,
+ "execution_count": 1,
"id": "50c27e82-92d8-4fa1-8bc4-b6544e59773d",
"metadata": {},
- "outputs": [],
+ "outputs": [
+ {
+ "data": {
+ "text/plain": [
+ "AIMessage(content=' Sure! Here\\'s the natural language response based on the input:\\n\\n\"Klay Thompson plays for the Golden State Warriors.\"')"
+ ]
+ },
+ "execution_count": 1,
+ "metadata": {},
+ "output_type": "execute_result"
+ }
+ ],
"source": [
"from langserve.client import RemoteRunnable\n",
"sql_app = RemoteRunnable('http://0.0.0.0:8001/sql_ollama')\n",
diff --git a/templates/sql-ollama/sql_ollama/__init__.py b/templates/sql-ollama/sql_ollama/__init__.py
index d92f805522..25bdf9683f 100644
--- a/templates/sql-ollama/sql_ollama/__init__.py
+++ b/templates/sql-ollama/sql_ollama/__init__.py
@@ -1,3 +1,3 @@
-from ollama.chain import chain
+from sql_ollama.chain import chain
__all__ = ["chain"]
\ No newline at end of file