diff --git a/src/pages/llmodels/hooks/index.ts b/src/pages/llmodels/hooks/index.ts index f872e5f1..63fff8fe 100644 --- a/src/pages/llmodels/hooks/index.ts +++ b/src/pages/llmodels/hooks/index.ts @@ -535,13 +535,22 @@ export const useCheckCompatibility = () => { cacheFormValuesRef.current = {}; }; + const noLocalPathValue = (allValues: any) => { + return ( + allValues.source === modelSourceMap.local_path_value && + !allValues.local_path + ); + }; const handleOnValuesChange = async (params: { changedValues: any; allValues: any; source: string; }) => { const { allValues, source } = params; - if (_.isEqual(cacheFormValuesRef.current, allValues)) { + if ( + _.isEqual(cacheFormValuesRef.current, allValues) || + noLocalPathValue(allValues) + ) { console.log('No changes detected, skipping evaluation.'); return; }