-
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
[Security assistant] Use inference connector in security AI features #204505
[Security assistant] Use inference connector in security AI features #204505
Conversation
…:YulNaumenko/kibana into ai-connector-inference-completion-openai
…n-openai' into inference_assistant_unified
…n-openai' into inference_assistant_unified
…:YulNaumenko/kibana into ai-connector-inference-completion-openai
…nce-completion-openai
Pinging @elastic/security-solution (Team: SecuritySolution) |
@elasticmachine merge upstream |
Has anything changed w/r/t the "queued" nature of the connector; specifically that we don't use task manager to arrange to run the connector "later". Asking since it has not be "queued" in the past, which means it is somewhat exempt from some ZDT/BWC issues (the thorny ones). |
@elasticmachine merge upstream |
No, we’re not using task manager to queue inference tasks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ResponseOps changes LGTM, assuming the connectors are not queued via task manager ... (left a question on that in the PR comments)
}), | ||
tap((line) => { | ||
if ('error' in line) { | ||
throw new Error(line.error.message); | ||
throw new Error(line.error.message ?? line.error.reason ?? 'Unknown error'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suggest using ||
instead of ??
, as ??
will allow ""
to pass through as the value:
> x = ""
''
> y = ""
''
> x ?? y ?? 'abc'
''
> x || y || 'abc'
'abc'
…/kibana into inference_assistant_unified
💛 Build succeeded, but was flaky
Failed CI StepsMetrics [docs]Async chunks
Unknown metric groupsESLint disabled line counts
Total ESLint disabled count
History
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Great work!
Very exciting to see the puzzle peaces are coming together.
Starting backport for target branches: 8.x |
…lastic#204505) (cherry picked from commit c6501da)
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
…tures (#204505) (#205923) # Backport This will backport the following commits from `main` to `8.x`: - [[Security assistant] Use inference connector in security AI features (#204505)](#204505) <!--- Backport version: 9.4.3 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Steph Milovic","email":"[email protected]"},"sourceCommit":{"committedDate":"2025-01-08T15:30:15Z","message":"[Security assistant] Use inference connector in security AI features (#204505)","sha":"c6501da809c5ff8dc5f16076205ec65abaffcb54","branchLabelMapping":{"^v9.0.0$":"main","^v8.18.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:enhancement","v9.0.0","Team: SecuritySolution","backport:prev-minor","Team:Security Generative AI","v8.18.0"],"title":"[Security assistant] Use inference connector in security AI features","number":204505,"url":"https://github.com/elastic/kibana/pull/204505","mergeCommit":{"message":"[Security assistant] Use inference connector in security AI features (#204505)","sha":"c6501da809c5ff8dc5f16076205ec65abaffcb54"}},"sourceBranch":"main","suggestedTargetBranches":["8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/204505","number":204505,"mergeCommit":{"message":"[Security assistant] Use inference connector in security AI features (#204505)","sha":"c6501da809c5ff8dc5f16076205ec65abaffcb54"}},{"branch":"8.x","label":"v8.18.0","branchLabelMappingKey":"^v8.18.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Steph Milovic <[email protected]> Co-authored-by: Elastic Machine <[email protected]>
Summary
Enables new inference connector in the AI Assistant and Attack Discovery. To use with Attack Discovery, you must increase the rate limit of the connector and set the number of alerts sent to minimum (50).
Only preconfigured inference connectors will be shown in Security until all the providers will support unified completion.
To test
inferenceConnectorOn
totrue
inx-pack/platform/plugins/shared/stack_connectors/common/experimental_features.ts
openai-completion-preconfig