Skip to content

Feature Request: Persistent chat history with directory isolation #2633

@jmmoser

Description

@jmmoser

Feature Description

Add persistent chat history that survives CLI restarts and is isolated by working directory.

Problem Statement

Currently, when users restart the Amazon Q CLI, all previous chat history is lost. Users cannot use up-arrow navigation to access previous commands from earlier sessions, which reduces productivity and user experience.

Proposed Solution

Implement persistent chat history with the following features:

Core Functionality

  • Persistent storage: Chat history survives CLI restarts using SQLite database
  • Directory isolation: History for /project/a is separate from /project/b
  • Up-arrow navigation: Works seamlessly with persistent history
  • Automatic cleanup: Maintain max number of entries per directory to prevent unlimited growth

User Experience

  • No configuration required - works out of the box
  • Transparent integration with existing readline functionality
  • Per-directory isolation matches user mental model

Use Cases

  • Developers working on multiple projects can maintain separate command history
  • Long-running development sessions benefit from persistent history across restarts
  • Power users with frequent CLI usage get improved productivity

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions