Skip to content

/AWS1/CL_BDKKNOWLEDGEBASEVEC00

The configuration details for returning the results from the knowledge base vector search.

CONSTRUCTOR

IMPORTING

Optional arguments:

iv_numberofresults TYPE /AWS1/BDKINTEGER /AWS1/BDKINTEGER

The number of text chunks to retrieve; the number of results to return.

iv_overridesearchtype TYPE /AWS1/BDKSEARCHTYPE /AWS1/BDKSEARCHTYPE

By default, Amazon Bedrock decides a search strategy for you. If you're using an Amazon OpenSearch Serverless vector store that contains a filterable text field, you can specify whether to query the knowledge base with a HYBRID search using both vector embeddings and raw text, or SEMANTIC search using only vector embeddings. For other vector store configurations, only SEMANTIC search is available.

io_filter TYPE REF TO /AWS1/CL_BDKRETRIEVALFILTER /AWS1/CL_BDKRETRIEVALFILTER

Specifies the filters to use on the metadata fields in the knowledge base data sources before returning results.

io_implicitfilterconf TYPE REF TO /AWS1/CL_BDKIMPLICITFILTERCONF /AWS1/CL_BDKIMPLICITFILTERCONF

Configuration for implicit filtering in Knowledge Base vector searches. This allows the system to automatically apply filters based on the query context without requiring explicit filter expressions.

io_rerankingconfiguration TYPE REF TO /AWS1/CL_BDKVECTORSRCHRERNKC00 /AWS1/CL_BDKVECTORSRCHRERNKC00

Configuration for reranking search results in Knowledge Base vector searches. Reranking improves search relevance by reordering initial vector search results using more sophisticated relevance models.


Queryable Attributes

numberOfResults

The number of text chunks to retrieve; the number of results to return.

Accessible with the following methods

Method Description
GET_NUMBEROFRESULTS() Getter for NUMBEROFRESULTS, with configurable default
ASK_NUMBEROFRESULTS() Getter for NUMBEROFRESULTS w/ exceptions if field has no val
HAS_NUMBEROFRESULTS() Determine if NUMBEROFRESULTS has a value

overrideSearchType

By default, Amazon Bedrock decides a search strategy for you. If you're using an Amazon OpenSearch Serverless vector store that contains a filterable text field, you can specify whether to query the knowledge base with a HYBRID search using both vector embeddings and raw text, or SEMANTIC search using only vector embeddings. For other vector store configurations, only SEMANTIC search is available.

Accessible with the following methods

Method Description
GET_OVERRIDESEARCHTYPE() Getter for OVERRIDESEARCHTYPE, with configurable default
ASK_OVERRIDESEARCHTYPE() Getter for OVERRIDESEARCHTYPE w/ exceptions if field has no
HAS_OVERRIDESEARCHTYPE() Determine if OVERRIDESEARCHTYPE has a value

filter

Specifies the filters to use on the metadata fields in the knowledge base data sources before returning results.

Accessible with the following methods

Method Description
GET_FILTER() Getter for FILTER

implicitFilterConfiguration

Configuration for implicit filtering in Knowledge Base vector searches. This allows the system to automatically apply filters based on the query context without requiring explicit filter expressions.

Accessible with the following methods

Method Description
GET_IMPLICITFILTERCONF() Getter for IMPLICITFILTERCONFIGURATION

rerankingConfiguration

Configuration for reranking search results in Knowledge Base vector searches. Reranking improves search relevance by reordering initial vector search results using more sophisticated relevance models.

Accessible with the following methods

Method Description
GET_RERANKINGCONFIGURATION() Getter for RERANKINGCONFIGURATION