Live data from Hacker News

Native JSON Output from GPT-4

yonom.substack.com

111–120 of 258 posts

Re: Native JSON Output from GPT-4

#111
post #66

Is it possible to fine-tune with custom data to output JSON?

That's not the current OpenAI recipe. Their expectation is that your custom data will be retrieved via a function/plugin and then be subsequently processed by a chat model.

Only the older completion models (davinci, curie, babbage, ada) are avaialble for fine-tuning.

Re: Native JSON Output from GPT-4

#112
Marvin Minsky was so damn far ahead of his time with Society of Mind.

Engineering of cognitively advanced multiagent systems will become the area of research of this century / multiple decades.

GPT-GPT > GPT-API in terms of power.

The space of possible combinations of GPT multiagents goes beyond imagination since even GPT-4 goes so.

Multiagent systems are best modeled with signal theory, graph theory and cognitive science.

Of course "programming" will also play a role, in sense of abstractions and creation of systems of / for thought.

Signal theory will be a significant approach for thinking about embedded agency.

Complex multiagent systems approach us.

Re: Native JSON Output from GPT-4

#113
> The process is simple enough that you can let non-technical people build something like this via a no-code interface. No-code tools can leverage this to let their users define “backend” functionality.

Early prototypes of software can use simple prompts like this one to become interactive. Running an LLM every time someone clicks on a button is expensive and slow in production, but probably still ~10x cheaper to produce than code.

Hah wow... no. Definitely not.

Re: Native JSON Output from GPT-4

#114
post #47

Actually I'm looking to take GPT-4 output and create file formats like keynote presentations, or pptx. Is that currently possible with some tools?

apparently pandoc also supports pptx so you can tell GPT4 to output markdown, then use pandoc to convert that markdown to pptx or pdf.

Here you go: https://preview.promptjoy.com/apis/m7oCyL

Re: Native JSON Output from GPT-4

#115
post #76

It works pretty good. You define a few “function” and enter a description on what it does, when user prompts, it will understand the prompt and tell you which likely “function” to use, which is just the function name. I feel like this is a new way to program, a sort of fuzzy logic type of programming

> fuzzy logic

Yes and no. While the choice of which function to call is dependent on an llm, ultimately, you control the function itself whose output is deterministic.

Even today, given an api, people can choose to call or not call based on some factor. We don’t call this fuzzy logic. E.g., people can decide to sell or buy stock through an api based on some internal calculations - doesn’t make the system “fuzzy”.

Re: Native JSON Output from GPT-4

#116
I pass a kotlin data class and ask chatGPT to return json which can be parsed by that class. Reduces errors with date-time parsing and other formatting issues and takes up lesser tokens than the approach in the article.

Re: Native JSON Output from GPT-4

#117

Earlier quoted context omitted.

99% of the time is still super frustrating when it fails, if you're using it in a consumer facing app. You have to clean up the output to avoid getting an error. If it goes from 99% to 100% JSON that is a big deal for me, much simpler.

Yup. Is there a good/forgiving "drunken JSON parser" library that people like to use? Feels like it would be a useful (and separable) piece?

Honestly, I suspect asking GPT-4 to fix your JSON (in a new chat) is a good drunken JSON parser. We are only scraping the surface of what's possible with LLMs. If Token generation was free and instant we could come up with a giant schema of interacting model calls that generates 10 suggestions, iterates over them, ranks them and picks the best one, as silly as it sounds.

Re: Native JSON Output from GPT-4

#119
post #115
post #76

It works pretty good. You define a few “function” and enter a description on what it does, when user prompts, it will understand the prompt and tell you which likely “function” to use, which is just the function name. I feel like this is a new way to program, a sort of fuzzy logic type of programming

> fuzzy logic Yes and no. While the choice of which function to call is dependent on an llm, ultimately, you control the function itself whose output is deterministic. Even today, given an api, people can choose to call or not call based on some factor. We don’t call this fuzzy logic. E.g., people can decide to sell or buy stock through an api based on some internal calculations - doesn’t make the system “fuzzy”.

If you feed that result into another io box you may or may not know if that is the correct answer, which may need some sort of error detection. I think this is going to be majority of the use cases

Re: Native JSON Output from GPT-4

#120
post #117

Earlier quoted context omitted.

Yup. Is there a good/forgiving "drunken JSON parser" library that people like to use? Feels like it would be a useful (and separable) piece?

Honestly, I suspect asking GPT-4 to fix your JSON (in a new chat) is a good drunken JSON parser. We are only scraping the surface of what's possible with LLMs. If Token generation was free and instant we could come up with a giant schema of interacting model calls that generates 10 suggestions, iterates over them, ranks them and picks the best one, as silly as it sounds.

I already do this today to create domain-specific knowledge focused prompts and then have them iterate back and forth and a ‘moderator’ that chooses what goes in and what doesn’t.
Post reply on HN