Skip to main content

No project description provided

Project description

Markdown Tester

该测评脚本用于评价markdown文档相似性,从段落、标题、表格和公式四个维度进行评价:

指标 说明
段落识别率 段落匹配的个数(段落编辑距离小于0.2) / 预测出的总段落数
段落召回率 段落匹配的个数(段落编辑距离小于0.2)/ 总的段落数
段落f1 2 * (段落识别率 * 段落召回率) / (段落识别率 + 段落召回率)
标题识别率 标题匹配的个数(标题编辑距离小于0.2) / 预测出的总标题数
标题召回率 标题匹配的个数(标题编辑距离小于0.2)/ 总的标题数
标题f1 2 * (标题识别率 * 标题召回率) / (标题识别率 + 标题召回率)
标题树状编辑距离 所有标题树编辑距离分数之和(pred,包含文字)/ 总标题数量(gt)
表格文本全对率 文本全对的表格个数(pred)/ 总表格个数(gt)
表格树状编辑距离 所有表格树编辑距离分数之和(pred,包含文字)/ 总表格数量(gt)
表格结构树状编辑距离 所有表格树编辑距离分数之和(pred,不包含文字)/ 总表格数量(gt)
公式识别率 公式匹配的个数(公式编辑距离小于0.2) / 预测出的总公式数
公式召回率 公式匹配的个数(公式编辑距离小于0.2)/ 总的公式数
公式f1 2 * ( 公式识别率 * 公式召回率) / (公式识别率 + 公式召回率)
阅读顺序指标 计算预测值和真值中,所有匹配段落的编辑距离

使用方法

  • 运行install.sh,安装软件包:
./install.sh
  • 待测评样本按照下述方式放置:
dataset/
├── pred/
│   ├── gpt-4o/
│   ├── vendor_A/
│   ├── vendor_B/
│   ├── ...
├── gt/
  • 运行下述命令
  • 使用命令如下:
python run_test.py --pred_path path_to_pred_md  --gt_path path_to_gt_md

其中:

  • path_to_pred_md:预测值文件所在文件夹。
  • path_to_gt_md:真值文件所在文件夹。

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

textin_tester-0.6.0.tar.gz (437.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

textin_tester-0.6.0-py3-none-any.whl (439.2 kB view details)

Uploaded Python 3

File details

Details for the file textin_tester-0.6.0.tar.gz.

File metadata

  • Download URL: textin_tester-0.6.0.tar.gz
  • Upload date:
  • Size: 437.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.3

File hashes

Hashes for textin_tester-0.6.0.tar.gz
Algorithm Hash digest
SHA256 613ac1ef49d411a7d44be2ce4621b0a50f2454b7045f72296d41c1d191558813
MD5 dd2e9c9eb8e54283f7be119c487a0364
BLAKE2b-256 2238efad7ef5055b24d5ac06a4e969235073a1637a156a8dab86fcb9972875ff

See more details on using hashes here.

File details

Details for the file textin_tester-0.6.0-py3-none-any.whl.

File metadata

  • Download URL: textin_tester-0.6.0-py3-none-any.whl
  • Upload date:
  • Size: 439.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.3

File hashes

Hashes for textin_tester-0.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 152797cb4eee1d2c232834e51a8084dcc54fba435d86991aadd8c5df744ddc9c
MD5 fcebdf628a084a470421e5b1fd131f1e
BLAKE2b-256 0abb799f007f9138076dc877c857e3e77b297f5df30b0e63919ba5b2ad7af541

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page