Skip to content

Add configurable CLI presentation themes (#248) - #305

Open
harshthakur3 wants to merge 5 commits into
ARPAHLS:mainfrom
harshthakur3:feat/248-cli-themes
Open

Add configurable CLI presentation themes (#248)#305
harshthakur3 wants to merge 5 commits into
ARPAHLS:mainfrom
harshthakur3:feat/248-cli-themes

Conversation

@harshthakur3

Copy link
Copy Markdown

Description

Adds user-configurable presentation themes to the interactive Skillware CLI.

Users can choose between pastel, ocean, and mono through the interactive menu. The selected theme is persisted in the global Skillware configuration, while a project-level configuration can override it. Missing, malformed, or unknown theme values fall back safely to pastel.

Fixes #248

Changes

  • Added pastel, ocean, and mono built-in presentation themes.
  • Added interactive theme selection through menu option 7 / theme.
  • Added global theme persistence under presentation.theme.
  • Preserved unrelated YAML settings when saving a theme.
  • Added support for project-level theme overrides.
  • Added graceful fallback to pastel for unknown or malformed values.
  • Applied the selected palette consistently across:
    • splash screen and gradient
    • tables and borders
    • headings and categories
    • skill IDs and statuses
    • interactive menus and links
    • warnings and errors
  • Updated skillware config show to display the effective theme.
  • Updated CLI help text, documentation, example configuration, and changelog.
  • Added configuration, persistence, fallback, interactive menu, and smoke-rendering tests.

Acceptance Criteria

  • Theme from configuration is applied consistently.
    • Implemented through the theme registry and active-theme resolver in skillware/cli.py.
    • Covered by built-in palette and smoke-rendering tests in tests/test_cli.py.
  • Users can change the theme without manually editing YAML.
    • Implemented through interactive menu option 7 / theme.
    • The selected theme is saved to the global configuration.
  • Unknown themes fall back gracefully.
    • Implemented through presentation-theme normalization in skillware/core/config.py.
    • Covered by malformed and unknown theme tests in tests/test_config.py.
  • CLI documentation and smoke tests are included.
    • Updated docs/usage/cli.md and .skillware.yaml.example.
    • Added smoke coverage for pastel, ocean, and mono.

Screenshots

The screenshots below demonstrate theme configuration, interactive selection, persistence, and rendering across all three built-in themes.

Configuration and available themes

Skillware presentation theme configuration and available themes

Default pastel theme

The existing pastel appearance remains the default and graceful fallback.

Skillware CLI using the default pastel theme

Interactive theme selection

Users can select a theme through the interactive CLI without manually editing YAML.

Skillware interactive CLI theme picker

Ocean theme configuration

The selected theme is saved under presentation.theme while unrelated configuration is preserved.

Skillware ocean theme configuration and persistence

Ocean theme rendering

The ocean palette is applied consistently to the splash screen, headings, menu entries, and links.

Skillware CLI using the ocean presentation theme

Mono theme selection

The monochrome palette can also be selected and persisted through the interactive menu.

Skillware mono theme selection and persistence

Mono theme rendering

The mono palette applies a consistent grayscale presentation across the CLI.

Skillware CLI using the mono presentation theme

Testing

The following verification was completed locally:

  • Full test suite: 421 tests passed
  • Theme-specific CLI and configuration tests: 81 tests passed
  • Black formatting check passed for the changed Python files.
  • Flake8 passed for the changed Python files.
  • git diff --check passed.
  • Wheel-build test passed.

Tests cover:

  • default pastel behavior
  • all three built-in palettes
  • global theme persistence
  • preservation of unrelated configuration
  • global and project precedence
  • unknown and malformed theme fallback
  • interactive menu dispatch
  • immediate theme refresh
  • smoke rendering for every built-in theme

Type of Change

  • CLI — changes to skillware/cli.py, configuration, tests, and CLI documentation

Checklist

  • Linked GitHub issue with Fixes #248.
  • Scope matches the issue with no unrelated refactors.
  • Black and Flake8 checks pass for the changed Python files.
  • Relevant CLI, configuration, and full-suite tests pass locally.
  • CHANGELOG.md was updated under [Unreleased].
  • CLI documentation and example configuration were updated.
  • No package version was changed.
  • examples/README.md is not applicable because no runnable scripts changed.
  • tests/test_registry_docs.py is not applicable because no skills, examples index, or agent-loop matrix changed.
  • The new or updated skill section is not applicable because no files under skills/ changed.

Related Issues

Fixes #248

- add pastel, ocean, and mono built-in themes
- persist global theme selection through the interactive menu
- support project-level overrides and graceful fallback
- update CLI documentation, tests, example config, and changelog
# Conflicts:
#	.skillware.yaml.example
#	CHANGELOG.md
#	docs/usage/cli.md
#	skillware/cli.py
#	skillware/core/config.py
@rosspeili

Copy link
Copy Markdown
Contributor

Thanks @harshthakur3, very strong work on this. The config merge (presentation.theme), three palettes, fallback to pastel, menu 8 / theme (with mail on 7 after main), docs, CHANGELOG, and tests all look good and match the issue.

One thing before merge: skillware/cli_mail.py still uses hardcoded pastel styles, so the mail submenu won’t follow ocean / mono. Please wire it to the active theme (shared palette helper or import from cli.py) so theming is consistent across the interactive CLI, as in the acceptance criteria.

After that, and if we confirm CI is green on the latest main and re-run the relevant suite locally, and once the mail submenu is themed, this should be good to merge <3

Thanks again for the thorough PR description and screenshots. Looks really good!

@harshthakur3

Copy link
Copy Markdown
Author

Sure, I’ll look into it and get the mail submenu themed as well. Thanks for the review!

Move CLI palette definitions into a shared theme module so the main
and mail interfaces use the same configured theme. Replace hardcoded
pastel styles in mail commands and add regression coverage for pastel,
ocean, and mono.
@harshthakur3

Copy link
Copy Markdown
Author

Hey @rosspeili, sorry for the late update—this was a small change I could’ve handled much sooner, and I’m sorry for keeping you waiting.

I’ve synced with the latest main and moved the palettes into a shared theme helper. The mail submenu and direct mail commands now follow the active theme. I also added regression coverage, and the relevant tests are green.

Mail submenu with active theme Mail submenu with alternate theme

Thanks for the clear feedback and your patience! 🙏

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[CLI]: User-configurable themes and presentation settings

2 participants