Skip to content

Latest commit

 

History

History
320 lines (258 loc) · 17.7 KB

File metadata and controls

320 lines (258 loc) · 17.7 KB

Changelog

All notable changes to this project are documented here. Format based on Keep a Changelog; versioning follows Semantic Versioning.

[Unreleased]

Added

Autonomous SaaS marketing loop across social networks and dev communities (epic #46, issues #47-#60):

  • Channel registry (lib/channels/registry.ts, issue #49): typed registry of 8 social platforms and 41 developer/community portals across 10 languages (id, audience, link policy, tone, publish method, compliance notes, frequency limits).
  • Integration broker (lib/integrations/broker.ts, issue #52): resolves publish/schedule/fetch_metrics/draft_ad/comment_monitor/evidence_capture to the safest adapter (api/mcp/browser/computer-use/manual) per channel, with dry-run simulation and structured failure logging.
  • Community compliance gate (lib/compliance/community.ts, issue #56): anti-spam/etiquette audit with a pass | fail | needs_review three-state result — checks that cannot be evaluated (unreadable channel rules, corrupted post history) hold for human review instead of silently passing.
  • Accrual-based analytics scoring (lib/analytics/score.ts, issue #54): ranks amplification candidates by the delta between successive polls (normalized per day), not a single cached snapshot, so slow-compounding threads aren't starved by yesterday's spike; flags implausible vanity-metric spikes as spam risk.
  • Strategy playbooks (.specs/strategy/PLAYBOOKS.md, issue #50): per-channel launch playbook for the 10 priority international dev/community channels.
  • Content templates (.specs/pieces/templates/*.md, lib/content/templates.ts, issue #57): five evidence-aware templates (dev article, social derivative, video script, Reddit/forum answer, launch thread) that mark missing evidence explicitly and render English-first before any localized adaptation.
  • Browser/computer-use lane (lib/automation/browser-lane.ts, issue #51): governed evidence capture with redaction and failure-mode classification (login_required, captcha, two_factor, platform_rejection, policy_block); DRY_RUN-gated, live actions require explicit human approval.
  • Paid-growth budget guardrails (lib/promotion/budget-guardrail.ts, issue #55): max daily spend, max CPA/CPL, max experiment duration, and stop-loss enforcement wired into the existing ads-draft flow, plus an append-only promotion-attempt audit log with hypothesis.
  • Campaign CLI (lib/cli/campaign.ts, lib/campaigns/campaign.ts, issue #53): marketing-engine campaign --brief <CAMPAIGN.md> plans a channel/language/format-tagged piece queue and enforces organic-before-paid by default; campaign review <id> summarizes winners/losers/spend.
  • Yool tuple-space board (lib/yool/board.ts, .specs/architecture/YOOL-BOARD.md, issue #59): event-sourced tuple board across 13 tuple classes and 11 worker lanes; mandatory agent-manifest guardrails (cpu/disk/timeout quotas); WorkerGovernor bounds concurrency per lane.
  • Community reply loop (lib/community/reply-loop.ts, issue #60): classifies incoming comments, assigns risk level, drafts evidence-honest replies for human review; never posts autonomously.
  • Root super-skill (.skills/simplicio-loop-marketing/SKILL.md, issue #48): orchestrates the full discover→...→learn loop by capability.
  • Runtime-first ADR (.specs/architecture/ADR-002-runtime-first.md, issue #47): confirms zero required dependency on simplicio-sprint/simplicio-prompt.
  • E2E mock launch loop (e2e/saas-launch-loop.spec.ts, issue #58): proves the full loop end-to-end against mocks, DRY_RUN throughout, never a live provider/platform call.

[0.3.1] - 2026-07-01

Changed

  • Hardened release-readiness and handoff guidance: added docs/release-readiness.md with a minimum readiness checklist, claims/evidence rules, and a handoff template; expanded docs/architecture-map.md, docs/domain-map.md, docs/local-setup.md, and docs/troubleshooting.md with clearer setup and troubleshooting detail; minor README.md update.

[0.3.0] - 2026-06-30

Added

  • watcher-gate (N-Nest style): independent verification layer in the generate loop that re-checks caption pillar hashtags, script topic coverage, caption length constraints, placeholder leakage, and overpromise language before allowing draft→scheduled transition. Every output receives a claims_tag: MEASURED, CANON, or UNVERIFIED.
  • claims-gate: enforce claims discipline at promote time — UNVERIFIED pieces blocked from ad creation. Watcher reports persisted under data/gate/<piece-id>.json.
  • .skills/watcher-gate/SKILL.md: skill manifest documenting gate rules, integration points, and DoD.
  • Piece frontmatter: claims_tag and watcher_report_path optional fields. Template defaults to claims_tag: UNVERIFIED.
  • Manifest payload now includes watcher_report_path.
  • maybeMarkMeasured sets claims_tag: MEASURED when performance data confirms value.
  • Promote loop checks claims gate before creating ad drafts; blocked pieces logged to data/learnings.md.

[0.2.13] - 2026-05-19

Added

  • <!-- rtk-cli:start --> block in AGENTS.md and .github/copilot-instructions.md (CLAUDE.md is a symlink to AGENTS.md) documenting optional RTK CLI usage for token-smart shell exploration (https://github.com/rtk-ai/rtk).
  • .skills/rtk-cli/SKILL.md skill manifest with plain→rtk mapping, trigger examples, and DoD.
  • <!-- yool-tuple-hamt:start --> capability-addressing block citing yool/tuple/HAMT spec v0.2 with mandatory guardrails (cpu_quota_pct=60, disk_quota_mb=100, timeout_s=300) per Victor Genaro's review.

[0.2.12] - 2026-05-18

Fixed

  • qa-tech-specs now reads channel constraints from .specs/product/CHANNELS.md, probes assets with ffprobe / identify, falls back to filename metadata when possible, and skips safely with install guidance when local probe tools are unavailable.
  • The generate loop now writes qa-tech-specs.json per piece, blocks pieces that fail hard platform-spec checks before scheduling, and records the QA report path in the manifest for successful runs.
  • Wavespeed image and video providers now support real model selection, batch-oriented variant expansion with concurrency capped at 5, and mocked local coverage for image downloads plus WAN video polling.

[0.2.11] - 2026-05-18

Fixed

  • Compliance loading now honors ACTIVE_CLIENT, reads additive client override rules from .specs/clients/<client>/COMPLIANCE.override.md, and writes warn lines to a weekly digest plus repeat-block alerts to data/learnings.md.
  • Blocking compliance reports now move local pieces to review, persist the report in data/compliance-blocked/, and keep the pipeline metadata pointed at the canonical data/compliance/<piece>.json audit trail.
  • generate now routes compliance through the shared loader instead of the old inline regex helper, and the repo ships a template .specs/clients/_template/COMPLIANCE.override.md plus focused coverage for override loading, escalation, and review transitions.

[0.2.10] - 2026-05-18

Fixed

  • marketing-engine sync now pulls Notion calendar rows into the host workspace .marketing-engine/pieces/, rendering new piece files from .specs/pieces/piece-template.md and recording the linked notion_page_id plus the last synced remote fingerprint.
  • Notion sync conflicts now preserve the local piece file and append the remote snapshot as a comment block instead of overwriting the frontmatter or losing local edits.
  • generate now back-syncs linked pieces to Notion when they advance to scheduled, and promote marks linked published pieces as measured in both the local piece file and the Notion calendar.
  • .ralph/sync-calendar.sh now calls the real marketing-engine sync command, and the repo adds focused Notion sync coverage for creation, conflict handling, and status back-sync paths.

[0.2.9] - 2026-05-18

Fixed

  • DeepSeekProvider now picks deepseek-chat for caption and translation, while reasoning-heavy tasks route through deepseek-reasoner.
  • DeepSeek pricing now resolves the correct model family in lib/providers/cost.ts, with optional per-1k token env overrides for chat and reasoner tiers.
  • Added provider coverage that asserts the DeepSeek request shape, retry behavior, usage accounting, and model-specific cost calculation.
  • Synchronized the package version metadata across package.json and package-lock.json.

[0.2.8] - 2026-05-18

Fixed

  • OllamaProvider now normalizes OLLAMA_HOST, preserves the configured OLLAMA_MODEL, and throws a descriptive unreachable-host error that points operators to start Ollama or change the host before the fallback chain moves on.
  • Added local adapter coverage that asserts the Ollama /api/chat request payload and retry behavior when the local server is offline.
  • Synchronized the published package metadata version between package.json and package-lock.json.
  • Added the missing scheduler helper parameter annotations in lib/schedule/{linux,mac}.ts so the repo-wide typecheck can complete again.

[0.2.7] - 2026-05-18

Fixed

  • marketing-engine schedule now routes install, status, and uninstall through platform-aware launchd and cron backends, including macOS uninstall/status support and a Windows manual Task Scheduler warning instead of silent writes.
  • Scheduler preview mode now prints the exact launchd plist bodies or cron lines that would be installed, and the Linux cadence now correctly renders 22:00 and 09:00 as 0 22 * * * / 0 9 * * *.
  • Added scheduler round-trip E2E coverage against temporary cron and launchd directories, plus updated setup guidance for the new CLI commands.

[0.2.6] - 2026-05-18

Fixed

  • Provider pricing and usage estimation now live in lib/providers/cost.ts, keeping the editable pricing table and char/4 fallback heuristic in one shared module.
  • Real LLM adapters now emit a concrete retry attempt count, and data/llm-usage.jsonl persists tokens, cost_usd, and the final attempt number from the provider call instead of logging only a router-level success marker.
  • Missing SDK usage payloads now warn once per provider/model pair while still producing cost estimates from the shared fallback token heuristic.

[0.2.5] - 2026-05-18

Fixed

  • lib/pieces/frontmatter.ts now enforces locale as a required frontmatter field, matching the documented piece template contract.
  • lib/pieces/id.ts now computes ISO weeks from UTC date parts, preventing timezone-dependent week rollover bugs in PIECE-YYYYWww-NNN ids.
  • lib/pieces/store.ts now exports list, read, and write aliases in addition to the existing *Piece* helpers so the public API matches the issue contract more directly.

[0.2.4] - 2026-05-18

Fixed

  • marketing-engine new-piece, status, and logs now operate against the host project's .marketing-engine/ workspace instead of assuming runtime files live at the host root.
  • new-piece now renders from .specs/pieces/piece-template.md, prints the created file path directly, and scans existing weekly piece files so repeated CLI invocations do not reuse the same PIECE-YYYYWww-NNN id.
  • status and logs now return infra exit code 2 when the workspace has not been initialized yet, while still succeeding cleanly when the data directory exists but the usage log file is empty.

[0.2.3] - 2026-05-18

Fixed

  • marketing-engine promote now reads and writes its runtime artefacts from the host project's .marketing-engine/{data,pieces,outputs} workspace by default, matching the scaffolded project layout.
  • Winner drafts now honor provider_override.ads from the source piece frontmatter, and the CLI summary output matches the documented promoted: N | losers: M | skipped: K format.

[0.2.2] - 2026-05-18

Fixed

  • marketing-engine generate now resolves the host project's .marketing-engine/{pieces,outputs,data} workspace by default instead of assuming runtime files live at the host root.
  • lib/cli/generate.ts now honors the MAX_ITER environment variable in addition to the existing --max-iter flag, and the E2E coverage exercises both the host-workspace defaults and the capped iteration flow.

[0.2.1] - 2026-05-18

Added

  • e2e/provider-factories.spec.ts exercises the non-DRY_RUN factory path so the suite proves the repo returns real provider adapters instead of production mocks.

Changed

  • E2E coverage now mirrors the Sprint 0 acceptance language more closely: e2e/cli-init.spec.ts and e2e/cli-scan.spec.ts split the host-project scaffold and scan coverage, e2e/generate-loop.spec.ts asserts structured usage-log tasks, and e2e/matrix.spec.ts proves that editing .specs/architecture/PROVIDERS.md changes routing without code edits.
  • CONTRIBUTING.md now documents how to update CHANGELOG.md, and the PR template links directly to the changelog checklist target.

[0.2.0] - 2026-05-18

Added

  • lib/providers/matrix.ts parses .specs/architecture/PROVIDERS.md as the single source of routing truth (ADR-001). Embedded defaults are used when the file is missing or malformed, with a stderr warning.
  • lib/providers/policy.ts — shared retry/backoff/timeout helper (withRetry), per-provider pricing table and estimateCost/estimateTokens helpers.
  • lib/router.ts exposes runWithFallback — wraps any provider call with the primary/fallback chain documented in PROVIDERS.md and writes one structured line per attempt to data/llm-usage.jsonl (ok, fallback_used, attempt, latency_ms).
  • lib/data/runs.ts and lib/data/manifest.ts write the artefacts the AGENTS Definition of Done requires: data/runs.jsonl per piece run and outputs/<client>/<date>/<piece-id>/manifest.json per piece.
  • lib/pieces/{id,frontmatter,store}.ts — piece engine. ISO-8601 week-numbered IDs (PIECE-YYYYWww-NNN), zero-dependency YAML frontmatter parser, state machine (draft → scheduled → published → measured, side state review).
  • lib/cli/generate.ts — real generation loop that reads pieces/, routes every task through the matrix + fallback chain, runs inline compliance, writes outputs/script/captions/compliance.json/manifest.json, transitions status, and appends to data/runs.jsonl.
  • lib/cli/promote.ts — real promotion loop that classifies data/analytics.jsonl (top/bottom 20% by save rate, ≥100 impressions), writes ads-draft.json for winners, appends data/learnings.md for losers.
  • lib/calendar/notion.ts — Notion calendar reader (pullCalendar, syncToLocal, pushStatus). DRY_RUN-safe.
  • lib/publish/adaptlypost.ts — real AdaptlyPost wiring with retry/backoff; DRY_RUN still writes adaptlypost-draft.json locally.
  • lib/publish/meta-ads.ts — Meta Ads draft builder + data/promotions.jsonl writer. Real Meta API call is a stub (calls into the meta-ads MCP layer when available).
  • lib/analytics/{meta,tiktok,youtube}.ts — DRY_RUN keeps deterministic synthetic data; non-DRY paths call Graph / TikTok Business / YouTube Data APIs.
  • lib/compliance/{generic,loader}.ts — executable cross-vertical audit, writes data/compliance/<piece>.json, escalates blocks to data/compliance-blocked/, exposes detectStreaks for the alerts module.
  • lib/skills/{humanizer,brand-voice}.ts — executable critic skills (regex pass
    • LLM secondary stub, voice-axis distance scoring).
  • lib/qa/tech-specs.ts — ffprobe/identify wrapper with filename fallback; per-platform validation against CHANNELS.md specs.
  • lib/observability/{cost,ab-report,failures}.ts — cost summary + HTML report, A/B per (task, provider) ROI table, failure-rate detector + webhook poster.
  • lib/schedule/cron.ts — cron / launchd install / uninstall / status helpers with marker block isolation.
  • CLI gains: new-piece, status, logs, cost, ab-report, alerts, sync, schedule. Each delegates to a TypeScript module via the bundled tsx runtime.
  • E2E coverage (Playwright) across all of the above: matrix parsing, fallback chain, policy retry/timeout/cost, pieces engine, init/scan/generate loop, promote loop, compliance, qa-tech-specs, observability, CLI surface.

Changed

  • lib/router.ts no longer hardcodes routing tables; everything resolves via lib/providers/matrix.ts.
  • lib/providers/{llm,image,video}.ts now contain real adapter classes that call concrete APIs. Mock variants live under lib/providers/__mocks__/ and the factory switches based on DRY_RUN.
  • bin/marketing-engine.mjs generate / promote are no longer placeholders.

Notes

  • All new external behavior is gated by DRY_RUN=true (the default) — CI never reaches real API endpoints.
  • The mock providers preserve the original deterministic output, so previously authored e2e specs continue to pass.

[0.1.0] - 2026-05-08

Added

  • CLI scaffold (bin/marketing-engine.mjs): init, scan, check commands.
  • Provider type interfaces (lib/providers/{types,llm,image,video}.ts) and mock implementations.
  • Publish + analytics scaffolds (lib/publish/adaptlypost.ts, lib/analytics/{meta,tiktok,youtube}.ts).
  • Specs tree under .specs/: architecture (DESIGN, PROVIDERS, ROUTING-MATRIX, ADR-001), product (BRAND, CHANNELS, COMPLIANCE, PERSONAS, PILLARS), piece + campaign templates, client _template/ overrides.
  • 11 SKILL.md documents under .skills/ (provider-neutral skills).
  • E2E suite (Playwright): CLI, compliance, caption-format, tech-specs, provider-router, AdaptlyPost-publish.
  • CI workflow + DoD workflow.
  • Remotion video explainer (PT-BR + EN) under video/.
  • Bilingual README + SETUP + CONTRIBUTING + AGENTS.md (charter) + Apache-2.0 LICENSE.