Framework

Framework

A framework is a prefabricated basic structure for programs that takes over many standard tasks for developers. They only have to write the parts that make their project unique and insert them into the existing scaffolding.

Anyone writing a computer program has to solve many things that have already been solved thousands of times before. A framework is a collection of ready-made building blocks and rules that takes on exactly these standard tasks. You can think of it like the shell of a house under construction: the foundation, walls, and pipes are already in place. Developers only need to furnish the rooms instead of starting from scratch. There are dedicated frameworks for practically every purpose: for websites, for smartphone apps, and also for artificial intelligence. The German term for it would be 'Rahmenwerk,' but the English word is the one commonly used.

Why hardly anyone starts from scratch anymore

The obvious advantage is time. A modern application consists of millions of lines of instructions. If every team had to write everything themselves, projects would hardly be affordable anymore. With a framework, a small team can write in weeks what would otherwise take years.

Just as important is reliability. Ready-made building blocks have been used and tested by thousands of people. Bugs and security vulnerabilities are usually caught early on. In-house code, on the other hand, is only tested by one’s own people, and it is often overlooked. Especially with security topics, such as handling passwords, building things yourself is a well-known risk.

A third point is the shared language. Anyone who has mastered a widely used framework can quickly find their way around in unfamiliar projects. This makes it much easier for companies to hire new people. That is why job postings often list not just a programming language, but also a specific framework.

Who calls whom: the principle of inversion

A framework differs from a mere collection of tools, so-called a library. You call a library yourself when you need something. With a framework, it’s the other way around: the scaffolding controls the flow and calls your own code at specific points. Experts call this the inversion of control. So you’re filling in gaps in an already running system.

For this to work, the framework sets rules. Certain files must have certain names, certain functions must have a fixed format. If you stick to that, a lot works automatically. If you deviate, you’re fighting against the tool. Experienced developers put it this way: you either follow the intended path or you have a problem.

This is also the biggest downside. A framework determines how a project is structured, and switching later is expensive. When new versions come with changed rules, your own code has to be adapted. And if a framework is no longer maintained, a project eventually finds itself without security updates.

PyTorch, React, and the frameworks behind AI models

In the AI world, PyTorch is the best-known example. Almost all large language models — the programs behind chatbots — are trained with it. PyTorch handles the complex mathematics and distributes the computational work across many graphics cards. Anyone building a model only describes its structure, not every single computational operation. A second well-known example is Google's TensorFlow.

Outside of AI, frameworks are mostly encountered on the internet. React, from Meta, powers countless websites and web apps. Other names from the news and job listings include Angular, Django, or Spring. Smartphone apps are also almost always built with such a framework.

A common misconception: a framework is not a programming language. It is written in a language and builds on top of it. PyTorch, for instance, uses the language Python. When news reports state that a company is making a framework openly available, this is nevertheless economically significant. Because whoever determines the tool an entire industry works with has great influence over where that industry develops.

Subscribe free. Unsubscribe the second it sucks.

High-signal news across AI, business, UX, and tech. Every morning.