Prefixes text with "hello"
Text to prefix with 'hello '
Run this model in Node.js with one line of code:
npm install replicate
REPLICATE_API_TOKEN
export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
import Replicate from "replicate"; const replicate = new Replicate({ auth: process.env.REPLICATE_API_TOKEN, });
Run bfirsh/hello-world using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run( "bfirsh/hello-world:df154106d4771d26f76466b48b91552b4d9c926d3d9db5c6dcf1997e66be3fc8", { input: { text: "world" } } ); console.log(output);
To learn more, take a look at the guide on getting started with Node.js.
pip install replicate
import replicate
output = replicate.run( "bfirsh/hello-world:df154106d4771d26f76466b48b91552b4d9c926d3d9db5c6dcf1997e66be3fc8", input={ "text": "world" } ) print(output)
To learn more, take a look at the guide on getting started with Python.
curl -s -X POST \ -H "Authorization: Bearer $REPLICATE_API_TOKEN" \ -H "Content-Type: application/json" \ -H "Prefer: wait" \ -d $'{ "version": "df154106d4771d26f76466b48b91552b4d9c926d3d9db5c6dcf1997e66be3fc8", "input": { "text": "world" } }' \ https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
{ "completed_at": "2022-03-05T01:35:36.895664Z", "created_at": "2022-03-05T01:35:36.710341Z", "data_removed": false, "error": null, "id": "hv5ivznhzzenxdmxggpruci4s4", "input": { "text": "world" }, "logs": null, "metrics": { "predict_time": 0.000002, "total_time": 0.185323 }, "output": "hello world", "started_at": "2022-03-05T01:35:36.895662Z", "status": "succeeded", "urls": { "get": "https://api.replicate.com/v1/predictions/hv5ivznhzzenxdmxggpruci4s4", "cancel": "https://api.replicate.com/v1/predictions/hv5ivznhzzenxdmxggpruci4s4/cancel" }, "version": "0fe6de4765bddcb91c820b469f263ed3e7484c0bf983681c6715cecf79576338" }
This example was created by a different version, bfirsh/hello-world:0fe6de47.
This model runs on CPU hardware. We don't yet have enough runs of this model to provide performance information.
This model doesn't have a readme.
This model is cold. You'll get a fast response if the model is warm and already running, and a slower response if the model is cold and starting up.