Remix.run Logo
▲ Truss: A programming language optimized for agent-written software(github.com)
19 points by sram1337 an hour ago | 9 comments
▲grahamlee 32 minutes ago | parent | next [-]

Difficulty: no existing model is trained on Truss. They have been trained on examples of design by contract in other languages (Ada, Eiffel, Java etc) and would do a better job with those and with contract-enforcement rules. Or even with grammar-constrained output and those languages.

Source: I also tried writing an agent-optimized language (for concision and adaptability, not correctness), then I measured.

▲capv 13 minutes ago | parent | next [-]

+1. You cannot teach AI a new programming language with prompts. In order to be efficient the language has to be in its "brain", i.e., AI's neural network has to be trained on large number of samples.

▲rfgplk 7 minutes ago | parent [-]

They already have been trained, on other languages that provide similar-enough constructs to translate over to the new language. Same principle as how a C++ developer can write Rust after looking at a few syntax examples.

For instance:

  contract ReplaceElement {
       function replace(words: &mutable Slice<UInt64>, index: UInt64, value: UInt64) -> UInt64
           requires index < words.len
           ensures result == old(words[index])
               and snapshot(words) == update(old(snapshot(words)), index, value)
           terminates
           effects { read(words), write(words) }
   }
This is _extremely_ similar to JS/Rust/Java style syntax mixed with common forms from general ALGOL descendant languages. LLMs should have no trouble writing this whatsoever.
▲cyanydeez 2 minutes ago | parent [-]

you don't want anything thats extremely close; you want something that is dissimilar and users very cogent keywords.

Similarity shits up context very quickly.

▲rfgplk 9 minutes ago | parent | prev [-]

Incorrect. Models can actually adapt to new syntax quite easily, even with zero training material. Of course that does depend on how truly novel your syntax && constructs are, but generally speaking if you don't deviate too-too far from conventional wisdom you should be fine. My language is quite exotic in fact and frontier LLMs have no trouble writing it, as long as you supply a .bnf file.

▲DonaldPShimoda 6 minutes ago | parent [-]

It's funny: if we were talking about programming languages generally, I would pop in to say something about how syntax really doesn't matter and a language having "exotic" syntax is almost entirely irrelevant. But since LLMs only interact with syntax, it's interesting that they are seemingly able to adapt to novel syntax fairly well.

▲pwdisswordfishq 27 minutes ago | parent | prev | next [-]

Named for having the lifespan of an iceberg lettuce?

▲phoghed 15 minutes ago | parent [-]

Named for how you have to respond to people at work questioning wtf you’re doing. “We got this bro. Truss”

▲acedTrex 8 minutes ago | parent | prev [-]

Its hard to hate a project more than this to be honest. What an anti human way to think.