Commit Graph

11 Commits

Author SHA1 Message Date
peptiderepo
429703064d ci: install phpcsextra for WPCS 3.x Universal/NormalizedArrays sniffs
Agent-Session: cowork-ci-parity-20260414
2026-04-14 17:54:00 +07:00
peptiderepo
c85bfa32b4 ci: exclude .github/ from PHP 7.4 lint + fix PHPCS allow-plugins
Agent-Session: cowork-ci-parity-20260414
2026-04-14 17:40:56 +07:00
peptiderepo
f1d0ce4c75 ci: add dedicated CI workflow (lint + phpcs + phpunit) on PR and push
Tests existed inside deploy.yml but only ran on push to main, so PRs
got no validation signal. This adds a standalone ci.yml mirroring the
same 3 jobs, triggered on both pull_request and push to main. The
in-deploy validate job stays for belt-and-suspenders; remove it in a
follow-up if desired.

Agent-Session: cowork-ci-parity-20260414
2026-04-14 17:37:11 +07:00
peptiderepo
6c0cbe05d7 ci: reviewer cost cap + 3-model A/B harness (#3)
* ci: cost cap + 3-model A/B harness on CTO reviewer

Two enhancements to the PR reviewer:

1. Monthly spend cap: tracked in Repo Variables (CTO_REVIEW_MONTH,
   CTO_REVIEW_SPEND_CENTS, CTO_REVIEW_CAP_CENTS). Default cap $10/month.
   Auto-resets on month rollover. Posts a skip-comment on PRs when cap hit.

2. A/B harness: reviews every PR with 3 models in parallel
   (Claude Haiku 4.5, DeepSeek V3.1, Kimi K2 Thinking). Comment shows
   all 3 verdicts side-by-side so we can compare quality/cost on real
   PRs before picking a permanent default. Drop to 1 model by editing
   the MODELS list after A/B window closes.

Agent-Session: cowork-reviewer-ab-20260414

* ci: use CTO_ADMIN_TOKEN for repo variables + restore formal APPROVE/REQUEST_CHANGES

Default GITHUB_TOKEN cannot mutate Repository Variables (always 403).
Use a PAT-backed secret CTO_ADMIN_TOKEN for the budget counter steps.
Also restores formal APPROVE/REQUEST_CHANGES verdicts now that repo
setting can_approve_pull_request_reviews is enabled.

Agent-Session: cowork-reviewer-ab-20260414

* ci: address review feedback — per-model timeout + simpler cost math

- Per-model timeout of 60s so one hung model does not block siblings
- Simplify cost_cents math (cost_usd * 100 directly, no double-rounding)

Defer: fine-grained PAT for CTO_ADMIN_TOKEN (requires manual OAuth device flow).

Agent-Session: cowork-reviewer-ab-20260414

* ci: stop exposing CTO_ADMIN_TOKEN as env var (security cleanup)

Pass the PAT only via github-token param. continue-on-error on the
budget step so a missing/expired secret degrades gracefully instead
of failing the whole workflow.

Agent-Session: cowork-reviewer-ab-20260414
2026-04-14 17:35:05 +07:00
peptiderepo
258da29ab7 ci: post CTO review as COMMENT instead of APPROVE (#2)
GITHUB_TOKEN cannot formally approve PRs without a repo setting toggle.
Verdict is still prominent in the first line of the review body, and
the human merges based on reading it — no behavior loss.

Agent-Session: cowork-reviewer-fix-20260414
2026-04-14 16:53:12 +07:00
peptiderepo
48f3119820 ci: add review gate (tripwire audit + Claude auto-review via OpenRouter) (#1)
* ci: add main-push audit tripwire

Flags direct pushes to main that did not come from a merged PR.
Free-plan workaround since branch protection requires GitHub Pro.

* docs: add Git Workflow section to CONVENTIONS.md

Documents the PR-gated review process enforced at the agent layer.
Free-plan workaround since branch protection requires GitHub Pro.

* ci: add Claude-powered CTO PR review workflow

Auto-reviews every PR with Claude Haiku 4.5 and posts a structured
review (APPROVE / REQUEST_CHANGES / COMMENT). Does NOT auto-merge — a
human still clicks Merge. Requires ANTHROPIC_API_KEY secret on the repo.

* ci: switch CTO reviewer from Anthropic direct to OpenRouter

Reuses the OPENROUTER_API_KEY secret that already backs the other AI
plugins. Consolidates AI spend on one bill. Model: anthropic/claude-haiku-4.5.
2026-04-14 16:45:47 +07:00
Terence Ong
ff8d8d4166 fix: combine composer global require calls in deploy workflow
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-13 09:09:42 +07:00
peptiderepo
b21d102afb feat: v0.2.2 — CI hardening, remove dead stubs, strengthen tests
Address CTO audit findings for PRAutoBlogger:
- CI pipeline now runs PHPCS (WordPress standards) and PHPUnit before deploy
- Removed TikTok/Instagram/YouTube stub providers (dead code, not registered)
- Rewrote PublisherTest with real behavioral assertions (post_status, metadata,
  taxonomy, log linking, hooks) instead of method-existence checks
- Added cross-system LLM budget coordination docs to ARCHITECTURE.md
- Bumped version to 0.2.2

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-12 22:41:10 +07:00
peptiderepo
726b378a52 feat: v0.2.0 — PullPush.io admin UI, version bump, deploy fix
- Remove Reddit OAuth fields (Client ID/Secret) from admin settings
- Add source status indicator showing PullPush.io + .json fallback health
- Add configurable cache TTL, time window, and posts-per-subreddit settings
- Update Test Connections to report which Reddit source is active
- Bump version 0.1.0 → 0.2.0 across plugin header, constant, and readme
- Switch deploy pipeline from zip/REST API to SSH rsync with --delete
- Add LiteSpeed cache purge step to prevent stale OPcache after deploy
- Update CHANGELOG.md and readme.txt for 0.2.0 release

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-12 10:59:35 +07:00
Terence Ong
88d674d679 Initial commit: PRAutoBlogger v0.1.0 with frontend posts widget 2026-04-10 23:33:42 +07:00
Terence Ong
68c6f67bcf Initial commit: AutoBlogger v0.1.0
WordPress plugin that auto-researches topics from Reddit, generates
SEO-optimized articles via OpenRouter LLMs, runs them through a chief
editor agent, and publishes on a daily schedule.

Includes:
- Full generation pipeline (collect → analyze → score → generate → review → publish)
- Cost tracking and budget enforcement
- Admin UI: settings, review queue, metrics, activity log
- CI/CD pipeline (GitHub Actions → WordPress REST deploy)
- Unit test suite (PHPUnit + Brain Monkey)
- Structured logging with configurable verbosity

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-10 16:10:27 +07:00