There's no way to take resources directly from their inventory, Instead Each AI type will unload their inventory into specific storages (Example: Lumberjack will store wood in Wood Piles). Also their max inventory increases automatically every time they level up!