diff --git a/docs/prompts/greenfield-architecture/PROMPT.md b/docs/prompts/greenfield-architecture/PROMPT.md new file mode 100644 index 0000000..d4caa1d --- /dev/null +++ b/docs/prompts/greenfield-architecture/PROMPT.md @@ -0,0 +1,111 @@ +--- +name: greenfield-architecture +description: Research established patterns and design a high-level architecture for a new app or library with explicit tradeoffs and test strategy. +x-personal-mcp: + id: greenfield-architecture + version: 1.0.0 + tags: + - architecture + - planning + - greenfield + - design + - testing + - prompts + capabilities: + - resource://prompts/greenfield-architecture/document + arguments: + scope_type: + title: Scope type + description: "Scope type: app or library." + required: true + intent_document: + title: Intent document + description: Optional full document describing goals, context, and desired outcomes. + required: false + problem_domain: + title: Problem domain + description: Domain and business goal for the new app or library when no full intent document is provided. + required: false + constraints: + title: Constraints + description: Runtime, deployment, and non-functional constraints. + required: false +--- + +# Greenfield Architecture Planner + +Use this prompt to design a new software app or library architecture in generic terms. + +## Inputs + +1. intent_document: optional full document that explains goals, context, constraints, and desired outcomes +2. problem_domain: concise domain and one-sentence business goal when no full intent document is provided +3. scope_type: app or library +4. optional constraints: runtime, deployment, scale, non-functional priorities + +If both intent_document and problem_domain are provided, treat intent_document as the primary source and use problem_domain as a summary cross-check. + +## Workflow + +1. Validate required inputs. + - scope_type is required + - at least one of intent_document or problem_domain must be provided + - ask one concise clarification question if inputs are incomplete or contradictory +2. Start with research before proposing architecture: + - identify at least three established patterns or methodologies used for similar systems + - summarize what each pattern optimizes for + - compare strengths, risks, and implementation complexity +3. Ask which aspects of those patterns matter most for the user context. +4. Identify major libraries or frameworks commonly used for this problem space and explain tradeoffs for each: + - strengths and weaknesses + - ecosystem maturity + - performance profile + - operational complexity + - learning curve +5. Recommend one primary stack and one fallback stack, with rationale tied to stated priorities. +6. Produce the architecture deliverables: + - high-level concepts, features, and requirements + - intended use cases and key workflows + - high-level package/module structure + - conceptual boundaries for each module (what belongs there and what does not) + - dependency and data-flow direction between modules +7. Plan incremental delivery with explicit growth paths: + - define the initial prototype slice with the smallest valuable feature set + - identify which features are intentionally deferred from the prototype + - describe extension paths that add complexity in controlled stages + - ensure each stage preserves clean module boundaries and low migration risk +8. Design a test strategy aligned to the proposed structure and staged delivery plan: + - unit, integration, contract, and end-to-end layers + - what each layer should cover in prototype stage vs extension stages + - fixture and environment setup for fast, deterministic tests + - boundary seams for mocks/fakes and minimization of nondeterministic external I/O + - CI execution approach for fast feedback and confidence +9. Call out key risks, assumptions, and open questions. + +## Output Contract + +Return these sections in order: + +1. Research Summary +2. Pattern Comparison +3. Library and Framework Tradeoffs +4. Recommended Stack +5. Architecture Overview +6. Concepts, Features, and Requirements +7. Intended Use Cases +8. Package and Module Layout +9. Conceptual Boundary Map +10. Initial Prototype Scope +11. Extension Roadmap +12. Test Strategy +13. Risks and Open Questions +14. Next Implementation Steps + +## Quality Rules + +1. Keep language generic and project-agnostic. +2. Prefer established patterns over novelty unless there is a strong reason to diverge. +3. Tie each recommendation to an explicit requirement or tradeoff. +4. Make assumptions explicit and concise. +5. Ask one focused clarifying question when confidence is low instead of over-speculating. +6. Prefer architecture decisions that support starting simple and growing complexity without major rewrites. diff --git a/tests/registry/models/test_skill_tag_conventions.py b/tests/registry/models/test_skill_tag_conventions.py index b2bbde4..53774fa 100644 --- a/tests/registry/models/test_skill_tag_conventions.py +++ b/tests/registry/models/test_skill_tag_conventions.py @@ -18,7 +18,6 @@ REQUIRED_LIBRARY_TAGS_BY_SKILL = { "fastapi-async-sqlalchemy-modernization": {"fastapi", "sqlalchemy", "asyncio"}, "fastapi-uv-docker": {"fastapi", "uv", "uvicorn", "docker"}, "mcp-details": {"mcp", "fastmcp"}, - "new-skill": {"mcp", "fastmcp"}, "nicegui": {"nicegui", "fastapi"}, "nicegui-ui-customization": {"nicegui", "fastapi"}, "pytesting": {"pytest", "testing", "fastapi", "asyncio", "anyio"}, diff --git a/zensical.toml b/zensical.toml index 0e3f2bb..4664d5f 100644 --- a/zensical.toml +++ b/zensical.toml @@ -66,6 +66,7 @@ nav = [ { "Prompts" = [ { "Authoring" = "prompts/authoring/PROMPT.md" }, { "Fill Pytest Scaffold" = "prompts/fill-pytest-scaffold/PROMPT.md" }, + { "Greenfield Architecture" = "prompts/greenfield-architecture/PROMPT.md" }, { "MCP Consumer Repo Shim" = "prompts/mcp-consumer-repo-shim/PROMPT.md" }, ] }, { "Skills" = [