File size: 1,534 Bytes
6b40106
 
 
 
58412c1
6b40106
 
58412c1
6b40106
58412c1
 
 
2fc3aec
 
6b40106
2fc3aec
 
 
 
 
6b40106
 
2fc3aec
58412c1
 
6b40106
2fc3aec
 
58412c1
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
---
license: mit
library_name: pytorch
pipeline_tag: text-generation
tags: [tool-calling, agent, function-calling, on-device, webgpu, from-scratch, byte-level]
---

# LocalAgent — tiny 30M byte-level tool-calling agent

A **28M-parameter, pretrained-from-scratch, byte-level** agent for tool dispatch. Selection is
**generable** (no fixed-N classifier): a 5-way **route head** gates modality, a **dense two-tower
selector** scores *any* tool by its description embedding, and a **pointer head** copies argument
values from the prompt. 50-tool surface. Trained on a corrected, paraphrase-rich + referent-
conditioned dataset ([danelcsb/localagent-dispatch-data](https://huggingface.co/datasets/danelcsb/localagent-dispatch-data)).

Eval (held, disjoint phrasings + slots):
- free-form OOD **call-name 53%** / top-1 56% (45 hand-written queries)
- paraphrase-eval selection **63%** · referent-conditioned (contextual) selection **72%**

Pure **PyTorch** (no `transformers`). Load with this repo's `LocalAgentLM` / `ModelConfig`.

## Files
- `model.pt` / `model.safetensors` + `config.json` — checkpoint (backbone + ptr + dense_selector + route_head).
- `model.fp16.onnx` — ONNX graph (`logits`, `hidden`) for the in-browser demo.
- `dispatch_heads.json` / `heads.json` / `meta.json` — head weights + tokenizer/tool contract.

**Demo:** https://huggingface.co/spaces/danelcsb/localagent-webgpu ·
**Data:** https://huggingface.co/datasets/danelcsb/localagent-dispatch-data ·
**Code:** https://github.com/sangbumchoi/localagent