Nested JSON Extraction: GLiFormer 575M Encoder Hits 91.10 F1

Knowledgator Engineering’s GLiFormer tackles a common pain point for teams building information extraction pipelines: the need to chain separate models for named‑entity recognition, document classification, relation extraction and nested JSON structuring. Each step adds latency, complexity and maintenance overhead, and switching between models often requires different hardware setups and fragile glue code. GLiFormer replaces that stack with a single encoder that can perform all of these tasks at inference time simply by providing the desired label set and extraction schema. The model works on CPU or GPU, is installable with a single pip command, and is released under an Apache 2.0 license, making it ready for immediate deployment in production environments.

The core idea is to encode the source text once, then reuse that shared representation for every requested task. A lightweight scoring head compares the encoded tokens against runtime anchors—whether they represent entity spans, classification groups, relation pairs or record slots—eliminating the need for token‑by‑token generation of JSON. Values are always taken directly from the input as spans, which prevents hallucination of missing text. Structuring follows four deterministic stages: grounding field values as source spans, assigning them to unordered record slots with Hungarian matching, predicting parent‑child links that respect the schema, and finally assembling the nested JSON without generating any output tokens. This approach yields measurable speed gains: on an NVIDIA RTX PRO 6000 Blackwell GPU the base checkpoint runs in about 69 ms per document, while on an 8‑thread AMD EPYC 9B45 CPU it runs in roughly 547 ms. These numbers are far below the analytical estimate for an autoregressive LLM that would need to write each JSON token sequentially.

By consolidating NER, classification, joint relations, multilevel structuring and embedding generation into one call, GLiFormer reduces engineering effort, lowers infrastructure costs and simplifies model versioning. Teams can now swap schemas on the fly, run multiple extraction tasks with a single forward pass, and keep the pipeline lean and maintainable.

#AI #Product #NLP #MachineLearning #DataExtraction #GLiFormer