feat: notion loader (#405)

This commit is contained in:
cachho
2023-08-09 09:45:22 +02:00
committed by GitHub
parent eeac84e2d9
commit ce6eb39009
7 changed files with 81 additions and 2 deletions

View File

@@ -54,6 +54,18 @@ To add any code documentation website as a loader, use the data_type as `docs_si
app.add("docs_site", "https://docs.embedchain.ai/")
```
### Notion
To use notion you must install the extra dependencies with `pip install embedchain[notion]`.
To load a notion page, use the data_type as `notion`.
The next argument must **end** with the `notion page id`. The id is a 32-character string. Eg:
```python
app.add("notion", "cfbc134ca6464fc980d0391613959196")
app.add("notion", "my-page-cfbc134ca6464fc980d0391613959196")
app.add("notion", "https://www.notion.so/my-page-cfbc134ca6464fc980d0391613959196")
```
### Text
To supply your own text, use the data_type as `text` and enter a string. The text is not processed, this can be very versatile. Eg:

View File

@@ -46,6 +46,7 @@ Default values of chunker config parameters for different `data_type`:
|pdf_file|1000|0|len|
|youtube_video|2000|0|len|
|docs_site|500|50|len|
|notion|300|0|len|
### LoaderConfig