docs for batch size (#1082)

searx-api
Harrison Chase 1 year ago committed by GitHub
parent 5e10e19bfe
commit 971458c5de
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -365,6 +365,20 @@
"chain({\"input_documents\": docs, \"question\": query}, return_only_outputs=True)"
]
},
{
"cell_type": "markdown",
"id": "d943c6c1",
"metadata": {},
"source": [
"**Batch Size**\n",
"\n",
"When using the `map_reduce` chain, one thing to keep in mind is the batch size you are using during the map step. If this is too high, it could cause rate limiting errors. You can control this by setting the batch size on the LLM used. Note that this only applies for LLMs with this parameter. Below is an example of doing so:\n",
"\n",
"```python\n",
"llm = OpenAI(batch_size=5, temperature=0)\n",
"```"
]
},
{
"cell_type": "markdown",
"id": "5bf0e1ab",

@ -356,6 +356,20 @@
"chain({\"input_documents\": docs, \"question\": query}, return_only_outputs=True)"
]
},
{
"cell_type": "markdown",
"id": "6391b7ab",
"metadata": {},
"source": [
"**Batch Size**\n",
"\n",
"When using the `map_reduce` chain, one thing to keep in mind is the batch size you are using during the map step. If this is too high, it could cause rate limiting errors. You can control this by setting the batch size on the LLM used. Note that this only applies for LLMs with this parameter. Below is an example of doing so:\n",
"\n",
"```python\n",
"llm = OpenAI(batch_size=5, temperature=0)\n",
"```"
]
},
{
"cell_type": "markdown",
"id": "6ea50ad0",

Loading…
Cancel
Save