-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[8.x] [Obs AI Assistant] Add uuid to knowledge base entries to avoid …
…overwriting accidentally (#191043) (#199263) # Backport This will backport the following commits from `main` to `8.x`: - [[Obs AI Assistant] Add uuid to knowledge base entries to avoid overwriting accidentally (#191043)](#191043) <!--- Backport version: 9.4.3 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Søren Louv-Jansen","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-11-07T08:55:34Z","message":"[Obs AI Assistant] Add uuid to knowledge base entries to avoid overwriting accidentally (#191043)\n\nCloses https://github.com/elastic/kibana/issues/184069\r\n\r\n**The Problem**\r\nThe LLM decides the identifier (both `_id` and `doc_id`) for knowledge\r\nbase entries. The `_id` must be globally unique in Elasticsearch but the\r\nLLM can easily pick the same id for different users thereby overwriting\r\none users learning with another users learning.\r\n\r\n**Solution**\r\nThe LLM should not pick the `_id`. With this PR a UUID is generated for\r\nnew entries. This means the LLM will only be able to create new KB\r\nentries - it will not be able to update existing ones.\r\n\r\n`doc_id` has been removed, and replaced with a `title` property. Title\r\nis simply a human readable string - it is not used to identify KB\r\nentries.\r\nTo retain backwards compatability, we will display the `doc_id` if\r\n`title` is not available\r\n\r\n---------\r\n\r\nCo-authored-by: Sandra G <[email protected]>\r\nCo-authored-by: kibanamachine <[email protected]>","sha":"7c92a10b324a8b1e10ae8924e5525b071b5c9797","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","v9.0.0","backport:prev-minor","Team:Obs AI Assistant","ci:project-deploy-observability"],"title":"[Obs AI Assistant] Add uuid to knowledge base entries to avoid overwriting accidentally","number":191043,"url":"https://github.com/elastic/kibana/pull/191043","mergeCommit":{"message":"[Obs AI Assistant] Add uuid to knowledge base entries to avoid overwriting accidentally (#191043)\n\nCloses https://github.com/elastic/kibana/issues/184069\r\n\r\n**The Problem**\r\nThe LLM decides the identifier (both `_id` and `doc_id`) for knowledge\r\nbase entries. The `_id` must be globally unique in Elasticsearch but the\r\nLLM can easily pick the same id for different users thereby overwriting\r\none users learning with another users learning.\r\n\r\n**Solution**\r\nThe LLM should not pick the `_id`. With this PR a UUID is generated for\r\nnew entries. This means the LLM will only be able to create new KB\r\nentries - it will not be able to update existing ones.\r\n\r\n`doc_id` has been removed, and replaced with a `title` property. Title\r\nis simply a human readable string - it is not used to identify KB\r\nentries.\r\nTo retain backwards compatability, we will display the `doc_id` if\r\n`title` is not available\r\n\r\n---------\r\n\r\nCo-authored-by: Sandra G <[email protected]>\r\nCo-authored-by: kibanamachine <[email protected]>","sha":"7c92a10b324a8b1e10ae8924e5525b071b5c9797"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/191043","number":191043,"mergeCommit":{"message":"[Obs AI Assistant] Add uuid to knowledge base entries to avoid overwriting accidentally (#191043)\n\nCloses https://github.com/elastic/kibana/issues/184069\r\n\r\n**The Problem**\r\nThe LLM decides the identifier (both `_id` and `doc_id`) for knowledge\r\nbase entries. The `_id` must be globally unique in Elasticsearch but the\r\nLLM can easily pick the same id for different users thereby overwriting\r\none users learning with another users learning.\r\n\r\n**Solution**\r\nThe LLM should not pick the `_id`. With this PR a UUID is generated for\r\nnew entries. This means the LLM will only be able to create new KB\r\nentries - it will not be able to update existing ones.\r\n\r\n`doc_id` has been removed, and replaced with a `title` property. Title\r\nis simply a human readable string - it is not used to identify KB\r\nentries.\r\nTo retain backwards compatability, we will display the `doc_id` if\r\n`title` is not available\r\n\r\n---------\r\n\r\nCo-authored-by: Sandra G <[email protected]>\r\nCo-authored-by: kibanamachine <[email protected]>","sha":"7c92a10b324a8b1e10ae8924e5525b071b5c9797"}}]}] BACKPORT--> Co-authored-by: Søren Louv-Jansen <[email protected]>
- Loading branch information
1 parent
de6da8a
commit 3b2a572
Showing
51 changed files
with
687 additions
and
1,438 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.