Repository navigation
Architectural shift: abstract metaconcepts above tool-specific formats #62
Description
Summary
Rethink DevSync's core model from file distribution to practice distribution. Packages should store abstract metaconcepts (rules, commands, skills, MCP servers) that are tool-agnostic, with translation to tool-specific formats happening at install time.
This is a vision-level architectural shift, not a single feature.
The Problem Today
Currently, DevSync packages contain files that are essentially tool-specific artifacts:
- A rule is a
.mdfile that gets copied to.claude/rules/or.cursor/rules/ - An MCP config is a JSON file that gets copied with path adjustments
- Content is passed through, not translated
This means:
- Packages are implicitly tied to the format they were authored in
- "Install" means "copy files to the right directories" — smart routing, dumb content
- Users can't adapt or merge practices — only overwrite/skip/rename at the file level
- MCP configs with credentials require manual scrubbing rather than declarative extraction
The New Model
Abstract metaconcepts
A package stores intent, not files:
- Rule: A practice with a name, description, principles, enforcement patterns, and examples — not a markdown blob written for one tool
- Command: A capability declaration (what it does, what inputs it needs, what it produces) — not a shell script
- MCP Server: A service declaration (what it does, what credentials it needs, how to describe them to users) — not a JSON config file
- Skill: A workflow declaration (steps, context needed, outputs) — not a directory with a SKILL.md
Translation at install time
The ai_tools/ layer becomes responsible for translating abstract declarations into tool-native formats. This is an expansion of what it already does (routing files to directories) into also handling content generation.
"Adapt, don't overwrite" workflow
Because practices are stored as structured concepts with intent, an AI-assisted merge becomes possible:
- User has existing testing rules
- User installs a package with testing best practices
- Instead of overwriting, DevSync (or an AI skill using DevSync) can semantically merge: "Your rules already cover X. The package adds Y and Z. Here's a combined version."
This is content-level merging, not file-level conflict resolution.
MCP credential extraction
A concrete example of the pattern:
Today: User has .claude/settings.local.json with real API keys. package create scrubs them into ${ENV_VAR} placeholders. Recipient gets a JSON file with holes.
New model: package create extracts the MCP server declaration: "This package needs a filesystem MCP server. It requires ALLOWED_DIRECTORIES (description: comma-separated paths to allow). It uses the @anthropic/mcp-filesystem package." At install time, DevSync builds the correct config format for the target tool, prompts for credentials with helpful descriptions, and writes the final config — never storing secrets.
What Changes
Keep
- Multi-tool translation engine (
ai_tools/) — this is the core differentiator - Package manifest format (evolve
ai-config-kit-package.yamlto support declarations) devsync installanddevsync package createcommandsdevsync toolsdetection- Secret detection and credential safety patterns
Evolve
- Package format: from file references to practice declarations
- Install logic: from file copying to content generation
- Conflict resolution: from file-level (skip/overwrite/rename) to content-level (merge/adapt/replace)
- MCP handling: from config scrubbing to declarative extraction
Simplify/Remove
- Library system (download/list/update/delete cache) — install directly from source
- Template system — subsumed by the new package model
- TUI browser — defer, not core to the new model
- Installation tracking — simplify to "what's installed where"
- Multiple install commands (install, package install, template install, mcp install) — unify to one
installverb
Acceptance Criteria
This is a large effort. Initial acceptance criteria for the first milestone:
- Define the abstract schema for each metaconcept (rule, command, skill, MCP server)
- Update
ai-config-kit-package.yamlformat to support declarations alongside file references (backwards compatible) - Implement declaration-based MCP install: extract credentials at create time, prompt and build config at install time
- Prove the model with one end-to-end example: create a package from a real project, install it to 2+ tools from declarations
- Document the new package format
Open Questions
- How much translation should DevSync do vs. delegating to AI at install time? (DevSync stays AI-free per vision, but a Claude Code skill could handle the AI-assisted merge)
- Should the abstract format be YAML declarations, structured markdown, or something else?
- How to handle backwards compatibility with existing file-based packages?
- Where does the "adapt/merge" workflow live — in DevSync CLI or as an AI skill that uses DevSync under the hood?
Vision Alignment
- ✅ Zero-friction: still pip install, still CLI
- ✅ IDE-agnostic: strengthens this — practices truly portable across tools
- ✅ Git as distribution: packages still live in Git repos
- ✅ Lean CLI: simplifies command surface area
- ✅ Credential safety: improves this — credentials are declarative, never in files
- ✅ Standards-first: abstract format is a new standard, but grounded in existing YAML/markdown
Activity
troylar commentedon Feb 21, 2026
Updated Direction: AI-Baked-In (Option B)
After discussion, the decision is to integrate AI directly into the CLI rather than keeping DevSync as a dumb tool layer that AI assistants orchestrate.
Why
The "holy shit" moment requires zero orchestration from the user. Two commands:
Nobody says "holy shit" about a library that other tools call. The value is in the CLI itself being intelligent.
The AI Pipeline
AI is the engine for the entire workflow, not just one step:
API Key Requirement
This means DevSync requires an LLM API key. Make it painless:
ANTHROPIC_API_KEY(users are likely already Claude users)OPENAI_API_KEYas alternative~/.devsync/configVision Update Needed
DevSync goes from "package manager for AI configs" to "AI-powered config distribution for AI coding tools."
Drop the "works offline" constraint — the tools being configured are AI coding assistants that require internet. The offline principle was holding back the actual value.
Update "Not a code generator" to acknowledge that install-time content generation (translating abstract practices to tool-specific formats) is a deliberate expansion of scope in service of the core mission.
Revised Product Identity
pip install devsync— still zero frictionWhat This Supersedes
troylar commentedon Feb 22, 2026
Completed by PR #79 (v0.12.0). DevSync v2 shipped with: abstract practice declarations (
PracticeDeclaration,MCPDeclaration), AI-powered extraction and adaptation, content-level merging, declarative MCP credential handling, and simplified 6-command CLI. Any remaining work (abstract commands/skills declarations) can be tracked as separate issues.