ChatGPT AutoExpert (Developer Edition)
A new set of ChatGPT Custom Instructions, for developers
ChatGPT really can code.
Note: if you’re wanting to get a behind-the-scenes view into how, exactly, this whole thing works, you should become a subscriber now. Why?
I’m soon going to share exactly how this was made in a subscriber-only post (both free and paid). Want to support these free prompts? Why not get a paid subscription? Either way, just mash this here button:
ChatGPT AutoExpert (Developer Edition)
License: Attribution-NonCommercial-ShareAlike 4.0 International
Important: This requires a ChatGPT professional subscription, as it needs both GPT-4 and Advanced Data Analysis!
You can get both of my AutoExpert custom instructions from Github now!
See it in action...
Why use this?
Verbosity Selection: Easily choose the complexity of the generated code, from compact "code golf" type responses, up to complex, modular code samples
Powered by Jupyter: ChatGPT Advanced Data Analysis already runs a Jupyter kernel under the hood. AutoExpert (Developer Edition) comes with a companion Python script that you simply upload to your conversation. It will automatically take advantage of the sandbox Python environment for editing longer code samples, and activate a handful of extra "slash commands" to make your life even easier.
Pick Up Where You Left Off: You can start a new chat without worrying about ChatGPT forgetting what you were doing in the previous one. The
/memory
slash command will download all your files, and a history of everything that's been done during your session. Simply upload it (along with the companion script) in a new session, and pick up where you left off.Install Custom Wheels: Yeah, you heard me. Wheels for Python packages can be uploaded and installed automatically.
Note that your ChatGPT sandbox uses Python 3.8, on a VM with
x86_64
architecture (as of this writing).
Save Your Work: Among other
/slash
commands, AutoExpert (Developer Edition) will save all your code snippets, dehydrate its memory of your requirements and the work it's done—even back up the code cells themselves. Then it zips it up, and you can quickly download your coding conversation history.File and Symbol Tree: By keeping a running history along with a file/symbol tree at the end of each response, ChatGPT will always remember what it just did, and you'll always see what files still need work. It's even smart enough to handle breaking down complex requirements in a way that allows it to write code over multiple turns.
Usage
Verbosity
You can alter the verbosity of the code written by ChatGPT by prefixing your request with V=[0–3]
.
V=0
: code golf (really terse)V=1
: concise, but not overly cleverV=2
: simple (the default)V=3
: verbose, paying even more attention to DRY principals
Slash Commands
Once autodev.py
has been uploaded (instructions below), you'll have some new functionality accessible through the use of Slash Commands:
/help
: Shows what slash commands are available
/install_ctags
: If attaching a ctags
release from ctags-nightly-build, will extract and install it to the sandbox (experimental)
/ctags
: If ctags
has been installed, builds a ctags file for your saved code (experimental)
/memory
: Saves files, session history, etc. and zips them up for download
/stash
: Prepares to stash some text, to be recalled later with /recall
/recall
: Recalls text, using a key or description that appears after the command, that was previously stored with /stash
Slash Command Tips
Before ending your session, use the /memory
slash command to zip up all your hard work. The next time you start a session, attach the zip file in the same message as autodev.py
, and AutoExpert will automatically extract your zip file and restore its memory of the work that was done in the last session.
Usage Notes
Once the custom instructions have been set (and the autodev.py
file has been uploaded), you should notice that ChatGPT's responses to your coding requests are a lot smarter. Why?
Every time you ask ChatGPT to code something, it is instructed to create a preamble at the start of its response. This preamble is designed to automatically adjust ChatGPT's "attention mechnisms" to pay more attention to your requirements, the type of code it will need to write, and the plan it should follow when writing it.
Preamble Example:
Me: Show me a sample JavaScript file that has a couple of classes with methods, and a couple of top-level functions. Don't use the sandbox yet.
ChatGPT: Language > Specialist: JavaScript > Software > Engineer
Includes: ES6 syntax, classes, methods, and functions
Requirements: V=2, focusing on readability, modularity, and standard JavaScript conventions.
Plan
Create a JavaScript file outline in text form.
Define two classes with methods.
Add two top-level functions.
It tries its best not to elide or omit any code, and will also attempt to break down its tasks to occur over several chat turns, asking you to continue when it needs to. It'll even throw in some // TODO:
comments where it knows it'll be editing something on the next chat turn.
The epilogue section at the end of each response keeps important things in memory no matter how long your chat context gets. Things like:
The stuff ChatGPT has done so far
A list of every file it has written
An outline of any classes and/or functions and methods in those files
Epilogue Example
History: Provided a sample JavaScript file with two classes (
Calculator
andAdvancedCalculator
) and their methods, along with two top-level functions (add
andsubtract
).Source Tree:
⚠️ sample.js
📦 Calculator
✅ add
✅ subtract
📦 AdvancedCalculator
✅ multiply
✅ divide
✅ add (global function)
✅ subtract (global function)
Next Task: No pending tasks. Would you like to implement this sample in a real JavaScript file?
Emoji key
💾: File was saved to the sandbox (the filename is linked for download)
⚠️: ChatGPT created a code snippet with a filename, but it hasn't been saved
👻: ChatGPT created a file snippet, but it doesn't have a filename
📦: Class name (if classes are being used)
✅: Symbol (function/method) is finished
⭕️: Symbol (function/method) is not finished yet, and has a TODO comment
🔴: Symbol (function/method) is not finished yet, but doesn't have a TODO comment
Installation (first time)
ChatGPT AutoExpert (Developer Edition) is intended for use in the ChatGPT web interface, and with a Pro subscription. To activate it, you'll need to do a few things!
Download the latest release
Expand Assets, then download the file titled "Source Code (zip)"
Extract the downloaded .zip file
Sign in to ChatGPT
Select the profile + ellipsis button in the lower-left of the screen to open the settings menu
Select Custom Instructions
Copy and paste the text from developer-edition/chatgpt__about_me.md to the first text box, replacing whatever was there
Copy and paste the text from developer-edition/chatgpt__custom_instructions.md to the second text box, replacing whatever was there
Select the Save button in the lower right
Continue with the per-chat installation steps
Installation (per-chat)
Start a new chat
Select GPT-4 at the top of the new chat
Select Advanced Data Analysis from the menu
Attach
autodev.py
by selecting the (+) button to the left of "Send a message" at the bottom of the chatWithout entering any other text in the input text box, select the paper airplane icon to send the empty text and upload the
autodev.py
fileIf all went well, you should see a heading "ChatGPT AutoExpert (Developer Edition)" along with an introduction to the tool!
This is fantastic! wow!