Closed
Description
my codes:
export const useInitTransformers = () => {
const init = async () => {
// @ts-ignore
env.allowLocalModels = false;
extractor = await pipeline(
"feature-extraction",
"Xenova/all-mpnet-base-v2",
);
};
return { init };
};
I'm building a frontend with React that can serve sentence bert directly in browser, but no idea why even i add the line
env.allowLocalModels = false
before pipeline loading the model. In the production environment, it's still trying to access model locally /models/...
, but which will never exists in this usecase.
Is there any way i can bypass this check and directly pull the model from remote?