feat(templates): offer API-node starter templates in the install picker - #1341
Conversation
Zero-model picks still create a download-task state entry for their input assets, so the existing guards all passed and the launch stepper showed a model-download phase for a template that downloads no models.
Hydrate `apiNode` from the manifest only — the index's `openSource` flag means closed weights, and 13 entries carry it alongside a multi-GB size. Also skip `api`/`3d model` when picking a card's task tag, and keep an API-node slot on its snapshot rather than substituting a local download into it.
Swap each modality's heaviest pick for its highest-usage API-node template, so the picker is no longer open-source only: - Seedream 5.0 Pro: Image Edit, Seedance 2.0: Reference to Video - Tripo H3.1: Image to Model, Seed Audio 1.0: Text to Audio `recommended` and `apiNode` are mutually exclusive by type — the auto-selected pick must never cost credits.
Badge the card with a crown and "Requires credits", and show the crown in place of a download size. The badge sits outside the aria-hidden media span so the cost reaches the card's accessible name. Reset an auto-selected API-node template to "none" when the picker step is skipped, so a credit-costing pick can't install without its only cost surface. Keep the picker on offer when the disk fits no local template, since the API-node cards need none.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
💤 Files with no reviewable changes (1)
📝 WalkthroughWalkthroughAPI-node starter templates are added to curated catalogs, propagated through standalone installation options, excluded from local-download substitution, and rendered with credit badges or crown indicators. Wizard sizing, telemetry, launch gating, localization, and tests are updated accordingly. ChangesAPI-node template flow
Sequence Diagram(s)sequenceDiagram
participant TemplatePickerStep
participant InstallWizardModal
participant standalone
participant handleLaunch
TemplatePickerStep->>InstallWizardModal: select API-node template
InstallWizardModal->>standalone: read apiNode and sizeBytes metadata
standalone-->>InstallWizardModal: return zero-download selection
InstallWizardModal->>handleLaunch: configure bundledTemplateSizeBytes = 0
handleLaunch-->>InstallWizardModal: skip template download phase
Suggested reviewers: 🚥 Pre-merge checks | ✅ 2✅ Passed checks (2 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
✨ Simplify code
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@src/renderer/src/assets/main.css`:
- Line 194: Update the --upgrade light-theme color token to provide sufficient
contrast for 12px badge text against its badge surface, using a darker
light-theme value or an opaque dark background while preserving the badge’s
intended upgrade styling.
In `@src/renderer/src/views/InstallWizardModal.vue`:
- Around line 243-246: Remove the assignments to bundledTemplate in the
templateIsApiNode branch so an explicitly selected API-node option from the
Advanced fallback remains unchanged; preserve the existing exclusion of API
nodes from automatic selection.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: ASSERTIVE
Plan: Pro Plus
Run ID: 3ab2c759-7726-481c-b924-9d3787a7df80
📒 Files selected for processing (14)
locales/en.jsonlocales/zh.jsonsrc/main/lib/ipc/sessionActions/launch.tssrc/main/sources/standalone/curatedTemplates.test.tssrc/main/sources/standalone/curatedTemplates.tssrc/main/sources/standalone/index.test.tssrc/main/sources/standalone/index.tssrc/main/sources/standalone/templateCatalog.test.tssrc/main/sources/standalone/templateCatalog.tssrc/renderer/src/assets/main.csssrc/renderer/src/components/TemplatePickerStep.test.tssrc/renderer/src/components/TemplatePickerStep.vuesrc/renderer/src/lib/installHelpers.tssrc/renderer/src/views/InstallWizardModal.vue
…back The picker step is not the only place a starter template can be chosen: when it is gated off, the field renders as cards in Advanced. Resetting the selection there discarded a deliberate choice, so surface the credit cost on those rows instead.
Summary
The install picker only offered local-model templates, so a new user's first run was always a multi-GB download. Each modality now also offers one API-node template, badged with its credit cost before Install.
Changes
What
recommendedandapiNodeare mutually exclusive by type.openSourceflag (that means closed weights, and 13 entries carry it alongside a multi-GB size).["API", "Image Edit"]being subtitled "API", and a model-download phase showing for zero-model picks.is_api_nodeto both template telemetry events.Screen.Recording.2026-07-29.at.11.11.34.PM.mov