[GH-ISSUE #1999] [Issue]: Refresh character panel first-open performance investigation #978

Closed
opened 2026-10-21 05:24:41 +07:00 by bsakaguchi · 0 comments
Owner

Originally created by @Promansis on GitHub (Jun 3, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/1999

Originally assigned to: @Promansis on GitHub.

Summary

Opening the Characters right side panel still feels heavier than it should on first open because the panel imports a broad characters shell and loads a summary shape that still includes prompt-heavy fields the compact panel does not need.

Expected behavior

Opening the Characters right side panel should load only the panel-specific UI and the lightweight character data needed for compact rows, groups, filters, tags, favorites, avatar display, and chat assignment.

Actual behavior

The right panel currently lazy-loads the broad characters shell entrypoint, and the side panel summary query still requests large prompt and lorebook-related fields. Row rendering also computes token estimates from those fields, so first-open work remains higher than necessary even after recent avatar thumbnail and managed image delivery improvements.

Steps to reproduce

  1. Start the refactor branch app.
  2. Open the right-side Characters panel for the first time in a fresh session.
  3. Observe the first-open delay compared with lighter panels and inspect the current code path.

Impact area

  • App shell, navigation, startup, or providers
  • Catalog resources
  • Chat mode
  • Roleplay mode
  • Game mode
  • Shared mode UI
  • Runtime systems: generation, world-state, visuals, tracker, or haptics
  • Professor Mari or shell tools
  • React-free engine behavior, contracts, agents, or capability ports
  • Shared API wrapper or remote runtime routing
  • Tauri/Rust storage, assets, LLM, integrations, security, imports, or HTTP runtime
  • Docs, contributor workflow, or templates

Environment

  • Branch or commit: refactor at 805ab939a4f7297dfbab6f7358ab9a40f4e026d2
  • Run mode: not captured; issue filed from current code inspection on the refactor branch
  • OS + version: not captured
  • Node + pnpm versions: not captured
  • Rust version, if relevant: not captured
  • Remote Runtime URL configured? (yes / no / not relevant): not relevant for the core issue
  • Provider, model, or integration, if relevant: not relevant

Logs, screenshots, or video

No screenshots or timing capture attached yet. Current evidence is from the live refactor code path:

  • src/app/shell/RightPanel.tsx lazy-loads ../../features/catalog/characters/shell for the Characters panel.
  • src/features/catalog/characters/shell.ts still exports the panel together with editor, full library, maker, create/import, and update modal surfaces.
  • src/features/catalog/characters/hooks/use-characters.ts uses a general summary projection that still requests description, personality, scenario, first_mes, mes_example, system_prompt, post_history_instructions, alternate_greetings, character_book, and extensions.
  • src/features/catalog/characters/components/CharacterListRow.tsx computes token estimates from the parsed card data for compact rows.

Regression notes

This has shifted since the earlier panel-performance discussion around issue #1934. Recent managed avatar thumbnail and deferred image-resolution work improved the image-loading side, but the remaining first-open cost appears to come more from broad module loading and oversized side-panel summary data than from avatar delivery itself.

Additional context

Recent image-loading work means this should be treated as a refreshed performance issue, not a duplicate of the older avatar-focused framing:

  • managed avatar and thumbnail delivery improved in a5a8234e and follow-up work
  • the panel still appears to need a narrower lazy entrypoint and a dedicated lightweight side-panel summary shape
  • likely fixes are to split the side-panel entrypoint from the broader characters shell and stop loading prompt/book-heavy fields for the compact list path unless a detail/search path truly needs them

Template check

Please uncheck the box below before submitting so we know you read the template. It is intentionally pre-checked:

  • I DID NOT read this template and provide the requested details.
Originally created by @Promansis on GitHub (Jun 3, 2026). Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/1999 Originally assigned to: @Promansis on GitHub. ## Summary Opening the Characters right side panel still feels heavier than it should on first open because the panel imports a broad characters shell and loads a summary shape that still includes prompt-heavy fields the compact panel does not need. ## Expected behavior Opening the Characters right side panel should load only the panel-specific UI and the lightweight character data needed for compact rows, groups, filters, tags, favorites, avatar display, and chat assignment. ## Actual behavior The right panel currently lazy-loads the broad characters shell entrypoint, and the side panel summary query still requests large prompt and lorebook-related fields. Row rendering also computes token estimates from those fields, so first-open work remains higher than necessary even after recent avatar thumbnail and managed image delivery improvements. ## Steps to reproduce 1. Start the refactor branch app. 2. Open the right-side Characters panel for the first time in a fresh session. 3. Observe the first-open delay compared with lighter panels and inspect the current code path. ## Impact area - [x] App shell, navigation, startup, or providers - [x] Catalog resources - [ ] Chat mode - [ ] Roleplay mode - [ ] Game mode - [x] Shared mode UI - [ ] Runtime systems: generation, world-state, visuals, tracker, or haptics - [ ] Professor Mari or shell tools - [ ] React-free engine behavior, contracts, agents, or capability ports - [ ] Shared API wrapper or remote runtime routing - [x] Tauri/Rust storage, assets, LLM, integrations, security, imports, or HTTP runtime - [ ] Docs, contributor workflow, or templates ## Environment - Branch or commit: `refactor` at `805ab939a4f7297dfbab6f7358ab9a40f4e026d2` - Run mode: not captured; issue filed from current code inspection on the refactor branch - OS + version: not captured - Node + pnpm versions: not captured - Rust version, if relevant: not captured - Remote Runtime URL configured? (yes / no / not relevant): not relevant for the core issue - Provider, model, or integration, if relevant: not relevant ## Logs, screenshots, or video No screenshots or timing capture attached yet. Current evidence is from the live refactor code path: - `src/app/shell/RightPanel.tsx` lazy-loads `../../features/catalog/characters/shell` for the Characters panel. - `src/features/catalog/characters/shell.ts` still exports the panel together with editor, full library, maker, create/import, and update modal surfaces. - `src/features/catalog/characters/hooks/use-characters.ts` uses a general summary projection that still requests `description`, `personality`, `scenario`, `first_mes`, `mes_example`, `system_prompt`, `post_history_instructions`, `alternate_greetings`, `character_book`, and `extensions`. - `src/features/catalog/characters/components/CharacterListRow.tsx` computes token estimates from the parsed card data for compact rows. ## Regression notes This has shifted since the earlier panel-performance discussion around issue #1934. Recent managed avatar thumbnail and deferred image-resolution work improved the image-loading side, but the remaining first-open cost appears to come more from broad module loading and oversized side-panel summary data than from avatar delivery itself. ## Additional context Recent image-loading work means this should be treated as a refreshed performance issue, not a duplicate of the older avatar-focused framing: - managed avatar and thumbnail delivery improved in `a5a8234e` and follow-up work - the panel still appears to need a narrower lazy entrypoint and a dedicated lightweight side-panel summary shape - likely fixes are to split the side-panel entrypoint from the broader characters shell and stop loading prompt/book-heavy fields for the compact list path unless a detail/search path truly needs them ## Template check Please uncheck the box below before submitting so we know you read the template. It is intentionally pre-checked: - [ ] I DID NOT read this template and provide the requested details.
bsakaguchi 2026-10-21 05:24:41 +07:00
  • closed this issue
  • added the
    bug
    label
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Engine#978
No description provided.