ChatGPT has become one of the applications of the moment. Since its launch in november last yearmillions of people have started using it and it seems that everyone is talking about the possibilities and challenges that this disruptive tool presents.
The arrival of the conversational chatbot API by OpenAI has favored this phenomenon. Now developers have the ability to integrate ChatGPT into their own applications, breaking the barrier of the classic web browser user interface.
With the availability of this resource, which has defined a business strategy within the company led by Sam Altman, many have begun to adopt it in modern apps. What if it could be used on a computer that is almost four decades old? Has anyone tried.
ChatGPT in MS-DOS
Yeo Kheng Meng, an airplane pilot, programmer, and retro computer hobbyist has taken up this interesting challenge. run to ChatGPT on an old system. Although with some tricks to achieve it, the result is surprising and fully functional.
The computer chosen for the project is a 1984 IBM Portable Personal Computer. We are talking about a computer with a 4.77 MHz Intel 8088 processor (like the first IBMPC 5150 released in 1981), 640 KB, CGA ISA Graphics, ISA network adapter and MS-DOS 6.22.
As Yeo explainsthe first step to completing his mission was to find a compiler to develop the ChatGPT client for MS-DOS. After some research he chose to work with Open Watcom C/C++, a 32-bit program that can run on Windows 11.
For development, he used a virtual machine in VirtualBox with MS-DOS 6.22 and then transferred the compiled binary to the target computer. This enthusiast also had to manage so that the client could access the Internet and thus obtain the answers that would appear on the screen.
In this step it was able to advance thanks to the Packet Driver API of 1983 and its integration with a open source MTPC library. So far so good, but there was a problem: the ChatGPT API only works with HTTPS connections, which required some extra effort.
To solve the problem of encrypted communications, Yeo resorted to creating an HTTP to HTTPS proxy that runs on a computer located halfway. That is, an intermediary that translates the requests and responses between the client and the ChatGPT API.
The developer also addressed other technical issues along the way, such as figuring out how to get it working. text input and output on the screen. All the details, in case someone wants to replicate this interesting project, can be found in the developer’s GitGHub profile.
Being able to use a conversational chatbot as advanced as ChatGPT on a 1984 computer is truly amazing. In those days this kind of thing was possible only in the imagination. Or in the movies, as he reminds us this scene from the 1983 movie ‘WarGames’.
In Xataka: The ultimate port of ‘Doom’: they manage to make it work in Windows notepad at 60 fps
In Xataka: x86 architecture, an essential history of computing