My Workflow stack with GPT

Thar Htet
8 min readFeb 11, 2023

--

Please bear with my long text. I could have written shorter if I had more time.

To be honest, I have been using GPT since before the release of ChatGPT. When the hype started, many people treated and interacted with ChatGPT like an intelligent beings. But it is not. Many of those in the ML field understand and can explain better than I do.

Current hype and people writing about it (including this post) is so dizzying, as many writers from the perspective of their own work domain. Many of them are not programmers, and they were aware of this tool only when it was so easy to interact via ChatGPT.

There are many controversies and arguments on its potential and future uses. I have my own opinion, but I won’t discuss that in this post.

As a person from the software engineering field and as a daily GPT user, I just want to share my setup of how I have been using it for a specific purpose in my day-to-day job. This may not be relevant to everyone, but I hope it gives you some perspective and is useful too.

Following is my daily tools integrated with GPT in my workflows

My Setup

Text Generator with Obsidian

Obsidian is my primary knowledge management software. It is a very easy-to-use and effective software with all text kept in Markdown format. I use it for my daily note, meeting notes, ideas, references, design drafts, etc. Obsidian allows a wide range of community plugins.

I use the Text Generator plugin that integrates the note editor with API calls to OpenAI GPT APIs. Just simply select the text with the prompt, and Cmd+J does the magic. The good thing is both input and generated outputs come in one place. The limitation is I can only do it per file basis context, and sometimes I need to adjust the max_token depending on how big the content is.

I use it primarily for the followings.

  • To summarize the daily note at the end of the day. I have specific keywords and patterns in my note typings. So my summary prompt gives me one paragraph summary and extracts any important points to remember at the end of the day. Not a perfect one, but it saves me the cognitive overload to getting a draft so that I can look and confirm.
  • To make exploration in Q & A form instead of searching with a Search engine. When I need to learn about a new technology or an unfamiliar topic, I just list down my mind-boggling questions and then Cmd+J to generate the Answer for each question. It saves me time to search and read and collect information with Search Engine. I don’t trust all the answers it generated, but at least I get my answers faster with less effort and understand a broader picture in the shortest time. I would tweak the prompt and question to explore further. This does not work on the interactive level like ChatGPT. But since I was using it before ChatGPT and the answers go straight into my note-taking tool for the record.
  • To summarize and extract key takeaways from meeting notes. None of my work days is without meetings. There always has an online meeting or face-to-face meeting. I have a habit of typing in anything that resonates with me and important points other parties spoke about. Typing along in meetings is quite a challenge, as I won’t be able to type proper sentences. I would throw in some screenshots and reference links along with my notes. At the end of the meeting, I just prompt for a single paragraph TL;dr and list of next action items to be generated at the end of the note. It is not perfect, but I got a draft to modify and send to anyone needed immediately.

Use for ideation and content conversions such as Listed items into Markdown Table or PlantUML diagram code. During my software solution design ideation, I would just type a concept in list form along with the requirements and constraints. Then I typed online headers (these important prompt inputs) and let the GPT draft me per section basis. It saves me time for repetitive work.

GPT-Prompter with Chrome

I have a GPT-Prompter plugin setup in my chrome with API Key for OpenAI API. I have it set up with templates for TL;dr. Three key take aways and Highlight worthy prompts. I use that for the following case

  • To summarize the article on Medium articles. I don’t do that on every article, but only to those I want to understand fast if I didn’t get what the author says in my skimming. I just select the chunk of Text and let the plugin calls to API for the selected text and the prompt. This gives me quite a good summary in addition to overview skimming. TL;dr and key takeaways help me remember the article better. After seeing them, sometimes I would skip reading the whole and sometimes I would read the whole article if the summary resonated with me.
  • The same goes for E-Book reading in the browser. In the E-Book case, I would skim through chapter titles and list them down as curious questions in my notebook first.
  • The only inconvenience is that I have to manually copy and paste the generated summaries. But I take it as part of the process for me to slow down.

ChatGPT, I use it for idea exploration of the topic I read. ChatGPT is suitable for contextual conversation alike interaction. I use it in two modes. Sometimes after reading the material or sometimes before reading it.

For example, when I saw the article “Managing Oneself” by Peter Drucker. Before I read, I asked ChatGPT if I knew about that title and kept asking about details and key statements from that article. And then ask for any other article or literature about those statements as well as opposite perspectives. It helps me break down the content before I even dive into the article, priming my mind with additional knowledge to help me understand the article better.

Frankly speaking, this is counterproductive for me, but it is enjoyable to ingest new knowledge. I notice that ChatGPT makes up unrealistic but sounds plausible stories just to answer my question. So I have to treat it like a friend who would bluff his way to answer anything that it seems to know but doesn’t know exactly.

