File tree 3 files changed +26
-8
lines changed
public/pages/workflow_detail/workflow_inputs
processor_inputs/ml_processor_inputs
3 files changed +26
-8
lines changed Original file line number Diff line number Diff line change @@ -259,6 +259,8 @@ export const SEARCH_PIPELINE_DOCS_LINK =
259
259
'https://opensearch.org/docs/latest/search-plugins/search-pipelines/using-search-pipeline/' ;
260
260
export const ML_RESPONSE_PROCESSOR_EXAMPLE_DOCS_LINK =
261
261
'https://opensearch.org/docs/latest/search-plugins/search-pipelines/ml-inference-search-response/#example-externally-hosted-text-embedding-model' ;
262
+ export const UPDATE_MODEL_DOCS_LINK =
263
+ 'https://opensearch.org/docs/latest/ml-commons-plugin/api/model-apis/update-model/' ;
262
264
263
265
/**
264
266
* Text chunking algorithm constants
Original file line number Diff line number Diff line change @@ -18,13 +18,15 @@ import {
18
18
EuiSmallButtonIcon ,
19
19
EuiFlexGroup ,
20
20
EuiFlexItem ,
21
+ EuiHealth ,
21
22
} from '@elastic/eui' ;
22
23
import {
23
24
MODEL_STATE ,
24
25
WorkflowFormValues ,
25
26
ModelFormValue ,
26
27
ML_CHOOSE_MODEL_LINK ,
27
28
FETCH_ALL_QUERY_LARGE ,
29
+ UPDATE_MODEL_DOCS_LINK ,
28
30
} from '../../../../../common' ;
29
31
import { AppState , searchModels , useAppDispatch } from '../../../../store' ;
30
32
import { getDataSourceId } from '../../../../utils' ;
@@ -92,8 +94,15 @@ export function ModelField(props: ModelFieldProps) {
92
94
< >
93
95
< EuiCallOut
94
96
size = "s"
95
- title = "The selected model does not have a model interface. Cannot automatically determine model inputs and outputs."
96
- iconType = { 'alert' }
97
+ title = {
98
+ < EuiText size = "s" >
99
+ This model has no interface set up yet.{ ' ' }
100
+ < EuiLink href = { UPDATE_MODEL_DOCS_LINK } target = "_blank" >
101
+ Learn more
102
+ </ EuiLink > { ' ' }
103
+ about updating a model. Refresh the list when you finish.
104
+ </ EuiText >
105
+ }
97
106
color = "warning"
98
107
/>
99
108
< EuiSpacer size = "s" />
@@ -137,12 +146,19 @@ export function ModelField(props: ModelFieldProps) {
137
146
) ,
138
147
dropdownDisplay : (
139
148
< >
140
- < EuiText size = "s" > { option . name } </ EuiText >
141
- < EuiText size = "xs" color = "subdued" >
142
- Deployed
143
- </ EuiText >
149
+ < EuiHealth
150
+ color = {
151
+ isEmpty ( option . interface )
152
+ ? 'warning'
153
+ : 'success'
154
+ }
155
+ >
156
+ < EuiText size = "s" > { option . name } </ EuiText >
157
+ </ EuiHealth >
144
158
< EuiText size = "xs" color = "subdued" >
145
- { option . algorithm }
159
+ { isEmpty ( option . interface )
160
+ ? 'Not ready - no model interface'
161
+ : 'Deployed' }
146
162
</ EuiText >
147
163
</ >
148
164
) ,
Original file line number Diff line number Diff line change @@ -224,7 +224,7 @@ export function MLProcessorInputs(props: MLProcessorInputsProps) {
224
224
) : (
225
225
< ModelField
226
226
fieldPath = { modelFieldPath }
227
- hasModelInterface = { modelInterface !== undefined }
227
+ hasModelInterface = { ! isEmpty ( modelInterface ) }
228
228
onModelChange = { onModelChange }
229
229
/>
230
230
) }
You can’t perform that action at this time.
0 commit comments