title: Amazon Sagemaker: write your own inference
body: <p>I was evaluating what is needed to write your own Estimator in Sagemaker. I was following this example <a href="https://github.com/aws/amazon-sagemaker-examples/tree/master/advanced_functionality/scikit_bring_your_own/container" rel="nofollow noreferrer">here</a> and it's well explained and quite simple.</p>
  <p>My question is regarding the inference <a href="https://github.com/aws/amazon-sagemaker-examples/blob/master/advanced_functionality/scikit_bring_your_own/container/decision_trees/predictor.py" rel="nofollow noreferrer">here</a>. I see an example in which we can feed the <a href="https://github.com/aws/amazon-sagemaker-examples/blob/e648e9a6f596263c7683635d1a55f1729b08277d/advanced_functionality/scikit_bring_your_own/container/decision_trees/predictor.py#L60" rel="nofollow noreferrer">invocations endpoint</a> a CSV. What if I want to just post a string or even individual parameters? What's the best practise for that? I see there is a condition like:</p>
  <pre><code>if flask.request.content_type == &quot;text/csv&quot;:
  </code></pre>
  <p>Should we add more like those to support different formats or should we create a new endpoint?</p>