The earliest point in the game an item base can drop, and the earliest point it can roll the sockets you want. Worked out from PD2's own drop tables and socket limits.
Bases are grouped into treasure classes by quality level (qlvl) in steps of 3: armo3, weap6 and so on. A monster's treasure class is upgraded by its monster level (mlvl). The tool walks the real TreasureClassEx chains to find the highest base group reachable at every mlvl.
In Nightmare and Hell, regular monsters take the area's level from Levels.txt (MonLvl2Ex, MonLvl3Ex). In Normal each monster keeps its own MonStats level, so an area can hold a range of levels; the tool uses the strongest regular monster that can spawn there. Champions are +2 and uniques and minions +3.
A dropped item's level (ilvl) is the monster's level. Each item type has a socket cap for ilvl 1–25, 26–40 and 41+ (ItemTypes.txt), and the base's own limit (gemsockets) caps it again. Larzuk's puzzlebox, the Horadric Cube socket recipes and corruption use the same cap, so a low-ilvl copy can't be fixed later.
Areas are ordered by difficulty, then act, then monster level. Boss-only areas, Pandemonium, Uber zones and endgame maps are left out.
Data: PD2's data.zip (launcher copy), data/global/excel. The socket cap is D2Common's own rule (0x6FD74610). Rebuild with node tools/build-data.js <excel folder> > data.js.