code: def load(self, path, name=None):
          
          if name is None:
              name = os.path.splitext(os.path.basename(path))[0]
              # TODO do we care if the file extension is .thrift?
  
          with open(path, 'r') as f:
              document = f.read()
  
          return self.compiler.compile(name, document, path).link().surface
docs: Load and compile the given Thrift file.
  
          :param str path:
              Path to the ``.thrift`` file.
          :param str name:
              Name of the generated module. Defaults to the base name of the
              file.
          :returns:
              The compiled module.