Proposal: Benchmarking on different PEFT techniques
I recently read this Hugging Face blog: "Beyond LoRA: Can You Beat the Most Popular Fine-Tuning Technique?" The blog concludes that, depending on the downstream task, PEFT techniques other than LoRA can outperform it. Inspired by this benchmark, I'd like to contribute by evaluating different PEFT methods on Table Recognition and OCR tasks using datasets available on Hugging Face.
I plan to run a comprehensive set of PEFT experiments on OCR-focused vision-language models such as:
zai-org/GLM-OCRPaddlePaddle/PaddleOCR-VL-1.6- and other relevant OCR/Table Recognition models.
Example dataset: apoidea/fintabnet-html
The goal is to benchmark different PEFT methods across these tasks and compare their effectiveness in terms of accuracy, efficiency, and resource usage.
If this sounds like a valuable addition to the benchmark, I'd be happy to take ownership of this task. Please assign it to me if you think it would be a good fit.
Hey! Thanks for the suggestion. Indeed, OCR is a relevant topic for fine-tuning, so it makes sense to have a benchmark for it.
However, adding and designing a benchmark is no small feat: it needs to be designed such that it can be run regularly on a budget (i.e. one experiment doesn't take more than 15 minutes) and doesn't need extreme hardware (VRAM < 24GB) while still being useful. This, of course, also means that testing several models is quite challenging, so it's best to focus on one model. Choosing the right model is also quite challenging, I imagine.
There are also quite a lot of dragons in the datasets themselves. Cross-contamination can be a problem and having a good train/valid/eval split that is also consistent across experiments can be challenging.
Building a benchmark is also not something you'd want to hand over to an agent and vibe your way through it. Training and benchmarking absolutely hangs on the details so you absolutely need to understand what is happening in your benchmark. Therefore it needs to be as simple as possible to have good confidence in the results.
If you still think that you can address these challenges, I'd suggest to formulate a detailed sketch of the benchmark architecture, what datasets to use, what model to base the experiments on and how to split/clean the data.
Thanks @githubnemo for the detailed feedback, these are exactly the right constraints to nail down before committing to this. Here's a concrete sketch addressing each point:
- Model:
zai-org/GLM-OCR - Task: Table recognition (HTML table structure output from an image)
- Dataset:
apoidea/fintabnet-html - Constraints: Already validated, LoRA fine-tuning GLM-OCR on ~200-500 examples trains in under 15 min on a single L4 (24GB) GPU. I'll keep this exact experiment size fixed across all methods so time/VRAM stays a controlled variable.
- Evaluation: Structure-aware table similarity Parse GT/predicted HTML into 2D cell grids, normalize cells, align rows/cols via Needleman–Wunsch, score cells by exact match or Levenshtein similarity → one 0–1 score per table (lenient on extra/missing edge rows).
- Future work: Generalize to OCR/text recognition once table recognition + harness are validated.
I'll be honest, I have very little confidence that you will adhere to what I wrote earlier
Building a benchmark is also not something you'd want to hand over to an agent and vibe your way through it.
and I don't want to wade through benchmark slop.
I might be wrong, of course, and you are legitimately trying to build the benchmark while knowing what you do and not just letting an agent run loose. In that case here are a few questions:
- Why use fintabnet-html? It doesn't seem very popular and is not well documented. I have no clue how they derived the HTML and if they made modifications to the data. It doesn't seem that FinTabNet is all that popular in literature, PubTabNet seems more popular, what's the reason behind choosing FinTabNet and that specific repo?
- it seems you are planning to roll your own evaluation code - why?
- Why GLM-OCR? Just because it is the current state of the art?
@githubnemo
Before the specifics: no agent is running this benchmark autonomously. I'm writing and running the fine-tuning/eval scripts myself, manually, and reviewing what they actually produce at each step.
- FinTabNet / this specific repo: PubTabNet and FinTabNet are typically used together in TSR literature rather than one replacing the other, FinTabNet's financial-filing tables (sparse, often borderless) are a meaningfully different distribution from PubTabNet's scientific tables, so it's not an arbitrary pick. That said, you're right that I hadn't verified the
apoidearepackaging's provenance, I'd only spot-checked a handful of samples visually, which isn't good enough. Both were developed by IBM research Link. I'll switch to PubTabNet instead, since it's preferred more in the literature and is available directly from the official IBM source with clear and documented provenance. - Eval code: I am not developing my own evaluation for the table recognition. I'm using the methodology from Reducto's RD-TableBench, specifically their hierarchical alignment approach: cell-level alignment via Needleman-Wunsch with Levenshtein-based partial matching, then row-level alignment pass using those cell scores, with free end-gaps so cropped/shifted subtables aren't over-penalized. Their grading code is open-sourced (
reductoai/rd-tablebench), so this is an adopted, published, auditable methodology rather than something bespoke. - Why GLM-OCR: Not chasing SOTA for its own sake, it is small enough to iterate quickly within the time/VRAM budget, and it's a VLM/OCR architecture, which fills a real gap since the existing PEFT method-comparison benchmark (and most others I've seen) are text-only LLMs.
@githubnemo Before the specifics: no agent is running this benchmark autonomously. I'm writing and running the fine-tuning/eval scripts myself, manually, and reviewing what they actually produce at each step.
I'm not worrying about who is running the benchmark, but who's writing it :) The person who submits the benchmark code needs to have a) a deep understanding of the benchmark itself and (b) a good understanding of the domain to make informed decisions. In my experience, agents tend to be very selective and, only when used by a proficient person, produce valuable results. I want to make sure that this is the case here so we don't waste each other's time.
- Eval code: I am not developing my own evaluation for the table recognition. I'm using the methodology from Reducto's RD-TableBench, specifically their hierarchical alignment approach: cell-level alignment via Needleman-Wunsch with Levenshtein-based partial matching, then row-level alignment pass using those cell scores, with free end-gaps so cropped/shifted subtables aren't over-penalized. Their grading code is open-sourced (
reductoai/rd-tablebench), so this is an adopted, published, auditable methodology rather than something bespoke.
Can you give me a reason for why this and not, say, the metric supplied with PubTabNet? Excuse my asking but these are quite important decisions and I think that we all need to understand what options there are and why the choices are made.
- Why GLM-OCR: Not chasing SOTA for its own sake, it is small enough to iterate quickly within the time/VRAM budget, and it's a VLM/OCR architecture, which fills a real gap since the existing PEFT method-comparison benchmark (and most others I've seen) are text-only LLMs.
Fair.
@githubnemo
On (1): Fair, and fair distinction, thank you for pushing on this. To be clear: I'm reviewing every experiment and decision myself, end-to-end. Questions like these are genuinely useful.
On (2): One correction to my last message: I'm not using the RD-TableBench dataset, only its scoring technique.
How the two techniques differ mechanically
TEDS parses each table into a full DOM tree (<table>/<tr>/<td>, with colspan/rowspan as attributes) and computes one global tree-edit distance between predicted and ground-truth trees, normalized by tree size.
RD-TableBench's technique flattens each table into a 2D array, then does two-level Needleman-Wunsch alignment: cells within a row pair are scored via partial-match Levenshtein, then whole rows are aligned to each other using those cell scores, with free end-gaps, meaning a gap at the very start/end of the row sequence isn't charged the usual gap penalty.
Example 1: cropped header row (boundary case)
Ground truth: header + 2 data rows. Prediction: header row missing (cropped), other two rows exact.
Ground truth:
| Name | Age | City |
|---|---|---|
| John | 25 | Boston |
| Mary | 30 | Denver |
Prediction (header row missing, cropped):
| John | 25 | Boston |
|---|---|---|
| Mary | 30 | Denver |
TEDS score: 0.6667 RD-TableBench score: 0.6667
Identical here. The missing row still costs its full potential score in RD-TableBench's normalization denominator, free end-gap or not, so the "boundary forgiveness" is smaller than it sounds.
Example 2: middle row split in two (non-boundary case)
Ground truth: same as above.
Prediction (middle row split, e.g. OCR line-wrap):
| Name | Age | City |
|---|---|---|
| John | ||
| 25 | Boston | |
| Mary | 30 | Denver |
TEDS: 0.6875 RD-TableBench: 0.5938
Here TEDS is actually more forgiving. The split isn't at a boundary, so RD-TableBench gets no free-end-gap benefit; it pays the full gap penalty plus partial-cell credit on both half-rows. TEDS only has to edit one local subtree, so the damage stays contained.
Takeaway
RD-TableBench's technique isn't uniformly more lenient; it specifically targets boundary cropping, a common artifact in our detection pipeline. TEDS actually handles mid-table structural errors (split/merged rows) more gently, since it isolates the edit locally rather than cascading a gap penalty. Since the two are lenient about different, non-overlapping failure modes, I'll report both going forward rather than treating one as strictly better.
Alright, thanks. Let's give this a go!
Can you build an OCR benchmark (specifically for table parsing) that follows the benchmark structure of the image and metamathqa benchmarks and submit it as a draft PR? The way the results are separated between main/other git branches and the general structure of the benchmark results are deliberate and should be as close as it gets with minor difference (e.g., the target metrics change).
@githubnemo Sounds good, happy to build this. I'll follow the same structure by referring the current implemented tasks.
@jeet-Abhi123 nice. I'd submit a PR rather sooner than later to get early feedback/steering so we can avoid too much wasted effort.
This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread.
Big fan of huggingface/peft, thanks for shipping this in the open. Wanted to share ModelRank in case it helps your community: an independent, auditable leaderboard for open-weight LLMs. Free embeddable badges, 5-dimension scoring, zero paid placements. If you ever want peft scored and listed, it is a one-line badge in the README (https://rankmodel.github.io). Either way, appreciate you building in the open.
This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread.