Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 3 additions & 10 deletions cookbook/agentic_retrieval.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -339,11 +339,7 @@
"source": [
"query = \"What are the evaluation methods used in this paper?\"\n",
"\n",
"for chunk in pi_client.chat_completions(\n",
" messages=[{\"role\": \"user\", \"content\": query}],\n",
" doc_id=doc_id,\n",
" stream=True\n",
"):\n",
"for chunk in pi_client.chat(query, doc_id=doc_id, stream=True):\n",
" print(chunk, end='', flush=True)"
]
},
Expand Down Expand Up @@ -426,11 +422,8 @@
"\n",
"full_response = \"\"\n",
"\n",
"for chunk in pi_client.chat_completions(\n",
" messages=[{\"role\": \"user\", \"content\": retrieval_prompt}],\n",
" doc_id=doc_id,\n",
" stream=True\n",
"):\n",
"for chunk in pi_client.chat(retrieval_prompt, doc_id=doc_id, stream=True,\n",
" show_process=False):\n",
" print(chunk, end='', flush=True)\n",
" full_response += chunk"
]
Expand Down
Loading
Loading