Skip to content

[Planning][P3] skilllite-services shared orchestration layer (Phase 1 redesign) #105

Description

@EXboys

Summary

Architecture docs describe a future skilllite-services crate sitting between entry crates (skilllite, skilllite-assistant, future MCP entry) and domain crates, hosting shared application orchestration used by both CLI and Desktop.

Phase 0 decisions were recorded (TASK-2026-042), a bootstrap crate was created (TASK-2026-043), and a Phase 1A migration was attempted (TASK-2026-044) — then rolled back (TASK-2026-045) because coupling risk outweighed benefit before the Assistant split contract was complete.

This issue tracks a redesigned Phase 1 that respects the split-ready L1/L2/L3 model.

Problem

Today, shared flows (workspace resolution, evolution orchestration, skill discovery) are duplicated or accessed via:

  • Direct path deps in Desktop (blocks repo split)
  • Ad-hoc logic in skilllite-commands
  • Growing --json CLI surface (preferred for split cleanliness)

We need a deliberate decision on when a shared Rust library layer adds value vs when L2 CLI JSON is sufficient.

Design constraints (from architecture)

  1. Assistant must not path-dep services at split time — only subprocess to skilllite binary
  2. Prefer L2 CLI JSON over in-process services for split cleanliness
  3. If services are needed, expose as skilllite desktop-serve daemon rather than linking from Assistant
  4. Dependencies flow one way: Entry → Services → Domain crates

Proposed scope (Phase 1 redesign)

Option Description Split-friendly?
A — CLI-only Continue expanding --json subcommands; no skilllite-services crate ✅ Best for split
B — Engine-internal services skilllite-services used by CLI + optional daemon; Assistant calls via subprocess ✅ If daemon/CLI only
C — Shared library in Assistant Path-dep services from Desktop ❌ Blocks P4 extract

Recommendation: Start with Option A inventory; adopt Option B only for flows where CLI JSON is too slow or too fragmented (with caching/TTL in bridge).

Acceptance criteria

  • Written ADR / CONTEXT doc comparing Options A/B/C with explicit decision
  • Inventory of duplicated orchestration between CLI and Desktop (with file references)
  • If Option B chosen: bootstrap skilllite-services with one vertical slice (e.g. workspace resolution) + deny.toml boundary rule
  • If Option A chosen: close this issue with checklist of remaining --json gaps
  • No regression to Assistant split P2 exit criterion (zero engine path deps)

References

Metadata

Metadata

Assignees

No one assigned

    Labels

    agentAgent related changesbackendBackendenhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions