ChatGPT generated code won’t paste to clipboard

Max Marshall's icon

Topic title pretty self explanatory. When I try to paste patcher code generated on ChatGPT, it doesn’t seem to want to paste into Max or Max for live. Am I missing something simple?

Source Audio's icon

can ChatGPT not answer that question ?

Max Marshall's icon

ChatGPT said it could be a formatting issue or a “misunderstanding“. Thought I’d ask actual people as well in case any one else ran into this and knew a work around.

Jan M's icon

It’s most likely a “misunderstanding“

Wil's icon

Ive never once used chatgp.t
but from a logic pov try pasting in a text editor like word or pages and see what you get.

here is what a toggle code look likes. I f I copy -> new from clipboard it make a toggle.

Roman Thilenius's icon

..........

Roman Thilenius's icon

2023, when the bard KI suggest you to manually enter some non-working max code from the GPT KI into max´s nonexisting max-code input field.

a while ago bard insisted that 1025 is 2^10, and last week it told me that you can prove that 2+2=4 by adding 2+2.

meanwhile in visualartistan: KI based systems with comfyUI produce more and faster useful collage material for abstract art than artmatic or processing ever could.

Jan M's icon

Ok, let's drop the sarcasm for moment :)

@MAX MARSHALL

tldr: the code generated by ChatGPT doesn't work and is not a valid Max Patcher.

Those so-called artificial intelligences aren't "intelligent". That's just a marketing term. ChatGPT and others produce texts (or other output) using a very complex probability network that was created by analysing pre-existing texts (images, sounds etc.). Those algorithms have no sense of what is right or wrong, no perception of what makes sense to a human or a program like Max.

The surprising strength of this algorithms is that their output is structured in a way, that humans start to make sense out something originally completely non-sensical. The intelligent part is not inside the AI models, it is located inside the person reading the output and managing to relate it to their own perception and categories.

In fact, I'd argue, that with the creation of AI models engineers have achieved even something more impressive than "Artificial Intelligence". They managed to create an "Artificial Stupidity", and hence giving us a tool to understand what intelligence might mean for us. Obviously intelligence isn't a category that can exists on its own, like temperature or momentum or a wavelength. It is a category that exists only in relation to a context. It is more like 'liberty' for example. What does liberty mean? Being free - seemingly. But being free of what? Free of paying taxes, might say some. Being free of existential fears might say others.
Intelligent are beings (and maybe things) what we include in our social sphere of intelligence. We included dogs in it for a long time already, but colonists would exclude other human beings and societies to justify exploiting and suppressing them.Those algorithms expose that intelligence is mainly a social category not a physical or biological one.

So ChatGPT has create some text for you, based on your input prompts. The algorithm has created an output by recombining and maybe altering text fragments it has previously been 'trained' on. Your expectation might have been that the output is a working Max patcher, because you might have decided to include ChatGPT into your sphere of 'intelligence'. But it's simply not. The expectation that the output should be a Max Patcher is based on your previous expectation that the output will be a Max Patcher. The algorithm just has done what is always does: Re-combining previously stored fragments (the technical term is 'tokens' within this context). The output is non-sensical, like all outputs from ChatGPT. Sometimes we are able to project sense into it, sometimes not.

Wil's icon

@JAN M - thank you for proofing my post.

if folks want (or feel the need) to use something other than a pencil + the power of the human mind -
then very simply:
ask chatgpt to write a Max toggle code.
copy and paste to a word processor
in Max select a toggle and copy (not copy compressed)
paste to a word processor
compare the 2 codes
very simple , very clear
either they are the same or they are not
if the same move on to more complex code
if different find what gpt got wrong
thse are called baby steps-

Babies (children) will be doing it soon so best to get on with it

Roman Thilenius's icon

the html capabilities of chatbots are superb.

if you want a chatbot to produce proper max code, you simply have to train it to do so and it´ll work.

of course it won´t be available online, it will be right inside max.

and to make it work you would need to create about 1,500,000 example patches covering all thinkable topics and techniques, fully document everything in it, add all books available about max, make fixed rules about the json synthax and positioning of objects, and that for every max version and in 80 languages.

dont ask what chatbots can do for you, ask what you can do for them.

note the last tip bard gave me: "use the forums". this is undoubtedly correct.

our patches and explanations are usually wrong, just like in the rest of the internet, but at least they can be pasted into max.

Wil's icon
Jan M's icon

hahaha :)
@WIL: Side note - just saw the SSL cert for your webpage has expired.

MakePatchesNotWar's icon

I don't think it will ever be possible for an llm to create a maxpatch as copy-compressed code unless you give proper context to the base64? code by either specifically training it do so or have it make the translation.

If you get any working patch now its because it has been able to scrape the forums for any mention of the keyword(s) and has been able to distill the corresponding base64 json-code from all the copy-compressed patches found in those threads into a working patch. If for example we never would've mentioned "bang" in any thread at all but would've littered all the patches in those threads with bangs it would never be able to make the translation.


Roman Thilenius's icon

if you feed a chatbot with the forum, it will be able to reproduce the forum (eventually remixed)

if you want it to write code, you need to teach him the synthax of the language and how it has to be used to reach a given aim.

teaching them to make json files for max is probably 10,000 times more work than to teach them html or php.

MakePatchesNotWar's icon

"if you feed a chatbot with the forum, it will be able to reproduce the forum (eventually remixed)"

Yeah but that's what they did. Its rumoured to have literaly scraped the entire internet (or at least in terms of text). No wonder it choose to suggest to search the forum as an answer :D

Roman Thilenius's icon

for max. not for 25 other programming languages, which the bots speak fluently.

MakePatchesNotWar's icon

Yeah, ofcourse because they're all human readable languages. Gpt would need a stone of Rosetta to make the translation between the base64* json code its supposed to give and a working patch based on the prompt a user gives.

I guess you could ask it to patch for you in javascript? Besides the issue with translation Max being node-based is also a challenge as patches also have a visual aspect to them?

*What compression is actually applied when you copy-compress? Its not base64 i believe? as i tried decoding it but didn't work

👽'tW∆s ∆lienz👽's icon

rumoured to have literaly scraped the entire internet (or at least in terms of text)

oh no wonder this ChatGPT didn't paste correctly into Max, ChatGPT was so effective, it reproduced the way in which people would later delete their own posts all over the Cycling74 forums 🥸

if you feed a chatbot with the forum, it will be able to reproduce the forum (eventually remixed)

"the 'infinite monkey theorem' states that a monkey hitting keys at random on a typewriter for an infinite amount of time will almost surely type any given text, including the complete works of William Shakespeare"...
...the forums read like they were written by an infinite set of monkeys writing for an infinite amount of time... if you then feed a chatbot these particular forums, i think it will simply reproduce the same damn monkey-business over and over 😜

humans have come so far :)

👽