code: def as_slugid(name):
      if name not in slugids:
          slugids[name] = slugid.nice().decode()
          print("cache miss", name, slugids[name])
      else:
          print("cache hit", name, slugids[name])
      return slugids[name]
  
imports: from __future__ import absolute_import, print_function, unicode_literals
  from glob import glob
  from functools import reduce
  import json
  import jsone
  import os
  import sys
  import requests
  import slugid
  import yaml
  import subprocess
  import networkx
label_desc: Use image node_id 9 for calling a global function with example usage: as_slugid(name) and returns: slugids