A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://python.langchain.com/docs/integrations/document_loaders/rspace/ below:

rspace | 🦜️🔗 LangChain

rspace

This notebook shows how to use the RSpace document loader to import research notes and documents from RSpace Electronic Lab Notebook into Langchain pipelines.

To start you'll need an RSpace account and an API key.

You can set up a free account at https://community.researchspace.com or use your institutional RSpace.

You can get an RSpace API token from your account's profile page.

%pip install --upgrade --quiet  rspace_client

It's best to store your RSpace API key as an environment variable.

RSPACE_API_KEY=<YOUR_KEY>

You'll also need to set the URL of your RSpace installation e.g.

RSPACE_URL=https://community.researchspace.com

If you use these exact environment variable names, they will be detected automatically.

from langchain_community.document_loaders.rspace import RSpaceLoader

You can import various items from RSpace:





rspace_ids = ["NB1932027", "FL1921314", "SD1932029", "GL1932384"]
for rs_id in rspace_ids:
loader = RSpaceLoader(global_id=rs_id)
docs = loader.load()
for doc in docs:

print(doc.metadata)
print(doc.page_content[:500])

If you don't want to use the environment variables as above, you can pass these into the RSpaceLoader

loader = RSpaceLoader(
global_id=rs_id, api_key="MY_API_KEY", url="https://my.researchspace.com"
)

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4