-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Log Explorer] Log Flyout AI assistant #169506
Comments
After a deeper investigation, the LogStream is already factoring out the flyout content from the To reuse the prompts configuration and avoid parallelism between the assistants, we could extract and expose the component from the |
For the usage of the AI Assistant in the Log Explorer Flyout details, it is important to ensure that the 'log-explorer' plugin remains independent of any observability-related concepts. This will enable its use on consumer applications that have observability dependencies disabled. After a conversation with @weltenwort, it becomes clear that it would be beneficial to implement a registration mechanism. This mechanism would allow the consumer application to inject specific features that are closely tied to a project area. The primary goal is to maintain the Log Explorer's independence from explicit dependencies. In this specific case, introducing the ObservabilityAIAssistant would introduce a dependency on an observability concept. This could prevent other consumers, such as Security, from using it. Therefore, the idea is to expose a registration mechanism that allows the consumer to inject any custom features as needed. |
## 📓 Summary Part of #169506 The reason behind exposing this component is that we'll use the same configuration and prompts to generate insights about log entries on different touchpoints: - Currently implemented, show AI insights on the LogStream flyout detail - To implement (follow up PR), show AI insights on the Log Explorer flyout detail These changes expose a new LogAIAssistant component in 2 ways: - Consume the component from the `logs-shared` plugin start contract. - Import the component from the plugin bundle. In both ways the component come lazy-loaded, the main difference is that consuming it from the start contract will pre-inject the aiAssistant dependency in the component. ```ts // Usage from plugin contract const {services} = useKibana() const { LogAIAssistant } = services.logsShared <LogAIAssistant doc={logEntry} /> // Usage from component import import { LogAIAssistant } from '@kbn/logs-shared-plugin/public'; const {services} = useKibana() <LogAIAssistant aiAssistant={services.observabilityAIAssistant} doc={logEntry} /> ``` To avoid mixing the registration of external components into the Log Explorer, I decided to split this work into different PRs to keep the changes scoped. --------- Co-authored-by: Marco Antonio Ghiani <[email protected]>
## 📓 Summary Closes #169506 This PR introduces a mechanism to apply customizations on the LogExplorer component. The first necessary customization which is implemented is for the flyout detail, allowing the consumer to display additional content on top of what is already displayed. This is a temporary solution which will be updated and embedded in a more structured customization system as a result of the work done for #165255. The current solution creates already a context to allow granular consumption of the customizations only for those subtrees where a specific customization should apply. The LogAIAssistant is used to customize the current LogExplorer as the first usage of this customization. https://github.com/elastic/kibana/assets/34506779/c9e6b40e-e636-456a-9e19-1778c26142db --------- Co-authored-by: Marco Antonio Ghiani <[email protected]> Co-authored-by: kibanamachine <[email protected]>
📓 Summary
Similarly to the AI assistant present in the Log Stream feature, the idea is to give the user a human-friendly explanation of the log message. To achieve this we'll introduce a section for the Elastic AI assistant.
🎨 Design
✔️ Acceptance criteria
💡 Implementation hints
The Log Entry Flyout as detail for the Log Stream page shows a good example of how to use the Message and ContextualInsight assistants.
The text was updated successfully, but these errors were encountered: