Skip to content

The agent engineering platform.

docs: update documentation of stackexchange component (#18486)

aditya thomas7803b973c735
diff --git a/docs/docs/integrations/tools/stackexchange.ipynb b/docs/docs/integrations/tools/stackexchange.ipynb
index 2f9dcd1170..1ade7c33de 100644
--- a/docs/docs/integrations/tools/stackexchange.ipynb
+++ b/docs/docs/integrations/tools/stackexchange.ipynb
@@ -6,29 +6,19 @@
"source": [
"# StackExchange\n",
"\n",
- "This notebook goes over how to use the stack exchange component.\n",
+ ">[Stack Exchange](https://stackexchange.com/) is a network of question-and-answer (Q&A) websites on topics in diverse fields, each site covering a specific topic, where questions, answers, and users are subject to a reputation award process. The reputation system allows the sites to be self-moderating.\n",
"\n",
- "All you need to do is install stackapi:\n",
- "1. pip install stackapi\n",
- "\n"
- ]
- },
- {
- "cell_type": "code",
- "execution_count": null,
- "metadata": {},
- "outputs": [],
- "source": [
- "pip install stackapi"
+ "The ``StackExchange`` component integrates the StackExchange API into LangChain allowing access to the [StackOverflow](https://stackoverflow.com/) site of the Stack Excchange network. Stack Overflow focuses on computer programming.\n",
+ "\n",
+ "\n",
+ "This notebook goes over how to use the ``StackExchange`` component."
]
},
{
- "cell_type": "code",
- "execution_count": null,
+ "cell_type": "markdown",
"metadata": {},
- "outputs": [],
"source": [
- "from langchain_community.utilities import StackExchangeAPIWrapper"
+ "We first have to install the python package stackapi which implements the Stack Exchange API."
]
},
{
@@ -37,7 +27,7 @@
"metadata": {},
"outputs": [],
"source": [
- "stackexchange = StackExchangeAPIWrapper()"
+ "pip install --upgrade stackapi"
]
},
{
@@ -46,13 +36,17 @@
"metadata": {},
"outputs": [],
"source": [
+ "from langchain_community.utilities import StackExchangeAPIWrapper\n",
+ "\n",
+ "stackexchange = StackExchangeAPIWrapper()\n",
+ "\n",
"stackexchange.run(\"zsh: command not found: python\")"
]
}
],
"metadata": {
"kernelspec": {
- "display_name": "Python 3",
+ "display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
},
@@ -66,7 +60,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
- "version": "3.8.8"
+ "version": "3.9.6"
}
},
"nbformat": 4,