ntedvs commited on
Commit
7f13220
·
verified ·
1 Parent(s): 521b329

Upload folder using huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +8 -10
README.md CHANGED
@@ -25,10 +25,10 @@ $ python infer.py "a hex color code like #fff or #a1b2c3"
25
  Requires Apple Silicon (MLX).
26
 
27
  ```
28
- hf download <user>/irex --local-dir irex && cd irex
29
  pip install -r requirements.txt
30
 
31
- python infer.py "iso date like 2024-01-31" # /^\d{4}-\d{2}-\d{2}$/
32
  python infer.py -k 5 "an email address" # top 5 candidates
33
  python infer.py # interactive
34
  ```
@@ -37,13 +37,11 @@ This is a custom MLX model. It does not load with `transformers`.
37
 
38
  ## Model
39
 
40
- | | |
41
- | ------------ | --------------------------------------------------------------------------------------------- |
42
- | Parameters | 2.6M (d192, 4 layers, 4 heads) |
43
- | Architecture | decoder-only, RMSNorm, RoPE, SwiGLU, tied embeddings |
44
- | Tokenizer | BPE (4096) trained from scratch for the English, one token per digit; raw bytes for the regex |
45
- | Decoding | beam search (8), reranked by: compiles, matches example strings in the request, in scope |
46
- | Training | 60k steps, batch 128, about 9 passes over the data, 40 minutes on an M4 Pro |
47
 
48
  ## Scope
49
 
@@ -51,7 +49,7 @@ JS regex at an intermediate level: literals, `.`, classes, `\d \w \s \b` and neg
51
 
52
  ## Training data
53
 
54
- About 815k English→regex pairs:
55
 
56
  - **Regexes:** 159k, sampled from a grammar plus realistic templates. Each is labeled with matching and non-matching strings using real JS semantics (QuickJS).
57
  - **English:** generated by DeepSeek-V4.1-Flash in five styles: casual, terse, precise, purpose, sloppy. Plus short everyday requests.
 
25
  Requires Apple Silicon (MLX).
26
 
27
  ```
28
+ hf download ntedvs/irex --local-dir irex && cd irex
29
  pip install -r requirements.txt
30
 
31
+ python infer.py "iso date like 2024-01-31" # /^\d{4}-\d{2}-\d{2}$/
32
  python infer.py -k 5 "an email address" # top 5 candidates
33
  python infer.py # interactive
34
  ```
 
37
 
38
  ## Model
39
 
40
+ - **Parameters:** 2.6M (d192, 4 layers, 4 heads)
41
+ - **Architecture:** decoder-only, RMSNorm, RoPE, SwiGLU, tied embeddings
42
+ - **Tokenizer:** BPE (4096) trained from scratch for the English, one token per digit; raw bytes for the regex
43
+ - **Decoding:** beam search (8), reranked by: compiles, matches example strings in the request, in scope
44
+ - **Training:** 60k steps, batch 128, about 9 passes over the data, 40 minutes on an M4 Pro
 
 
45
 
46
  ## Scope
47
 
 
49
 
50
  ## Training data
51
 
52
+ About 815k English-to-regex pairs:
53
 
54
  - **Regexes:** 159k, sampled from a grammar plus realistic templates. Each is labeled with matching and non-matching strings using real JS semantics (QuickJS).
55
  - **English:** generated by DeepSeek-V4.1-Flash in five styles: casual, terse, precise, purpose, sloppy. Plus short everyday requests.