Update content indices pipeline management UI with ELSER v2 (wording) (#167401)

This commit is contained in:
Aurélien FOUCRET 2023-09-27 21:11:46 +02:00 committed by GitHub
parent dac98ef60a
commit f3f1eec08e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 19 additions and 19 deletions

View file

@ -55,7 +55,7 @@ export const DeployModel = ({
<h3>
{i18n.translate(
'xpack.enterpriseSearch.content.index.pipelines.textExpansionCallOut.title',
{ defaultMessage: 'Improve your results with ELSER' }
{ defaultMessage: 'Improve your results with ELSER v2' }
)}
</h3>
</EuiText>
@ -73,7 +73,7 @@ export const DeployModel = ({
<EuiText size="s">
<FormattedHTMLMessage
id="xpack.enterpriseSearch.content.index.pipelines.textExpansionCallOut.body"
defaultMessage="ELSER (Elastic Learned Sparse EncodeR) is our <strong>new trained machine learning model</strong> designed to efficiently use context in natural language queries. This model delivers better results than BM25 without further training on your data."
defaultMessage="ELSER (Elastic Learned Sparse EncodeR) is our trained machine learning model designed to efficiently use context in natural language queries, with version 2 now available. This model delivers better results than BM25 without further training on your data."
tagName="p"
/>
</EuiText>

View file

@ -51,7 +51,7 @@ export const ModelDeployed = ({
<h3>
{i18n.translate(
'xpack.enterpriseSearch.content.index.pipelines.textExpansionCallOut.deployedTitle',
{ defaultMessage: 'Your ELSER model has deployed but not started.' }
{ defaultMessage: 'Your ELSER v2 model has deployed but not started.' }
)}
</h3>
</EuiText>

View file

@ -28,7 +28,7 @@ export const ModelDeploymentInProgress = ({
<h3>
{i18n.translate(
'xpack.enterpriseSearch.content.index.pipelines.textExpansionCallOut.deployingTitle',
{ defaultMessage: 'Your ELSER model is deploying.' }
{ defaultMessage: 'Your ELSER v2 model is deploying.' }
)}
</h3>
</EuiText>

View file

@ -49,20 +49,20 @@ export const ModelStarted = ({
? isCompact
? i18n.translate(
'xpack.enterpriseSearch.content.index.pipelines.textExpansionCallOut.startedSingleThreadedTitleCompact',
{ defaultMessage: 'Your ELSER model is running single-threaded.' }
{ defaultMessage: 'Your ELSER v2 model is running single-threaded.' }
)
: i18n.translate(
'xpack.enterpriseSearch.content.index.pipelines.textExpansionCallOut.startedSingleThreadedTitle',
{ defaultMessage: 'Your ELSER model has started single-threaded.' }
{ defaultMessage: 'Your ELSER v2 model has started single-threaded.' }
)
: isCompact
? i18n.translate(
'xpack.enterpriseSearch.content.index.pipelines.textExpansionCallOut.startedTitleCompact',
{ defaultMessage: 'Your ELSER model is running.' }
{ defaultMessage: 'Your ELSER v2 model is running.' }
)
: i18n.translate(
'xpack.enterpriseSearch.content.index.pipelines.textExpansionCallOut.startedTitle',
{ defaultMessage: 'Your ELSER model has started.' }
{ defaultMessage: 'Your ELSER v2 model has started.' }
)}
</h3>
</EuiText>
@ -91,7 +91,7 @@ export const ModelStarted = ({
'xpack.enterpriseSearch.content.index.pipelines.textExpansionCallOut.startedBody',
{
defaultMessage:
'Enjoy the power of ELSER in your custom Inference pipeline.',
'Enjoy the power of ELSER v2 in your custom Inference pipeline.',
}
)}
</p>

View file

@ -80,19 +80,19 @@ describe('TextExpansionCalloutLogic', () => {
});
it('uses the correct title and message from a create error', () => {
expect(getTextExpansionError(error, undefined, undefined)).toEqual({
title: 'Error with ELSER deployment',
title: 'Error with ELSER v2 deployment',
message: error.body?.message,
});
});
it('uses the correct title and message from a fetch error', () => {
expect(getTextExpansionError(undefined, error, undefined)).toEqual({
title: 'Error fetching ELSER model',
title: 'Error fetching ELSER v2 model',
message: error.body?.message,
});
});
it('uses the correct title and message from a start error', () => {
expect(getTextExpansionError(undefined, undefined, error)).toEqual({
title: 'Error starting ELSER deployment',
title: 'Error starting ELSER v2 deployment',
message: error.body?.message,
});
});
@ -303,7 +303,7 @@ describe('TextExpansionCalloutLogic', () => {
describe('textExpansionError', () => {
const error = {
body: {
error: 'Error with ELSER deployment',
error: 'Error with ELSER v2 deployment',
message: 'Mocked error message',
statusCode: 500,
},
@ -318,21 +318,21 @@ describe('TextExpansionCalloutLogic', () => {
it('returns extracted error for create', () => {
CreateTextExpansionModelApiLogic.actions.apiError(error);
expect(TextExpansionCalloutLogic.values.textExpansionError).toStrictEqual({
title: 'Error with ELSER deployment',
title: 'Error with ELSER v2 deployment',
message: 'Mocked error message',
});
});
it('returns extracted error for fetch', () => {
FetchTextExpansionModelApiLogic.actions.apiError(error);
expect(TextExpansionCalloutLogic.values.textExpansionError).toStrictEqual({
title: 'Error fetching ELSER model',
title: 'Error fetching ELSER v2 model',
message: 'Mocked error message',
});
});
it('returns extracted error for start', () => {
StartTextExpansionModelApiLogic.actions.apiError(error);
expect(TextExpansionCalloutLogic.values.textExpansionError).toStrictEqual({
title: 'Error starting ELSER deployment',
title: 'Error starting ELSER v2 deployment',
message: 'Mocked error message',
});
});

View file

@ -97,7 +97,7 @@ export const getTextExpansionError = (
title: i18n.translate(
'xpack.enterpriseSearch.content.indices.pipelines.textExpansionCreateError.title',
{
defaultMessage: 'Error with ELSER deployment',
defaultMessage: 'Error with ELSER v2 deployment',
}
),
message: getErrorsFromHttpResponse(createError)[0],
@ -107,7 +107,7 @@ export const getTextExpansionError = (
title: i18n.translate(
'xpack.enterpriseSearch.content.indices.pipelines.textExpansionStartError.title',
{
defaultMessage: 'Error starting ELSER deployment',
defaultMessage: 'Error starting ELSER v2 deployment',
}
),
message: getErrorsFromHttpResponse(startError)[0],
@ -117,7 +117,7 @@ export const getTextExpansionError = (
title: i18n.translate(
'xpack.enterpriseSearch.content.indices.pipelines.textExpansionFetchError.title',
{
defaultMessage: 'Error fetching ELSER model',
defaultMessage: 'Error fetching ELSER v2 model',
}
),
message: getErrorsFromHttpResponse(fetchError)[0],