All the nvidia/torch stuff is "only" to make it run two orders of magnitude faster or so. For the actual principles behind LLMS, 500 lines seems quite accurate.
How long would it take to explain what an LLMs is doing to someone from 1800s? It is remarkably simple.