Instructions to use pooria/foxmind with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers.js
How to use pooria/foxmind with Transformers.js:
// npm i @huggingface/transformers import { pipeline } from '@huggingface/transformers'; // Allocate pipeline const pipe = await pipeline('token-classification', 'pooria/foxmind'); - GLiNER2
How to use pooria/foxmind with GLiNER2:
from gliner2 import AutoExtractor extractor = AutoExtractor.from_pretrained("pooria/foxmind") # Extract entities text = "Apple CEO Tim Cook announced iPhone 15 in Cupertino yesterday." result = extractor.extract_entities(text, ["company", "person", "product", "location"]) print(result) - Notebooks
- Google Colab
- Kaggle
File size: 1,714 Bytes
14b1e81 ba96433 14b1e81 ba96433 14b1e81 ba96433 14b1e81 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 | ---
license: apache-2.0
base_model: fastino/gliner2-multi-v1
library_name: transformers.js
tags:
- gliner2
- foxpilot
- onnx
- token-classification
---
# foxmind
foxmind is the on-device decision model of [foxpilot](https://github.com/pooriaarab/foxpilot), a browser agent for Firefox. It is an ONNX export of the agent graph of GLiNER2 multi-v1, with a batch axis.
Base model: [`fastino/gliner2-multi-v1`](https://huggingface.co/fastino/gliner2-multi-v1) (Apache-2.0), by [Fastino](https://fastino.ai).
It is the same single-graph export as [`onnx-community/gliner2-multi-v1-agent-ONNX`](https://huggingface.co/onnx-community/gliner2-multi-v1-agent-ONNX), with one change: every input and output has a batch axis.
| Name | Shape |
| --- | --- |
| `input_ids`, `attention_mask` | `[batch, seq]` |
| `word_positions` | `[batch, words]` |
| `schema_positions` | `[batch, schema]` |
| `cls_logits` | `[batch, schema - 1]` |
| `count_logits` | `[batch, 20]` |
| `span_logits` | `[batch, schema - 1, words, 8]` |
At batch 1 it behaves like the original export. Pad shorter rows with 0 and set their mask to 0.
## Files
- `onnx/model.onnx` + `model.onnx_data`: fp32
- `onnx/model_fp16.onnx` + `model_fp16.onnx_data`: fp16
## Accuracy
`export/verify_onnx.py` in the foxpilot repository checks this export. In fp32, 14 reference calls match the Python library, and each padded batch row matches its single call within 8.0e-6 on label and span scores.
## Speed
Firefox 157, WebGPU, fp32: one call with 4 prompts takes 517 ms, against 1,242 ms for 4 single calls (2.4x).
## License
Apache-2.0, the license of the base model. Export scripts: [pooriaarab/foxpilot](https://github.com/pooriaarab/foxpilot) (MIT).
|