Copiloting in VS Code

I use VS Code for both programming and software solution documentation. My day-to-day work involves more code exploration than programming and typing solution design and diagrams in Markdown files. I use PlantUML to draw the diagrams as code, which suits so well as I am using Text Generators.
I use CoPilot like a friend who would guess to complete my sentences as I speak.
In the given context of the solution file, it is aware of the Vocabulary, Object names, Function names, etc. and given the prompt, it suggests the next line of text as autocomplete, in addition to code block suggestions.

  • It is a powerful intelligence and autocompletes engine in the IDE.
  • It is integrated so well with VS code.
  • I usually type proper titles for the solution document and headers.
  • Then I set the main context. I type the problem requirements and describe the intended solution design as if I am explaining to someone. I make sure to cover all the Domain Object names, and function names between them, including the Actors, Systems, and brief explanation of the interaction between them.
  • Once the paragraph is set, I just move my cursor to the next line under each titled section, and CoPilot will start suggesting what you shall auto-complete.
  • I usually have the section titles such as overview, context, domain models, erd, sequence flow, API spec etc. Depending on the effort and coverage I put into the main context, CoPilot will pick up a lot of things accurately and generate respective content suggestions.
  • For example, under the ERD section, if I lead by typing `plantuml` it would suggest ERD diagram. This is same for the sequence flow diagrams too. Surprisingly, if the main context description is very clear, it will generate the interaction between the system so close to the description in main context. If I type ahead with yml under the API section, it would suggest open API spect.
  • Not all the suggested text is good, but I can complete my first draft of the whole solution document with respective diagrams and specifications w/o much effort. Then I would revise the whole draft to be precise.
  • The good thing is, Copilot only suggests me, as I am thinking and typing along step by step, so I am still in control. The bad thing is also that step-by-step suggesting and only to related context.

So I use the CodeGPT extension to overcome that. CodeGPT is like the TextGenerator extension and GPT-Prompter plugin. It talks to OpenAI API.

With CodeGPT

  • I can document the whole file (eg. Java Class) into a summary or list of functions with explanations etc.
  • It has ready-made prompts for frequently used functions such as creating standard Documentation, explaining the code in English etc.
  • This is very useful for exploring the code bases and creating the documentation for previously developed but un-documented source codes.

I also use the Copilot in VIM editor too. Sometimes it is easier to open up and file in VIM quickly and make changes rather than firing up the whole VS Code.

GPT in Commandline

As I get old and lazy, I forgot some complex structures of linux commands and regex etc. And sometimes for a small quick question, putting that question into Obsidian and generating breaks the flow. And I can’t type that arbitrary question into VS Code and wait for Copilot to complete me. These integrations are great in their own workflow.

I needed a quick and easy interface to query / complete when needed. So I fall back to basic of the command line.

  • I use the openai-python sdk which comes with openai command.
  • The openai command has function to call API directly.
  • So I created a shell script which works in REPL mode like Q&A session.
  • The script also accept a large text chunk from file and single direct question input.
  • This script provides me GPT access during my command line workflows.

The program is available at https://github.com/kotharthar/aok

The Cost

  • I subscribed to OpenAI API for pay-as-you-go billing with hard limit at $10 per month. My daily use is about 20–50 API calls aday and cost about $0.3 to $0.5 per day. I will still keep this as it is quite well integrated into my workflows.
  • I have Github CoPilot Subscription at $10 per month. I will still keep this as it helps me in coding and documentation.
  • I just subscribed to ChatGPT Plus at $20 per month with curiosity to get early access to upcoming latest features. I may fall back to Free Plan if they provide API and no new exciting features.

Does AI make me dumb? Will it make me lose my job?

You see. This GPT is a powerful tool for me in my creative workflows. I am glad that some awesome people have created awesome integrations with the tools that I used for my creative work. Going back and forth to ChatGPT disrupts my flow. Since OpenAI provides API, there are many ways to integrate, like my own shell script for terminal integration.

By any means, I don’t feel obsolete by using AI tools. I feel empowered and save time and effort in repetitive steps in my workflows. Like we all adapted to use various computing tools, this is just another tool for us. We just have to adapt accordingly to do better. AI and those learned machines need a good operator to get good results.

I hope this article is helpful. I will try to put an example demonstration in video clips for the cases I am using above.

--

--

Thar Htet

A Software Engineer turned Entrepreneur, running a Software Company in Myanmar serving Web, Mobile and Cloud solutions to Consumer, Businesses & Public.