Skip to content

The strip() operation in clean_text can cause incorrect hierarchy of lists #197

Description

@shannanyinxiang

Leading whitespaces are removed in https://github.com/rednote-hilab/dots.ocr/blob/75bd78eaca801585453c13e2672edc692c779d6c/dots_ocr/utils/format_transformer.py#L136

Thus, multi-level lists will be normalized to a single level during post-processing. For example

Image

will be recognized as

  • Treatments
  • Control
  • Traditional DDGS
  • DDGS from fractionation process

rather than

  • Treatments
    • Control
    • Traditional DDGS
    • DDGS from fractionation process

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions