### What problem does this PR solve? add support for ollama Issue link:#221 ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@@ -151,6 +151,17 @@ const model: DvaModel<SettingModelState> = {
|
||||
}
|
||||
return retcode;
|
||||
},
|
||||
*add_llm({ payload = {} }, { call, put }) {
|
||||
const { data } = yield call(userService.add_llm, payload);
|
||||
const { retcode } = data;
|
||||
if (retcode === 0) {
|
||||
message.success(i18n.t('message.modified'));
|
||||
|
||||
yield put({ type: 'my_llm' });
|
||||
yield put({ type: 'factories_list' });
|
||||
}
|
||||
return retcode;
|
||||
},
|
||||
},
|
||||
};
|
||||
export default model;
|
||||
|
||||
Reference in New Issue
Block a user