# Knowledge Base connections for AI

A Knowledge Base function retrieves external information for an AI feature to use in its answers.

*Release 3.3 · developer, operator*

**Settings › AI › Functions** · **Settings › AI › Features**

## What it is

A **Knowledge Base** function searches an external information service when an AI feature needs supporting content. The feature can use the returned matches to answer a question. Where configured, the answer can also identify its sources.

## Who uses it and why

Developers configure the search service and the information to retrieve. Operators use AI assistance backed by that content. Visitors receive the resulting answer through the AI feature handling their conversation.

## Where to find it

Create or edit a **Knowledge Base** function in **Settings › AI › Functions**, then make it available to the appropriate feature in **Settings › AI › Features**.

These are client-managed screens for the **Developer** role, or the **Settings** role with **AI** access. Operators do not need configuration access to use an enabled AI feature.

## How it works

1. An enabled AI feature calls a knowledge function available to it with a search question.
2. INSIDE sends the question to the selected external service.
3. The service returns matching content. The AI feature receives those results for its next response.
4. Citation configuration can let the feature show where the information came from. A search match alone does not guarantee a visible citation.

Weaviate offers these search choices:

| Choice | Search behaviour |
|---|---|
| **Keyword** | Matches words in the question; no embedding request is needed. |
| **Vector** | Uses an embedding of the question to find content with similar meaning. |
| **Hybrid** | Combines word and meaning matching; verify the saved function with Powerfront before relying on this choice in 3.3. |

Weaviate requests can include the visitor's website and subsite context when a subsite is available. They can also include the assigned operator and that operator's teams. The external search service must apply any required content restrictions.

## Configure it

1. Choose **Knowledge Base** when adding a function, then select **Knowledge Base Type**.
2. For **Weaviate**, enter **Host**, **API Key** and the appropriate **Class Name**. Select **Weaviate Query Type**, choose **Fields** to return and optionally set **Results**. The default result count is 5. Configure the separate embedding options for Vector or Hybrid.
3. For **Amazon Bedrock**, supply **AWS Access Key ID**, **AWS Secret Access Key**, **AWS Region** and **Knowledge Base ID**. **Number of Results** defaults to 10 when omitted. This retrieval connection is separate from the Bedrock model account.
4. **Algolia Search** is another visible service choice. Its setup and other enterprise connectors are covered by the knowledge-connectors feature.
5. Optionally select **Knowledge Source** for citation information or **Result Processor** to process the returned content.
6. Keep **Enabled** on, save the function, make it available to the intended AI feature and check a representative question.

Powerfront can check advanced Weaviate weighting options for you. The built-in hybrid weighting is 0.75 when no override is supplied; the inspected editor has no separate weighting control.

### Settings

| Setting | Where | Applies to | Default | Who can change it | What it does |
|---|---|---|---|---|---|
| Enabled | Settings › AI › Functions | website | On for a new function | Settings role, Developer role | Makes the function eligible for use by AI features configured to call it. |
| Knowledge Base Type | Settings › AI › Functions | website | Weaviate for a new function | Settings role, Developer role | Selects the external search service; the form offers Weaviate, Amazon Bedrock and Algolia Search. A saved function needs a search service selected to retrieve content. |
| Weaviate Query Type | Settings › AI › Functions | website | Keyword | Settings role, Developer role | Chooses Keyword, Vector or Hybrid; an omitted choice uses keyword search, and Hybrid needs release-specific verification. |
| Results | Settings › AI › Functions | website | 5 | Settings role, Developer role | Sets the number of Weaviate matches to request. |
| Fields | Settings › AI › Functions | website | Not set | Settings role, Developer role | Chooses which pieces of information each Weaviate match should return; blank supplies no content fields, so select fields from the external collection. |
| AWS Region | Settings › AI › Functions | website | Not set | Settings role, Developer role | Selects the Amazon Bedrock knowledge-base region; a region must be supplied for this retrieval connection. |
| Number of Results | Settings › AI › Functions | website | 10 | Settings role, Developer role | Sets the number of Amazon Bedrock matches to request. |
| Knowledge Source | Settings › AI › Functions › Knowledge Source | website | None | Settings role, Developer role | Associates returned content with source and citation information; None adds no knowledge-source association. |
| Result Processor | Settings › AI › Functions › Result Processor | website | None | Settings role, Developer role | Optionally processes search results before citation handling or model use; None leaves results without this processing step. |

### Fields

