Live data from Hacker News

A Friendly Introduction to Racket

geometridae.bearblog.dev

191–195 of 195 posts

Re: A Friendly Introduction to Racket

#191

Earlier quoted context omitted.

It is not due to deployment options. People put all sorts of stuff in docker containers every day. It is rather that few people make an effort to learn a lisp, and fewer still who choose to learn Racket. The few universities teaching good computer programming basics using Racket don't really make a dent. You simply don't have coworkers who know this stuff. Are you going to be the one person making a decision at the c…

Would love to get coffee or kölsch sometime.

Could do. I have a website in my profile. : )

Re: A Friendly Introduction to Racket

#192
post #185

Earlier quoted context omitted.

Are you suggesting, possibly, that a team of 10x Lisp hackers with 10x agent force multipliers could catch up with the depth and bread of Python's CheeseShop and proceed to right the world?

No, what makes you think so? I'm saying that you can produce some interesting apps to explore.

possibly, but not something i would want to learn from.

Re: A Friendly Introduction to Racket

#193

Earlier quoted context omitted.

I don't see where the above says that Prolog is a "poor general purpose language"? I'd instead say that claim is incompatible with the following paragraphs that rather sing the praises of Prolog as a programming language: Prolog is one of the two classic languages for symbolic artificial intelligence programming (the other classic language being Lisp). Prolog excels at implementing symbolic rule-based systems in whic…

That link wasn't an argument to support my claim, just a related comparison. > So, why do you say that Prolog is a "poor general purpose language"? Big disclaimer: I have almost no Prolog experience beyond a distant university class, so I've no idea what's possible with a pragmatic impl. like SWI-Prolog. Still, this is my uninformed "Emacs vs vim tier" opinion. For the same reason as most other people do so: when you…

> Prolog loses much of its power and intuitiveness to become a barebones functional PL

How do you mean? The grain of Prolog isn't functional in the slightest, and it's not a barebones language by any means. It comes with a massive standard library, extensive tooling, etc. Real Prolog implementations come with their own UI toolkit, IDE, etc.

> without much going for it

There's plenty of going for it, there's frankly nothing else like it. It has all the same mutable grammar as a Lisp, and a computational model that's much, much better at language-processing. Bi-directional structural matching through unification, execution path natively handled by backtracking, and DCGs as part of the standard, etc. All of these things contribute to an incredibly unique superpower that makes implementing sound DSLs of any type-0 grammar incredibly trivial. More so than any other language, including Lisp!

This is all incredibly superficial too. DCGs are a lot more general than just describing a foreign grammar, and they're a single example of what you can use Prolog's mutable grammar to do (DCGs are just a macro!)

> (needing lots of extensions beyond ISO)

Which is true of all industrial grade tools. Look at LispWorks and SBCL, look at Racket. They don't stop at the standard, do they? The ISO standard for Prolog is a massive beast, much larger than you think it is, and is plenty useful by itself. But it's hardly meaningful that serious tools go beyond the standard, or provide ways to break it. That's a universal for serious tools.

Here's the thing, even putting aside all the architectural choices of miniKanren that make it inappropriate for symbolic AI (immutability, occurs-check, etc.) it is what you accuse Prolog of being: barebones. To this date, I don't think a single real debugger exists for any miniKanren implementation. It's always the most hacky, unsound, "why care about it" neglect. All other issues aside, this one (of many) effectively kills it. We're not talking an issue of needing to build up intuition for an alien execution model, we're talking the complete and total lack of introspection for something we're trying to build a complex system with.

In Symbolic AI, your inference system cannot be a second class citizen. It is where the overwhelming majority of your work lives. It is where all the complex machinery is built. It requires a real development system built around the inference engine, because that thing is your computer. You need a debugger. You need an IDE. There's a reason LispWorks puts so much effort into KnowledgeWorks, why it comes with so much stuff. That's why corporations pay out the nose for enterprise licenses. You can't have a serious, usable system without serious tools.

Re: A Friendly Introduction to Racket

#194
btw: Lean 4 is getting all the buzz these days, but how many people know that Scheme/Racket is an extraction target language for the Rocq Prover (aka Coq).

https://rocq-prover.org/

The Rocq Prover implements a high-level program specification and mathematical language called Gallina that is based on an expressive formal language called the Polymorphic, Cumulative Calculus of Inductive Constructions that itself combines both a higher-order logic and a richly-typed functional programming language. Through a vernacular language of commands, the Rocq Prover allows:

    to define data structures, functions or predicates, that can be evaluated efficiently;
    to state mathematical theorems and software specifications;
    to interactively develop formal proofs of these theorems;
    to machine-check these proofs by a relatively small certification "kernel";
    to extract certified programs to languages like OCaml, Haskell or Scheme.
As a proof development system, the Rocq Prover provides interactive proof methods, decision and semi-decision algorithms, and a tactic language for letting the user define its own proof methods. Connection with external computer algebra systems or theorem provers is available.

As a platform for the formalization of mathematics or the development of programs, the Rocq Prover provides support for high-level notations, implicit contents and other mechanisms for formalization at scale.

Re: A Friendly Introduction to Racket

#195
post #44

Earlier quoted context omitted.

It's not a program, it is (obviously) a totally unrealistic hodgepodge expression for a list of constant values that simply demonstrates the literal syntax for a variety of types of values (real numbers, dotted pairs, rational numbers, complex numbers, polar coordinates, etc. -- Racket is unusually expressive in the types of literals). Your comment demonstrates something typical of HN, and it's not a good thing. It's…

I think in this case it is probably justified, as the claim of "no special syntax" is unfortunately not true. To convey the amount of special syntax, it got crammed into one brief example snippet. Still, far less than most other programming languages, virtue of having parentheses making things unambiguous. Outliers are Smalltalk and maybe (?) Forth.

Aren't reader macros just a convenient shorthand?
Post reply on HN