Skip to content

feat: settings mcp tool commands#567

Merged
yacosta738 merged 1 commit into
developfrom
feature/dallay-544-settings-mcp-tool-commands
Apr 18, 2026
Merged

feat: settings mcp tool commands#567
yacosta738 merged 1 commit into
developfrom
feature/dallay-544-settings-mcp-tool-commands

Conversation

@yacosta738
Copy link
Copy Markdown
Contributor

This pull request introduces several improvements across GitHub configuration, workflow automation, and the corvus-traits Rust crate. The main focus is on enhancing session management capabilities in the memory trait, updating workflow dependencies, and improving the documentation and configuration for branch protection. Below are the most important changes:


Session Management Enhancements (corvus-traits)

  • Added new session management types and methods to the Memory trait, including session snapshots, state records, resumable sessions, and explicit error handling for unsupported backends. This enables more robust and extensible session lifecycle tracking and management. (F1a8e0a1L1, [1] [2]
  • Implemented default trait methods that return explicit errors for session-related operations when unsupported, and provided tests to ensure these errors are raised for non-SQLite backends. [1] [2]

GitHub Rulesets and Documentation

  • Updated .github/rulesets/README.md to use English, clarify instructions, and improve explanations of ruleset files and their import process. [1] [2]
  • Enhanced main-protection.json and minor-protection.json by adding merge queue rules, expanding branch coverage (including develop), and updating bypass actors for integrations. [1] [2] [3] [4]

Workflow Automation and Quality

  • Upgraded all reusable workflow dependencies to dallay/common-actions v2.0.0 for improved automation, security, and maintainability. [1] [2] [3] [4] [5] [6]
  • Enhanced the documentation build workflow to upload a preview artifact of the docs site, making it easier to review unreleased documentation.
  • Refactored the docs deployment workflow to support publishing from any specified ref via workflow dispatch, increasing flexibility for documentation releases. [1] [2]

…mands (#544)

- Add /model, /provider, /temperature handlers (settings family)
- Add /mcp list/add/remove handlers (mcp management family)
- Add /tool enable/disable handlers (tool management family)
- Add CommandCapability variants: SettingsRead, SettingsWrite, McpManagement, ToolManagement
- Add SessionCommandSuccessData variants for all new command responses
- Add SlashCommandArgumentShape::RequiredText
- Add regression tests: 16 new tests covering success paths, validation, and error cases
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Apr 18, 2026

Important

Review skipped

Auto reviews are limited based on label configuration.

🚫 Review skipped — only excluded labels are configured. (2)
  • wip
  • do-not-review

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 97d352e6-1a0b-44f6-ab08-f37db98b6b9c

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

Implements a deterministic "slash session commands" runtime layer supporting /resume, /suspend, /tldr, and /compact with SQLite-backed session snapshots and state persistence. Adds a centralized slash command registry, ingress short-circuit routing, and extends the Memory trait with session lifecycle APIs. Updates GitHub workflows to v2.0.0 and translates GitHub rulesets README to English.

Changes

Cohort / File(s) Summary
GitHub Rulesets & Branch Protection
.github/rulesets/README.md, .github/rulesets/main-protection.json, .github/rulesets/minor-protection.json
Spanish-to-English documentation translation; added merge_queue rule with batch limits and bypass actor (Integration id:2502251) to main protection; expanded minor protection scope to include refs/heads/develop and added matching merge_queue rule.
CI/CD Workflow Updates
.github/workflows/cleanup-cache.yml, contributor-report.yml, deploy-docs.yml, docs-quality.yml, greetings.yml, pr-size-labeler.yml, semantic-pull-request.yml, stale.yml
Updated reusable workflow references from v1.2.0 to v2.0.0 (commit SHAs); changed deploy-docs.yml from automatic push/release triggers to manual workflow_dispatch with ref input; added artifact upload and summary notification steps to docs-quality.yml.
Slash Session Commands Infrastructure
clients/agent-runtime/src/session_commands/{mod.rs,types.rs,parser.rs,registry.rs,service.rs}, clients/agent-runtime/src/pre_execution/session_command_adapter.rs
New session command platform with lexical parser, static registry with descriptor-driven dispatch, typed execution context/requirements/outcomes, and service implementation for /resume, /suspend, /tldr, /compact with memory/SQLite backend validation.
Memory Trait & Session State
clients/agent-runtime/crates/corvus-traits/src/memory.rs, clients/agent-runtime/src/memory/{mod.rs,traits.rs,sqlite.rs,lucid.rs,markdown.rs,none.rs}
Extended Memory trait with snapshot/state CRUD (load transcript excerpts, create/fetch snapshots, read/patch session state, list/lookup resumable sessions, take pending hydration). Implemented SQLite-backed persistence with session_snapshots and session_state tables; explicit unsupported-backend errors for non-SQLite backends.
Runtime Integration
clients/agent-runtime/src/agent/{unified_entrypoint.rs,unified_loop.rs,memory_loader.rs}, clients/agent-runtime/src/gateway/{mod.rs,webhook_dispatch.rs}, clients/agent-runtime/src/channels/mod.rs, clients/agent-runtime/src/bootstrap/mod.rs, clients/agent-runtime/src/main.rs, clients/agent-runtime/src/lib.rs
Updated approval/blocking tracking to include reasons; refactored ingress handling to intercept slash commands before autosave/memory enrichment via pre_execution::evaluate_ingress() + adapt_handled_ingress(); added tool snapshot helpers; extended CLI/gateway/webhook/channel entry points to route session commands with handler result adaptation; added pending-resume hydration via memory loader.
Extensive Specification & Documentation
openspec/changes/archive/2026-04-*/{proposal.md,design.md,specs/**,tasks.md,state.yaml,verify-report.md}, openspec/specs/{agent-loop,sessions,slash-command-registry}/spec.md
Comprehensive design/proposal/specification docs for slash-session-commands, command-context-permissions-result-contract, registry-core, transport-parity, regression tests, and tools-listing features with verification reports and implementation checklists.

Sequence Diagram(s)

sequenceDiagram
    participant Client as Client/Transport<br/>(CLI, Gateway, Webhook, Channel)
    participant Ingress as pre_execution::<br/>evaluate_ingress()
    participant Registry as SlashCommandRegistry<br/>.dispatch()
    participant Service as SessionCommandService<br/>(Handler)
    participant Memory as Memory Backend<br/>(SQLite)
    participant Adapter as adapt_handled_ingress()

    Client->>Ingress: prompt (e.g., "/suspend")
    Ingress->>Ingress: parse_slash_command()
    alt Recognized Slash Command
        Ingress->>Registry: dispatch(context, prompt)
        Registry->>Service: handle_suspend(session_id)
        Service->>Memory: get_session_state_record()
        Memory-->>Service: SessionStateRecord
        Service->>Memory: update_session_state_record()
        Memory-->>Service: updated state
        Service-->>Registry: SessionCommandOutcome::Success
        Registry-->>Ingress: IngressDecision::SessionCommand{outcome}
    else Unknown/Non-Command Input
        Ingress-->>Ingress: not_a_slash_command()
        Ingress-->>Adapter: IngressDecision::Continue
    end
    Ingress-->>Adapter: IngressDecision
    Adapter->>Adapter: classify_result()
    Adapter-->>Client: HandledIngress{Success/Failure/Blocking/NotHandled}
    alt Handled by Ingress
        Client->>Client: transport_wrap(result)
    else Not Handled
        Client->>Client: continue_normal_loop()
    end
Loading

Estimated code review effort

🎯 5 (Critical) | ⏱️ ~120 minutes

Rationale: This PR introduces a substantial new session-management feature touching core runtime surfaces (ingress, memory trait, persistence layer, gateway/webhook/channel/CLI routing), with high-density logic across multiple new modules (session_commands/), significant trait extension, SQLite schema changes, and heterogeneous updates spanning control flow refactoring in existing entry points. The scope encompasses 10+ affected runtime files plus extensive supporting documentation, requiring careful review of authorization boundaries (caller-scope /resume), memory semantics (pending hydration), unsupported-backend error propagation, and transport parity across multiple ingress surfaces.

Possibly related PRs

Suggested labels

area:rust, area:docs, area:ci, risk:security

Suggested reviewers

  • yuniel-acosta
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feature/dallay-544-settings-mcp-tool-commands

@yacosta738 yacosta738 changed the base branch from main to develop April 18, 2026 13:41
@github-actions
Copy link
Copy Markdown
Contributor

✅ Contributor Report

User: @yacosta738
Status: Passed (12/13 metrics passed)

Metric Description Value Threshold Status
PR Merge Rate PRs merged vs closed 90% >= 30%
Repo Quality Repos with ≥100 stars 0 >= 0
Positive Reactions Positive reactions received 11 >= 1
Negative Reactions Negative reactions received 0 <= 5
Account Age GitHub account age 3094 days >= 30 days
Activity Consistency Regular activity over time 108% >= 0%
Issue Engagement Issues with community engagement 0 >= 0
Code Reviews Code reviews given to others 572 >= 0
Merger Diversity Unique maintainers who merged PRs 2 >= 0
Repo History Merge Rate Merge rate in this repo 92% >= 0%
Repo History Min PRs Previous PRs in this repo 252 >= 0
Profile Completeness Profile richness (bio, followers) 90 >= 0
Suspicious Patterns Spam-like activity detection 1 N/A

Contributor Report evaluates based on public GitHub activity. Analysis period: 2025-04-18 to 2026-04-18

@yacosta738 yacosta738 enabled auto-merge April 18, 2026 13:57
@yacosta738 yacosta738 disabled auto-merge April 18, 2026 13:57
@yacosta738 yacosta738 merged commit 53a50a8 into develop Apr 18, 2026
14 of 16 checks passed
@yacosta738 yacosta738 deleted the feature/dallay-544-settings-mcp-tool-commands branch April 18, 2026 13:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant