You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With the below code, If the body is very big, I get a "value too large" error.
After having put logging everywhere, I found that the error is thrown at the curl.post line, when the body is past to plenary.curl.
I think that there is a size limit for the body, but I don't know how where is that limit set.
What is exactly the limit?
localcurl=require('plenary.curl')
localquery= {}
functionquery.askCallback(res, opts)
-- Process res and optsendfunctionquery.ask(instruction, prompt, opts, api_key)
localurl='https://generativelanguage.googleapis.com'localpath='/v1beta/models/gemini-1.5-pro-latest:generateContent'curl.post(url..path,
{
headers= {
['Content-type'] ='application/json',
['x-goog-api-key'] =api_key
},
body=json.encode(
{
-- Big, very big body
}),
callback=function(res)
vim.schedule(function() query.askCallback(res, opts) end)
end
})
endreturnquery
The text was updated successfully, but these errors were encountered:
Hello,
With the below code, If the body is very big, I get a "value too large" error.
After having put logging everywhere, I found that the error is thrown at the
curl.post
line, when the body is past to plenary.curl.I think that there is a size limit for the body, but I don't know how where is that limit set.
What is exactly the limit?
The text was updated successfully, but these errors were encountered: