Knowledgator 发布 GLiFormer:575M 参数编码器不生成 token 实现 91.10 F1 嵌套 JSON 提取

MarkTechPost(RSS)·2026-09-17 05:19·58分钟前·Asif Razzaq
AI 导读

Knowledgator Engineering 发布 schema 条件化编码器框架 GLiFormer,单个模型可在推理时按标签和 schema 完成 NER、分类、关系抽取、嵌套 JSON 结构化和文本嵌入。

MarkTechPost(RSS)
62AI 编辑部评分,满分 100

Knowledgator 发布 GLiFormer:575M 参数编码器不生成 token 实现 91.10 F1 嵌套 JSON 提取

2026-09-17 05:19· 58分钟前· Asif Razzaq
AI 导读

Knowledgator Engineering 发布 schema 条件化编码器框架 GLiFormer,单个模型可在推理时按标签和 schema 完成 NER、分类、关系抽取、嵌套 JSON 结构化和文本嵌入。

Knowledgator Engineering has released GLiFormer, a schema-conditioned encoder framework for information extraction. One model handles named-entity recognition (NER), text classification, relation extraction, nested JSON structuring, and text embeddings. You pass labels and extraction schemas at inference time. Two checkpoints are on Hugging Face. GLiFormer Base v1 has 264.2M parameters, and GLiFormer Large v1 has 575.6M.

Deployable today? Yes. Both checkpoints are Apache 2.0, install with pip install gliformer, and run on CPU or GPU.

The Problem It Targets

Extraction stacks often chain separate models. One tags entities, another classifies documents, and a third rebuilds records. The research team argues these tasks share one core operation. Encode the source, represent the requested concepts, then score their compatibility.

LLMs can emit nested JSON, but they generate field names, punctuation, and values token by token. GLiFormer removes output generation from that path.

How GLiFormer Works

GLiFormer builds on GLiNER and generalizes its label matching through an ‘anchor.’ An anchor is the object each runtime label gets scored against. It can be a group vector for classification, an entity pair for relations, or a record slot.

The source is encoded once. Multiple schemas for the same document then run as task-local groups over that shared encoding. Head compute still grows with the number of groups, labels, and anchors.

For NER, the head scores start, end, and inside evidence for every token and label pair. Independent sigmoid outputs let nested mentions and shared boundaries coexist.

Structuring runs in 4 stages:

  1. Ground field values as spans taken directly from the source text.
  2. Assign spans to unordered record slots, trained with Hungarian matching.
  3. Predict directed parent-child links, restricted to paths the schema allows.
  4. Assemble nested JSON with a deterministic decoder.

Values are source spans, so the model cannot invent value text missing from the input. Span selection, record assignment, and hierarchy can still be wrong.

Checkpoints and Training

Both v1 checkpoints use the gliformer-layout model type with 5 heads: NER, classification, joint relations, multilevel structuring, and embeddings. Each configures a 12-word maximum span width and 100 record anchors. Full specs sit in the pretrained models docs.

SpecBase v1Large v1
Parameters264.2M575.6M
Encoder layers1224
Embedding dimension7681024
Configured max_len16,3848,192

GLiFormer-base starts from a DeBERTa backbone further pretrained on 100 billion tokens. The paper documents 1,357,671 examples for broad multitask training and 372,090 for task-focused post-training.

Benchmarks

All scores below are reported by Knowledgator.

  • Nested JSON (500 examples): Large scores 91.10 F1 and Base 87.20. GPT-5.6-luna scores 91.96 and GPT-5-mini 82.56. The metric is order-free and boundary-tolerant, not exact JSON match.
  • Classification (13 datasets): Large reaches 75.03 mean macro-F1 and Base 72.36. GLiNER2.5 scores 64.89, while GPT-5-mini leads at 79.79.
  • CrossNER (5 domains): Base averages 65.10 F1 and Large 64.35. Gemma-4-31B-IT reaches 70.74.
  • Relations (4 benchmarks): Large averages 21.33 micro-F1 and Base 18.94. GLiNER-Relex reaches 25.6 and Gemma-4-31B-IT 25.08.

On combined NER and classification aggregates, the paper reports Large beats Gemma-4-E4B with about 14× fewer parameters.

Speed Without Token Generation

Knowledgator timed GLiFormer-base on 40 structuring documents at batch size 1. Median latency was 69 ms on an NVIDIA RTX PRO 6000 Blackwell GPU in FP16. On an 8-thread AMD EPYC 9B45 CPU in FP32, it was 547 ms.

The key claim ‘up to 95.8× faster’ figure is an analytical estimate, not a measured LLM run. It assumes prefill at 2,000 input tokens per second and generation at 60 output tokens per second. It excludes queueing, network delay, and hidden reasoning, and assumes nothing about accuracy parity.

Using It

The GitHub repo and model card show a short structuring call:

records = model.structure(
    "Alice works at Acme.",
    {"employee": ["name", "company"]},
)
print(records)
# {'employee': [{'name': 'Alice', 'company': 'Acme'}]}

Nested Pydantic schemas work for multilevel records. One inference call can also run entities, classes, and structures together. Use joint_relations for relations, since the v1 checkpoints lack an open relation head.

Key Takeaways

  • GLiFormer runs NER, classification, relations, nested JSON, and embeddings on one encoder.
  • Large hits 91.10 structuring F1, close to GPT-5.6-luna at 91.96.
  • Base reports 69 ms median GPU latency with zero generated output tokens.
  • Relation extraction still trails GLiNER-Relex and larger LLMs.
  • Apache 2.0 weights install via pip and self-host on CPU or GPU.

来源:MarkTechPost(RSS)· marktechpost.com