A Generative AI Engineer is developing a model-serving endpoint that needs to validate and format user inputs before passing them to the model, and also adjust the model’s outputs before returning them to the client. Which technique supports this requirement?