{"named_endpoints":{"/generate":{"parameters":[{"label":"1st","parameter_name":"image_path","parameter_has_default":true,"parameter_default":"","type":{"type":"string"},"python_type":{"type":"str","description":""},"component":"Api","example_input":""},{"label":"2nd","parameter_name":"temperature","parameter_has_default":true,"parameter_default":0.0,"type":{"type":"number"},"python_type":{"type":"float","description":""},"component":"Api","example_input":0.0},{"label":"3rd","parameter_name":"max_tokens","parameter_has_default":true,"parameter_default":0,"type":{"type":"integer"},"python_type":{"type":"int","description":""},"component":"Api","example_input":0},{"label":"4th","parameter_name":"partial_svg","parameter_has_default":true,"parameter_default":"","type":{"type":"string"},"python_type":{"type":"str","description":""},"component":"Api","example_input":""},{"label":"5th","parameter_name":"data","parameter_has_default":true,"parameter_default":null,"type":{"anyOf":[{"type":"object","additionalProperties":{}},{"type":"array","items":{}},{"type":"null"}]},"python_type":{"type":"dict(str, Any) | list[Any] | None","description":""},"component":"Api","example_input":"..."}],"returns":[{"label":"1st","type":{},"python_type":{"type":"Any","description":""},"component":"Api"}],"api_visibility":"public","description":"Streams the generation over the gradio call API. Wire-format shim, as in inkling-2-mini: gradio's /call/v2 handler rejects any body key that is not an endpoint parameter, and a caller in the request chain (queue machinery / ZeroGPU middleware) POSTs the arguments wrapped in a top-level \"data\" key. Declaring `data` here lets both wire formats through; unwrap before use. Every yield is one JSON payload: {\"add\": delta, \"tokens\": n} while streaming, a final {\"done\": True, ...} when the generation ends, or {\"error\": ...} on failure. Registration follows the Server-mode docs: the generator is registered directly via @app.api, with stream_every=0 — every yield is emitted the moment it is produced (the inkling studio's registration, which renders in true real time; gradio's 0.5 default coalesces the SSE stream into 2 Hz bursts instead) — and drives the @spaces.GPU generator inline, inside the request context — so ZeroGPU attributes the task to the caller's account, and gradio's own SSE keepalives hold the connection open.","code_snippets":{"python":"from gradio_client import Client\n\nclient = Client(\"akhaliq/Unlimited-SVG-ZeroGPU\")\nresult = client.predict(\n\timage_path=\"\",\n\ttemperature=0.0,\n\tmax_tokens=0,\n\tpartial_svg=\"\",\n\tdata=None,\n\tapi_name=\"/generate\",\n)\nprint(result)","javascript":"import { Client } from \"@gradio/client\";\n\nconst client = await Client.connect(\"akhaliq/Unlimited-SVG-ZeroGPU\");\nconst result = await client.predict(\"/generate\", {\n\t\timage_path: \"\",\n\t\ttemperature: 0.0,\n\t\tmax_tokens: 0,\n\t\tpartial_svg: \"\",\n\t\tdata: null,\n});\n\nconsole.log(result.data);","bash":"curl -X POST http://localhost:7860/gradio_api/call/v2/generate -s -H \"Content-Type: application/json\" \\\n  -d '{\"image_path\": \"\", \"temperature\": 0.0, \"max_tokens\": 0, \"partial_svg\": \"\", \"data\": null}' \\\n  | awk -F'\"' '{ print $4}' \\\n  | read EVENT_ID; curl -N http://localhost:7860/gradio_api/call/generate/$EVENT_ID","cli":"{command} predict akhaliq/Unlimited-SVG-ZeroGPU /generate '{\n  \"image_path\": \"\",\n  \"temperature\": 0.0,\n  \"max_tokens\": 0,\n  \"partial_svg\": \"\",\n  \"data\": \"...\"\n}'\n"}}},"unnamed_endpoints":{}}