API: show status of parsing (#1504)

### What problem does this PR solve?

show status of parsing.

### Type of change

- [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
cecilia-uu
2024-07-15 17:18:44 +08:00
committed by GitHub
parent 258a10fb74
commit 1a6bd437f5
3 changed files with 69 additions and 0 deletions

View File

@ -159,7 +159,11 @@ class RAGFlow:
# ----------------------------stop parsing-----------------------------------------------------
# ----------------------------show the status of the file-----------------------------------------------------
def show_parsing_status(self, dataset_id, document_id):
endpoint = f"{self.dataset_url}/{dataset_id}/documents/{document_id}/status"
res = requests.get(endpoint, headers=self.authorization_header)
return res.json()
# ----------------------------list the chunks of the file-----------------------------------------------------
# ----------------------------delete the chunk-----------------------------------------------------