Non-Coder Lawyer Using GPT-4 to Learn to Code and Create a Python Script

So I just wanted to share here my experience and say how amazing it has been.

I’m an attorney, not a coder, but I’ve started at least 10 intro to coding courses but always fizzled out after a few lessons. So needless to say I’m not a 100% newb, but I know for example, what python is and how to use the command line.

Anyway, when GPT-4 came out, I said, ok let’s test this baby out. So I worked with GPT-4 over the course of about 6 hours of trial and error, GPT and I worked together to write a python script that goes to a particular Court’s website, scrapes recent legal opinions, scans the pdfs it finds and extracts the text, then takes that text and feeds it back into the GPT-4 API to provide text summaries output to a text file.

Needless to say, I’m gobsmacked and so excited for whatever comes next. The idea of writing even such a simple program a week ago was outside the realm of possible for me in my mind.

My next step is to compile the summaries into a newsletter and then have it autosend weekly with all new opinions.

So stoked.

Here’s an example of one of the summaries:

Case Name and Number: Yasha Clark and Morgan Walker vs. Stephanie Bridges and others, 2023-C-00237

Facts: Yasha Clark and Morgan Walker filed a petition to disqualify Stephanie Bridges as a candidate for the upcoming election for the office of Orleans Parish Civil District Court Judge, Division “B.” They alleged that Ms. Bridges falsely certified that she had filed her state and federal income taxes for the past five years. The specific issue before the court was whether Ms. Bridges’ 2021 state tax returns were electronically filed at the time she filed her notice of candidacy.

Court’s Rationale and Holding: The court reversed the judgment sustaining an objection to candidacy and petition for disqualification filed by the plaintiffs, reinstating the defendant’s candidacy. The court concluded that at the time of her candidacy, Ms. Bridges complied with the statutory law and administrative regulations related to filing her income tax return. The court reasoned that a tax return filed electronically is deemed filed on the date of transmission to the Louisiana Department of Revenue (LDR) or on the date of transmission to a third party acting as its agent. In this case, the court found that TaxWise, a third-party filing service, acted as the LDR’s agent and received the tax returns from Ms. Bridges’ tax preparer before transmitting them to the LDR.

Notable Dissents: Justice Crichton, Justice Genovese, and Justice Crain dissented and assigned reasons, arguing that Ms. Bridges did not meet her burden of proof in this matter, and therefore should be disqualified as a candidate.


Hi @dprice

As our community is a community for software developers, why not share you code so other software developers can see what you and ChatGPT did together?


So cool @dprice, I’m also a lawyer learning to write some python. Agree it is so satisfying when you figure something out. Good for you.

I am not a lawyer and I do not play one on TV nor on Streaming devices… but, I am a “matured” web guy that had not programmed anything in a long time. Let alone, anything like Python and machine learning.

I am as stoked and excited as you are. I found a new life being able to create all kind of scripts that I need for work or personal stuff. Coding I would have tried to hire a freelancer for and never get the results I am getting for the cost and time.

While not perfect and can be time consuming, I am still amazed at the opportunities.