Skip to content

feat(website): Paparazzi me app (mocked) - #20863

Open
mariana953 wants to merge 11 commits into
mariana/editor-kitfrom
mariana/app-paparazzi-me
Open

mariana953 wants to merge 11 commits into
mariana/editor-kitfrom
mariana/app-paparazzi-me

Conversation

@mariana953

@mariana953 mariana953 commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Adds Paparazzi me to the Workshop at /hub/apps/paparazzi-me/: type a star, pick one of their looked-up paparazzi photos (or upload your own scene), add your face, and get that photo with you inserted next to the star. Works like the reference API flow (face + celebrity look-up + optional scene override + resolution + seed); same full-screen editor kit as Relight and Move anything. Backend is mocked. Built on the shared editor kit (#20630), with no dependency on Relight or Move anything. Replaces #19826.

Changes

  • What:
    • Opens on a worked example: the site's own shot-close.jpg face, the made-up star "Nova Reyes" already looked up, her red-carpet photo picked. No real person is suggested; the look-up only suggests made-up names and accepts any name.
    • Panel, top to bottom: Your face (image row with Change, drop or paste an image), Star (name combobox with suggestions; Enter, a suggestion or the arrow button runs the look-up with a short searching state), Scene (one row with the picked photo and its place; opens a picker grid beside the panel like Cinematic Studio's Light picker, a bottom sheet on phones: the star's photos plus a last "Upload your own scene" tile), Resolution 1K/2K/4K (direct row), Seed (direct row). No Advanced section. Run: "Insert me · 10 credits".
    • Stage shows the picked photo full-bleed; after the run the result. Pill: Compare (shared EditorCompareToggle, original photo vs result), Edit shot, Try again, then undo/redo at the right end. Download in the header, zoom bottom right (kit).
    • Layout E (?ux=e): chips for Your face, Star, Scene, Seed open trays (Scene tray holds the same grid), Resolution as a pill.
    • Shared kit adopted (from feat(website): shared full-screen editor pieces for the Workshop apps #20630): the Scene row is EditorPickerRow, the picker is EditorPicker, the grid is EditorTiles (2 columns of 3:2 tiles with a check on the picked one, placeholders while searching, the trailing upload tile), the face row uses EditorDropZone and EditorUploadSlot, paste uses useImagePaste, and the run uses EditorRun's progress and missing. Removed the local PaparazziScenePicker, PaparazziSceneTile and PaparazziUpload. The run progress (look-up, queued, percent) is one function, runProgress in sections.ts, used by the photo's status and the run button.
    • Removed: preset scene list (red carpet/street/café/airport), "describe your own scene" text, Shuffle the crowd, all drawn/cartoon art (PaparazziSceneArt, draw-scene.ts, draw-figures.ts, random.ts, canvas previews and thumbnails), floating face card, result-*.jpg.
    • Added (small): drag-and-drop on the face row (highlighted while held over it) and the scene upload tile, paste an image to replace the face, "Type a star's name or upload a scene." on the run button (in place of its label and credits) when it can't run, run progress (look-up, Queued, "Inserting you · N%", and Queued / N% on the run button), Download named paparazzi-me-<seed>.jpg.
    • Photos: nine candidate scenes of the example star in public/images/apps/paparazzi-me/scenes/ (JPEG 1264 wide q82, plus 400-wide thumbs). In the mock, any star name returns these same nine candidates.
    • Gated by workshop-paparazzi-me-app-enabled. Copy in en + zh-CN in lib/workshop/paparazzi-me/copy.ts.

Backend contract (lib/workshop/paparazzi-me/contract.ts), 1:1 with the API's fields:

// GET /api/paparazzi/search?q=<celebrity>  ->  { provider, candidates: [{ token, title }] }
// picture of a candidate: /api/paparazzi/scene?token=<token>
interface PaparazziSearch { provider: string; candidates: SceneCandidate[] }

// POST /api/run/paparazzi-me (multipart; images sent as files under these keys)
interface PaparazziRequest {
  user: string            // "Your face", required
  celebrity: string       // trimmed name
  sceneToken?: string     // the picked candidate; sent only without `scene`
  scene?: string          // "Scene override" upload; beats the look-up
  resolution: '1K' | '2K' | '4K'   // 3:2, long edge 1024/2048/4096
  seed: number
}
interface PaparazziResult { url: string; seed: number }

Run rule (same as the API's client): needs a face, and either a celebrity of 2+ letters or an uploaded scene. The first candidate is used unless another is picked. If the star wasn't looked up yet, Run looks it up first.

Mocks: searchScenes (mock-search.ts) answers after 0.7 s with the nine sample candidates (provider "Comfy sample library"); the mock candidate carries a local place (photo, thumb, label) where the real one has title and the scene URL. runPaparazzi (mock-run.ts) waits 2.4 s; the example (example face + Nova Reyes + red-carpet token, no upload) answers the prepared example-result.jpg; any other combination is a canvas stand-in (the scene photo with a soft head-and-shoulders cut of the face beside the star), falling back to the scene photo where the canvas can't draw.

Review Focus

  • The mock composite is deliberately rough; the real model does the insertion.
  • Upload face crop assumes a centred portrait.
  • The missing-input message moved from a line above the run button into the button itself (the kit's missing).
  • Tests: unit (setup, contract table, mock search, mock run table incl. upload/override/fallback/cancel, composable: look-up, cached look-up on undo, run gating, own scene), component (PaparazziStudio.test.ts: picker grid, run, compare, typed look-up + missing message, face/scene upload, paste, resolution/seed rows, layout E tray, phone sheet), e2e e2e/workshop-paparazzi-me.spec.ts (desktop picker beside the panel and run, phone sheet run with no overflow) plus e2e/workshop-apps.spec.ts.
  • Shared with the other app PRs. The app registers itself in the kit's EDITOR_APPS list on the studio page (one entry), and its copy goes through lib/workshop/app-copy.ts. Shared helpers (app-copy.ts, and where used load-image.ts, nudge.ts, useSnapshotHistory.ts) are identical in every app PR, so they merge cleanly whichever lands first.

Screenshots (if applicable)

Desktop 1440 (example, picker, drop highlight on the face row, running, result, compare, layout E) and phone 390 (example, sheet, picker, result) reviewed locally.


Generated by Claude Code

@mariana953
mariana953 requested review from a team and dante01yoon as code owners October 12, 2026 19:44
@coderabbitai

coderabbitai Bot commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration
  • Configuration used: Repository: Comfy-Org/ComfyUI_frontend/.coderabbit.yaml
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: e508fa03-5c98-48fc-a634-aa5b3fc87a3c

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Oct 12, 2026 •

Copy link
Copy Markdown
Contributor

📦 Bundle Size

⏳ Size data collection in progress…

🧩 Custom Nodes Ecosystem Matrix: 🟡 Withheld — could not measure

Executes the frontend JS of every registry pack that ships any, against this change, in both renderers. The eight ecosystem-matrix shard checks are a harness self-test; the pack verdict is matrix-verdict.

This candidate changes nothing the matrix measures, so every expensive stage was skipped.

Reproduce locally
# build one shard's fixture, then run it
python3 scripts/registry-census/build_matrix.py --shard 1/4
MATRIX_RENDERER=vue MATRIX_VUE=1 \
  npx vitest run --config vitest.matrix.config.mts

Full docs: scripts/registry-census/README.md

🌾 Fallow: ✅ Passed

Fallow audits the diff for duplication, complexity and dead code. It gates on new findings only, so when the audit completes, a red is something this PR introduced or moved — never inherited backlog. A red can also mean the audit itself did not finish; the details below say which happened.

No new findings in the changed files.

Reproduce locally
# the base the gate compared against
npx fallow audit --root . --quiet --format json \
  --changed-since fa6d451f5d507b9e31956425e939e0ee8d12cd1d

Full docs: ADR-DEVEX-LINT-0015

🌐 Website E2E

Tip

All tests passed.

Status ✅ Passed
Report View Report

🔗 Website Preview

Website Preview: https://comfy-website-preview-pr-20863.vercel.app

Models is built and gated by PostHog (workshop-enabled), using staging Cloud.

This commit: https://website-frontend-6hplqjhqy-comfyui.vercel.app

Last updated: 2026-10-14T00:40:30Z for 3c276fd

@codecov

codecov Bot commented Oct 12, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 78.29615% with 107 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
...ps/website/src/lib/workshop/paparazzi-me/render.ts 1.88% 52 Missing ⚠️
apps/website/src/composables/usePaparazziMe.ts 86.52% 7 Missing and 12 partials ⚠️
...nents/workshop/paparazzi-me/PaparazziSceneGrid.vue 68.00% 1 Missing and 7 partials ⚠️
...components/workshop/paparazzi-me/PaparazziStar.vue 77.77% 5 Missing and 3 partials ⚠️
...components/workshop/paparazzi-me/PaparazziMain.vue 75.00% 0 Missing and 3 partials ⚠️
...components/workshop/paparazzi-me/PaparazziSeed.vue 0.00% 3 Missing ⚠️
...ponents/workshop/paparazzi-me/PaparazziFaceRow.vue 0.00% 2 Missing ⚠️
...mponents/workshop/paparazzi-me/PaparazziStudio.vue 92.30% 2 Missing ⚠️
apps/website/src/composables/useSnapshotHistory.ts 92.59% 0 Missing and 2 partials ⚠️
...omponents/workshop/paparazzi-me/PaparazziPanel.vue 92.30% 0 Missing and 1 partial ⚠️
... and 7 more

❌ Your patch check has failed because the patch coverage (78.29%) is below the target coverage (80.00%). You can increase the patch coverage or adjust the target coverage.

@@                  Coverage Diff                  @@
##             mariana/editor-kit   #20863   +/-   ##
=====================================================
  Coverage                      ?   86.16%           
=====================================================
  Files                         ?     3644           
  Lines                         ?   172930           
  Branches                      ?    47507           
=====================================================
  Hits                          ?   149002           
  Misses                        ?    21999           
  Partials                      ?     1929           
Flag Coverage Δ
website-unit 80.58% <78.29%> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...ebsite/src/components/workshop/ModelsCatalogue.vue 100.00% <100.00%> (ø)
.../workshop/cinematic-studio/CinematicStudioPage.vue 91.46% <100.00%> (ø)
...omponents/workshop/paparazzi-me/PaparazziChips.vue 100.00% <100.00%> (ø)
...omponents/workshop/paparazzi-me/PaparazziDocks.vue 100.00% <100.00%> (ø)
...ponents/workshop/paparazzi-me/PaparazziHistory.vue 100.00% <100.00%> (ø)
...ents/workshop/paparazzi-me/PaparazziResultDock.vue 100.00% <100.00%> (ø)
.../components/workshop/paparazzi-me/PaparazziRun.vue 100.00% <100.00%> (ø)
...onents/workshop/paparazzi-me/PaparazziSceneRow.vue 100.00% <100.00%> (ø)
...omponents/workshop/paparazzi-me/PaparazziStage.vue 100.00% <100.00%> (ø)
...ents/workshop/paparazzi-me/PaparazziStarOption.vue 100.00% <100.00%> (ø)
... and 28 more
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions github-actions Bot added the risk:high PR risk grade (advisory shadow check; grader-owned) label Oct 12, 2026

@dante01yoon dante01yoon left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Thanks. The flow is clear and the contract module mirrors the API fields nicely. Requesting changes for the copy approach (shared with the sibling app PRs) and internal comments. I also have a product question about real people.

Size. This PR is about 3,000 lines (excluding binaries). That is far past the ~300-line guideline and hard to review well in one pass. Could you split it, e.g. (1) wiring: catalogue, routes, flag, Hub card; (2) pure lib/ logic with its tests; (3) components and e2e?

Stacking. Base is mariana/editor-kit (#20630), which is still open with changes requested. Every app PR edits the same shared lists (routes.ts, apps.ts, catalogue-apps.ts, CinematicStudioPage.vue, schema enums, locales, vercel.json), so they will conflict with each other as they land. The identical helpers (app-copy.ts, load-image.ts, useSnapshotHistory.ts, nudge.ts) would be better landed once in #20630 than duplicated in every app branch.

Checks: CI is green; I didn't run tests locally.

named: CopyValues = {}
): string {
const [one, many = one] = (entry[locale] ?? entry.en).split(' | ')
return (named.n === 1 ? one : many).replace(

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

issue: appCopy fills placeholders with .replace and parses | plurals by hand, and the app's strings live in a TS copy.ts instead of src/locales/<locale>/main.json. apps/website/AGENTS.md says copy goes in main.json and is read with translationsFor(locale).t, and to "never fill a placeholder with .replace". Doing it this way also skips the catalog test that compiles each message and checks zh-CN coverage. It also treats a literal {word} the visitor types (a star name, a light name) as a placeholder whenever named has that key.

Could the app's strings move under a namespaced key in main.json (moveAnything.*, relight.*, …) and be read through t(key, named, { locale })? If keeping them out of the site-wide bundle is the real goal (as for catalogue-apps.ts), please get that exception agreed on #20630 first, where all seven apps can share it, without hand-rolled interpolation.

leaveResult({ kind: 'editing' })
}

/** Shows the look-up already made for the setup's star, if any. */

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

issue: this PR adds comments to internal, non-exported code, like this one and the others on inner functions of this composable. The repo rule only allows a short JSDoc on exported API. Please drop the internal ones and let the names carry the meaning.

* The multipart fields of `POST /api/run/paparazzi-me`, one for one. The
* images are URLs here; the real call sends their files under the same keys.
*/
export interface PaparazziRequest {

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

question: the look-up accepts any name and the real /api/paparazzi/search returns paparazzi photos of that person, which the run then composites the visitor into. Has this had legal / trust & safety sign-off (likeness rights, real-person deepfakes) before it goes behind a public route, even staff-flagged? Separately, PaparazziSearch / PaparazziRequest is a hand-written request/response contract for a backend that doesn't exist yet. Is there a tracking issue for the endpoint? Once it ships in the OpenAPI spec, these types should be imported from @comfyorg/ingest-types rather than kept by hand. Could you link the issue here (or in the PR body) so the swap isn't forgotten?

if (usingOwnScene.value && ownScene.value)
return { upload: ownScene.value.url }
await findScenes()
return candidate.value && { token: candidate.value.token }

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

suggestion: if the look-up fails (search.kind === 'failed'), candidate is undefined, so sceneForRun returns undefined. The run then goes out with neither sceneToken nor scene. The mock hides this by falling back to the first sample scene, but the real backend won't. Could snap go to failed (or show the look-up error) when there's no scene, instead of sending the request? (PLAUSIBLE: the mock search never fails today.)

}

async function readImage(file: File): Promise<PaparazziImage | undefined> {
picks += 1

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

suggestion: readImage uses one picks counter for both face and scene uploads. Dropping a face and then quickly a scene (or the reverse) makes the first decode see pick !== picks and silently discard that upload. Separate counters (or per-slot pending URLs) would keep the two slots independent. (PLAUSIBLE: needs two uploads inside one decode.)

This branch was previously deployed

1 inactive deployment
website-approval — 3c276fd0 Deployed Oct 14, 2026 by mariana953 via fast-lane #1892
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk:high PR risk grade (advisory shadow check; grader-owned)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants