Add Sources to an Index

Add URLs to an Index

1from reasoner import Reasoner
2
3r = Reasoner(api_key=”foobar”)
4index = r.indexes.get("your-index-uid")
5r.indexes.add_urls(['https://reasoner.com'], index["uid"])

Add Files to an Index

1from reasoner import Reasoner
2
3r = Reasoner(api_key=”foobar”)
4index = r.indexes.get("your-index-uid")
5files_or_dirs = [list of Path]
6r.indexes.add_documents(files_or_dirs, index["uid"])