mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 01:38:56 -04:00
# Backport This will backport the following commits from `main` to `8.17`: - [[ES3] Enable AI assistant knowledge base (#202210)](https://github.com/elastic/kibana/pull/202210) <!--- Backport version: 9.4.3 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Sander Philipse","email":"94373878+sphilipse@users.noreply.github.com"},"sourceCommit":{"committedDate":"2024-11-30T13:52:39Z","message":"[ES3] Enable AI assistant knowledge base (#202210)\n\n## Summary\r\n\r\nThis enables the knowledge base for the Serverless Search AI assistant.\r\nIt also renames a few options to align naming, including a rename for\r\nthe settings page in Observability's Serverless deployment to remove a\r\nreference to Search.","sha":"0854996ba19ed61786fc32b9403552ac564e2d85","branchLabelMapping":{"^v9.0.0$":"main","^v8.18.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","ci:project-deploy-elasticsearch","ci:project-deploy-observability","backport:version","v8.17.0","v8.18.0"],"title":"[ES3] Enable AI assistant knowledge base","number":202210,"url":"https://github.com/elastic/kibana/pull/202210","mergeCommit":{"message":"[ES3] Enable AI assistant knowledge base (#202210)\n\n## Summary\r\n\r\nThis enables the knowledge base for the Serverless Search AI assistant.\r\nIt also renames a few options to align naming, including a rename for\r\nthe settings page in Observability's Serverless deployment to remove a\r\nreference to Search.","sha":"0854996ba19ed61786fc32b9403552ac564e2d85"}},"sourceBranch":"main","suggestedTargetBranches":["8.17","8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/202210","number":202210,"mergeCommit":{"message":"[ES3] Enable AI assistant knowledge base (#202210)\n\n## Summary\r\n\r\nThis enables the knowledge base for the Serverless Search AI assistant.\r\nIt also renames a few options to align naming, including a rename for\r\nthe settings page in Observability's Serverless deployment to remove a\r\nreference to Search.","sha":"0854996ba19ed61786fc32b9403552ac564e2d85"}},{"branch":"8.17","label":"v8.17.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.x","label":"v8.18.0","branchLabelMappingKey":"^v8.18.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Sander Philipse <94373878+sphilipse@users.noreply.github.com>
This commit is contained in:
parent
5fd3b1e15c
commit
5fbc576705
6 changed files with 33 additions and 6 deletions
|
@ -27,6 +27,13 @@ xpack.features.overrides:
|
|||
stackAlerts:
|
||||
name: "Alerts"
|
||||
category: "enterpriseSearch"
|
||||
### Observability AI Assistant feature is moved to Search and renamed
|
||||
observabilityAIAssistant:
|
||||
name: "AI Assistant"
|
||||
category: "enterpriseSearch"
|
||||
### AI Assistant enables the Inventory feature, moving to Search
|
||||
inventory:
|
||||
category: "enterpriseSearch"
|
||||
|
||||
## Cloud settings
|
||||
xpack.cloud.serverless.project_type: search
|
||||
|
@ -94,7 +101,6 @@ xpack.observabilityAIAssistant.enabled: true
|
|||
xpack.searchAssistant.enabled: true
|
||||
xpack.searchAssistant.ui.enabled: true
|
||||
xpack.observabilityAIAssistant.scope: "search"
|
||||
xpack.observabilityAIAssistant.enableKnowledgeBase: false
|
||||
aiAssistantManagementSelection.preferredAIAssistantType: "observability"
|
||||
xpack.observabilityAiAssistantManagement.logSourcesEnabled: false
|
||||
xpack.observabilityAiAssistantManagement.spacesEnabled: false
|
||||
|
|
|
@ -23,7 +23,7 @@ export const installElser = async ({
|
|||
inference_config: {
|
||||
service: 'elasticsearch',
|
||||
service_settings: {
|
||||
num_allocations: 1,
|
||||
adaptive_allocations: { enabled: true },
|
||||
num_threads: 1,
|
||||
model_id: '.elser_model_2',
|
||||
},
|
||||
|
|
|
@ -54,8 +54,9 @@ export class SearchAssistantPlugin
|
|||
pluginsStart,
|
||||
});
|
||||
const isEnabled = appService.isEnabled();
|
||||
const aiAssistantIsEnabled = coreStart.application.capabilities.observabilityAIAssistant?.show;
|
||||
|
||||
if (!isEnabled) {
|
||||
if (!isEnabled || !aiAssistantIsEnabled) {
|
||||
return {};
|
||||
}
|
||||
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
"actions",
|
||||
"data",
|
||||
"encryptedSavedObjects",
|
||||
"ml",
|
||||
"navigation",
|
||||
"share",
|
||||
"security",
|
||||
|
|
|
@ -59,7 +59,7 @@ export class ServerlessObservabilityPlugin
|
|||
observabilityAiAssistantManagement: {
|
||||
category: appCategories.OTHER,
|
||||
title: i18n.translate('xpack.serverlessObservability.aiAssistantManagementTitle', {
|
||||
defaultMessage: 'AI Assistant for Observability and Search Settings',
|
||||
defaultMessage: 'AI Assistant Settings',
|
||||
}),
|
||||
description: i18n.translate(
|
||||
'xpack.serverlessObservability.aiAssistantManagementDescription',
|
||||
|
|
|
@ -13,7 +13,7 @@ import {
|
|||
Plugin,
|
||||
} from '@kbn/core/public';
|
||||
import { i18n } from '@kbn/i18n';
|
||||
import { appIds } from '@kbn/management-cards-navigation';
|
||||
import { appCategories, appIds } from '@kbn/management-cards-navigation';
|
||||
import { AuthenticatedUser } from '@kbn/security-plugin/common';
|
||||
import { QueryClient, MutationCache, QueryCache } from '@tanstack/react-query';
|
||||
import { of } from 'rxjs';
|
||||
|
@ -147,12 +147,31 @@ export class ServerlessSearchPlugin
|
|||
): ServerlessSearchPluginStart {
|
||||
const { serverless, management, indexManagement, security } = services;
|
||||
serverless.setProjectHome(services.searchIndices.startRoute);
|
||||
const aiAssistantIsEnabled = core.application.capabilities.observabilityAIAssistant?.show;
|
||||
|
||||
const navigationTree$ = of(navigationTree(core.application));
|
||||
serverless.initNavigation('es', navigationTree$, { dataTestSubj: 'svlSearchSideNav' });
|
||||
|
||||
const extendCardNavDefinitions = serverless.getNavigationCards(
|
||||
security.authz.isRoleManagementEnabled()
|
||||
security.authz.isRoleManagementEnabled(),
|
||||
aiAssistantIsEnabled
|
||||
? {
|
||||
observabilityAiAssistantManagement: {
|
||||
category: appCategories.OTHER,
|
||||
title: i18n.translate('xpack.serverlessSearch.aiAssistantManagementTitle', {
|
||||
defaultMessage: 'AI Assistant Settings',
|
||||
}),
|
||||
description: i18n.translate(
|
||||
'xpack.serverlessSearch.aiAssistantManagementDescription',
|
||||
{
|
||||
defaultMessage:
|
||||
'Manage knowledge base and control assistant behavior, including response language.',
|
||||
}
|
||||
),
|
||||
icon: 'sparkles',
|
||||
},
|
||||
}
|
||||
: undefined
|
||||
);
|
||||
|
||||
management.setupCardsNavigation({
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue