chore: replace all cn comments to en version by volc api (#313)
This commit is contained in:
@@ -34,52 +34,52 @@ type Config struct {
|
||||
// ParsingStrategy for document parse before indexing
|
||||
type ParsingStrategy struct {
|
||||
// Doc
|
||||
ExtractImage bool `json:"extract_image"` // 提取图片元素
|
||||
ExtractTable bool `json:"extract_table"` // 提取表格元素
|
||||
ImageOCR bool `json:"image_ocr"` // 图片 ocr
|
||||
FilterPages []int `json:"filter_pages"` // 页过滤, 第一页=1
|
||||
ExtractImage bool `json:"extract_image"` // Extract image elements
|
||||
ExtractTable bool `json:"extract_table"` // Extract table elements
|
||||
ImageOCR bool `json:"image_ocr"` // Image ocr
|
||||
FilterPages []int `json:"filter_pages"` // Page filter, first page = 1
|
||||
|
||||
// Sheet
|
||||
SheetID *int `json:"sheet_id"` // xlsx sheet id
|
||||
HeaderLine int `json:"header_line"` // 表头行
|
||||
DataStartLine int `json:"data_start_line"` // 数据起始行
|
||||
RowsCount int `json:"rows_count"` // 读取数据行数
|
||||
IsAppend bool `json:"-"` // 行插入
|
||||
Columns []*document.Column `json:"-"` // sheet 对齐表头
|
||||
IgnoreColumnTypeErr bool `json:"-"` // true 时忽略 column type 与 value 未对齐的问题,此时 value 为空
|
||||
HeaderLine int `json:"header_line"` // header row
|
||||
DataStartLine int `json:"data_start_line"` // Data start row
|
||||
RowsCount int `json:"rows_count"` // number of rows read
|
||||
IsAppend bool `json:"-"` // row insertion
|
||||
Columns []*document.Column `json:"-"` // Sheet Alignment Header
|
||||
IgnoreColumnTypeErr bool `json:"-"` // Ignore the problem that the column type and value are not aligned when true, when the value is empty
|
||||
|
||||
// Image
|
||||
ImageAnnotationType ImageAnnotationType `json:"image_annotation_type"` // 图片内容标注类型
|
||||
ImageAnnotationType ImageAnnotationType `json:"image_annotation_type"` // Image content labeling type
|
||||
}
|
||||
|
||||
type ChunkingStrategy struct {
|
||||
ChunkType ChunkType `json:"chunk_type"`
|
||||
|
||||
// custom config
|
||||
ChunkSize int64 `json:"chunk_size"` // 分段最大长度
|
||||
Separator string `json:"separator"` // 分段标识符
|
||||
Overlap int64 `json:"overlap"` // 分段重叠比例
|
||||
ChunkSize int64 `json:"chunk_size"` // maximum segmentation length
|
||||
Separator string `json:"separator"` // segmentation identifier
|
||||
Overlap int64 `json:"overlap"` // segmented overlap ratio
|
||||
TrimSpace bool `json:"trim_space"`
|
||||
TrimURLAndEmail bool `json:"trim_url_and_email"`
|
||||
|
||||
// leveled config
|
||||
MaxDepth int64 `json:"max_depth"` // 按层级分段时的最大层级
|
||||
SaveTitle bool `json:"save_title"` // 保留层级标题
|
||||
MaxDepth int64 `json:"max_depth"` // Maximum level when segmented by level
|
||||
SaveTitle bool `json:"save_title"` // Preserve Hierarchical Titles
|
||||
}
|
||||
|
||||
type ChunkType int64
|
||||
|
||||
const (
|
||||
ChunkTypeDefault ChunkType = 0 // 自动分片
|
||||
ChunkTypeCustom ChunkType = 1 // 自定义规则分片
|
||||
ChunkTypeLeveled ChunkType = 2 // 层级分片
|
||||
ChunkTypeDefault ChunkType = 0 // Automatic sharding
|
||||
ChunkTypeCustom ChunkType = 1 // Custom rule sharding
|
||||
ChunkTypeLeveled ChunkType = 2 // Hierarchical sharding
|
||||
)
|
||||
|
||||
type ImageAnnotationType int64
|
||||
|
||||
const (
|
||||
ImageAnnotationTypeModel ImageAnnotationType = 0 // 模型自动标注
|
||||
ImageAnnotationTypeManual ImageAnnotationType = 1 // 人工标注
|
||||
ImageAnnotationTypeModel ImageAnnotationType = 0 // automatic model annotation
|
||||
ImageAnnotationTypeManual ImageAnnotationType = 1 // manual annotation
|
||||
)
|
||||
|
||||
type FileExtension string
|
||||
|
||||
Reference in New Issue
Block a user