{"id":9595,"plugin_id":"plugin_asdk_app_6a215179debc8191a28dd0f3723c0646","kind":"skill","collection_source":null,"comparison_source":null,"observed_at":"2026-09-30T22:55:15.022Z","digest":"4f5704150e26377a592c832ad71346729f2bc32046b79fc74ffc3ef1ca091758","against":null,"payload":{"description":"Produce a Sector Brief HTML report for any industry sector using Moody's GenAI MCP tools and web research. Use this skill whenever the user asks to analyze a sector, write a sector report, do an industry analysis, create a sector overview, or generate a sector deep-dive. Trigger even if they just name a sector and mention \"analysis\", \"overview\", \"outlook\", \"report\", or \"deep-dive\". Also trigger for phrases like \"what's happening in the retail sector\" or \"give me a sector breakdown for aerospace\".","included_files":[{"relative_path":"__MACOSX/._SKILL.md","size_in_bytes":163},{"relative_path":"__MACOSX/._assets","size_in_bytes":163},{"relative_path":"__MACOSX/._evals","size_in_bytes":163},{"relative_path":"__MACOSX/._references","size_in_bytes":163},{"relative_path":"__MACOSX/assets/._template.html","size_in_bytes":163},{"relative_path":"__MACOSX/evals/._evals.json","size_in_bytes":163},{"relative_path":"__MACOSX/references/._report-spec.md","size_in_bytes":163},{"relative_path":"__MACOSX/references/._shared-citations.md","size_in_bytes":163},{"relative_path":"__MACOSX/references/._shared-template.md","size_in_bytes":163},{"relative_path":"assets/template.html","size_in_bytes":11247},{"relative_path":"evals/evals.json","size_in_bytes":5352},{"relative_path":"references/report-spec.md","size_in_bytes":6010},{"relative_path":"references/shared-citations.md","size_in_bytes":5814},{"relative_path":"references/shared-template.md","size_in_bytes":8111}],"name":"sector-brief","skill_md_contents":"---\nname: sector-brief\ndescription: >\n  Produce a Sector Brief HTML report for any industry sector using Moody's GenAI MCP tools\n  and web research. Use this skill whenever the user asks to analyze a sector, write a sector\n  report, do an industry analysis, create a sector overview, or generate a sector deep-dive.\n  Trigger even if they just name a sector and mention \"analysis\", \"overview\", \"outlook\", \"report\",\n  or \"deep-dive\". Also trigger for phrases like \"what's happening in the retail sector\" or\n  \"give me a sector breakdown for aerospace\".\n---\n\n# Sector Brief Skill\n\nGenerates a professional HTML report (styled like a Moody's sector brief document) for a\nspecified industry sector. The report is research-heavy and text-driven, combining Moody's\ninternal research with supplemental web data across six structured sections plus an executive\nsummary and citations.\n\nThe workflow is **single-artifact delivery**: gather all data, then write the entire filled\nHTML document to a single `.html` file in `/mnt/user-data/outputs/` and actively render it to\nthe user with **both** `present_files` and `visualize:show_widget`. The rendered HTML artifact\nis the deliverable — writing the file without rendering it is a failed run.\n\n> ## ⚠️ CRITICAL — NON-NEGOTIABLE OUTPUT CONTRACT\n>\n> **The LLM MUST deliver the final report as a single standalone HTML artifact file that it\n> then actively renders on screen.** Creating the file is only half the job — a file that is\n> written but never surfaced is a failed run, and is the single most common failure mode for\n> this skill. Specifically:\n>\n> - The LLM **MUST** write the **complete, standalone HTML document** (`<!doctype html>` →\n>   `</html>`), with every section from the streaming protocol populated inline, to a single\n>   `.html` file in `/mnt/user-data/outputs/` using the `create_file` tool.\n> - The LLM **MUST** then render that file with **both** display tools — `present_files`\n>   **and** `visualize:show_widget` — before ending its turn. Firing both renderers is what\n>   guarantees the report always appears even if one tool is unavailable.\n> - The LLM **MUST NOT** end its turn after `create_file` without having called the display tools.\n> - The LLM **MUST NOT** emit the report inline as a fenced ` ```html ` code block, as prose,\n>   Markdown, JSON, attachments, or links. The rendered HTML artifact itself is the answer.\n> - The LLM **MUST NOT** split the report across multiple files, multiple messages, partial\n>   snippets, or summaries.\n> - If data gathering fails partially, still produce the single HTML artifact file with the\n>   best-available content and brief `\"Data unavailable\"` placeholders for missing sections —\n>   never skip the artifact or the render step.\n>\n> Treat any other output shape as a hard failure of the skill.\n\n## Required MCP server\n\n`Moodys MCP server` — tools used: `searchAllDocuments` (sector research), `getEntitySectorOutlook`,\n`searchNews`, `findEntity`\n\nWeb research is also required via `searchNews` or general web search tools.\n\nIf any of the tools required for a section do not exist, inform the user: One or more tools required for this section are not available under your current subscription. Unlock more of the expert insights, data, and analytics you trust. Get Link:https://www.moodys.com/web/en/us/capabilities/gen-ai/ai-ready-data.html with us to learn more.\n\n## Bundled files\n\n- `assets/template.html` — pre-styled scaffold with the Moody's cover, a baked-in static 6-item\n  table of contents, and empty fill-in targets (cover title, date, section-content divs, sources\n  container). Treat this file as the **read-only structural reference**: read it, fill it in\n  mentally, and emit the complete filled document in the final response.\n\n## Shared chrome & citations\n\nBefore emitting, read [`references/shared-template.md`](references/shared-template.md) (page\nchrome: cover, TOC, section block, sources-section wrapper, footer, outlook-badge, design\ntokens) and [`references/shared-citations.md`](references/shared-citations.md) (citation\nnumbering, hyperlinking, source data shape, markup snippets). Both are **authoritative** — do\nnot invent, duplicate, or restyle anything they already define. The canonical CSS is already\ninlined in `assets/template.html` between the `/* BEGIN/END shared-template-css */` and\n`/* BEGIN/END shared-citations-css */` markers; never re-copy it at emit time.\n\nThe rest of this section is the skill-specific binding.\n\nThis skill uses the **`cover-simple`** variant. Skill-specific overrides retained above the\nmarker region: **none** for SA (it inherits the canonical `body { font-size: 13px }` and\n`.page { max-width: 900px }` defaults). SA is the lightest of the four parent skills — almost\nall its visual chrome now lives in the shared layer. Any outlook-badge usage in this skill\n(e.g. for sector outlook indicators) must use the canonical pastel variants\n(`stable` / `positive` / `negative` / `review` / `na`) defined by the shared skill — no\nsolid-fill or inline-color overrides.\n\nThe prefix used for the end-of-document container in this skill is `sa`, so the container id\nis `#sa-sources`. This skill does not use the optional per-section `.section-citations` recap\ncomponent.\n\n## Parameters\n\nThe user should provide:\n- **Sector** (required — e.g., \"Retail & Apparel\", \"Aerospace/Defense\", \"Banking\")\n\nIf the user specifies a sub-sector like \"Luxury Retail\", use it as-is for focused analysis.\n\n---\n\n## Step 0 — Sector Picker (run before anything else)\n\nIf the user has not named a specific sector in their message, **stop** and call\n`ask_user_input_v0` with a single `single_select` question before proceeding. Do **not**\nbegin any research or template reading until the sector is confirmed.\n\n**Preamble:** \"Which Moody's-covered sector would you like to analyze? Select one below\nand I'll generate the full report.\"\n\n**Options:**\n\n- Aerospace & Defense\n- Automotive Manufacturing\n- Banking — Global\n- Building Materials & Construction\n- Chemicals\n- Commercial Real Estate & REITs\n- Consumer Products\n- Diversified Manufacturing\n- Food & Beverage\n- Forest Products & Paper\n- Gaming & Lodging\n- Healthcare — Hospitals & Health Systems\n- Healthcare — Medical Devices & Technology\n- Healthcare — Pharmaceuticals\n- Infrastructure & Project Finance\n- Insurance\n- Media & Entertainment\n- Metals & Mining\n- Oil & Gas — E&P\n- Oil & Gas — Integrated & Refining\n- Oil & Gas — Midstream & Pipeline\n- Packaging\n- Retail & Apparel\n- Shipping & Ports\n- Steel\n- Structured Finance — ABS/RMBS/CMBS\n- Technology — Hardware & Semiconductors\n- Technology — Software & Services\n- Telecommunications\n- Transportation & Logistics\n- Utilities — Electric\n- Utilities — Gas Distribution\n- Utilities — Water\n\nOnce the user selects, treat their choice exactly as if they had typed\n`Run a sector brief for {selected sector}` and continue from Step 1.\n\nIf the user already named a sector, **skip this step entirely** and go straight to Step 1.\n\n---\n\n## Step 1 — Read the template\n\nRead `assets/template.html` (relative to this skill directory) once. Keep its exact structure —\nCSS, `<head>`, cover, hardcoded TOC, section order, and element IDs — as the scaffold for the\nfinal artifact. Do **not** copy it to the workspace and do **not** open it.\n\n---\n\n## Step 2 — Research phase (parallel)\n\nFire ALL of the following searches in a **single parallel batch**:\n\n### Moody's internal research (via MCP)\n\n| Search | Purpose |\n|--------|---------|\n| `searchAllDocuments` with criteria: \"{Sector} Sector Overview\" | Sector definition, methodology, key activities |\n| `searchAllDocuments` with criteria: \"Economic factors impact on {Sector} Sector\" | Macro-economic context |\n| `searchAllDocuments` with criteria: \"{Sector} Sector, industry\" | Financial performance data |\n| `searchAllDocuments` with criteria: \"{Sector} Sector Risk and challenges\" | Risk analysis |\n| `searchAllDocuments` with criteria: \"{Sector} sector Outlook\" | Sector outlook |\n| `getEntitySectorOutlook` for a major company in the sector | Formal Moody's outlook |\n\n### Web research (via searchNews or web tools)\n\n| Search | Purpose |\n|--------|---------|\n| \"Key players from {Sector} industry, market share, roles\" | Key players for overview |\n| \"Key regions of activity and growth markets for {Sector} sector\" | Geographic scope |\n| \"{Sector} sector aggregate revenue, profit margins, return on equity\" | Financial metrics |\n| \"Major companies from {Sector} sector benchmark comparison\" | Industry structure and dynamics |\n\n---\n\n## Step 3 — Synthesize all sections\n\nUse Moody's internal research as the **primary foundation** for every section. Web sources\nserve only to supplement gaps or validate findings. When conflicts arise, prioritize Moody's\nunless external data provides substantial evidence for reconsideration.\n\nWrite in professional credit-research language. Always attribute sources with numbered citation\nreferences inline. The exact inline markup, the URL-less fallback, and the rule that `n`\nmatches the row position of the source inside `#sa-sources` are defined in\n[references/shared-citations.md](references/shared-citations.md).\n\nAuthor the Executive Summary and Sections 1–6 per the per-section content specs in\n[`references/report-spec.md`](references/report-spec.md) (see `## Section content specs`).\nEach section's required subsections — and the inline SVG charts that attach to Sections 3, 4,\nand 6 — are defined there. Populate the `#sa-*` content targets listed in Step 4.\n\n### Sources\n\nCollect all sources. The source data shape (`id`, `title`, `source`, `date`, `url`) and the\nend-of-document Citations row markup are defined in\n[references/shared-citations.md](references/shared-citations.md).\n\n---\n\n## Inline SVG Charts — Section Instructions\n\nThis report embeds three inline SVG charts (Chart A in Section 3, Chart C in Section 4,\nChart D in Section 6). Before emitting them, read\n[`references/report-spec.md`](references/report-spec.md) for each chart's type, axes,\ncolors, `viewBox`, placement, and the **mandatory pre-computation requirement** (compute\nevery coordinate programmatically with bash/Python — never mentally). If source data for a\nchart is unavailable, emit a `<p>Chart data unavailable</p>` placeholder rather than\nomitting it silently.\n\n---\n\n## Step 4 — Assemble the complete HTML artifact\n\nAfter all sections are synthesized, write the **entire filled `template.html` document** — with\nevery element from the streaming protocol populated in place — to a single `.html` file in\n`/mnt/user-data/outputs/`. The full required delivery sequence (`create_file` → `present_files`\n→ `visualize:show_widget` → one short sentence) is specified in the **Output and presentation**\nsection below; follow it exactly.\n\nThe HTML file **must**:\n\n- Be written in a single `create_file` call (no progressive `StrReplace` edits, no multi-file\n  split).\n- Contain a complete, standalone HTML document (doctype → `</html>`) that renders without\n  external dependencies.\n- Preserve the template's `<head>` (CSS, fonts), cover, hardcoded TOC, section order, and\n  element IDs exactly. Only the empty targets defined below are populated.\n\n### Cover + footer\n\n1. `#sa-cover-title` — `<strong>{Sector}</strong><br>Analysis` (HTML, not plain text).\n2. `#sa-date` — report date string, e.g. `April 15, 2026`.\n3. `#sa-footer-date` — same date string.\n\n### Section headings\n\n4. `#sa-overview-title` — override the default \"Sector Overview\" with\n   `{Sector} — Sector Overview`.\n\n### Section content targets\n\nEach of the following divs takes fully-authored HTML (`<p>`, `<ul><li>`, and\n`<strong class=\"subsection-title\">…</strong>` only — no other block tags):\n\n5. `#sa-exec` — Executive Summary. Flowing paragraphs only, no bullets.\n6. `#sa-overview` — Section 1 body with four `<strong class=\"subsection-title\">` subheaders.\n7. `#sa-macro` — Section 2 body with three subheaders.\n8. `#sa-financial` — Section 3 body with three subheaders. Every metric must include a\n   concrete number.\n9. `#sa-structure` — Section 4 body with four subheaders. Porter's Five Forces must use\n   High / Moderate / Low ratings per force.\n10. `#sa-risks` — Section 5 body with five subheaders.\n11. `#sa-outlook` — Section 6 body. Lead with the Moody's outlook (Positive / Stable /\n    Negative) and date, then 2–3 paragraphs. Paragraph form only.\n\n### Sources container\n\n12. `#sa-sources` — end-of-document Citations rows. One `<div class=\"source-item\">` per\n    source, in ascending `id` order, using the canonical row markup defined in\n    [references/shared-citations.md](references/shared-citations.md). Apply that file's rules\n    for URL-less rows and missing `source`/`date` fields.\n\n### HTML conventions\n\n- Use `<p>` for paragraphs.\n- Use `<ul><li>…</li></ul>` for bullet points (nested `<ul>` for sub-bullets).\n- Use `<strong class=\"subsection-title\">Subheader</strong>` for subsection headers within\n  each section. Do not repeat the top-level section title — the template already renders it.\n- Emit inline citations per\n  [references/shared-citations.md](references/shared-citations.md).\n- Escape any `&`, `<`, `>` that appear in the narrative (`&amp;`, `&lt;`, `&gt;`).\n\n---\n\n## Tips\n\n- Run ALL research searches in a single parallel batch.\n- Moody's data is the foundation — web data supplements. Make this hierarchy clear in the\n  writing by attributing external sources explicitly.\n- The executive summary should be written last, after all other sections are synthesized.\n- Financial Performance must include actual numbers, not just directional statements.\n- Porter's Five Forces in Industry Structure should use ratings (High, Moderate, Low) for\n  each force.\n- Sector Outlook must be in paragraph form only — no bullet points.\n- Citations follow the shared citations skill — read\n  [references/shared-citations.md](references/shared-citations.md) before authoring any `[n]`\n  reference or the Citations block.\n\n---\n\n## Negative number formatting\n\nUnify ALL negative numbers across narrative, tables, and any JSON/HTML string values to use\nthe parenthesis-minus convention `(-X)`. Examples: `(-9%)`, `(-1.2pp)`, `(-$3.4B)`,\n`(-250 bps)`. Do NOT use a bare leading minus (`-9%`), en-dash (`–9%`), or accounting\nparentheses without the minus sign (`(9%)`). Apply this consistently to growth rates, margin\nchanges, YoY deltas, and any negative monetary values.\n\n---\n\n## Output and presentation (required final steps)\n\n> ## ⚠️ CRITICAL — THE SKILL IS NOT COMPLETE UNTIL THE REPORT IS VISIBLY RENDERED\n>\n> Writing the file is **not** delivery. After you write the HTML you **must** actively render\n> it with every display tool available, in order, before you say anything else. Do not end\n> your turn until the rendered report is on screen.\n\nFollow this exact sequence. Do not skip a step, reorder, or substitute alternatives. When\nupdating this skill, do not delete or modify any other file in the `skills/sector-brief/`\nfolder.\n\n1. **Write the HTML file in a single call.** Call `create_file` to write the entire standalone\n   HTML document (`<!doctype html>` → `</html>`) to\n   `/mnt/user-data/outputs/{sector_slug}_sector_analysis.html` in **one** call. `{sector_slug}`\n   is the lowercased, hyphenated sector name (e.g. `retail-apparel`, `oil-gas`). No progressive\n   edits, no multi-file split.\n2. **Present the file.** Immediately call `present_files` on that exact path to surface the\n   artifact to the user.\n3. **Show the widget.** Immediately call `visualize:show_widget` on the same file to render the\n   report visually. Call this even if `present_files` already succeeded — firing both renderers\n   is what guarantees the report always appears.\n4. **Confirm in one short sentence.** Only after the renderers return, add a single brief\n   sentence in chat (e.g. `Sector Brief for {Sector} — the report is available above as a\n   self-contained HTML artifact.`). Nothing more.\n\nIf a display tool call fails or is unavailable, immediately try the other one rather than\nstopping. Never end your turn at step 1.\n\n**Strict prohibitions:**\n\n- **Never** emit the HTML as a fenced ` ```html ` code block in the chat response.\n- **Never** inline the HTML, JSON payload, or large excerpts of the report body in the chat\n  message.\n- **Never** end your turn after `create_file` without having called both display tools.\n"},"changes":[],"summary":"First saved snapshot. No earlier version is available for comparison.","summary_kind":"deterministic","summary_metadata":{}}