Gemma-3-1B-DBpediaArchivo-StructSelect-Q1-e2

This causal language model starts from google/gemma-3-1b-pt and was adapted with two epochs of continual pretraining (CPT) on Q1, a structurally selected subset of DBpedia Archivo. It was developed for Quality over Quantity: Ontology Dataset Selection for Efficient Triple Generation in LLMs (Canal-Esteve et al., 2026), where it was first introduced and evaluated. It is intended for research on ontology-to-ontology generation, where the model continues an RDF/OWL fragment serialized as Turtle.

Training data

Q1 was drawn from the 15 July 2025 DBpedia Archivo snapshot. The selection score sums three min–max-normalized measures: mean subclasses per class, mean non-taxonomic relations per class, and property density. Ontologies were added in score order until the selection reached the 25% token budget. Including the last ontology in full yielded 37 ontologies and about 389 million tokens, or about 31% of the full corpus. CPT used a causal language-modeling objective on Turtle text, with the model's own tokenizer.

Source corpus and Q1 ranking · Data preparation and evaluation

Evaluation

The evaluation used 12 Turtle prefixes from AGRO, EDAM, MDS and SWEET, with six sampled continuations per prefix and 72 continuations per configuration. The table reports manually assessed error rates. The final column is the arithmetic mean of the seven category rates. The CPT checkpoint used 29.50 GPU hours on NVIDIA A100 40 GB GPUs.

Model Syntax Triple repetition Text repetition Redundancy Ambiguity Semantic contradiction Vocabulary Mean error rate ↓
Original base model 1.4% 35.9% 3.6% 3.6% 0.9% 0.6% 0.1% 6.6%
Q1 after two epochs 2.8% 4.8% 2.0% 0.5% 2.3% 0.9% 0.0% 1.9%

Usage

Pass a Turtle prefix directly to the model. For ontology editing workflows, parse the completed Turtle and review the generated statements before adding them to an ontology.

from transformers import AutoModelForCausalLM, AutoTokenizer

model_id = "gplsi/Gemma-3-1B-OntologyLearning-DBpediaArchivo-StructSelect-Q1-e2"
tokenizer = AutoTokenizer.from_pretrained(model_id)
model = AutoModelForCausalLM.from_pretrained(model_id)
prompt = """@prefix ex: <https://example.org/ontology/> .
@prefix owl: <http://www.w3.org/2002/07/owl#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .

ex:Material a owl:Class .
ex:Metal a owl:Class ;
    rdfs:subClassOf ex:Material .
"""
inputs = tokenizer(prompt, return_tensors="pt")
output = model.generate(
    **inputs, max_new_tokens=100, do_sample=True,
    temperature=0.7, top_k=50, top_p=0.95,
)
continuation = output[0, inputs["input_ids"].shape[1]:]
print(tokenizer.decode(continuation, skip_special_tokens=True))

License

This checkpoint is distributed under the Gemma Terms of Use.

Citation

When reporting results with this checkpoint, cite the model repository and Miquel Canal Esteve’s doctoral thesis, Aprender del conocimiento ontológico: Selección eficiente de datos para la adaptación semántica de modelos de lenguaje, Universidad de Alicante.

@article{canal2026quality,
  title   = {Quality over Quantity: Ontology Dataset Selection for Efficient Triple Generation in LLMs},
  author  = {Canal-Esteve, Miquel and Abreu, José I. and Gutiérrez, Yoan and Muñoz, Rafael},
  journal = {Procesamiento del Lenguaje Natural},
  volume  = {77},
  pages   = {275--288},
  year    = {2026}
}

@misc{canal_gemma_3_1b_dbpediaarchivo_structselect_q1_e2,
  author = {Canal Esteve, Miquel},
  title = {{Gemma-3-1B-DBpediaArchivo-StructSelect-Q1-e2}},
  howpublished = {Hugging Face model checkpoint},
  url = {https://huggingface.co/gplsi/Gemma-3-1B-OntologyLearning-DBpediaArchivo-StructSelect-Q1-e2}
}

This research has been partially funded by the University of Alicante, the Spanish Ministry of Science and Innovation (MICIU), and the European Regional Development Fund (ERDF) through the project HEART-NLP (PID2024-156263OB-C22); funded by MICIU/AEI/10.13039/501100011033 / “ERDF, EU”.

Downloads last month
407
Safetensors
Model size
1.0B params
Tensor type
BF16
·
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Model tree for gplsi/Gemma-3-1B-OntologyLearning-DBpediaArchivo-StructSelect-Q1-e2

Finetuned
(431)
this model

Dataset used to train gplsi/Gemma-3-1B-OntologyLearning-DBpediaArchivo-StructSelect-Q1-e2

Collection including gplsi/Gemma-3-1B-OntologyLearning-DBpediaArchivo-StructSelect-Q1-e2