upd log
This commit is contained in:
10
demo.ipynb
10
demo.ipynb
@@ -2,7 +2,7 @@
|
|||||||
"cells": [
|
"cells": [
|
||||||
{
|
{
|
||||||
"cell_type": "code",
|
"cell_type": "code",
|
||||||
"execution_count": 8,
|
"execution_count": null,
|
||||||
"metadata": {},
|
"metadata": {},
|
||||||
"outputs": [
|
"outputs": [
|
||||||
{
|
{
|
||||||
@@ -274,6 +274,14 @@
|
|||||||
" Final enriched results: 2 passages\n",
|
" Final enriched results: 2 passages\n",
|
||||||
"LEANN Chat response: Python has gained immense popularity significantly more so than C#, becoming one of the most widely used programming languages globally today.\n"
|
"LEANN Chat response: Python has gained immense popularity significantly more so than C#, becoming one of the most widely used programming languages globally today.\n"
|
||||||
]
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "stdout",
|
||||||
|
"output_type": "stream",
|
||||||
|
"text": [
|
||||||
|
"[leann_backend_hnsw.hnsw_embedding_server LOG]: /Users/yichuan/.local/share/uv/python/cpython-3.11.12-macos-aarch64-none/lib/python3.11/multiprocessing/resource_tracker.py:254: UserWarning: resource_tracker: There appear to be 1 leaked semaphore objects to clean up at shutdown\n",
|
||||||
|
"[leann_backend_hnsw.hnsw_embedding_server LOG]: warnings.warn('resource_tracker: There appear to be %d '\n"
|
||||||
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"source": [
|
"source": [
|
||||||
|
|||||||
@@ -375,8 +375,9 @@ class OllamaChat(LLMInterface):
|
|||||||
"stream": False, # Keep it simple for now
|
"stream": False, # Keep it simple for now
|
||||||
"options": kwargs,
|
"options": kwargs,
|
||||||
}
|
}
|
||||||
logger.info(f"Sending request to Ollama: {payload}")
|
logger.debug(f"Sending request to Ollama: {payload}")
|
||||||
try:
|
try:
|
||||||
|
logger.info(f"Sending request to Ollama and waiting for response...")
|
||||||
response = requests.post(full_url, data=json.dumps(payload))
|
response = requests.post(full_url, data=json.dumps(payload))
|
||||||
response.raise_for_status()
|
response.raise_for_status()
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user