Live data from Hacker News

Who needs Graphviz when you can build it yourself?

spidermonkey.dev

21–30 of 114 posts

Re: Who needs Graphviz when you can build it yourself?

#21
It is one of the game changers of AI.

It used to be a that the barrier of entry of creating a new tool was high - so we had to use popular pieces of software, often stretching them, or writing plugins (that had their own constraints).

Now it is often easier to write from scratch a new piece of software, for which with have full control.

We can stand on the shoulders of giants - not just "a giant".

Re: Who needs Graphviz when you can build it yourself?

#23
post #21

It is one of the game changers of AI. It used to be a that the barrier of entry of creating a new tool was high - so we had to use popular pieces of software, often stretching them, or writing plugins (that had their own constraints). Now it is often easier to write from scratch a new piece of software, for which with have full control. We can stand on the shoulders of giants - not just "a giant".

I'm sorry, I don't get your comment. What makes you think the approach or the code described in the article were developed by an LLM?

Re: Who needs Graphviz when you can build it yourself?

#24
This is a great write up and thank you to the author! Just a note that graphviz dot is not purely Sugiyama’s, there is a paper on the site that details the actual implementation.

Also judging from the final two images (dot vs iongraph for the same large graph) it’s clear that dot is optimized for minimal area where iongraph does not. That’s the trade off. The author claims one is more easy to navigate than the other, I think that’s debatable.

Ultimately I found that visualizing large graphs is rarely helpful in practice; they can certainly look nice for some well defined graphs, but I rarely saw well defined graphs in the wild. Ymmv but maybe some would agree?

Re: Who needs Graphviz when you can build it yourself?

#25
post #19

To be more accurate, the comparison is not with Graphviz, but with dot(1). Graphviz is a visualization framework and it includes many layout engines, implementing different algorithms: dot, neato, fdp, sfdp, circo, twopi, ... It would be great if this new custom algorithm were to be contributed to Graphviz.

It's a bit confusing. Dot apparently is both the language name [1] for the Graphviz syntax, and one of the layout engines [2], possibly with different capitalizations.

[1] https://graphviz.org/doc/info/lang.html [2] https://graphviz.org/docs/layouts/dot/

Re: Who needs Graphviz when you can build it yourself?

#26
post #9

anyone working on this space easily gets a +1! I have struggled with code to diagram tools for a while [mermaid and graphviz], and usually return to figjam when I need the readabilty and aesthetics. graph-viz is MASSIVE and a binary. mermaid requires the browser's svg rendering system to work. I just need something that builds diagrams from description easily ...

The problem with all these tools is that any diagram becomes unreadable past a certain number of nodes. So we need a higher amount of control over the compromise that is inherent in these scenarios. The approach taken by the author is a very good step in this direction and hopefully others will follow.

Re: Who needs Graphviz when you can build it yourself?

#27
Layout is one of those things humans do so easily and intuitively, yet you couldn't write an easy algorithm for it. I wonder if there's potential to use gen ai to achieve human like results. Anyone has any thoughts on feasibility and complexity of such an approach?

Re: Who needs Graphviz when you can build it yourself?

#28
post #9

anyone working on this space easily gets a +1! I have struggled with code to diagram tools for a while [mermaid and graphviz], and usually return to figjam when I need the readabilty and aesthetics. graph-viz is MASSIVE and a binary. mermaid requires the browser's svg rendering system to work. I just need something that builds diagrams from description easily ...

I've had good results using ELK for a terraform diagram generator. You can see some samples here.

https://marketplace.visualstudio.com/items?itemName=infragra...

Re: Who needs Graphviz when you can build it yourself?

#29

Looks nice. Two things on my wish list: 1. Make graphs from Clang's AST. 2. Invent some style flourish to help follow an edge that becomes part of a bundle of many edges.

If you can get the AST output into a text file, then it should be easy to convert it to the DOT input that GraphViz takes, which at heart is just a list of node connections (A -> B).

Re: Who needs Graphviz when you can build it yourself?

#30
post #21

It is one of the game changers of AI. It used to be a that the barrier of entry of creating a new tool was high - so we had to use popular pieces of software, often stretching them, or writing plugins (that had their own constraints). Now it is often easier to write from scratch a new piece of software, for which with have full control. We can stand on the shoulders of giants - not just "a giant".

To me, this article demonstrated the value of knowing your domain and its particular constraints, as well as a good understanding of prior art. Together with the only 1000 line demo it took to produce (which I suppose could have been aided by an LLM), I did not finish reading with any specific appreciation for AI.
Post reply on HN