feat: add corresponding icons to files (#164)

This commit is contained in:
balibabu
2024-03-28 16:18:16 +08:00
committed by GitHub
parent a5384446e3
commit b6837d4ca6
13 changed files with 137 additions and 55 deletions

View File

@ -206,3 +206,26 @@ export const useSelectKnowledgeDetails = () => {
return knowledgeDetails;
};
//#endregion
//#region Retrieval testing
export const useTestChunkRetrieval = () => {
const dispatch = useDispatch();
const knowledgeBaseId = useKnowledgeBaseId();
const testChunk = useCallback(
(values: any) => {
dispatch({
type: 'testingModel/testDocumentChunk',
payload: {
...values,
kb_id: knowledgeBaseId,
},
});
},
[dispatch, knowledgeBaseId],
);
return testChunk;
};
//#endregion