moinnadeem
/
mlc_llama_70b
- Public
- 144 runs
Run moinnadeem/mlc_llama_70b with an API
Use one of our client libraries to get started quickly. Clicking on a library will take you to the Playground tab where you can tweak different inputs, see the results, and copy the corresponding code to use in your own project.
Input schema
The fields you can use to run this model with an API. If you don't give a value for a field its default value will be used.
Field | Type | Default value | Description |
---|---|---|---|
prompt |
string
|
Can you write a poem about open source machine learning? Let's make it in the style of E. E. Cummings.
|
Prompt to send to Llama v2.
|
system_prompt |
string
|
You are a helpful, respectful and honest assistant. Always answer as helpfully as possible, while being safe. Your answers should not include any harmful, unethical, racist, sexist, toxic, dangerous, or illegal content. Please ensure that your responses are socially unbiased and positive in nature.
If a question does not make any sense, or is not factually coherent, explain why instead of answering something not correct. If you don't know the answer to a question, please don't share false information.
|
System prompt to send to Llama v2. This is prepended to the prompt and helps guide system behavior.
|
max_new_tokens |
integer
|
128
Min: 1 |
Maximum number of tokens to generate. A word is generally 2-3 tokens
|
temperature |
number
|
0.75
Min: 0.01 Max: 5 |
Adjusts randomness of outputs, greater than 1 is random and 0 is deterministic, 0.75 is a good starting value.
|
top_p |
number
|
0.9
Max: 1 |
When decoding text, samples from the top p percentage of most likely tokens; lower to ignore less likely tokens
|
repetition_penalty |
number
|
1.15
Min: 0.01 Max: 5 |
Penalty for repeated words in generated text; 1 is no penalty, values greater than 1 discourage repetition, less than 1 encourage it.
|
stop_str |
string
|
A sequence to stop generation at. For example, '<end>' will stop generation at the first instance of '<end>'.
|
{
"type": "object",
"title": "Input",
"properties": {
"top_p": {
"type": "number",
"title": "Top P",
"default": 0.9,
"maximum": 1,
"minimum": 0,
"x-order": 4,
"description": "When decoding text, samples from the top p percentage of most likely tokens; lower to ignore less likely tokens"
},
"prompt": {
"type": "string",
"title": "Prompt",
"default": "Can you write a poem about open source machine learning? Let's make it in the style of E. E. Cummings.",
"x-order": 0,
"description": "Prompt to send to Llama v2."
},
"stop_str": {
"type": "string",
"title": "Stop Str",
"x-order": 6,
"description": "A sequence to stop generation at. For example, '<end>' will stop generation at the first instance of '<end>'."
},
"temperature": {
"type": "number",
"title": "Temperature",
"default": 0.75,
"maximum": 5,
"minimum": 0.01,
"x-order": 3,
"description": "Adjusts randomness of outputs, greater than 1 is random and 0 is deterministic, 0.75 is a good starting value."
},
"system_prompt": {
"type": "string",
"title": "System Prompt",
"default": "You are a helpful, respectful and honest assistant. Always answer as helpfully as possible, while being safe. Your answers should not include any harmful, unethical, racist, sexist, toxic, dangerous, or illegal content. Please ensure that your responses are socially unbiased and positive in nature.\n\nIf a question does not make any sense, or is not factually coherent, explain why instead of answering something not correct. If you don't know the answer to a question, please don't share false information.\n",
"x-order": 1,
"description": "System prompt to send to Llama v2. This is prepended to the prompt and helps guide system behavior."
},
"max_new_tokens": {
"type": "integer",
"title": "Max New Tokens",
"default": 128,
"minimum": 1,
"x-order": 2,
"description": "Maximum number of tokens to generate. A word is generally 2-3 tokens"
},
"repetition_penalty": {
"type": "number",
"title": "Repetition Penalty",
"default": 1.15,
"maximum": 5,
"minimum": 0.01,
"x-order": 5,
"description": "Penalty for repeated words in generated text; 1 is no penalty, values greater than 1 discourage repetition, less than 1 encourage it."
}
}
}
Output schema
The shape of the response you’ll get when you run this model with an API.
Schema
{
"type": "array",
"items": {
"type": "string"
},
"title": "Output",
"x-cog-array-type": "iterator",
"x-cog-array-display": "concatenate"
}