PenGPT, an experimental system for generating handwriting and sketches, has paired two relatively small transformer models with large collections of reconstructed pen strokes. The project’s creator says the work was driven much more by data preparation and training efficiency than by a novel neural-network architecture.
The handwriting model has 6 million parameters and can produce print or cursive. It is designed to adapt to an unfamiliar person’s writing after receiving a few sample words, without fine-tuning the full model or using a separate style encoder. A second, 54 million-parameter model produces drawings from text prompts. Both use the same basic representation: pen movement is converted into a sequence built from ten symbols, with token merging used mainly to shorten sequences.
Building suitable data was the central challenge because most handwriting archives contain scanned pages rather than recorded pen trajectories. The project assembled 495,590 words from 1,255 writers, drawing chiefly on research collections and public archives. A vision-language system identified and transcribed legible pages, individual words were extracted, and InkSight reconstructed likely strokes. Quality filters removed many uncertain traces, leaving between one-third and one-half of processed words. The drawing corpus contained 477,670 sketches selected from ten public datasets.
Experiments reported by the developer suggest that scale and presentation of the data mattered more than several architectural choices. Reducing the corpus degraded results, while removing augmentation caused the drawing system to lose prompt-following ability. Training handwriting on isolated words also weakened its capacity to continue a newly supplied style. By contrast, increasing vocabulary size, doubling the model, or explicitly supplying pen position brought little or no measured gain. An LSTM trained with the same representation remained competitive on handwriting, although it fell further behind on the longer drawing sequences.
The adaptation method places as many as four words from one writer in a training sequence. That encourages the model to infer that later words should resemble earlier ones. At generation time, a user can provide several genuine samples and ask the system to continue in a matching hand. For handwriting available only as a photograph, the workflow reconstructs strokes for a few words and fits a new writer vector while keeping the main model frozen.
Important limitations remain. Generated handwriting was less legible than real samples in the reported evaluation, scoring 54% against 66%. Stroke order reconstructed from scans is an estimate rather than a record of how a person actually wrote. The drawing model can combine familiar concepts, but it struggles with relationships and direction because a single conditioning vector behaves more like a summary of prompt words than a structured scene description. The datasets are not being released, although the project documentation describes their construction.



