new skill meta

This commit is contained in:
John Lancaster
2026-06-18 22:22:30 -05:00
parent 9f34e12e08
commit 818de1b3f9
7 changed files with 192 additions and 4 deletions
+2
View File
@@ -5,6 +5,7 @@ from personal_mcp.skills.fastapi_async_sqlalchemy_modernization.server import (
fastapi_async_sqlalchemy_modernization_server,
)
from personal_mcp.skills.fastapi_uv_docker.server import fastapi_uv_docker_server
from personal_mcp.skills.new_skill.server import new_skill_server
from personal_mcp.skills.nicegui.server import nicegui_server
from personal_mcp.skills.nicegui_ui_customization.server import (
nicegui_ui_customization_server,
@@ -21,6 +22,7 @@ mcp.mount(
fastapi_async_sqlalchemy_modernization_server,
namespace="fastapi_async_sqlalchemy_modernization",
)
mcp.mount(new_skill_server, namespace="new_skill")
mcp.mount(nicegui_server, namespace="nicegui")
mcp.mount(nicegui_ui_customization_server, namespace="nicegui_ui_customization")
mcp.mount(pytest_scaffolding_server, namespace="pytest_scaffolding")
+8 -3
View File
@@ -5,9 +5,8 @@ def _repo_root() -> Path:
return Path(__file__).resolve().parents[3]
def load_skill_document(*, skill_id: str, skill_slug: str) -> dict[str, str]:
"""Load the canonical skill markdown document for an MCP skill."""
document_path = _repo_root() / "docs" / "skills" / skill_slug / "SKILL.md"
def load_markdown_document(*, skill_id: str, document_path: Path) -> dict[str, str]:
"""Load an arbitrary Markdown document and expose it as a skill resource."""
if not document_path.exists():
raise FileNotFoundError(
f"Missing skill document for '{skill_id}': {document_path}"
@@ -20,3 +19,9 @@ def load_skill_document(*, skill_id: str, skill_slug: str) -> dict[str, str]:
"source_path": str(document_path),
"content": document_path.read_text(encoding="utf-8"),
}
def load_skill_document(*, skill_id: str, skill_slug: str) -> dict[str, str]:
"""Load the canonical skill markdown document for an MCP skill."""
document_path = _repo_root() / "docs" / "skills" / skill_slug / "SKILL.md"
return load_markdown_document(skill_id=skill_id, document_path=document_path)
@@ -0,0 +1 @@
"""Pseudo-skill exposing the new skill bootstrap guide."""
@@ -0,0 +1,12 @@
id: new-skill
name: New Skill Bootstrap
version: 1.0.0
description: Provide the bootstrap checklist and templates for creating new MCP skills.
tags:
- bootstrap
- scaffolding
- skills
- mcp
capabilities:
- resource://skills/new-skill/document
depends_on: []
@@ -0,0 +1,17 @@
from pathlib import Path
from fastmcp import FastMCP
from personal_mcp.skills.document_loader import load_markdown_document
new_skill_server = FastMCP("new-skill")
@new_skill_server.resource("resource://skills/new-skill/document")
def skill_document() -> dict[str, str]:
"""Return the bootstrap guide used to scaffold new skills."""
document_path = Path(__file__).resolve().parents[4] / "docs" / "new_skill.md"
return load_markdown_document(
skill_id="new-skill",
document_path=document_path,
)