tltr; I add an imaginary dimension to the emacs terminal using OpenAI-Codex.
Integrating real interpreters with imaginary ones creates something new that is greater than the sum of their parts; A complex terminal.
The complex terminal utilises the Codex LM to perform its underlying prompt functions. A complex terminal uses imaginary functions to enable the user to see what may happen upon running a command, to see what may follow after writing some code, and see what people usually do within a terminal context, no matter how deeply nested within interpreters or files.
Much more of this to come. I am trying to make this as robust as possible and it’s too exciting.
Using Codex with vim and nano
- First start emacs
- Then start the emacs terminal
- As you can see I am autocompleting for vim, using emacs
- Likewise you will see I can do the same for nano
- Nano is still pretty hard to use haha
- I could design as many prompt functions as I like for vim using this method
- As you can see I could use context menus and create definitions for vim-related things
- What else can I do?
- Well, while browsing syslogs, I can generate commands to match things, for example
- I could also rely on the autocompletion for EX from within vim
What do people typically do in
- I demonstrated showing what people would probably do in a given context.
- I demonstrated using the glossary system to find out what a linux utility/log for a linux utility does.
Switching from bash to python
- I will demonstrate using the same imaginary functions from one interpreter to the next.
- It’s also interesting that upon switching to a different interpreter such as python, Codex will suggest relevant Python libraries for the directory, so long as you listed out the contents or made it apparent.
Switching from bash to vim and using Codex inside vim
- It appears that codex runs commands from the EX REPL.
cterm and ptpython
pen-complete-lines to look ahead while
using an interpreter such as ptpython to see
what would follow if you were to run the current line.
I have bound it to
- Simple vs complex
The etymology of complex means multiple braids.
A complex terminal has braided imaginary programming with real programming. The word complex is suitable because it describes this braiding along with the mathematical connotations of complex numbers.
We could further extend this terminology to include complex programming in the realm of imaginary programming to describe a programming style that combines both real programming with imaginary programming.
But that is the topic of another blog article.
OK, what about automating emacs with Codex?
- I can’t generate the emacs chrome from
emacs -nw -Q, at least from an initial attempt
- Well, I just did “Hello World”. What’s next?
If this article appears incomplete, it may be intentional. Try prompting for a continuation.