2023-04-11 17:40:32 +00:00
|
|
|
{
|
|
|
|
"cells": [
|
|
|
|
{
|
|
|
|
"cell_type": "markdown",
|
|
|
|
"id": "66a7777e",
|
|
|
|
"metadata": {},
|
|
|
|
"source": [
|
2023-05-16 17:13:57 +00:00
|
|
|
"# BiliBili\n",
|
2023-04-11 17:40:32 +00:00
|
|
|
"\n",
|
2023-05-06 00:44:54 +00:00
|
|
|
">[Bilibili](https://www.bilibili.tv/) is one of the most beloved long-form video sites in China.\n",
|
|
|
|
"\n",
|
|
|
|
"This loader utilizes the [bilibili-api](https://github.com/MoyuScript/bilibili-api) to fetch the text transcript from `Bilibili`.\n",
|
2023-04-11 17:40:32 +00:00
|
|
|
"\n",
|
|
|
|
"With this BiliBiliLoader, users can easily obtain the transcript of their desired video content on the platform."
|
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"cell_type": "code",
|
2023-05-02 22:24:53 +00:00
|
|
|
"execution_count": null,
|
|
|
|
"id": "43128d8d",
|
|
|
|
"metadata": {
|
|
|
|
"tags": []
|
|
|
|
},
|
2023-04-11 17:40:32 +00:00
|
|
|
"outputs": [],
|
|
|
|
"source": [
|
2023-05-18 13:56:51 +00:00
|
|
|
"#!pip install bilibili-api-python"
|
2023-04-11 17:40:32 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"cell_type": "code",
|
2023-05-02 22:24:53 +00:00
|
|
|
"execution_count": null,
|
|
|
|
"id": "9ec8a3b3",
|
|
|
|
"metadata": {
|
|
|
|
"tags": []
|
|
|
|
},
|
2023-04-11 17:40:32 +00:00
|
|
|
"outputs": [],
|
|
|
|
"source": [
|
2023-05-16 17:13:57 +00:00
|
|
|
"from langchain.document_loaders import BiliBiliLoader"
|
2023-04-11 17:40:32 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"cell_type": "code",
|
|
|
|
"execution_count": 13,
|
|
|
|
"id": "35d6809a",
|
|
|
|
"metadata": {
|
|
|
|
"pycharm": {
|
|
|
|
"name": "#%%\n"
|
|
|
|
}
|
|
|
|
},
|
|
|
|
"outputs": [],
|
|
|
|
"source": [
|
2023-06-16 18:52:56 +00:00
|
|
|
"loader = BiliBiliLoader([\"https://www.bilibili.com/video/BV1xt411o7Xu/\"])"
|
2023-04-11 17:40:32 +00:00
|
|
|
]
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"cell_type": "code",
|
|
|
|
"execution_count": null,
|
2023-05-02 22:24:53 +00:00
|
|
|
"id": "3470dadf",
|
2023-04-11 17:40:32 +00:00
|
|
|
"metadata": {
|
|
|
|
"collapsed": false,
|
2023-05-02 22:24:53 +00:00
|
|
|
"jupyter": {
|
|
|
|
"outputs_hidden": false
|
|
|
|
},
|
2023-04-11 17:40:32 +00:00
|
|
|
"pycharm": {
|
|
|
|
"name": "#%%\n"
|
|
|
|
}
|
2023-05-02 22:24:53 +00:00
|
|
|
},
|
|
|
|
"outputs": [],
|
|
|
|
"source": [
|
|
|
|
"loader.load()"
|
|
|
|
]
|
2023-04-11 17:40:32 +00:00
|
|
|
}
|
|
|
|
],
|
|
|
|
"metadata": {
|
|
|
|
"kernelspec": {
|
|
|
|
"display_name": "Python 3 (ipykernel)",
|
|
|
|
"language": "python",
|
|
|
|
"name": "python3"
|
|
|
|
},
|
|
|
|
"language_info": {
|
|
|
|
"codemirror_mode": {
|
|
|
|
"name": "ipython",
|
|
|
|
"version": 3
|
|
|
|
},
|
|
|
|
"file_extension": ".py",
|
|
|
|
"mimetype": "text/x-python",
|
|
|
|
"name": "python",
|
|
|
|
"nbconvert_exporter": "python",
|
|
|
|
"pygments_lexer": "ipython3",
|
2023-05-02 22:24:53 +00:00
|
|
|
"version": "3.10.6"
|
2023-04-11 17:40:32 +00:00
|
|
|
}
|
|
|
|
},
|
|
|
|
"nbformat": 4,
|
|
|
|
"nbformat_minor": 5
|
2023-05-02 22:24:53 +00:00
|
|
|
}
|