Skip to content

Commit 9679858

Browse files
Darragh-McGonigleapaparazzi0329
authored andcommitted
chore(comments): Add comment changes to discovery
1 parent 859db47 commit 9679858

File tree

1 file changed

+19
-2
lines changed

1 file changed

+19
-2
lines changed

ibm_watson/discovery_v2.py

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# coding: utf-8
22

3-
# (C) Copyright IBM Corp. 2019, 2024.
3+
# (C) Copyright IBM Corp. 2019, 2025.
44
#
55
# Licensed under the Apache License, Version 2.0 (the "License");
66
# you may not use this file except in compliance with the License.
@@ -14,7 +14,7 @@
1414
# See the License for the specific language governing permissions and
1515
# limitations under the License.
1616

17-
# IBM OpenAPI SDK Code Generator Version: 3.97.0-0e90eab1-20241120-170029
17+
# IBM OpenAPI SDK Code Generator Version: 3.105.0-3c13b041-20250605-193116
1818
"""
1919
IBM Watson® Discovery is a cognitive search and content analytics engine that you can
2020
add to applications to identify patterns, trends and actionable insights to drive better
@@ -1206,6 +1206,23 @@ def delete_document(
12061206
remove subdocuments that are generated by an uploaded file, delete the original
12071207
document instead. You can get the document ID of the original document from the
12081208
`parent_document_id` of the subdocument result.
1209+
If the document with the given document ID exists, Watson Discovery first marks or
1210+
tags the document as deleted when it sends the 200 response code. At a later time
1211+
(within a couple of minutes unless the document has many child documents), it
1212+
removes the document from the collection.
1213+
There is no bulk document delete API. Documents must be deleted one at a time
1214+
using this API. However, you can delete a collection, and all the documents from
1215+
the collection are removed along with the collection.
1216+
The document will be deleted from the given collection only, not from the
1217+
corresponding data source. Wherever relevant, an incremental crawl will not bring
1218+
back the document into Watson Discovery from the data source. Only a full crawl
1219+
will retrieve the deleted document back from the data source provided it is still
1220+
present in the same data source.
1221+
Finally, if multiple collections share the same dataset, deleting a document from
1222+
a collection will remove it from that collection only (in other remaining
1223+
collections the document will still exist). The document will be removed from the
1224+
dataset, if this document is deleted from all the collections that share the same
1225+
dataset.
12091226

12101227
:param str project_id: The Universally Unique Identifier (UUID) of the
12111228
project. This information can be found from the *Integrate and Deploy* page

0 commit comments

Comments
 (0)