Minds · Select Creatives
Minds · Select Creatives and Its Tie Rule
- preference_result
- tested_creatives
- selected_creatives
- selected_labels_json
Where the ranking becomes a decision
The results node gives you a distribution. This one turns it into a shortlist: "for this Audience, these are the top top_k creatives."
That distinction matters more than it sounds when you have more than one Audience - and having more than one is the whole reason Minds exists. Results never pool across Audiences. A 250-Mind panel of designers and a 250-Mind panel of suburban parents get separate distributions, and there is no combined winner to hand downstream. This node is where you say which Audience's opinion you're shipping against.
The name of the game is audience_id. It's a single UUID string. With one Audience in the test you can leave it blank and it'll resolve to the only result it has. With two or more, blank means "ambiguous" and you get "Choose one result Audience ID for downstream creative selection."
Deprecation caveat: 0.2.2 marks this DEPRECATED = True, since the single Audience Preferences node does its own selection internally via selection_audience_id and top_k. This node remains for the classic chain, where selection is a real step in the graph:
Candidates → Prepare → Run → Select Creatives → Selected Images / Selected Video
How it works
Three checks before any sorting happens, and they're all fingerprint checks:
First, it hashes the candidates you connected and compares it to the fingerprint stored in the result. Different batch, different hash, hard stop - "These creatives are different from the ranked creative batch." That's why tested_creatives exists as an output on the Run node: you're supposed to wire that in, not re-run your candidate nodes. If you ever need to understand why a selection refuses, this is usually it. Two candidate nodes producing visually identical batches still don't match, because the hashes are over bytes.
Second, it picks exactly one Audience's block out of the result. Third, it validates top_k against the actual candidate count.
Then the sort, and this is the bit worth reading twice. Shares are distribution[label] / total - an exact normalisation of the API's categorical distribution, no smoothing, no confidence interval. Ranks are computed by counting how many items beat each one, so equal shares share a rank. And the selection is:
cutoff = ranking[top_k - 1]["share"]
selected = [item for item in ranking if item["share"] >= cutoff]
>=, not == on position. Every candidate tied with the one at the cutoff comes along. Ask for top_k=1 and get a two-way tie at the top, you get both. The code comment says why: a tied winner must never be chosen by input order. Given how often generated alternatives tie on a small Audience, expect this to actually happen rather than treating it as a corner case.
Inputs and outputs
preference_result - from Run Reviewed Test. Complete research only; a failed, cancelled or media-incomplete run never yields a selection.
tested_creatives - from the same Run node's second output. Not optional, and not interchangeable with your candidate node's output.
audience_id - one UUID. Blank only when there's exactly one result.
top_k - 1 to 20, and it must be within the candidate count.
selected_creatives - a MINDS_CREATIVES of just the winners, feeding Selected Images or Selected Video.
selected_labels_json - a JSON array of the winning labels, e.g. ["Revision B"]. Cheap to route into a text display, and genuinely useful: it's the human-readable record of what the run chose.
Install
Manager → search comfyui-minds (publisher minds), or:
cd ComfyUI/custom_nodes
git clone https://github.com/minds-ai-co/ComfyUI-Minds
cd ComfyUI-Minds && pip install -r requirements.txt
Restart with MINDS_API_KEY in the server environment. requests and Pillow; this node itself makes no network call - it's pure local arithmetic over the result you already paid for. Which is a nice property after the research stage: re-selecting with a different top_k or a different Audience costs nothing, and you don't need to re-run anything.
Common issues
"These creatives are different from the ranked creative batch." You wired a candidate node instead of tested_creatives, or you changed something upstream. Use the Run node's output.
"Choose one result Audience ID for downstream creative selection." Multiple Audiences, blank field. Fill it in.
"Choose a shortlist size within the candidate count." top_k of 3 against a 2-candidate test. The ceiling is the candidate count, not 20.
"Hosted files and concepts are retained in selected_creatives, but cannot produce a native IMAGE/VIDEO output." If any winner was a URL or a text concept, selection works and the media output doesn't. Check your candidate mix.
More items in the shortlist than top_k. Ties at the cutoff. Working as designed.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| preference_result | MINDS_CREATIVE_RESULT | — | |
| tested_creatives | MINDS_CREATIVES | — | |
| audience_id | STRING | — | |
| top_k | INT | 11–20 | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| selected_creatives | MINDS_CREATIVES | — |
| selected_labels_json | STRING | — |