Failed to load versions. Head to the versions page to see all versions for this model.
You're looking at a specific version of this model. Jump to the model overview.
ydideh810 /cosmo-speak:fd8ed716
Input
Run this model in Node.js with one line of code:
npm install replicate
REPLICATE_API_TOKEN
environment variable: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 ydideh810/cosmo-speak using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"ydideh810/cosmo-speak:fd8ed7161c14133273cfa8fdc60a10143a0107a7d4adeb495ba98f22257d965e",
{
input: {
debug: false,
top_k: 50,
top_p: 0.9,
prompt: "How do Sun and Earth sensors boost spacecraft navigation and mission success?",
temperature: 0.75,
max_new_tokens: 128,
min_new_tokens: -1
}
}
);
console.log(output);
To learn more, take a look at the guide on getting started with Node.js.
pip install replicate
REPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
import replicate
Run ydideh810/cosmo-speak using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"ydideh810/cosmo-speak:fd8ed7161c14133273cfa8fdc60a10143a0107a7d4adeb495ba98f22257d965e",
input={
"debug": False,
"top_k": 50,
"top_p": 0.9,
"prompt": "How do Sun and Earth sensors boost spacecraft navigation and mission success?",
"temperature": 0.75,
"max_new_tokens": 128,
"min_new_tokens": -1
}
)
# The ydideh810/cosmo-speak model can stream output as it's running.
# The predict method returns an iterator, and you can iterate over that output.
for item in output:
# https://replicate.com/ydideh810/cosmo-speak/api#output-schema
print(item, end="")
To learn more, take a look at the guide on getting started with Python.
REPLICATE_API_TOKEN
environment variable:export REPLICATE_API_TOKEN=<paste-your-token-here>
Find your API token in your account settings.
Run ydideh810/cosmo-speak using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
curl -s -X POST \
-H "Authorization: Bearer $REPLICATE_API_TOKEN" \
-H "Content-Type: application/json" \
-H "Prefer: wait" \
-d $'{
"version": "ydideh810/cosmo-speak:fd8ed7161c14133273cfa8fdc60a10143a0107a7d4adeb495ba98f22257d965e",
"input": {
"debug": false,
"top_k": 50,
"top_p": 0.9,
"prompt": "How do Sun and Earth sensors boost spacecraft navigation and mission success?",
"temperature": 0.75,
"max_new_tokens": 128,
"min_new_tokens": -1
}
}' \
https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
Add a payment method to run this model.
By signing in, you agree to our
terms of service and privacy policy
Output
{
"completed_at": "2024-07-30T20:11:56.693204Z",
"created_at": "2024-07-30T20:09:16.331000Z",
"data_removed": false,
"error": null,
"id": "d5en6kq75drgg0ch0n1a584bww",
"input": {
"debug": false,
"top_k": 50,
"top_p": 0.9,
"prompt": "How do Sun and Earth sensors boost spacecraft navigation and mission success?",
"temperature": 0.75,
"max_new_tokens": 128,
"min_new_tokens": -1
},
"logs": "Your formatted prompt is:\nHow do Sun and Earth sensors boost spacecraft navigation and mission success?\nprevious weights were different, switching to https://replicate.delivery/pbxt/rSIuuP8T2eUOJarWa0ZDrY3orSuayx7xBIJjIUmqll9nJxmJA/training_output.zip\nDownloading peft weights\nusing https://replicate.delivery/pbxt/rSIuuP8T2eUOJarWa0ZDrY3orSuayx7xBIJjIUmqll9nJxmJA/training_output.zip instead of https://replicate.delivery/pbxt/rSIuuP8T2eUOJarWa0ZDrY3orSuayx7xBIJjIUmqll9nJxmJA/training_output.zip\nDownloaded training_output.zip as 10 824 kB chunks in 0.3842 with 0 retries\nDownloaded peft weights in 0.384\nUnzipped peft weights in 0.017\nInitialized peft model in 0.008\nOverall initialize_peft took 9.953\nExllama: False\nINFO 07-30 20:11:53 async_llm_engine.py:371] Received request 0: prompt: 'How do Sun and Earth sensors boost spacecraft navigation and mission success?', sampling params: SamplingParams(n=1, best_of=1, presence_penalty=0.0, frequency_penalty=1.0, temperature=0.75, top_p=0.9, top_k=50, use_beam_search=False, length_penalty=1.0, early_stopping=False, stop=['</s>'], ignore_eos=False, max_tokens=128, logprobs=None, skip_special_tokens=True), prompt token ids: None.\nINFO 07-30 20:11:53 llm_engine.py:631] Avg prompt throughput: 0.0 tokens/s, Avg generation throughput: 0.0 tokens/s, Running: 1 reqs, Swapped: 0 reqs, Pending: 0 reqs, GPU KV cache usage: 0.0%, CPU KV cache usage: 0.0%\nINFO 07-30 20:11:56 async_llm_engine.py:111] Finished request 0.\nhostname: model-hp-73001d654114dad81ec65da3b834e2f6-888dc6d68-m2gtq",
"metrics": {
"predict_time": 13.046766136,
"total_time": 160.362204
},
"output": [
"\n",
"S",
"un",
" and",
" Earth",
" sens",
"ors",
" play",
" an",
" important",
" role",
" in",
" ens",
"uring",
" the",
" accuracy",
" of",
" navigation",
" systems",
" and",
" the",
" success",
" of",
" space",
"craft",
" miss",
"ions",
".",
" Here",
"’",
"s",
" how",
":",
"\n",
"Acc",
"ur",
"ate",
" Navigation",
":",
" Sun",
" sens",
"ors",
" are",
" used",
" to",
" accur",
"ately",
" determine",
" the",
" orientation",
" of",
" a",
" space",
"craft",
" with",
" respect",
" to",
" the",
" sun",
".",
" This",
" information",
" is",
" critical",
" for",
" navig",
"ating",
" through",
" space",
",",
" as",
" it",
" helps",
" keep",
" a",
" space",
"craft",
" on",
" course",
" and",
" avoid",
" coll",
"isions",
" with",
" other",
" objects",
" in",
" orbit",
".",
" Sun",
" sens",
"ors",
" can",
" also",
" be",
" used",
" to",
" determine",
" the",
" position",
" of",
" a",
" space",
"craft",
" relative",
" to",
" its",
" surr",
"ound",
"ings",
",",
" which",
" is",
" essential",
" for",
" mission",
" planning",
" and",
" execution",
".",
"\n",
"A",
"st",
"ero",
"id",
" Pro",
"be",
" Mission"
],
"started_at": "2024-07-30T20:11:43.646438Z",
"status": "succeeded",
"urls": {
"stream": "https://streaming-api.svc.us.c.replicate.net/v1/streams/b4fko4z7r3tfa5euybmqkaav4dwjow24mjrybel6gccnujung2tq",
"get": "https://api.replicate.com/v1/predictions/d5en6kq75drgg0ch0n1a584bww",
"cancel": "https://api.replicate.com/v1/predictions/d5en6kq75drgg0ch0n1a584bww/cancel"
},
"version": "fd8ed7161c14133273cfa8fdc60a10143a0107a7d4adeb495ba98f22257d965e"
}
Your formatted prompt is:
How do Sun and Earth sensors boost spacecraft navigation and mission success?
previous weights were different, switching to https://replicate.delivery/pbxt/rSIuuP8T2eUOJarWa0ZDrY3orSuayx7xBIJjIUmqll9nJxmJA/training_output.zip
Downloading peft weights
using https://replicate.delivery/pbxt/rSIuuP8T2eUOJarWa0ZDrY3orSuayx7xBIJjIUmqll9nJxmJA/training_output.zip instead of https://replicate.delivery/pbxt/rSIuuP8T2eUOJarWa0ZDrY3orSuayx7xBIJjIUmqll9nJxmJA/training_output.zip
Downloaded training_output.zip as 10 824 kB chunks in 0.3842 with 0 retries
Downloaded peft weights in 0.384
Unzipped peft weights in 0.017
Initialized peft model in 0.008
Overall initialize_peft took 9.953
Exllama: False
INFO 07-30 20:11:53 async_llm_engine.py:371] Received request 0: prompt: 'How do Sun and Earth sensors boost spacecraft navigation and mission success?', sampling params: SamplingParams(n=1, best_of=1, presence_penalty=0.0, frequency_penalty=1.0, temperature=0.75, top_p=0.9, top_k=50, use_beam_search=False, length_penalty=1.0, early_stopping=False, stop=['</s>'], ignore_eos=False, max_tokens=128, logprobs=None, skip_special_tokens=True), prompt token ids: None.
INFO 07-30 20:11:53 llm_engine.py:631] Avg prompt throughput: 0.0 tokens/s, Avg generation throughput: 0.0 tokens/s, Running: 1 reqs, Swapped: 0 reqs, Pending: 0 reqs, GPU KV cache usage: 0.0%, CPU KV cache usage: 0.0%
INFO 07-30 20:11:56 async_llm_engine.py:111] Finished request 0.
hostname: model-hp-73001d654114dad81ec65da3b834e2f6-888dc6d68-m2gtq