You'd have to pester Nicholas until they added the command for that. And quite crazy. But don't worry, I'm crazy, Fax is crazy, Essence is crazy, and I wager Ruigi has his own share of craziness too, and we're all awesome.
Jiminy Christmas... Can I at least copy what lets Unarmed negate the stat bonuses if you're holding anything but an orb, tome, or shield?
Nope. Or at least not as far as sane-and-not-time-wasting modding goes. Anything particular you want that feature for? Because we (likely "me" in this case, seeing as I'm here now) might be able to help you find an alternative.
Original idea was a weapon skill, "Library Science," that acted as a weapon skill with Tomes. Then when that turned out to be prohibitive, thought of turning it into something like Unarmed with biggish magical damage and def stats but only when unarmed to give it some balance (along with a couple utility abilities) and give some flavor and utility to Shield/Unarmed melee builds and/or throwing builds. I'm fairly certain that I can salvage a less interesting skill that'll work for what I was thinking, but it's likely to be either OP as a "magical Unarmed" that you don't need to be unarmed for, or just boring without Reshelving, transmuting one tome into another (Palimpsest), or teleporting between bookshelves on a level, which I hold out no hope of possibility for.
Skill triggers that allow you to change what things do based on what's in your hand are coming in 1.14. At the moment, there are triggers for shields, swords, axes, maces, staffs, daggers, and polearms. I've begged David for triggers for dualwielding, non-wielding (i.e. unarmed), and single-wielding (which you could combine with shields to do sword-and-board, leave alone to do two-handed style, and so forth.) Unfortunately, tomes and orbs are considered shields by the game, and I highly doubt that the GLG folks are going to rip deeply enough into the core game files to separate them out. But you can always try asking really nicely. Also, the ability to obtain new recipes exists (<effect type="findrecipe">). I don't think there's any way to target specifically empty bookshelves, but you could put together SOMETHING that gives you new recipes (a la Alien Autopsy). Just gotta figure out how to balance it.
A trigger for Unarmed would be plenty I'd wager. Making Tomes a separate thing isn't REALLY necessary (if for no other reason than there just aren't that many of them in the basic game). Could sacrifice tomes (if you could restrict it to tomes, re-doing the palimpsest idea) or possibly artifacts in a similar manner to It Belongs In A Museum. You could give a Very Long(tm) "buff" that prevents Magical Law from abusing it (seriously, the fact that you have to design every new super cool ability around Magical Law means it is overpowered). Or alternately it could have a chance to make you forget a known craft skill, which I'm sure can't actually be done, but would be very balanced.
Perhaps a skill that spawns a bookshelf and takes away Zorkmids, like the Bankster tree? Give it to Magic Training or something?
That could even be it's own tree, spawning fountains, vending machines and walls. No anvils- too risky.
Sadly, at the moment and probably forever unless they decide to open-source DoD, the only dungeon object a player can create on the fly is a static blocker. No bookshelves, fountains, etc. -- at least, not that you can interact with.