class_docstr: Static Faiss Retrieval Flask resource.
  The PUT method is to get KNN tokens.
code: def put(self):
      data = request.get_json()
      sentences = data["sentences"]
      num_neighbors = data["neighbors"]
      with (
          lock
      ):  # Need to get lock to keep multiple threads from hitting code
          neighbors = self.get_knn(sentences, num_neighbors)
      return jsonify(neighbors.tolist())
  
imports: import base64
  import logging
  import pickle
  import threading
  import time
  from typing import List, Union
  import faiss
  import numpy
  import torch
  from flask import Flask, jsonify, request
  from flask_restful import Api, Resource
  from nemo.collections.common.tokenizers.tokenizer_spec import TokenizerSpec
  from nemo.collections.nlp.data.language_modeling.megatron.indexed_retrieval_dataset import MMapRetrievalIndexedDataset
  from nemo.collections.nlp.modules.common.megatron.retrieval_services.util import lock, request_data
label_desc: Use image node_id 2 for calling the FaissRetrievalResource obj's underlying member method code with example usage: obj.put() and returns: jsonify