Skip to content
Agentmart
Submit a tool

Deliver Brief

Render brief from template and deliver to configured targets (email, GitHub issue, terminal).

Skill by YuiZhou

IndexedMIT★ 2
Write a review

Install

Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.

npx agentmarket install skill/yuizhou-deliver-brief

Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.

Get the weekly diff

The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.

We use your email only for this newsletter. Privacy

About

Render brief from template and deliver to configured targets (email, GitHub issue, terminal).

Use cases: productivity

No reviews yet. Installed it? Reviews come from verified installers only. How reviews work

Permissions

What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.

Tools
No tools found
Secrets
None asked for
Install scripts
None found

Network hosts it talks to 1

  • codeload.github.com · found in install command

Files it touches

  • ~/.claude/skills/deliver-brief

What's inside

Skill name
Deliver Brief
Description
Render brief from template and deliver to configured targets (email, GitHub issue, terminal).
License
MIT
Instructions
181 lines in SKILL.md · view on GitHub

Agent Skills spec issues

  • name: only lowercase letters, digits and single hyphens allowed
  • name: "Deliver Brief" does not match folder "dayarc-deliver"

Files (9)

  • SKILL.md
  • am.hbs · templates/
  • am.md.hbs · templates/
  • monthly.hbs · templates/
  • monthly.md.hbs · templates/
  • pm.hbs · templates/
  • pm.md.hbs · templates/
  • weekly.hbs · templates/
  • weekly.md.hbs · templates/

SKILL.md (first lines)

## Templates
Located in this skill's `templates/` directory:

**HTML templates (for email):**
- `pm.hbs` — Evening Wrap-up
- `am.hbs` — Morning Brief
- `weekly.hbs` — Weekly Report
- `monthly.hbs` — Monthly Report

**Markdown templates (for GitHub issues and other markdown-native targets):**
- `pm.md.hbs` — Evening Wrap-up
- `am.md.hbs` — Morning Brief
- `weekly.md.hbs` — Weekly Report
- `monthly.md.hbs` — Monthly Report

## Delivery Targets

Read `~/Documents/dayarc/config.json → delivery` to determine where to send the brief. If the `delivery` field is absent or empty, fall back to the default: **email-only for all brief types**.

```json
{
  "delivery": [
    { "target": "email", "briefs": ["pm", "am", "weekly", "monthly"] },
    { "target": "github-issue", "briefs": ["weekly"],
      "config": { "repo": "owner/repo", "labels": ["weekly-brief"] } }
  ]
}
```

**Allowed brief IDs:** `am`, `pm`, `weekly`, `monthly`

For each target entry where the current `briefType` is in the `briefs` array, execute that target's delivery handler. **Targets are independent** — if one fails, log the error and continue with others. End with a delivery summary showing which targets succeeded and which failed.

### Impact narrative data

PM, weekly, and monthly templates accept `impact_summaries` generated by **dayarc-write-impact-summary**. Each item
contains `title`, `situation`, `task`, `action`, optional `result`, optional `impact`, `status`, and
`source_breadcrumbs`.

- Prefer `impact_summaries` whenever present.
- Preserve every field and breadcrumb during rendering and translation.
- Do not fill missing result or impact text during delivery; missing fields mean the evidence did not support a
  claim.
- For older memory without `impact_summaries`, use the templates' activity/accomplishment fallback.

---

## Delivery Modes

### Scheduled (multi-target)

**Step 1: Render** — Render the appropriate template with brief data. Use `.hbs` (HTML) for email targets and `.md.hbs` (Markdown) for GitHub and other markdown-native targets. If `locale` is not `en`, translate the rendered content into the target language (preserving all markup, emoji, and links).

**Step 2: Deliver to each target** — For each matching target in config:

#### Target: `email`

1. Verify Outlook is running (check process).
2. **Idempotency check:** Query Outlook Sent Items for a message with this brief's subject:
   ```powershell
   $ol = New-Object -ComObject Outlook.Application
   $sent = $ol.Session.GetDefaultFolder(5)  # 5 = olFolderSentMail
   $subject = "{subject}"
   $alreadySent = $sent.Items | Where-Object { $_.Subject -eq $subject } | Select-Object -First 1
   if ($alreadySent) {
       Write-Host "already delivered — skipping send (ItemID: $($alreadySent.EntryID))"
       # skip this target, continue to next
   }
   ```
3. Send via Outlook COM:
   ```powershell
   $ol = New-Object -ComObject Outlook.Application
   $mail = $ol.CreateItem(0)
   $mail.To = $ol.Session.CurrentUser.Address
   $mail.Subject = "{subject}"
   $mail.HTMLBody = Get-Content "{html-path}" -Raw
   $mail.Send()
   ```

Email subjects (translate if `locale` is not `en`):
- PM: `🌙 Evening Wrap-up — {date}`
- AM: `☀️ Morning Brief — {date}`
- Weekly: `📊 Weekly — Week of {date}`
- Monthly: `📅 Monthly — {month} {year}`

#### Target: `github-issue`

Creates a GitHub issue with the rendered Markdown brief.

**Config fields:**
| Field | Required | Description |
|-------|----------|-------------|
| `repo` | ✅ | Target repository in `owner/repo` format |
| `labels` | optional | Array of label names to apply |
| `assignees` | optional | Array of GitHub usernames to assign |

**Account context (do this FIRST — before idempotency or create):**

`gh` may have multiple authenticated accounts, and the *active* account may not be able to see the configured `repo` (e.g., a private repo owned by a different account). You **must** ensure the active account can resolve the exact configured repo. **Never** redirect delivery to a different repository — if the configured repo cannot be resolved, fail this target with a clear error.

```powershell
$repo  = "{repo}"                 # exact owner/repo from config — do NOT change it
$owner = $repo.Split("/")[0]

# 1. Is the configured repo already resolvable under the active account?
$ok = $false
gh repo view $repo --json nameWithOwner 2>$null | Out-Null
if ($LASTEXITCODE -eq 0) { $ok = $true }

# 2. If not, try switching to a logged-in account matching the repo owner, then re-check.
if (-not $ok) {
    $accounts = gh auth status 2>&1 | Select-String "account (\S+)" | ForEach-Object { $_.Matches.Groups[1].Value }
    if ($accounts -contains $owner) {
        gh auth switch --user $owner 2>&1 | Out-Null
        gh repo view $repo --json nameWithOwner 2>$null | Out-Null
        if ($LASTEXITCODE -eq 0) { $ok = $true }
    }
}

From YuiZhou/dayarc-agent, MIT.

More from YuiZhou/dayarc-agent

Signals

Stars
2
Forks
2
Open issues
7
Last commit (this folder)
Aug 26, 2026 (2 months ago)

From GitHub (fetched Oct 24, 2026).

Details

License
MIT
First seen
Oct 24, 2026
Last checked
Oct 24, 2026

More from YuiZhou

Cite this page

Deliver Brief skill. Agent Mart. https://agentmart.dev/skills/yuizhou-deliver-brief (last updated 2026-10-24)