JSON.stringify(inputs).length needs to be less than 9.5 MB, to be precise. I.e. the input to AI.run is stringified at one point internally and must not exceed ~10 million bytes or you'll get "request to large". cc @Kristian)8b, but there is no 8b Llama 3.2 model@cf/meta/llama-3.2-3b-instructsharp, I believe they have a WASM backend now that might work in WorkersAiError: AiError: Unknown internal error@cf/black-forest-labs/flux-1-schnell to work? Even the short example at https://developers.cloudflare.com/workers-ai/models/flux-1-schnell/ is broken for me.JSON.stringify(inputs).length8b8b@cf/meta/llama-3.2-3b-instructsharp{
"messages": [
{
"role": "system",
"content": "You are a bot that parses user input into recipe ingredients..."
},
{
"role": "user",
"content": [
{
"type": "text",
"text": "[\"2 tbsp minced cilantro, leaves and stems\"]"
}
]
}
],
"return_citations": true,
"return_images": true
}{
"errors": [
{
"message": "AiError: Bad input: must have required property 'prompt', 'messages1content' must be string, must match exactly one schema in oneOf",
"code": 5006
}
],
"success": false,
"result": {},
"messages": []
}AiError: AiError: Unknown internal errorcurl https://api.cloudflare.com/client/v4/accounts/$CLOUDFLARE_ACCOUNT_ID/ai/run/@cf/black-forest-labs/flux-1-schnell -X POST -H "Authorization: Bearer $CLOUDFLARE_API_TOKEN" -d '{ "prompt": "cyberpunk cat" }'
{"errors":[{"message":"AiError: AiError: Input prompt contains NSFW content.","code":3030}],"success":false,"result":{},"messages":[]}@cf/black-forest-labs/flux-1-schnell