| Field | Where | Required | What it is for |
|---|---|---|---|
| Name | Settings › AI › Functions | Yes | Identifies the function; use 1 to 64 letters, digits, underscores or hyphens. |
| Description | Settings › AI › Functions | No | Describes what the function searches so the AI can understand when to use it. |
| Host | Settings › AI › Functions | Yes | Supplies the Weaviate search-service address. |
| API Key | Settings › AI › Functions | Yes | Supplies authentication for the selected Weaviate or Algolia search service. |
| Class Name | Settings › AI › Functions | No | Identifies the content collection to query in Weaviate. |
| AWS Access Key ID | Settings › AI › Functions | Yes | Supplies the AWS access credential for Amazon Bedrock knowledge retrieval. |
| AWS Secret Access Key | Settings › AI › Functions | Yes | Supplies the matching AWS secret for Amazon Bedrock knowledge retrieval. |
| Knowledge Base ID | Settings › AI › Functions | Yes | Identifies the Amazon Bedrock knowledge base to search. |

### Permissions

| Permission | Lets you |
|---|---|
| AI | With the Settings role, allows configuration of AI Functions and the features that use them. |

## Limits and good to know

- **Hybrid** can fail because its saved selection does not match the accepted search mode in this release. Ask Powerfront to verify the configuration. Use a verified alternative while resolving a failure.
- No matches return an empty result. Invalid configuration or a search-service failure can produce an error instead.
- **Fields** can contain several requested result fields. They must match information available from the external collection.
- External services own their stored documents and indexes. Configuring this function does not upload or refresh them.
- Caller context is additional information for the search service. Its presence alone does not prove document-access restrictions are enforced.
- Keep returned content and result counts appropriate to the AI feature's available context.

## Depends on and works with

### This feature uses

- **Requires** [AI functions and required inputs](AI-016.md): Knowledge retrieval runs as an authorised AI function.
- **Configured in** [AI feature settings and change history](AI-001.md): The AI feature determines which knowledge functions it can use.
- **Configured in** [AI result processor templates](AI-040.md): The function's selected Result Processor and mode control how successful retrieval results are transformed.
- **Configured in** [Knowledge sources behind AI citations](AIP-012.md): The function's selected Knowledge Source record supplies the name associated with its retrieved information.
- **Works better with** [Subsites](ADM-003.md): Weaviate requests can include the visitor's website and subsite context.
- **Works better with** [Teams](ADM-013.md): Weaviate requests can include the assigned operator's team context.
- **Works better with** [AI answer citations and summaries](AI-028.md): Features can use configured citations to identify sources in answers.
- **Works better with** [Embedding models for knowledge search](AIP-008.md): Vector and hybrid Weaviate retrieval need an embedding service; keyword retrieval does not.
- **Works better with** [Algolia Search for AI knowledge](AIP-010.md): Algolia provides another search service for Knowledge Base functions.
- **Works better with** [Saved responses as AI knowledge](AIP-011.md): Saved responses can supply content for a managed knowledge index.
- **Related** [AI knowledge and web search](AI-017.md): The knowledge and web search overview explains how agents choose between knowledge retrieval, web search and page reading.

### Used by

- **Configures** [AI knowledge and web search](AI-017.md): Knowledge Base function settings choose the retrieval service, search mode and result limits.
- **Configures** [Embedding models for knowledge search](AIP-008.md): The Weaviate Knowledge Base function holds the embedding model, endpoint, credential and search-mode choices.
- **Configures** [Saved responses as AI knowledge](AIP-011.md): The generated Knowledge Base function sets the retrieval service and search options used to find published responses.
- **Enhances** [Knowledge sources behind AI citations](AIP-012.md): Knowledge-base searches can provide evidence from retrieved articles.
- **Related** [Algolia Search for AI knowledge](AIP-010.md): Algolia is one of the search services available through a Knowledge Base function.

## FAQ and troubleshooting

### Why does the AI not search my knowledge base?

Check that the function is available to the enabled feature and that the feature's model supports its required tool use. Having a function record alone does not make every feature use it.

### Why does Keyword work while Vector fails?

Vector also requires a working embedding model, endpoint and credential. Check those separately from the search-service connection.

### Why does Hybrid fail after saving?

The visible choice has a saved-mode compatibility problem in 3.3. Ask Powerfront to verify it and use a working search choice while it is resolved.

### Why is there no source link in the answer?

Retrieval and citation display are separate. Check the function's knowledge-source information and the AI feature's citation configuration.

### Does this search my knowledge base with the Bedrock chat account?

Amazon Bedrock knowledge retrieval uses the function's separate AWS credentials, region and knowledge-base identifier. A Bedrock model account alone does not configure it.
