Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(ui): add graph-to-workflow debug helper #6181

Merged
merged 1 commit into from
Apr 9, 2024

Conversation

psychedelicious
Copy link
Collaborator

Summary

This is intended for debug usage, so it's hidden away in the workflow library ... menu. Hold shift to see the button for it.

  • Paste a graph (from a network request, for example) and then click the convert button to convert it to a workflow.
  • Disable auto layout to stack the nodes with an offset (try it out). If you change this, you must re-convert to get the changes.
  • Edit the workflow JSON if you need to tweak something before loading it.

Get the graph from the browser JS console, it's in the Batch enqueued log:
image

You could also get the graph from the network request to enqueue.

Here's a demo using a SDXL canvas inpainting graph (retrieved from JS console after generating on canvas).

Note that for this specific graph, I needed to go and tick Save to Gallery on the main "Canvas Paste Back" output node to save the image to the gallery. That's needed because canvas graph outputs are intermediates by default - the app handles adding them to gallery in a different way.

Screen.Recording.2024-04-09.at.10.22.48.am.mov

Related Issues / Discussions

Should be helpful for #6158 .

QA Instructions

Try it out. You'll need to pnpm i.

Merge Plan

n/a

Checklist

  • The PR has a short but descriptive title, suitable for a changelog
  • Tests added / updated (if applicable) n/a
  • Documentation added / updated (if applicable)

This is intended for debug usage, so it's hidden away in the workflow library `...` menu. Hold shift to see the button for it.

- Paste a graph (from a network request, for example) and then click the convert button to convert it to a workflow.
- Disable auto layout to stack the nodes with an offset (try it out). If you change this, you must re-convert to get the changes.
- Edit the workflow JSON if you need to tweak something before loading it.
@github-actions github-actions bot added frontend-deps PRs that change frontend dependencies frontend PRs that change frontend files labels Apr 9, 2024
@hipsterusername hipsterusername merged commit b58494c into main Apr 9, 2024
14 checks passed
@hipsterusername hipsterusername deleted the psyche/feat/ui/graph-to-workflow branch April 9, 2024 00:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
frontend PRs that change frontend files frontend-deps PRs that change frontend dependencies
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants