@croutons-agent/cli
v0.1.0
Published
Drop-in CLI for the Croutons SEO agent: crawl/inventory audit, Dev UI, wired to the main croutons-seo-agents package.
Downloads
152
Maintainers
Readme
@croutons-agent/cli
NPM entry point for the Croutons SEO agents (croutons-seo-agents/): same Python codebase the monorepo uses, vendored into vendor/croutons-seo-agents when you publish this package (prepack runs scripts/sync-croutons-vendor.mjs from the repo root).
How it connects to “main croutons”
| Piece | Role |
|--------|------|
| Source of truth | croutons-seo-agents/ at the repo root (Python: Dev UI, PSE curator, page audit, apply pipeline). |
| This package | Ships a snapshot of that folder under vendor/ so npx @croutons-agent/cli works outside the monorepo. |
| npm run prepack | Refreshes vendor/ from root croutons-seo-agents/ — run before npm publish. |
To update the published CLI, change Python in croutons-seo-agents/, then from packages/croutons-cli:
npm version patch
npm publish --access public(Use your npm org scope; rename "name" in package.json if @croutons is not yours.)
Commands
croutons init— writescroutons.config.jsonin the current repo (editpublicSiteUrl).croutons init --unpack— copies the vendored agent into./croutons-seo-agents(consumer repos without the monorepo).croutons audit— deterministic URL inventory + SEO issues →.croutons/last-audit.json(callsaudit_cli.py).croutons devui—python3 app.pyfrom the agent root (OpenAI.envetc. unchanged).
Override agent location: CROUTONS_AGENT_ROOT=/path/to/croutons-seo-agents.
Monorepo dev
From the website repo root, install workspaces and run the local bin against this tree (no vendor needed):
npm install
npx croutons agent-path
# …/your-website.com/croutons-seo-agentsPython setup
The agent is still Python 3 + requirements.txt. After --unpack:
cd croutons-seo-agents
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
cp .env.example .envThen croutons devui from the site repo (CLI finds croutons-seo-agents by walking up from cwd).
