I’ve really enjoyed using Shen so far and have learned a lot working on the different ports and tooling. As I’ve started leaning more into building real software with it, I’ve run into challenges around actually leveraging the full power of the type system to write expressive programs.
It’s not that LLMs can’t write Shen (and it’s not that they can’t with enough prompting). It’s that they don’t really want to. Shen can express design patterns from any functional language, so that’s what they typically produce. I once had a model write a “Shen program” in ShenScript that passed my test case. When I opened the file it was a giant case statement that returned hardcoded strings for each case, instead of using the dependent type system to generate the strings according to the ruleset I’d described. It had just hacked the problem with a hashmap.
I’m wondering whether we already have (or could begin assembling) a repository of Shen programs that clearly demonstrate how to leverage the language’s power and flexibility. Something that would give both humans and agents better context for learning what it means to “think in Shen” when writing a program.
For now I’ve pointed the models at the various online Shen resources, and the results have been fine, but Claude and ChatGPT are still leaving a lot of expressiveness on the table. Curious whether others have suggestions or experience on this specifically—getting better quality Shen code out of LLMs.