Skip to content

Added support for type and strength#256

Open
Sirsho1997 wants to merge 5 commits intomainfrom
feature-ExactlySupport
Open

Added support for type and strength#256
Sirsho1997 wants to merge 5 commits intomainfrom
feature-ExactlySupport

Conversation

@Sirsho1997
Copy link
Collaborator

@Sirsho1997 Sirsho1997 commented Mar 17, 2026

Added

  • IInputReference: type and strength (for sketch-style refs).
  • Image inference: inputs.referenceImages can be IInputReference items; each image is run through process_image before send

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds type and strength optional fields to the IInputReference dataclass, enabling sketch-style reference support for image inference. It also adds processing logic to convert local file paths in IInputReference.image to base64 before sending API requests.

Changes:

  • Added type: Optional[str] and strength: Optional[float] fields to IInputReference in types.py.
  • Added image processing loop in _imageInference to run process_image on IInputReference items within inputs.referenceImages.
  • Minor whitespace cleanup in IInputs class.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
runware/types.py Added type and strength fields to IInputReference; whitespace cleanup in IInputs
runware/base.py Imported IInputReference; added loop to process reference images within inputs.referenceImages for image inference

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds type and strength fields to the IInputReference dataclass, allowing sketch-style reference images in image inference. It also adds processing logic in _imageInference to handle IInputReference items in inputs.referenceImages by running each item's image through process_image.

Changes:

  • Added optional type (str) and strength (float) fields to IInputReference in types.py.
  • Added logic in base.py _imageInference to iterate inputs.referenceImages, processing IInputReference.image individually while handling plain strings/Files via the existing process_image path.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
runware/types.py Added type and strength optional fields to IInputReference; minor whitespace cleanup in IInputs.
runware/base.py Imported IInputReference; added per-item image processing for inputs.referenceImages in _imageInference.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

@Sirsho1997 Sirsho1997 requested review from Copilot and teith March 17, 2026 16:18
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants