nanocoder icon indicating copy to clipboard operation
nanocoder copied to clipboard

[Feature] Session Auto-Save Indicator

Open akramcodez opened this issue 3 months ago • 2 comments

Description

Add a subtle visual indicator in the corner of the CLI that briefly flashes when the session state is autosaved to disk.

Use Case

Since Nanocoder is local-first and maintains continuous semantic memory, users want peace of mind knowing that their complex agent interactions and context are safely persisted to disk. A small visual confirmation builds trust in the auto-save mechanism without interrupting the chat flow.

Proposed Solution

  • Add a small isSaving boolean state to the global application context.
  • When the internal saveSession or updateHistory function triggers, set isSaving to true.
  • In the main layout component (e.g., the bottom status bar or next to the token counter), conditionally render a subtle or [Saving...] text.
  • Revert the state back to false after the write operation completes.

Alternatives Considered

  • Printing a "Session Saved" log message in the chat feed (too noisy and clutters the UI).

Additional Context

  • [x] I have searched existing issues to ensure this is not a duplicate
  • [x] This feature aligns with the project's goals (local-first AI assistance)

Implementation Notes (optional)

  • Ink.js renders very fast, so if the disk write is nearly instantaneous, the indicator might flicker too fast to see. Consider wrapping the state revert in a setTimeout(..., 500) to ensure it's visible for at least half a second.

akramcodez avatar Aug 24 '26 08:08 akramcodez

hey would love to work on this issue can you assign it to me!

rishu685 avatar Aug 25 '26 08:08 rishu685

sure @rishu685 👍

akramcodez avatar Aug 25 '26 08:08 akramcodez