document_search
Search for documents by content and metadata criteria, narrowing results with filter conditions. Returns only released versions of matching documents.
Instructions
PREREQUISITES IN ORDER: To use this tool, you MUST call two other tools first in a specific sequence.
determine_class tool to get the class_name for search_class. The search class must be a document class or a document subclass.
get_searchable_property_descriptions to get a list of valid property_name for search_properties
Description: This tool will execute a request to search for documents based on content and the metadata criteria.
:param search_term: The words for CBR search. This will be used to search for documents based on their CBR indexed content and metadata If empty string or None, then only search by metadata.
:param search_parameters (SearchParameters): provide parameters search_class and addiontal search conditions. Note the search_class is filled in by determine_class tool. search_properties inside search_parameters include any property being searched for and any search conditions. Note: additional properties beside the search_class are used to narrow down the result set, not to expand the result set, ie it does not make sense to support prompt such as: get me all XXXCBRDocClass documents that are created by XXXuser OR contains 'XXX Content' . For CBR, Content search will be carried out first to get a result set and additional properties are placed on this result set to narrow it down.
:returns: the released versions of documents that fit the search criteria. - if search by content and CBR is not enabled, tool will return a ToolError.
Example of search by content and class is CBR enabled: Prompt: get me all XXXCBRDocClass documents that are created by XXXuser and contains 'XXX Content' Request: { "doc_class": "XXXCBRDocClass", "max_results": 50, "search_parameters": { "search_class": "XXXCBRDocClass", "search_properties": [ { "operator": "=", "property_name": "Creator", "property_value": "XXXuser" } ] }, "search_term": "XXX Content" }
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| search_parameters | Yes | Complete set of parameters for executing a repository search. | |
| search_term | No | ||
| max_results | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |