@lobehub/chat
Version:
Lobe Chat - an open-source, high-performance chatbot framework that supports speech synthesis, multimodal, and extensible Function Call plugin system. Supports one-click free deployment of your private ChatGPT/LLM web application.
24 lines (19 loc) • 596 B
text/typescript
import { platform } from 'node:os';
import { MacOSSearchServiceImpl } from './impl/macOS';
export const createFileSearchModule = () => {
const currentPlatform = platform();
switch (currentPlatform) {
case 'darwin': {
return new MacOSSearchServiceImpl();
}
// case 'win32':
// return new WindowsSearchServiceImpl();
// case 'linux':
// return new LinuxSearchServiceImpl();
default: {
return new MacOSSearchServiceImpl();
// throw new Error(`Unsupported platform: ${currentPlatform}`);
}
}
};
export { FileSearchImpl } from './type';