Spaces:
Runtime error
Runtime error
Update main.py
Browse files156 unmodified lines157158159160160161162163164165165166167167168169170156 unmodified lines result_data = asyncio.run(GeneraTestoAsync("https://matteoscript-fastapi.hf.space/Genera", input_data)) return {"response": result_data}
async def make_request(session, token, data, url, max_retries=3, index):async def make_request(session, token, data, url, max_retries=3, i): headers = { 'Content-Type': 'application/json', 'Authorization': 'Bearer ' + token } if index % 3 == 1: if i % 3 == 1: data.max_new_tokens = data.max_new_tokens elif index % 3 == 2: elif i % 3 == 2: data.max_new_tokens = max(200, data.max_new_tokens - 200) else: data.max_new_tokens = data.max_new_tokens + 200 main.py+3-3