Primary guide for AI agents working on the PageSeeds CLI project.
PageSeeds CLI is an open-source automation toolkit for:
- SEO research and content operations
- Reddit opportunity search and engagement workflows
- Deterministic utility automations with agent-assisted workflows
Design goal: Provide a complete, installable tool (pageseeds) that users can install via uv/pip and use to manage their website automation workflows.
pageseeds-cli/
├── packages/
│ ├── automation-cli/ → Core automation commands (reddit, gsc, posthog)
│ ├── seo-cli/ → SEO research tools (ahrefs, keywords)
│ └── seo-content-cli/ → Content lifecycle operations
├── dashboard_ptk/ → Interactive TUI + orchestration engine
└── .github/skills/ → Workflow knowledge source of truth
Command entry point: pageseeds (unified CLI)
Execution context: Target repos under .github/automation/
Users install PageSeeds CLI in their workspace:
# Using uv (recommended)
uv tool install git+https://github.com/fstrauf/pageseeds-cli
# Or using pip
pip install git+https://github.com/fstrauf/pageseeds-cliThen configure in their target website repos:
cd /path/to/website
git init # if not already a git repo
pageseeds automation repo init --site-id my-siteUse this model whenever two agents collaborate on work in this repo.
Responsibilities:
- Clarify objective, constraints, acceptance criteria
- Define interfaces and boundaries before edits
- Identify migration and rollback implications
- Produce decision-complete change plan
Must deliver:
- scope
- affected files/modules
- invariants to preserve
- test/verification plan
Responsibilities:
- Execute against the plan
- Keep changes minimal and cohesive
- Preserve backward compatibility unless explicitly changing schema/contracts
- Validate behavior with tests/checks
Must deliver:
- working code
- updated docs
- verification results
- known limitations
Before coding handoff, Agent A provides:
- exact modules to create/modify
- expected data contracts
- success/failure behavior
- test scenarios
After implementation handoff, Agent B provides:
- what changed
- what was verified
- residual risks
-
Skills are source of truth.
- Workflow logic belongs in
.github/skills/*/SKILL.md. - Prompts are launchers, not full workflow specs.
- Workflow logic belongs in
-
Never push or commit on behalf of the user.
- Do NOT run
git push,git commit,git add,git checkout -b, or any command that creates branches, commits, or pushes to a remote. - File edits are made to the working tree only. The user commits and deploys when ready.
- Do NOT run
-
Deterministic steps use CLIs.
- Prefer explicit
pageseeds automation seo ...,pageseeds reddit ...calls. - Avoid shell parsing pipelines for core logic.
- Prefer explicit
-
Agentic steps must be observable.
- Persist raw agent output artifacts.
- Normalize to structured artifacts deterministically.
-
Secrets stay machine-local.
- Use env vars or
~/.config/pageseeds/secrets.env. - Never embed keys in repo files.
- Use env vars or
-
No mock data unless explicitly requested.
-
One content-dir resolver.
- Use
dashboard_ptk/dashboard/engine/content_locator.pyfor content directory discovery. - Do not reimplement candidate path scans in UI/runners/utils.
- Project
content_diroverride must take precedence when valid.
- Use
-
No direct subprocess outside engine.
subprocess.runis only allowed indashboard_ptk/dashboard/engine/*.- UI (
dashboard/cli.py) and task runners must call engine services/tool registry instead.
-
Date edits must be frontmatter-safe.
- For markdown date fixes, update YAML frontmatter deterministically first, then sync task metadata/JSON.
- Do not use broad regex replacements that can modify body content.
- Dashboard orchestration:
dashboard_ptk/dashboard/engine/ - Dashboard UI shell:
dashboard_ptk/dashboard/cli.py,dashboard_ptk/dashboard/batch.py - Task runners:
dashboard_ptk/dashboard/tasks/ - Task persistence/schema migration:
dashboard_ptk/dashboard/storage/,dashboard_ptk/dashboard/engine/task_store.py,dashboard_ptk/dashboard/engine/migration.py - CLI implementations:
packages/*/src/ - Workflow knowledge:
.github/skills/
- Define capability and acceptance criteria.
- Decide deterministic vs agentic split.
- Add/extend deterministic CLI command first (if needed).
- Wire orchestration in dashboard engine workflows.
- Add/update task schema mappings only when required.
- Add tests for:
- migration/compatibility (if schema touched)
- deterministic execution path
- normalization behavior (if agent output used)
- Update docs in place (
AGENTS.MD,ARCHITECTURE.md, dashboard guide).
- Preserve task state compatibility by default.
- If schema changes, provide migration + backup + rollback behavior.
- Keep UI behavior stable unless change is intentional.
- Do not introduce parallel/duplicate runtime paths.
- one canonical execution path through
dashboard/engine
- one canonical execution path through
- If project setup/validation behavior changes, update preflight checks and interactive fix paths together.
- No secrets added
- No hardcoded absolute machine paths in runtime logic
- Deterministic calls go through centralized tool execution
- Agent outputs are persisted and normalized when structured results are required
- Docs updated in existing files (no duplicate guidance)
- Tests executed and reported
test_no_subprocess_outside_engine.pypasses- If content directory logic changed:
test_content_locator.pyandtest_project_preflight.pyupdated/passing - If date-fix logic changed:
test_frontmatter_dates.py(and affected workflow tests) updated/passing