Skip to content

Feature Request: Global Defaults with Per-Project Overrides #58

Closed

Description

@malys

Currently, Mode, Agent, Model, Effort, and Turns must be configured manually for each project.

It would be useful to support global default values that are automatically applied to all projects, while still allowing project-specific overrides when needed.

Use Case

Example global configuration:

defaults:
  mode: Task
  agent: Single
  model: Opus
  effort: Auto
  turns: 5

Any new project would automatically inherit these values.

For a specific project, only the settings that need to differ would be overridden:

project:
  model: Sonnet
  turns: 10

Effective configuration:

mode: Task      # inherited
agent: Single   # inherited
model: Sonnet   # overridden
effort: Auto    # inherited
turns: 10       # overridden

Benefits

  • Avoid reconfiguring the same settings for every project.
  • Ensure consistency across projects.
  • Allow project-specific tuning when necessary.
  • Improve workflow for users who primarily work with the same Mode, Agent, and Model combination.

Suggested UI

  • Add a Global Defaults section in Settings.
  • Apply defaults automatically to newly created projects.
  • Allow projects to override any setting.
  • Add a Reset to Defaults button at project level.
  • Visually indicate overridden values (badge, icon, tooltip, different color, etc.).

Example

Many users always work with:

  • Mode: Task
  • Agent: Single
  • Model: Opus
  • Effort: Auto
  • Turns: 5

Today, these values must be manually selected every time a project is created or opened.

With global defaults, projects would start with the preferred configuration automatically, while retaining the flexibility to override specific settings when needed.

Activity

  1. Lexus2016 commented on Aug 23, 2026

    @Lexus2016
    Owner

    Shipped in #62 (a696098).

    The chain — project override > global default (config.json) > BUILTIN, resolved by a new pure module chat-defaults.js. The five dials are Mode, Agent, Model, Effort and Turns.

    All five asks are covered:

    • Global Defaults in Settings — five rows in the settings catalog (section: 'defaults'), so the existing generic form renders them with source badges and a per-row Reset.
    • Auto-applied — a new chat, a project switch and a page reload all seed the toolbar from the resolved defaults instead of the literals that used to sit in newTab().
    • Per-project override — the ★ button pins the current five dials to the active project; PUT /api/projects/:id/defaults.
    • Reset to Defaults — the ↺ button next to it, shown only when something is actually pinned.
    • Override indicator — an accent border and a dot on the toolbar group label of each pinned dial.

    The per-project link is deliberately sparse: a project stores only the dials it pinned, so an unpinned dial keeps following the global when the global changes. A full five-key snapshot would have frozen each project at whatever the global happened to be the day it was created.

    BUILTIN is the pre-#58 behaviour verbatim, so an install that never opens the settings form behaves exactly as before. An existing chat is never re-seeded — it carries its own mode/model in SQLite.

    The diff went through an independent cross-provider review before merge, which caught a real precedence bug: the two config files were spread together raw, so a local empty value could mask a valid global one and fall through to the built-in instead of to the global. Fixed in the second commit, along with unifying the turns coercion between the settings form and the resolver.

    Tests: test/chat-defaults.test.js (53 assertions, pure resolver) and test/chat-defaults-api.test.js (51 assertions, real server with both config layers on disk). Full suite: 63 files, 1858 assertions, CI green.

  2. added 2 commits that reference this issue on Aug 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions