Is your feature request related to a problem? Please describe.
I'm always frustrated when I need to copy generated Mermaid script from the chat window into Mermaid Live just to see the diagram.
Describe the solution you'd like
It would be amazing if the chat renderer could detect the Mermaid script tag and render the diagram using Mermaid.js.
This feature could be enabled or disabled via a user setting or controlled by an inline toggle in the chat when you hover over the Mermaid script. This setting should be sticky, remembering the last used preference.
Basically, I'm looking for the "Diagram" feature from big-aig
Describe alternatives you've considered
The only alternative I've found is to copy and paste the generated Mermaid code from the chat into an online renderer.
Additional context
This project is great, and I am looking forward to seeing how it evolves.
Originally created by @joelmnz on GitHub (May 15, 2024).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/2271
**Is your feature request related to a problem? Please describe.**
I'm always frustrated when I need to copy generated Mermaid script from the chat window into Mermaid Live just to see the diagram.
**Describe the solution you'd like**
It would be amazing if the chat renderer could detect the Mermaid script tag and render the diagram using Mermaid.js.
This feature could be enabled or disabled via a user setting or controlled by an inline toggle in the chat when you hover over the Mermaid script. This setting should be sticky, remembering the last used preference.
> Basically, I'm looking for the "Diagram" feature from big-aig
**Describe alternatives you've considered**
The only alternative I've found is to copy and paste the generated Mermaid code from the chat into an online renderer.
**Additional context**
This project is great, and I am looking forward to seeing how it evolves.
@newzealandpaul commented on GitHub (May 29, 2024):
This is support in some LLM clients. It is a very useful feature. Is there a plugin interface to open-webui to enable content filters?
<!-- gh-comment-id:2136465225 -->
@newzealandpaul commented on GitHub (May 29, 2024):
This is support in some LLM clients. It is a very useful feature. Is there a plugin interface to open-webui to enable content filters?
@newzealandpaul commented on GitHub (May 29, 2024):
@tjbck great! I Looked at the example, does it allow modifying how LLM responses are rendered?
Here is an example conversation below. Ideally some JS could be inserted inside the web ui that simply renders a mermaid chart above or below the response. Just like how GitHub issues does it.
User: Generate a mermaid 10.0.7 diagram showing relationships inside a transformer neural network
Assistant: Creating a diagram in Mermaid 10.0.7 to show the relationship in a Transformer Neural Network is a great idea. A Transformer model comprises an encoder and a decoder, with multiple layers for attention mechanism and feedforward neural networks. I'll outline a basic structure for you.
Here's the Mermaid diagram code to demonstrate the components and how they relate to each other:
@newzealandpaul commented on GitHub (May 29, 2024):
Mermaid as generated by GPT4 start with the following (where ' is a `)
'''mermaid
Its very hard showing this in Github issues because Github aggressively renders mermaid
<!-- gh-comment-id:2136486334 -->
@newzealandpaul commented on GitHub (May 29, 2024):
Mermaid as generated by GPT4 start with the following (where ' is a `)
'''mermaid
Its very hard showing this in Github issues because Github aggressively renders mermaid
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Originally created by @joelmnz on GitHub (May 15, 2024).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/2271
Is your feature request related to a problem? Please describe.
I'm always frustrated when I need to copy generated Mermaid script from the chat window into Mermaid Live just to see the diagram.
Describe the solution you'd like
It would be amazing if the chat renderer could detect the Mermaid script tag and render the diagram using Mermaid.js.
This feature could be enabled or disabled via a user setting or controlled by an inline toggle in the chat when you hover over the Mermaid script. This setting should be sticky, remembering the last used preference.
Describe alternatives you've considered
The only alternative I've found is to copy and paste the generated Mermaid code from the chat into an online renderer.
Additional context
This project is great, and I am looking forward to seeing how it evolves.
@newzealandpaul commented on GitHub (May 29, 2024):
This is support in some LLM clients. It is a very useful feature. Is there a plugin interface to open-webui to enable content filters?
@tjbck commented on GitHub (May 29, 2024):
@newzealandpaul We're planning on pushing our plugin framework Pipelines to allow such actions, stay tuned!
@newzealandpaul commented on GitHub (May 29, 2024):
@tjbck great! I Looked at the example, does it allow modifying how LLM responses are rendered?
Here is an example conversation below. Ideally some JS could be inserted inside the web ui that simply renders a mermaid chart above or below the response. Just like how GitHub issues does it.
User: Generate a mermaid 10.0.7 diagram showing relationships inside a transformer neural network
Assistant: Creating a diagram in Mermaid 10.0.7 to show the relationship in a Transformer Neural Network is a great idea. A Transformer model comprises an encoder and a decoder, with multiple layers for attention mechanism and feedforward neural networks. I'll outline a basic structure for you.
Here's the Mermaid diagram code to demonstrate the components and how they relate to each other:
Here's the Mermaid diagram code to demonstrate the components and how they relate to each other:
@newzealandpaul commented on GitHub (May 29, 2024):
Mermaid as generated by GPT4 start with the following (where ' is a `)
'''mermaid
Its very hard showing this in Github issues because Github aggressively renders mermaid
@tjbck commented on GitHub (Jun 3, 2024):
Added to dev, releasing 0.2.2 soon!