Skip to content
Snippets Groups Projects
Commit 77aeed39 authored by Marcus Schiesser's avatar Marcus Schiesser Committed by GitHub
Browse files

Feat: Removed pdf-parse, and directly use latest pdf.js (#288)

parent 4ba560e2
No related branches found
No related tags found
No related merge requests found
......@@ -53,14 +53,6 @@ const copyTestData = async (
openAiKey?: string,
vectorDb?: TemplateVectorDB,
) => {
if (framework === "nextjs") {
// XXX: This is a hack to make the build for nextjs work with pdf-parse
// pdf-parse needs './test/data/05-versions-space.pdf' to exist - can be removed when pdf-parse is removed
const srcFile = path.join(__dirname, "components", "data", "101.pdf");
const destPath = path.join(root, "test", "data");
await fs.mkdir(destPath, { recursive: true });
await fs.copyFile(srcFile, path.join(destPath, "05-versions-space.pdf"));
}
if (engine === "context" || framework === "fastapi") {
const srcPath = path.join(__dirname, "components", "data");
const destPath = path.join(root, "data");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment