# Model mosaic/mpt-7b predict error after deploy in aws sagemaker

**URL:** <https://discuss.huggingface.co/t/model-mosaic-mpt-7b-predict-error-after-deploy-in-aws-sagemaker/41187>\
**Category:** Models\
**Created:** [May 27, 2023, 11:32pm UTC](https://discuss.huggingface.co/t/model-mosaic-mpt-7b-predict-error-after-deploy-in-aws-sagemaker/41187 "2023-05-27T23:32:17Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![genaiquest](https://avatars.discourse-cdn.com/v4/letter/g/a8b319/32.png) [@genaiquest](https://discuss.huggingface.co/u/genaiquest)\
**Post date:** [May 27, 2023, 11:32pm UTC](https://discuss.huggingface.co/t/model-mosaic-mpt-7b-predict-error-after-deploy-in-aws-sagemaker/41187/1 "2023-05-27T23:32:18Z")

</div>

How to deploy mosaic/mpt-7b model in AWS Sagemaker? I followed the instructions similar to [here](https://github.com/huggingface/notebooks/blob/main/sagemaker/11_deploy_model_from_hf_hub/deploy_transformer_model_from_hf_hub.ipynb), but get the following error. My guess is something to do with the following:

> …this model requires that `trust_remote_code=True`. This is because we use a custom `MPT` model architecture that is not yet part of the Hugging Face `transformers` package

**Any pointer on how to solve this?**

_Error on model.predict() after model.deploy()_  
_```_  
\*ModelError: An error occurred (ModelError) when calling the InvokeEndpoint operation: Received client error (400) from primary with message "{  
“code”: 400,  
“type”: “InternalServerException”,  
“message”: “/.sagemaker/mms/models/model does not appear to have a file named config.json. Checkout \u0027https://huggingface.co//.sagemaker/mms/models/model/None\u0027 for available files.”

```auto

```
