Re: "just like with a compiler"
> Compilers are dying, and language servers are rising in their place
Hmm, what? I don't see any signs that compilers are going to go away now or at any time in the foreseeable future.
> a file format that formally includes metadata about the source, like copyright critical sections, language server state
Trying to understand what this is supposed to mean, a web search for "language server state" throws up things like:
"LSIF is basically a way to persist language server state" from https://news.ycombinator.com/item?id=22446984
or
"However, if you have a simple use case where embedded content can be easily handled without context or language server state," from https://code.visualstudio.com/api/language-extensions/embedded-languages
Both of these - and all the similar hits - are just talking about using a "Language Server Protocol" server to provide super-duper features to source code editors. LSP servers contain lots of language-aware features (such as, ooh, the front ends from compilers) but are otherwise unrelated to running a good old compiler to generate your exes.
> a file format that formally includes metadata about the source
Like, in the source code file itself? Such as annotations within comments, laid out in, ooh, another formally defined language suited to the purpose - you could define one using XML; either way around - have the XML as a comment in the source or have the source as one or more text blocks within the XML elements. That last coud even lead to going the full Literate Programming route (not necessarily using Knuth's web/weave tools, as they don't look for the metadata you want to enforce).
Notice how the above formats are also - text! Text files *are* a good way to keep lots of the metadata about your source and its attributions, if only so that you can actually pass it on to the legal team. You can even keep the digital signature as text in the same field, to prove it hasn't been modified. About the only thing that I'd not automatically propose being text in the source file is the version control history (although VCS using simple text files is quite doable and has advantages, although speed isn't one of them).