Skip to content
This repository has been archived by the owner on Mar 1, 2024. It is now read-only.

Microsoft SharePoint Data Loader #745

Merged
merged 6 commits into from
Dec 8, 2023

Conversation

arun-soliton
Copy link
Contributor

@arun-soliton arun-soliton commented Dec 7, 2023

Description

Microsoft SharePoint Data Loader for llama-hub

Fixes # (issue)
#674

Type of Change

Please delete options that are not relevant.

  • New Loader/Tool
  • Bug fix / Smaller change
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

  • Added new unit/integration tests
  • Added new notebook (that tests end-to-end)
  • I stared at the code and made sure it makes sense
  • I created a package using poetry build and tested locally

Suggested Checklist:

  • I have added a library.json file if a new loader/tool was added
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • I ran make format; make lint to appease the lint gods

@anoopshrma
Copy link
Collaborator

Awesome! Thanks for the contribution.
Could you check the conflict and checks that failed!!

Thanks!

@arun-soliton
Copy link
Contributor Author

@anoopshrma Updated. Kindly check!

@EmanuelCampos EmanuelCampos merged commit adf1620 into run-llama:main Dec 8, 2023
3 checks passed
@arun-soliton
Copy link
Contributor Author

@anoopshrma @EmanuelCampos Thank you for accepting the PR and approving it 🙂!

@arun-soliton arun-soliton deleted the arun/sharepoint-loader branch December 8, 2023 17:19
@arun-soliton arun-soliton restored the arun/sharepoint-loader branch December 8, 2023 17:19
@lilz12
Copy link

lilz12 commented Jan 30, 2024

I am trying to use llama_index SharePointLoader and am getting error that my site does not exist, but the link that prints out in the error message works and brings me to my site. Any ideas?

@arun04cbe
Copy link

@lilz12 #901

@lilz12
Copy link

lilz12 commented Jan 31, 2024

@arun04cbe Thank you! I wasn't sure if that was the same issue. Do you have example of string to pass for SharePoint site?
This is what I am trying:

loader = SharePointLoader(
client_id = "app_client_id",
client_secret = "app_cert_secrete_value",
tenant_id = "azure_tenant_id"
)

documents = loader.load_data(
sharepoint_site_name = "https://wmsafety.sharepoint.com/sites/WMSC",
sharepoint_folder_path = "Reference%20Codes",
recursive = True,
)

ERROR:custom_module:An error occurred while accessing SharePoint: The specified sharepoint site https://wmsafety.sharepoint.com/sites/WMSC is not found.

@arun04cbe
Copy link

@lilz12 Just pass the SharePoint site name. In your case just pass WMSC. And if the folder in documents library is Data/Folder. Pass Data/Folder in folder path

@lilz12
Copy link

lilz12 commented Jan 31, 2024

@arun04cbe Within the SharePoint site, it looks like you can have additional sites. So once I'm at my SharePoint site name, I navigate to the site, "Technical Writers" and then the folder is "Reference Codes". Could that be the problem that there are multiple sites under WMSC?

@arun04cbe
Copy link

arun04cbe commented Jan 31, 2024

I am not aware on having additional sites in SharePoint site. Current implementation works for the parent Site. There is also an issues mentioned at #901. Kindly take a look at it also.

@lilz12
Copy link

lilz12 commented Jan 31, 2024 via email

@arun04cbe
Copy link

@lilz12 could you try giving Folder path as Reference/Codes

@lilz12
Copy link

lilz12 commented Jan 31, 2024 via email

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants