Repository navigation
Conversation
Owner
|
@atrebek07 Hey! I tested everything locally and made some images. The API standard matches and on Discord you mentioned it supports other models supported by openvino. Excellent work! Lmk when its ready to merge |
Text-to-image generation via OpenVINO GenAI: - OVGenAI_Diffusion engine + OVGenAI_DiffusionGenConfig schema contract - OpenAI-compatible /v1/images/generations route (b64_json) - model type, registry, worker, and CLI add wiring - track output/ dir via placeholder; ignore generated images Refs SearchSavior#197
Contributor
Author
|
@SearchSavior It’s ready now. Just force-pushed two small edits: changed the text displayed at server start, and changed the naming of generated images. Post-edits testing didn’t show any issues. And yeah, as I said on Discord, the v1/images/generations endpoint should work with all of the models ovgenai has a pipeline for. I tested with FLUX.2-klein and Qwen-Image-2.1 this weekend. |
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes issue #197.
Adds text-to-image generation to the OpenArc server via OpenVINO GenAI
What's new
src/engine/ov_genai/diffusion.py—OVGenAI_Diffusiontext-to-image pipeline.contract_ovgenai_diffusion.py—OVGenAI_DiffusionGenConfig(prompt, negative_prompt, guidance_scale, height/width, num_inference_steps, num_images_per_prompt, seed, strength, max_sequence_length).POST /v1/images/generations(OpenAI-compatible). Returnsb64_jsonbase64 PNGs; also saves each PNG tooutput/and reports its path infile.diffusionadded toModelType,MODEL_CLASS_REGISTRY, the worker registry, andopenarc add.openarc add --model-type diffusionexposes the config fields as flags (--guidance-scale,--num-inference-steps,--seed, ...); the server startup banner lists the new endpoint.configure.md(load_config + Diffusion example + seed behavior),models.md(SD1.5/SDXL links),index.md(Image Diffusion).output/tracked via a placeholder; generated images are gitignored.Behavior / caveats
seed: if unset, the server draws a random seed per request (non-deterministic). Set it for reproducible images.strength: image-to-image knob; rejected by the text-to-image route (useguidance_scaleto steer).response_format:b64_jsononlyRequestLoggingMiddlewareis aBaseHTTPMiddleware, which swallows thehttp.disconnectmessage. Because of this, mid-denoise cancellation does not currently fire. A bare-ASGI middleware fixes it; this could be added as a separate PR.Development environment