![MindMaps take PartyRock to the Next Level](https://assets.community.aws/a/2dYB0mSjqItf8C3XTRWpm2QyVe6/img_.webp)
MindMaps take PartyRock to the Next Level
And by that, I mean you can now present content differently.
Published Mar 11, 2024
Last Modified Mar 23, 2024
Here's what this post is about.
![architecture architecture](https://assets.community.aws/a/2dYBA2Or5dYeWdBWD7UKAhLg86O/img_.webp)
In this project, we will visualize AI-generated content created in PartyRock.
The LLM produces markdowns on a topic and simultaneously a link that renders the markdown as a mind map.
The LLM produces markdowns on a topic and simultaneously a link that renders the markdown as a mind map.
A static HTML file receives the payload in the link and uses JavaScript to create the mind map.
If the AI-generated link does not work, users can access the static HTML page without parameters and manually copy the LLM output. More on this later.
If the AI-generated link does not work, users can access the static HTML page without parameters and manually copy the LLM output. More on this later.
The focus is on ease of use.
![input input](https://assets.community.aws/a/2dYBODucafHE3uqYxR9m92xj5DS/img_.webp)
![output output](https://assets.community.aws/a/2dYBW9tPol35LweLldAmN8Kk6M3/img_.webp)
![flow flow](https://assets.community.aws/a/2dYBb5Fn9i9rPJ5vpEiPtqyapR9/img_.webp)
There are many ways to influence the output of the LLM.
For the generation of the markdowns, I have created slight variations for the 4 markdowns. There's much more that could be prompted.
For the generation of the markdowns, I have created slight variations for the 4 markdowns. There's much more that could be prompted.
The prompt for creating the link:
I use XML tags for my prompts. Whether this is necessary or if PartyRock masks it, I'm not sure. Does anyone know?
I'm using XML tags because I work with Claude, and the info comes from Claude - Use XML Tags.
I'm using XML tags because I work with Claude, and the info comes from Claude - Use XML Tags.
It's amazing that LLMs can do such things.
Unfortunately, it doesn't work 100%.
For example, the LLM generated the following in the base64 payload:
Unfortunately, it doesn't work 100%.
For example, the LLM generated the following in the base64 payload:
The code in index.html addresses this with regex.
It deletes everything before the first "# Topic":
It deletes everything before the first "# Topic":
The following corrections to the base64 payload are also made:
For markdown, even more correction and check code could be written.
The two measures above already yield good results.
The two measures above already yield good results.
Although Markdown was used because it's more pleasant to read in PartyRock, JSON might be better suited for AI processing.
This file serves as both the backend and frontend, and is a simple HTML file with some JavaScript.
If no base64 string is provided, an input form is displayed. Submitting the form reloads index.html but with parameters.
If no base64 string is provided, an input form is displayed. Submitting the form reloads index.html but with parameters.
- Very long request parameters are not ideal, and there's also a limit.
- Link creation works, but it requires extensive testing, and decoding should be additionally verified with traditional methods.
- Since the LLM generates the link, it could inject malicious code. Very theoretical, but demonstrated in Sleeper Agents: Training Deceptive LLMs that Persist Through Safety Training.
- Rendering a clickable link in PartyRock would be more user-friendly. (see update)
- Link creation works, but it requires extensive testing, and decoding should be additionally verified with traditional methods.
- Since the LLM generates the link, it could inject malicious code. Very theoretical, but demonstrated in Sleeper Agents: Training Deceptive LLMs that Persist Through Safety Training.
- Rendering a clickable link in PartyRock would be more user-friendly. (see update)
- The generated link may start with a space, which could lead you to a search engine page in your browser. Pressing 'pos1' and removing the space helps. In the Chrome browser, I also had no problems with the link. Or, more simply, select the link manually and then copy it.
LLMs are functions that transform input into output. They are also good at performing text transformations.
We humans are good at developing ideas and being creative.
The ability to 'take' content from PartyRock via links and process it elsewhere should lead to many interesting projects.
We humans are good at developing ideas and being creative.
The ability to 'take' content from PartyRock via links and process it elsewhere should lead to many interesting projects.
Eager to see what you'll create.
Who'll drop the first remix?
Who'll drop the first remix?
Now, you can easily access the created mind map via a link in PartyRock.
Below are snapshots for you to try out. Have fun!