Oh, to have a non player character (NPC) with an inventory, just create a room by itself somewhere and use that to store the NPC objects. Then you can loop through the room objects to list the inventory, etc.
In the QDP the script command editor window has a section called "Game Control" and when you expand that section there is a selection to "Run a script for each object in a room." Click that and select the room name that you're calling your NPC inventory. Then you could do whatever... like a print statement with #quest.thing# to list each item in the room (i.e. inventory), or check if #quest.thing# is equal to the object you're looking for. (By the way #quest.thing# is not a made up name. It's the pointer you would always use in a room loop to reference the current object in the list).
The other way to do this of course is in a customized array, but that's kind of messy (in my opinion) when you can just use a room object and all the built in functionality that goes along with room objects.
And if you do a customized get or put command to move objects from an NPC to the player, to notify the player that you did it you just do a print statement (i.e. MSG <whatever>) like:
#(NPC_name):prefix# #@NPC_name# gave you #(quest.thing):prefix# #@quest.thing#