Skip to main content
Named Entity Recognition (NER) lets you extract structured information — people, organizations, products, locations, and any custom entity type you define — from unstructured text. Pioneer’s GLiNER encoder models are purpose-built for this task and support LoRA fine-tuning so you can adapt them to your domain with a small labeled dataset and no GPU infrastructure of your own.
1

Choose a base model

Pioneer offers four GLiNER base models. For most tasks, fastino/gliner2-base-v1 is the right starting point: it’s fast, accurate, and supports LoRA and full fine-tuning. If your data includes non-English text, use a multi variant instead.You can always fetch the latest catalog from the API:
2

Prepare your training data

You have two options: generate synthetic labeled examples with Pioneer, or bring your own labeled data.Option A — Generate synthetic data. If you don’t have labeled examples yet, use the /generate endpoint. See the Synthetic Data guide for full details.
Option B — Upload through the platform. If you already have labeled data, upload it directly via the Pioneer dashboard.Once your dataset is ready, confirm its status before starting training:
Wait until the dataset status is ready before proceeding.
3

Start a training job

Submit your training job with POST /felix/training-jobs. Set base_model to the GLiNER model you chose in step 1 and training_type to "lora".
The response includes your job ID and initial status:
Save the id — you’ll use it to poll status, run evaluations, and call inference.
4

Poll job status and review metrics

Training typically takes a few minutes to a few hours depending on dataset size and epoch count. Poll the job endpoint until status is "complete".
Job status values: requestedrunningcomplete (or failed / stopped).When the job reaches "complete", the response includes evaluation metrics:
A high F1 score (above 0.85) generally indicates a model ready for production. If scores are lower, consider adding more training examples or adjusting your entity label definitions.
5

Run an evaluation

Evaluate your trained model against a held-out dataset to get a more rigorous view of performance before deploying.
Retrieve evaluation results with GET /felix/evaluations/:id. Results include f1, precision, recall, and a per_entity breakdown so you can see which entity types need more training data.
6

Run inference with your trained model

Use your job ID as the model_id to run predictions. The schema field controls what Pioneer extracts.
Schema optionsThe schema field accepts four optional keys — use any combination:You can also call inference using the OpenAI-compatible endpoint. Set base_url to https://api.pioneer.ai/v1 and pass Pioneer fields via extra_body:
The threshold parameter controls the confidence cutoff for returned entities. The default is 0.5. Lower it (e.g., 0.3) to surface more candidates at the cost of more false positives; raise it (e.g., 0.7) for higher-precision results with fewer extractions.

Entity descriptions

Instead of passing a plain list of entity type names, you can pass a dictionary mapping each entity type to a natural-language description. Descriptions give the model more context about what to extract, improving accuracy — especially for ambiguous or domain-specific entities.
Basic (no descriptions)
With descriptions (more accurate)
When to use descriptions:
  • When entity types are ambiguous (e.g. “time” could mean many things)
  • In domain-specific contexts (medical, legal, financial)
  • When you need higher precision and the model is making wrong extractions
Tips for writing good descriptions:
  • Be specific about what counts and what doesn’t
  • Include examples inline (e.g. “like ‘400mg’ or ‘2 tablets’”)
  • Keep them to one sentence — concise beats verbose
The output format is identical whether or not you use descriptions — descriptions purely influence what the model decides to extract.

Next steps