MS-DOS ChatGPT Client Arrives for 1984 IBM PC
A hobby software developer and retro computing enthusiast has successfully bridged the gap between ChatGPT and IBM PC-XT computing. Aiming for a challenge Yo Ken Men I was wondering if it’s possible to create a ChatGPT client for MS-DOS.Specifically, it has a 4.77 MHz Intel 8088 CPU with 640KB of RAM (enough Anyone, right? ). Several technical obstacles had to be overcome for the project to be successful.
Most people usually access ChatGPT via a web browser, but there seems to be a growing trend to access this AI resource via a client. We reported on notable and fun clients such as the Raspberry Pi-powered ChatGPT Smartwatch and Microsoft’s highly infamous Clippy using an AI brain implant. However, getting ChatGPT to work on his one of the oldest PCs might be even more ambitious.
Meng started by finding a compiler that could bridge the 40-year gap between target computers and ChatGPT. The Open Watcom C/C++ compiler fits that need. During development he wanted to test the DOS application, so he decided to run it in a virtual machine on his latest PC (his Virtualbox virtual machine running DOS 6.22).
One of DOS’s biggest stumbling blocks was the network required to connect to the ChatGPT service. Meng found that his MTCP, written by Michael B. Brutman, facilitates connecting to ChatGPT’s Chat Completion API. However, in order to communicate with this API, developers had to “manually construct the entire POST request in C.”
A few more hurdles the developer had to go through included JSON parsing, changing ChatGPT output from HTTPS to HTTP, and dealing with the lack of multithreading in DOS. You can read more about how this was achieved in his book. full blog post.
OpenAI’s conversational AI ChatGPT (Chat Generative Pre-Trained Transformer) has received a lot of attention both inside and outside the tech world since it debuted late last year. It spurred renewed fierce competition among his web giants such as Google and Microsoft, helped clarify the potential (and some drawbacks) of AI, and sparked a mini-boom in many related businesses. rice field.