Skip to content

[unification][oblt] Integrate AI Assistant CTA#215207

Closed
clintandrewhall wants to merge 4 commits intoelastic:mainfrom
clintandrewhall:ai/cta-oblt-integration
Closed

[unification][oblt] Integrate AI Assistant CTA#215207
clintandrewhall wants to merge 4 commits intoelastic:mainfrom
clintandrewhall:ai/cta-oblt-integration

Conversation

@clintandrewhall
Copy link
Contributor

@clintandrewhall clintandrewhall commented Mar 19, 2025

Summary

This PR is one of a pair that integrates Call-to-Action and Knowledge Base components into the AI Assistant. It includes a commit that contains @elastic/appex-sharedux changes, which is included in both.

I fully expect CI tests to fail with the first pass or so.

This PR aligns the AI Assistant with the unified design for an Assistant.

No Connector

Before

Screenshot 2025-03-19 at 9 26 54 AM

After

Screenshot 2025-03-19 at 9 22 45 AM

No Knowledge Base

Before

Screenshot 2025-03-19 at 9 28 07 AM

After

Screenshot 2025-03-19 at 9 23 07 AM

Installing Knowledge Base

Before

Screenshot 2025-03-19 at 9 28 00 AM

After

Screenshot 2025-03-19 at 9 28 13 AM

Ready to Help

Before

Screenshot 2025-03-19 at 9 31 46 AM

After

Screenshot 2025-03-19 at 9 28 33 AM

@clintandrewhall clintandrewhall added review release_note:skip Skip the PR/issue when compiling release notes backport:prev-minor Team:Obs AI Assistant Observability AI Assistant v9.1.0 labels Mar 19, 2025
@clintandrewhall clintandrewhall requested review from a team as code owners March 19, 2025 16:25
@elasticmachine
Copy link
Contributor

Pinging @elastic/obs-ai-assistant (Team:Obs AI Assistant)

@clintandrewhall clintandrewhall force-pushed the ai/cta-oblt-integration branch from d5771d1 to d9147a7 Compare March 20, 2025 21:20
@botelastic botelastic bot added the ci:project-deploy-observability Create an Observability project label Mar 25, 2025
@github-actions
Copy link
Contributor

🤖 GitHub comments

Expand to view the GitHub comments

Just comment with:

  • /oblt-deploy : Deploy a Kibana instance using the Observability test environments.
  • run docs-build : Re-trigger the docs validation. (use unformatted text in the comment!)

@clintandrewhall clintandrewhall force-pushed the ai/cta-oblt-integration branch 2 times, most recently from 78b05ba to f191911 Compare March 26, 2025 01:35
@clintandrewhall clintandrewhall requested review from a team as code owners March 26, 2025 03:37
Copy link
Contributor

@stephmilovic stephmilovic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM for the Security GenAI changes. Code review only, thanks!

@arturoliduena
Copy link
Contributor

When opening the AI Assistant, before the “Install” button appears, there is a brief flash of another element. It is unclear what this element is, but it appears momentarily before the correct UI is displayed.

Screen.Recording.2025-03-26.at.23.53.20.mov

