Skip to content

Commit

Permalink
[8.16] [DOCS] Fine-tunes inference connector and action docs (#198345) (
Browse files Browse the repository at this point in the history
#198402)

# Backport

This will backport the following commits from `main` to `8.16`:
- [[DOCS] Fine-tunes inference connector and action docs
(#198345)](#198345)

<!--- Backport version: 9.4.3 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"István Zoltán
Szabó","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-10-30T16:12:53Z","message":"[DOCS]
Fine-tunes inference connector and action docs
(#198345)","sha":"dc8322a46f51a2e12fa0eafee1dad365e5adffb5","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Team:Docs","release_note:skip","v9.0.0","docs","v8.16.0","backport:version","v8.17.0"],"title":"[DOCS]
Fine-tunes inference connector and action
docs","number":198345,"url":"https://github.com/elastic/kibana/pull/198345","mergeCommit":{"message":"[DOCS]
Fine-tunes inference connector and action docs
(#198345)","sha":"dc8322a46f51a2e12fa0eafee1dad365e5adffb5"}},"sourceBranch":"main","suggestedTargetBranches":["8.16","8.x"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","branchLabelMappingKey":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/198345","number":198345,"mergeCommit":{"message":"[DOCS]
Fine-tunes inference connector and action docs
(#198345)","sha":"dc8322a46f51a2e12fa0eafee1dad365e5adffb5"}},{"branch":"8.16","label":"v8.16.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.x","label":"v8.17.0","branchLabelMappingKey":"^v8.17.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: István Zoltán Szabó <[email protected]>
  • Loading branch information
kibanamachine and szabosteve authored Oct 30, 2024
1 parent 623c445 commit 495a530
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 10 deletions.
4 changes: 2 additions & 2 deletions docs/management/action-types.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ a| <<gemini-action-type,{gemini}>>

| Send a request to {gemini}.

a| <<inference-action-type,{inference}>>
a| <<inference-action-type,{infer}>>

| Send a request to {inference}.
| Send a request to {infer}.

a| <<email-action-type,Email>>

Expand Down
32 changes: 24 additions & 8 deletions docs/management/connectors/action-types/inference.asciidoc
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
[[inference-action-type]]
== {infer-cap} connector and action
++++
<titleabbrev>{inference}</titleabbrev>
<titleabbrev>{infer-cap}</titleabbrev>
++++
:frontmatter-description: Add a connector that can send requests to {inference}.
:frontmatter-tags-products: [kibana]
:frontmatter-tags-content-type: [how-to]
:frontmatter-tags-user-goals: [configure]


The {infer} connector uses the {es} client to send requests to an {infer} service. The connector uses the <<execute-connector-api,run connector API>> to send the request.
The {infer} connector uses the {es} client to send requests to an {infer} service.
The connector uses the <<execute-connector-api,run connector API>> to send the request.

[float]
[[define-inference-ui]]
Expand All @@ -19,7 +20,7 @@ You can create connectors in *{stack-manage-app} > {connectors-ui}*. For example

[role="screenshot"]
image::management/connectors/images/inference-connector.png[{inference} connector]
// NOTE: This is an autogenerated screenshot. Do not edit it directly.


[float]
[[inference-connector-configuration]]
Expand All @@ -44,7 +45,8 @@ while creating or editing the connector in {kib}. For example:

[role="screenshot"]
image::management/connectors/images/inference-completion-params.png[{infer} params test]
// NOTE: This is an autogenerated screenshot. Do not edit it directly.


[float]
[[inference-connector-actions]]
=== {infer-cap} connector actions
Expand All @@ -56,33 +58,40 @@ The {infer} actions have the following configuration properties. Properties depe
==== Completion

The following example performs a completion task on the example question.

Input::
The text on which you want to perform the {infer} task. For example:
+
[source,text]
--
[source,text]
------------------------------------------------------------
{
input: 'What is Elastic?'
}
------------------------------------------------------------
--

[float]
[[inference-connector-perform-text-embedding]]
==== Text embedding

The following example performs a text embedding task.

Input::
The text on which you want to perform the {infer} task. For example:
+
[source,text]
--
[source,text]
------------------------------------------------------------
{
input: 'The sky above the port was the color of television tuned to a dead channel.',
task_settings: {
input_type: 'ingest'
}
}
------------------------------------------------------------
--

Input type::
An optional string that overwrites the connector's default model.

Expand All @@ -91,16 +100,20 @@ An optional string that overwrites the connector's default model.
==== Reranking

The following example performs a reranking task on the example input.

Input::
The text on which you want to perform the {infer} task. Should be a string array. For example:
+
[source,text]
--
[source,text]
------------------------------------------------------------
{
input: ['luke', 'like', 'leia', 'chewy', 'r2d2', 'star', 'wars'],
query: 'star wars main character'
}
------------------------------------------------------------
--

Query::
The search query text.

Expand All @@ -109,14 +122,17 @@ The search query text.
==== Sparse embedding

The following example performs a sparse embedding task on the example sentence.

Input::
The text on which you want to perform the {infer} task. For example:
+
[source,text]
--
[source,text]
------------------------------------------------------------
{
input: 'The sky above the port was the color of television tuned to a dead channel.'
}
------------------------------------------------------------
--

[float]
Expand Down

0 comments on commit 495a530

Please sign in to comment.