lagrangedao / community

1 stars 2 forks source link

An API link for accessing the model deployed on Lagrange space #13

Open TomYang-TZ opened 1 year ago

TomYang-TZ commented 1 year ago

Dear Lagrange Space engineers,

Is it possible to provide an api link of the model after it is deployed on a Lagrange space. The goal is to be able to call the model through an API link and get the inference result back.

The functionality is the similar to the one provided by Google APP Enginer:

image

Thank you!

flyworker commented 1 year ago

Does it mean the result for the model can be called via https? can you give a example model on googel? a real working one

TomYang-TZ commented 1 year ago

For example, you can access a diffusion model through a curl api call using the following code:

curl https://b4j1i91ceh.dev1.crosschain.computer/ \ -X POST \ -d '{"inputs": "a glass of water"}' \ --output water.jpg

Normalnoise commented 1 year ago

For example, you can access a diffusion model through a curl api call using the following code:

curl https://b4j1i91ceh.dev1.crosschain.computer/ -X POST -d '{"inputs": "a glass of water"}' --output water.jpg

this feature you are using is Lagrange Testnet Space @TomYang-TZ

space link: https://testnet.lagrangedao.org/spaces/0xFbc1d38a2127D81BFe3EA347bec7310a1cfa2373/model-test/app

image
Normalnoise commented 1 year ago

but you can just deploy the models on the diffusers framework in huggingface