mirror of
https://github.com/labring/FastGPT.git
synced 2025-07-23 13:03:50 +00:00

* perf: read file worker * fix: Http node url input * fix: htm2md * fix: html2md * fix: ts * perf: Problem classification increases the matching order * feat: tool response answer
14 lines
379 B
TypeScript
14 lines
379 B
TypeScript
import { ReadRawTextByBuffer, ReadFileResponse } from '../type';
|
|
import { readFileRawText } from './rawText';
|
|
import { html2md } from '../../htmlStr2Md/utils';
|
|
|
|
export const readHtmlRawText = async (params: ReadRawTextByBuffer): Promise<ReadFileResponse> => {
|
|
const { rawText: html } = readFileRawText(params);
|
|
|
|
const rawText = html2md(html);
|
|
|
|
return {
|
|
rawText
|
|
};
|
|
};
|