mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-07-21 07:01:04 +08:00
Feat: add built in DSL file API (#17003)
### Summary 1. list and get by id API for builtin DSL 2. add DSL default component param values validation 3. remove all hard code keys for parser config
This commit is contained in:
@@ -6,6 +6,7 @@ import (
|
||||
"context"
|
||||
"errors"
|
||||
"fmt"
|
||||
"ragflow/internal/common"
|
||||
|
||||
deepdocpdf "ragflow/internal/deepdoc/parser/pdf"
|
||||
deepdoctype "ragflow/internal/deepdoc/parser/type"
|
||||
@@ -15,6 +16,7 @@ func (p *PDFParser) ParseWithResult(filename string, data []byte) ParseResult {
|
||||
if err := p.validateParseMethod(); err != nil {
|
||||
return ParseResult{Err: err}
|
||||
}
|
||||
common.Info(fmt.Sprintf("------------file: %s, parse_method: %s", filename, p.ParseMethod))
|
||||
switch normalizePDFParseMethod(p.ParseMethod) {
|
||||
case "plain_text":
|
||||
return parsePDFWithPlainText(filename, data, p)
|
||||
|
||||
Reference in New Issue
Block a user