2

What I have:

I built a python model which generates a JSON file based on the given input. Now i want my Flutter Application to use this JSON file and to show the required output on the screen. But I don't know how to generate this JSON file whenever requested by my Flutter App. Please guide me with the approach where I will be able to integrate my Python Model with my Flutter Application.

What I want:

Python Model -> Generates a JSON file based on given input on my Flutter App -> Displaying contents of the JSON file on Flutter Application

2 Answers 2

3

You need to serve python (AI) model as a REST (API) service. You can use Django, Flask or FastAPI for this. Then called the API in Flutter, which will return JSON. You can then use the JSON as you like in Flutter.

Another brief example here: https://flutterrepos.com/lib/ketanchoyal-InstaKnow

Sign up to request clarification or add additional context in comments.

Comments

2

You need to export your Machine Learning model to tensorflow lite (assuming you built it using tensorflow). After that you can access your tensorflow model using flutter, see this and scroll down to Module 2: Importing and using model.tflite in a Flutter app.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.