</EuiFlexGroup>
</EuiPanel>
</EuiFlexItem>
{connectors?.length ? (
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why don’t we allow navigating to a new conversation when there are no connectors?

Currently, if there is no connector, we show a button to add one directly from the AI Assistant, without requiring navigation to the connector settings page. However, if a user previously had a connector, started a conversation, and then deleted the connector, they can still see the list of past conversations.

In this scenario, we should allow the user to navigate back to the “New Conversation” page from the “Add Connector” button.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be raised with @isaclfreire and others involved in the unified design. The designs make no allowances for "New Conversation" to be available.

@clintandrewhall
Copy link
Contributor Author

@arturoliduena The "create connector" portion of the flow is flashing because retrieving the current connector and knowledge base state is delegated to a hook, which executes after the first render. I didn't have the depth of knowledge of the codebase to account for that until you pointed it out, but can look into it. I welcome commits in the meantime!

@clintandrewhall clintandrewhall force-pushed the ai/cta-oblt-integration branch from 8bf03eb to 5f30775 Compare March 27, 2025 18:54
@elastic-vault-github-plugin-prod elastic-vault-github-plugin-prod bot requested a review from a team as a code owner March 27, 2025 19:17
@clintandrewhall clintandrewhall force-pushed the ai/cta-oblt-integration branch 2 times, most recently from e680d6c to 5f1e378 Compare March 27, 2025 20:25
@clintandrewhall
Copy link
Contributor Author

@viduni94 @arturoliduena I was able to address all of your feedback with my latest commit:

Loading state

Mar-27-2025 16-05-19

Conversation width

Mar-27-2025 16-05-39

Knowledge base "flashing"

Mar-27-2025 16-13-37

@clintandrewhall clintandrewhall removed the request for review from a team March 27, 2025 20:29
@clintandrewhall clintandrewhall force-pushed the ai/cta-oblt-integration branch from 5f1e378 to 770b0c0 Compare March 28, 2025 01:24
@arturoliduena arturoliduena requested review from a team as code owners April 11, 2025 08:42
@botelastic botelastic bot added Team:Fleet Team label for Observability Data Collection Fleet team Team:obs-ux-infra_services - DEPRECATED DEPRECATED - Use Team:obs-presentation. Team:actionable-obs Formerly "obs-ux-management", responsible for SLO, o11y alerting, significant events, & synthetics. labels Apr 11, 2025
@elasticmachine
Copy link
Contributor

Pinging @elastic/fleet (Team:Fleet)

@elasticmachine
Copy link
Contributor

Pinging @elastic/obs-ux-management-team (Team:obs-ux-management)

@elasticmachine
Copy link
Contributor

Pinging @elastic/obs-ux-infra_services-team (Team:obs-ux-infra_services)

Copy link
Contributor

@rmyz rmyz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Infra & Services changes LGTM

);

const isConnectorReady = useMemo(
() => !connectors.error && connectors.connectors?.length && connectors.connectors.length > 0,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we have both connectors.connectors?.length and connectors.connectors.length > 0 here?
Isn't checking for connectors.connectors?.length automatically mean connectors.connectors.length > 0 as well?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It just eliminates the undefined check for clarity. Happy to change it, just submit a suggestion and I'll merge it... or I can just change it.

@elasticmachine
Copy link
Contributor

elasticmachine commented Apr 15, 2025

💔 Build Failed

  • Buildkite Build
  • Commit: d277e0d
  • Kibana Serverless Image: docker.elastic.co/kibana-ci/kibana-serverless:pr-215207-d277e0d21a44

Failed CI Steps

Test Failures

  • [job] [logs] FTR Configs #15 / @ess @serverless SecuritySolution Explore Overview Overview Host With auditbeat Make sure that we get OverviewHost data
  • [job] [logs] FTR Configs #15 / @ess @serverless SecuritySolution Explore Overview Overview Host With auditbeat Make sure that we get OverviewHost data
  • [job] [logs] FTR Configs #49 / console app misc console behavior keyboard shortcuts open documentation should open documentation when Ctrl+/ is pressed
  • [job] [logs] FTR Configs #49 / console app misc console behavior keyboard shortcuts open documentation should open documentation when Ctrl+/ is pressed
  • [job] [logs] FTR Configs #49 / Observability AI Assistant Functional tests conversations/index.spec.ts Conversations without a connector after clicking on the setup connectors button opens a flyout
  • [job] [logs] FTR Configs #49 / Observability AI Assistant Functional tests conversations/index.spec.ts Conversations without a connector after clicking on the setup connectors button opens a flyout
  • [job] [logs] Jest Tests #5 / WelcomeMessageKnowledgeBase renders "Base setup failed" with inspect issues
  • [job] [logs] Jest Tests #5 / WelcomeMessageKnowledgeBase renders "Base setup failed" with inspect issues
  • [job] [logs] Jest Tests #5 / WelcomeMessageKnowledgeBase renders "not set up" if model is not ready (but no errorMessage because endpoint exists)
  • [job] [logs] Jest Tests #5 / WelcomeMessageKnowledgeBase renders "not set up" if model is not ready (but no errorMessage because endpoint exists)
  • [job] [logs] Jest Tests #5 / WelcomeMessageKnowledgeBase renders "We are setting up your knowledge base" with the inspect button
  • [job] [logs] Jest Tests #5 / WelcomeMessageKnowledgeBase renders "We are setting up your knowledge base" with the inspect button

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
observabilityAIAssistantApp 440 460 +20
observabilityAiAssistantManagement 387 407 +20
searchAssistant 270 290 +20
total +60

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
observabilityAIAssistantApp 251.2KB 252.6KB +1.4KB
observabilityAiAssistantManagement 92.0KB 95.8KB +3.8KB
searchAssistant 165.5KB 166.9KB +1.4KB
stackConnectors 618.1KB 618.1KB -56.0B
total +6.6KB

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
observabilityAIAssistantApp 15.8KB 15.8KB +11.0B

History

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci:project-deploy-observability Create an Observability project release_note:skip Skip the PR/issue when compiling release notes review Team:actionable-obs Formerly "obs-ux-management", responsible for SLO, o11y alerting, significant events, & synthetics. Team:Fleet Team label for Observability Data Collection Fleet team Team:Obs AI Assistant Observability AI Assistant Team:obs-ux-infra_services - DEPRECATED DEPRECATED - Use Team:obs-presentation. v9.1.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants