From 3d90b2a88dfcf5e447167da1852b64acbe78f139 Mon Sep 17 00:00:00 2001 From: jason Date: Tue, 19 May 2026 12:32:44 -0500 Subject: [PATCH] feat: add SKILL.md v1.0.0 --- skills/project-timeline-site-creator/SKILL.md | 242 ++++++++++++++++++ 1 file changed, 242 insertions(+) create mode 100644 skills/project-timeline-site-creator/SKILL.md diff --git a/skills/project-timeline-site-creator/SKILL.md b/skills/project-timeline-site-creator/SKILL.md new file mode 100644 index 0000000..49b2ef7 --- /dev/null +++ b/skills/project-timeline-site-creator/SKILL.md @@ -0,0 +1,242 @@ +# sow-gantt-provisioner + +Provisions a project timeline instance in the MPM Agile Dashboard and exports Gantt chart images for embedding in a Statement of Work document. Operates in two modes: **programmatic** (called by the SOW generator skill with a full context object) or **interactive** (called manually, runs a structured interview to gather missing information). + +--- + +## When to Use This Skill + +Trigger this skill when: +- Generating or updating a draft or final SOW and a project timeline needs to be created or refreshed +- A PM wants to provision a standalone Agile Dashboard project for a new deployment +- A change order requires updated timeline images +- Someone asks to "create the Gantt chart", "set up the project timeline", "provision the dashboard", or "generate the timeline for [customer]" + +Do NOT use this skill for: +- Viewing or browsing existing project timelines (use `get_project` directly) +- Updating a single phase or milestone on an existing project (use `update_phase` / `update_milestone` directly) + +--- + +## Prerequisites — MCP Server + +The Agile Dashboard MCP must be reachable. Connection config: + +```json +{ + "mcpServers": { + "agile-dashboard": { + "serverUrl": "https://agile.apps.mpmedia.tv/mcp", + "headers": { + "Authorization": "Bearer 7f036d6dd709823f79dbf0a4dbae83e9aeb84b2149b3362f76acf72af3f4df12" + } + } + } +} +``` + +Available tools (all prefixed `agile-dashboard__` or equivalent MCP namespace): +`list_projects`, `get_project`, `create_project`, `update_project`, `delete_project`, +`list_phases`, `get_phase`, `create_phase`, `update_phase`, `delete_phase`, +`list_milestones`, `get_milestone`, `create_milestone`, `update_milestone`, `delete_milestone`, +`get_settings`, `set_setting`, `delete_setting`, +`export_image`, `list_versions`, `get_version`, `restore_version`, +`import_csv`, `get_subsite_url` + +--- + +## Template File + +Project type templates are stored in a Google Drive Markdown file maintained by the PM team: + +**File:** `MPM_Timeline_Templates.md` +**Location:** Google Drive → PM 2.0 Resources folder +**Drive Folder ID:** `1Uy-2CDQFLOHcnU5DRRt_Alz6UibDQd5z` +**Access:** Read via Google Workspace MCP (`get_drive_file_content` or `read_file_content` by file ID) + +Read this file at the start of every provisioning run — do not rely on cached or previously read content. The PM team edits it directly and changes must always be reflected. + +--- + +## Execution Flow + +### Step 0 — Determine Mode + +Check whether a `project_context` object was passed by the calling skill. + +**A `project_context` is considered complete if it contains ALL of:** +- `customer_name` (string) +- `project_type` (one of: `onboard`, `wayside`, `off-grid-solar`) +- `hardware_variant` (one of: `in-stock`, `mto`) +- `construction_variant` (one of: `new-construction`, `retrofit`) +- `unit_count` (integer >= 1) + +If all five are present → **Programmatic mode**: skip to Step 2. +If any are missing → **Interactive mode**: proceed to Step 1. + +--- + +### Step 1 — Interactive Interview + +Ask the following questions in order. Stop after any [REQUIRED] question goes unanswered — do not proceed without it. For optional questions with defaults, accept a blank/skip and use the default. + +Present questions conversationally, not as a numbered list. Confirm all collected values with the user as a summary before provisioning. + +**Q1 [REQUIRED]** — Customer / client name: +> "What is the customer or client name for this project?" + +**Q2 [REQUIRED]** — Project type: +> "What type of deployment is this? Options: +> - **Onboard** — displays installed on vehicles (bus, rail, BRT, streetcar) +> - **Wayside** — fixed displays at stations, shelters, or platforms +> - **Off-Grid Solar** — solar-powered displays at locations without grid power" + +**Q3 [REQUIRED]** — Hardware variant: +> "Is the hardware for this project already in MPM's inventory (in-stock), or will it be manufactured to order?" + +**Q4 [REQUIRED]** — Construction variant: +> "Is this a retrofit into an existing installation, or new construction (new vehicles, new structures, or sites that don't yet exist)?" + +**Q5 [REQUIRED]** — Unit / site count: +> "How many [vehicles / sites / locations] are in scope? Enter a number." +> *(Use "vehicles" for onboard, "sites" for wayside/off-grid-solar)* + +**Q6 [OPTIONAL, default: TBD]** — Start date: +> "What is the estimated project start date? (YYYY-MM-DD format, or say 'TBD' to leave open)" + +**Q7 [OPTIONAL, default: mpm]** — Install owner: +> "Who will handle the physical installation — MPM directly, a reseller or partner, or the transit authority's own crew?" +> *(Options: `mpm`, `reseller`, `transit-authority`)* + +**Q8 [OPTIONAL, default: none]** — Hard deadline: +> "Is there a hard deadline, grant expiration, or revenue service date we absolutely must hit? If yes, provide the date (YYYY-MM-DD)." + +After collecting answers, present a confirmation summary and wait for explicit confirmation before proceeding. + +**Slug generation rule:** `{customer_name_slug}-{project_type}-{YYYY}` +- `customer_name_slug`: lowercase, spaces to hyphens, remove special characters +- Example: `reno-rta-onboard-2026` +- If slug already exists, append `-2` (then `-3`, etc.) + +--- + +### Step 2 — Load Template + +1. Fetch `MPM_Timeline_Templates.md` from Google Drive using the Google Workspace MCP. +2. Parse the matching `## Template: {project_type}` block. +3. Extract: phases table, milestones table, default settings, duration scaling table, variant modifiers table. +4. Store as working data — do not modify the source file. + +If the file is inaccessible, halt and report the error. + +--- + +### Step 3 — Apply Variants and Scaling + +Apply modifiers in this order: + +**3a. Hardware variant:** +- If `in-stock`: override Phase 4 durations to `min=7, max=21` +- If `mto`: use template defaults + +**3b. Construction variant:** +- If `new-construction` + `wayside`: add 30 min / 60 max days to Phase 6 +- If `new-construction` + `off-grid-solar`: add 21 min / 45 max days to Phase 7 +- If `retrofit`: no change + +**3c. Install owner:** +- If `reseller` or `transit-authority`: reduce Phase 7 max by 20%, add Phase 7b: Partner Installation Oversight (min=14, max=45, depends=7) + +**3d. Duration scaling:** +Look up `unit_count` in the Duration Scaling table. Apply multiplier to affected phases. Round to nearest whole day. Do not scale phases already overridden by variant modifier. + +**3e. Hard deadline check (advisory):** +If `hard_deadline` provided, compute critical path max. Warn if it exceeds the deadline. + +--- + +### Step 4 — Provision the Project + +**4a.** `list_projects()` — check for existing slug +**4b.** `create_project(name="{slug}", seed="master")` +**4c.** `update_project(project_id, phases, milestones, settings)` — full replace with computed data + +All duration values must be **strings** (e.g., `"21"` not `21`). All phases need `completed: false`. + +**4d.** `set_setting(project_id, "project_start_date", "{start_date}")` — skip if TBD + +--- + +### Step 5 — Export Images + +``` +export_image(project_id, output="timeline", scenario="current", width=1400, height=400) +export_image(project_id, output="gantt", scenario="current", width=1400, height=600) +export_image(project_id, output="milestone", scenario="current", width=1400, height=300) +export_image(project_id, output="phase_table", scenario="current", width=1000, height=800) +``` + +--- + +### Step 6 — Capture Version and Generate URLs + +``` +list_versions(project_id) → take first timestamp as draft_version_ts +get_subsite_url(project_id, audience="team") +get_subsite_url(project_id, audience="customer") +get_subsite_url(project_id, audience="customer", version="{draft_version_ts}") +``` + +The versioned customer URL goes into the signed SOW. + +--- + +### Step 7 — Output + +Return structured result with: project_id, urls (team/customer_live/customer_signed), exports (4 PNGs), draft_version_ts, timeline range (min/max days), deadline_warning if applicable. + +In interactive mode, present as a summary with links and chart export confirmation. + +--- + +## Change Order / Re-Export Flow + +1. Skip Steps 1–4 +2. Load existing project via `get_project(project_id)` +3. Apply targeted updates via `update_phase`, `update_milestone`, `set_setting` +4. Re-run Steps 5–6 +5. Return with `change_order: true` and old/new version timestamps + +--- + +## Error Handling + +| Condition | Action | +|-----------|--------| +| Template file not found in Drive | Halt, ask user to confirm file location | +| Project slug already exists | Ask user: overwrite or use `{slug}-2`? | +| MCP call returns error | Report specific error, do not silently continue | +| `export_image` returns no data | Retry once; note in output if still empty | +| ETag conflict (412) | MCP handles retry automatically | +| `unit_count` outside all scaling tiers | Use highest tier multiplier, add note to output | + +--- + +## Notes for Calling Skills + +Pass a `project_context` object for programmatic mode: + +```json +{ + "customer_name": "Reno RTA", + "project_type": "onboard", + "hardware_variant": "mto", + "construction_variant": "retrofit", + "unit_count": 42, + "start_date": "2026-09-01", + "install_owner": "mpm", + "hard_deadline": "2027-06-30" +} +``` + +Pass `result.exports` to the docx skill for embedding. Pass `result.urls.customer_signed` to SOW Section 4 timeline embed.