← всі звіти · pm-agent.md

type: agent name: PM Agent (Project Manager) slug: pm-agent kind: subagent department: it reports_to: it-director manages: [scout-agent, threads-news-editor] status: active version: v0.4 readiness_pct: 80 implementation: systemd-timer runtime: python + gemini-api model: gemini-3.1-pro-preview trigger: cron schedule: "0 19 * * *" source_dir: /srv/services/pm-agent skills:


PM Agent (Project Manager) v0.4

Role

Автономний project-manager що тримає документацію живою. Щодоби (22:00 Kyiv = 19:00 UTC) автоматично:

  1. Читає JSONL-сесії за останні 24h + git log /srv/wiki + frontmatter всіх проектів
  2. Виявляє SPARC-фази проектів через sparc_detector → детермінований readiness_pct
  3. Bootstrap legacy проектів без sparc/ папки (генерує 01-specification.md)
  4. Детектує переходи фаз з попереднього run'у → flag'ує review gates (S→P, R→C)
  5. Викликає Gemini 3.1 Pro з контекстом → отримує digest + auto_changes
  6. Apply: bumps last_updated, append ## 🤖 PM Changelog → ### YYYY-MM-DD секцію
  7. Git commit у /srv/wiki з підписом «🤖 PM Agent v0.4»
  8. Шле Telegram digest з SPARC progress (bootstrap'и, readiness updates, transitions з gate-marker)
  9. Збирає відповіді Сергія з /srv/services/pm-agent/answers/

Skills

Tools

Why Gemini: AI Ultra subscription покриває use, $0 incremental cost, 1M context перекриває читання багатьох сесій + wiki за один pass.

Triggers

Trigger Schedule Запускає
systemd timer pm-agent.timer daily 19:00 UTC (22:00 Kyiv) systemd auto
On-demand manual Сергій або Claude через python3 /srv/services/pm-agent/pm_agent.py
Dry-run (тестовий) manual python3 pm_agent.py --dry-run --hours 1 (Telegram skip, друк у stdout)
No-bootstrap (тестовий) manual python3 pm_agent.py --dry-run --no-bootstrap (тільки detection, не модифікує файли)

CLI прапори

--hours <N>       lookback на сесії (default 24)
--dry-run         не шле Telegram digest, друкує у stdout
--no-bootstrap    не виконує SPARC bootstrap (тільки detection)

RACI

Project / Area R A C I
All projects/deltamedical/*
All projects/personal/*
products/, integrations/, agents/

Implementation

Status: ✅ active v0.4 (з 2026-05-10)

Code:

Backups:

Config / state:

Deployment:

Logs: /var/log/pm-agent.log Credentials: /srv/passepartout/google/gemini-sandbox.key

SPARC integration (v0.4 нове)

Кожен PM run проходить через sparc_detector.run_sparc_lifecycle():

  1. Для кожного проекту:

    • detect_sparc_phase(<project_dir>) → стан фаз
    • Якщо bootstrap_needed=Truebootstrap_sparc() створює sparc/01-specification.md
    • compute_readiness(detected) → точне число (= completed_phases / N × 100)
    • Якщо result != current frontmatter → write_frontmatter_field
  2. detect_phase_transitions() порівнює з sparc_state.json:

    • Кожна транзиція додається у Telegram digest
    • Транзиції S→P і R→C маркуються 🚪 (потрібен Сергієвий ОК)
  3. Окремий git commit для SPARC-змін з префіксом «🌱 PM Agent v0.4»

Escape hatches

Telegram digest формат

📋 PM Daily YYYY-MM-DD (v0.4)

[summary 1-2 речення]

🌱 SPARC bootstrap: <list проектів>      # тільки якщо було
📊 Readiness updates (по SPARC-фазах):   # тільки якщо було
  • <slug>: X% → Y% (фаза: P)
🎯 SPARC переходи фаз:                   # тільки якщо було
  • <slug>: S→P 🚪                       # 🚪 = потрібен gate review

🟢 Активні проекти:
  • <slug> — що зроблено за 24h

✅ PM-агент задокументував:
  • <slug>: last_updated→YYYY-MM-DD, changelog +N ряд.
    💾 git commit зроблено

🟡 Stale (>7д):
  • <slug> — Nд. <suggestion>

❓ Питання для Сергія:
  • <q1>
  • <q2>

➡️ PM next: <one sentence>

Members

{single agent — не crew}

Notes

Changelog (агент-рівень)