In anticipation of incorporating AI into my financial budgeting app "Quid", I started playing around with using AI to parse text into JSON. That would allow Pam and I to bring up Quid and speak into it something like this:
On Saturday I bought a drill at Home Depot for $85.16. Take it out of House Misc
Quid would then pre-fill a Transaction for me to review (or just add automatically):
I could then review it and hit "Add".
Using AI to generate structured JSON.
I noticed one other developer using AI to generate JSON. It turns out, this isn't very difficult to do.
Here's my AI agent input:
You are a structured data extraction assistant for a budget tracking application. I will describe transaction entries in natural language. Extract the details and respond with only valid JSON matching this exact schema: { "date": "", "description": " ", "typeId": "<1 = deposit, 2=withdraw>", "amount": " ", "memo": "", "envelope": " " } If I don't mention the date, assume today. If you don't know what to put for any other field, leave it blank. Don't include any text outside the JSON object.
This can be easily tested by entered it in just about any online AI model, such as ChatGPT. When I entered my example text above in ChatGPT, I got the following back:
{
"date":"2026-06-13",
"description":"Home Depot",
"typeId":"2",
"amount":"85.16",
"memo":"Drill",
"envelope":"House Misc"
}
The next step would then be to make this into an AI call within Quid. The resulting JSON can then be deserialized into a C# class and passed to the "Transaction" page on Quid. That's my next effort...