Download README.md from HelloSun/dosllm: direct link, hf CLI and curl.
- Browser
- Download file 3.28 kB
-
https://huggingface.co/spaces/HelloSun/dosllm/resolve/main/README.md
- Command line
-
hf download hf://spaces/HelloSun/dosllm/README.md
-
curl -L -o README.md https://huggingface.co/spaces/HelloSun/dosllm/resolve/main/README.md
title: DOS LLM
emoji: 💾
colorFrom: green
colorTo: blue
sdk: static
pinned: false
short_description: Ask an LLM in Chinese or English from inside FreeDOS
DOS LLM — ask an AI from inside DOS (中文 / English)
Type a question, press the button: a FreeDOS machine (v86 x86 emulator, in your browser) runs G <question>.
G.EXE is a real DOS program that does its own DNS, TCP and HTTP through an emulated NE2000 card and calls a public Gradio Space
(default tencent/Hy3) with Gradio's documented API. The answer is printed on the DOS screen.
POST /gradio_api/call/chatwith the question ->event_idGET /gradio_api/call/chat/<event_id>-> server-sent events (generating...complete)- G.EXE decodes the
completeframe and prints it asA> ...
The page then compares the text printed on the DOS screen with the text Gradio returned and shows DOS = LLM when they are identical.
How the packets leave the browser
Inside DOS: Crynwr NE2000 packet driver -> mTCP DHCP.EXE (192.168.86.100) -> G.EXE (mTCP TCP/IP stack).
DOS has no TLS and browsers cannot open raw TCP, so v86 terminates the guest's TCP streams and bridge.js (a tiny in-page WISP server)
turns each HTTP request DOS sends on port 80 into an HTTPS fetch(). It relays only *.hf.space hosts and paths starting with /gradio_api/
(GET/POST, body <= 8 KB, no credentials), so it is not an open proxy. DNS is answered by v86 using DNS-over-HTTPS.
Things to know
- Chinese and English both work. DOS runs 小貓中文 (Big5 display + Zhuyin input), so the question and the answer are shown in Chinese on the DOS screen; type in DOS with
Ctrl+Space(注音). Characters Big5 does not have (Simplified Chinese, emoji) show as?; Chinese questions ask the model for Traditional Chinese. Replies are limited to ~40 words / ~80 Chinese characters. - The DOS screen is 640x400 (XiaoMao). The page presents it in device pixels, 4:3 like a real VGA monitor by default, sharp on HiDPI screens; the card has a zoom selector (fit width / integer / 2x scrollable) and a 4:3 checkbox.
- 小貓中文 v1.0 — author HelloSun, first version 2026-10-25. It prints its notice every time it loads in DOS,
TYPE AUTHOR.TXTshows the licence terms. Please keep the author notice (seeLICENSE). - The Big5 <-> UTF-8 conversion happens in the page (
big5.js); DOS only ever sees Big5. - Your question is sent to the chosen public Space (it is a third-party service). Do not type secrets.
- If DOS ever hangs, press 重新開機 (reboot). Another Space can be tried under "進階" if it exposes a
/chatendpoint with the same 9 parameters astencent/Hy3. - Needs a modern browser (WebAssembly,
DecompressionStream) and internet access.
Developer package
dev/dosllm-dev.zip has the sources, build scripts, tests and the handover document dev/HANDOFF.md; it also contains the mTCP source archive that
G.EXE is linked against and the unmodified 小貓中文 package. Rebuild everything with tools/build_all.sh. Our code is GPL-3.0-or-later. 小貓中文 is by HelloSun (v1.0, 2026-10-25): GPL-3.0-only plus a GPLv3 §7(b) term: the author attribution must be kept; see LICENSE and NOTICE.md.