Commit Graph

21 Commits

Author SHA1 Message Date
Auree Aubert bf23619313 Stop documenting the first-party enrichment provider (#122)
* Stop documenting the first-party enrichment provider

Its playbook, its 21 priced actions, and every recipe step that led with it
are removed. Each one now leads with the rung the pack already named as its
fallback, so nothing here is invented — the replacements were sitting in
stage-action-map.md and alternatives.md the whole time.

The substitutions:

    firmographics   aiArk.enrichCompany (0.01) -> companyEnrich (0.25) -> waterfall (1)
    person          aiArk.enrichPerson (0.1) -> waterfall.enrichContact (2)
    funding         enrichCrm.getFunding (1), now the catalog's only one
    technographics  builtwith.getDomainSummary (free) -> enrichDomain (1)
    dedupe          free storage query against the workspace's own models

That last line is the one worth reading twice. The match actions existed to
mint an id the other actions required; every replacement keys on the domain
or a LinkedIn URL, so a step that cost 0.5/record now costs nothing.

The event feed has no replacement and the recipes say so. fetchBusinessEvents
took a timestamp_from and nothing else in the catalog does, so funding-watch,
re-engagement and lost-deal-revival are rewritten as a diff: re-pull, compare
against the stored round date, keep what moved. Cadence becomes the only cost
dial, which is why funding-watch's default drops from daily to weekly.

Every credit budget was recomputed rather than relabelled:

    build-tam        2,955 -> 2,210   (500 companies + 1,500 contacts)
    prospecting P2     821 ->   107   (200 verified prospects)
    icp-discovery      602 ->   204   (200 deals)
    context bootstrap    3 ->     1

Catalog counts now follow the generated data file rather than the older
hand-kept figure: 136 integrations, 176 credits-based actions of 513.

Also bumps the CLI pin 1.0.66 -> 1.0.78.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019wkwbhrEoE5KW9A1CKBmcA

* Fix the three generated artifacts the removal invalidated

CI caught what the local lint could not: skills-lint.mjs is only one of five
checks, and the other four all had something to say.

llms.txt was stale — it is generated from the skill descriptions, and
cargo-gtm's dropped a provider from its roster.

The codex package build enforces override version == upstream version, so
bumping only .github/package-overrides/cargo-quickstart.SKILL.md to 1.0.3 broke
it. The guard exists to stop the override silently shipping last month's demo,
so the fix is to bump both, not to revert the override.

That build also patches literal source strings at package time, and one anchor
ran through a line this branch rewrote:

    snitcher.searchSessions (0 cred) -> cargo.matchProspect
    snitcher.searchSessions (0 cred) -> aiArk.reverseLookup (0.05)

The edit strips the visitor-de-anonymisation path from the packaged skill, so a
silent miss would have shipped it. Re-anchored, and every other PACKAGE_EDITS
find string verified against the tree — 1 broken, now 0.

Also drops the packaged cargo-connection description from 138 integrations to
136, matching the repo.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019wkwbhrEoE5KW9A1CKBmcA

* Say where revenue went, and that employee ratings went nowhere

Removing the provider took two data points off the map without replacing the
map entry, which is the failure mode this recipe's own feasibility gate exists
to prevent: an attribute that quietly stops being answerable reads the same as
one nobody asked for.

They are not the same case, so they get different rows.

Revenue and NAICS survive. companyEnrich.enrichByDomain (0.25) returns them in
the same call as firmographics, employees, funding and socials — so it fills
several rows at once and the row says that, because the per-account arithmetic
in step 4 gets it wrong otherwise.

Employee ratings have no successor at any price. Nothing credits-based in the
catalog returns Glassdoor-style employer reputation. The row says none, and
says to report it as a research note rather than substituting a scrape that
reads like the real thing — which is the recipe's stated position on valuable
attributes with no obtainable source, applied to itself.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019wkwbhrEoE5KW9A1CKBmcA

* Fix the data-flow breaks the provider swap left behind

Bugbot found eight, all real, and verifying them turned up five more. The
pattern in every case is the same: I replaced an action but left the code that
consumed its output reading the old response shape, so the step still runs,
still bills, and quietly returns nothing.

Response-shape breaks:

  funding-watch      Pattern A still filtered funding_rounds[].announced_date
                     while Pattern B read lastFundingDate. The 90-day select
                     matched nothing, so the primary path returned an empty
                     list after a paid pull.
  re-engagement      Step 5 read .results[] and .events[] from a file step 3
                     now writes as a bare array. Funding branch always empty.
  lost-deal-revival  Step 4 read .events[0] and expected a deal_id that
                     getFunding does not return. Step 3b now carries deal_id
                     through, which is the only place it exists.

Wrong-source breaks:

  re-engagement      The diff read last_funding_round_at off the Contacts
                     segment. It is a Companies column, so the stored date was
                     always empty and every account re-flagged every week. Now
                     queries the Companies model, and fans the company-level
                     signal back out to contacts, since step 5 unions on email.
  build-tam          Step 4 keyed searchLeads on .linkedinId from the
                     aiArk.enrichCompany output. No enrichment action returns a
                     Sales Navigator accountId. Now carried from the sourcing
                     step, with an explicit gate for rows that have none.
  guide              snitcher.searchSessions identifies a COMPANY; I had
                     chained it into aiArk.reverseLookup, which needs an email
                     or phone. Its own playbook says to route identified
                     domains through the enrich chain.

Budget break:

  prospecting        P2 step 5 ran FullEnrich over every lead while the budget
                     quoted the residue. 200 credits against 60. P1 had the
                     gate; P2 did not.

Pre-existing, fixed because the fixes above sit inside them:

  icp-discovery      [.[] | {domain}] over storage query execute output, which
                     is {rows: [...]}. Enriched one null domain, not 200.
  jq inputs[N]       `inputs` is a generator, not an array, so the union
                     expressions in re-engagement and lost-deal-revival errored
                     out. Slurped to [inputs] as $in.

Every rewritten jq expression was run against fixtures rather than eyeballed.

Also five provider mentions the sweep missed, because they wrote it as bare
`cargo` with a price rather than cargo.actionName: societeInfo, snitcher,
enrichCrm, linkedin, oceanio, apolloio, rocketreach.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019wkwbhrEoE5KW9A1CKBmcA

* Make funding-watch Pattern B stand on its own

It re-pulled two hardcoded example domains and then diffed them against
/tmp/targets.json, a Pattern A artifact. Run Pattern B alone and the slurp
fails; run both and it compares a fresh pull of one set against stored dates
for a different set, so the "new round" filter cannot fire correctly either way.

Both sides of a diff have to come from the same query. Now they do: one storage
read supplies the domains to pull *and* the stored dates to compare against, so
the sets align by construction and the pattern has no cross-dependency.

Also states what a missing stored date means — it compares against "" and always
passes, which is right on a first run and is exactly why the write-back step is
not optional. Without it every run is a first run and the watch re-flags the
whole segment forever.

Verified against fixtures: an account whose round moved is kept, one whose
stored date already matches is dropped, one with no stored date passes.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_019wkwbhrEoE5KW9A1CKBmcA

* Route the questions people ask but the map never answered (#124)

Measured instead of guessed. Of the 176 credits-based actions, 148 were
reachable from a routing surface — the stage map, the phase guides,
alternatives.md, a recipe. The other 28 were reachable only from their own
provider playbook, which is findable if you already know which provider to
open. That is the wrong way round.

The worst of it: headcount had no section at all. It is the most-asked company
attribute and the first row of the custom-datapoints feasibility gate, and not
one of the four salesNavigator.find* actions appeared anywhere in the stage map.
New section carries all four, plus the only historical series
(companyEnrich.getWorkforce), plus linkedin.findCustomHeadcount for the roles
the fixed buckets don't have, plus the companyId prerequisite that quietly
turns a 0.25 action into 0.30 on a list that arrived without one.

"Who works at this domain" was not a documented question either. It is not the
same as searching a population by title, and it has two answers at very
different prices. New section, with the trap stated: looping hunter.searchDomain
to build a list is the pitfall its own playbook warns about.

Also adds rocketreach, mixrank and societeInfo to Enrich/Sourcing —
societeInfo reaches French registry data (NAF code, collective agreement,
filed accounts) that nothing else in the catalog does — and gives Hiring intent
a second index at the same price.

154/176 now. The remaining 22 stay unrouted on purpose, and the CHANGELOG says
why for each: the four LinkedIn engagement actions would undercut the
acceptable-use refusal to batch-blast them, three natives belong to other
skills, searchLeadsLegacy costs 300x its replacement, and the rest are finer
grain on an already-routed surface rather than separate questions.

One thing the build caught: adding aiArk.analyzePersonality re-introduced a
term the codex package deliberately strips, since the directory rejected
person-level inference. Kept for the channels that carry it, with matching
PACKAGE_EDITS so the package still removes it. Dropped the forager rung rather
than add machinery for a last-resort action priced 20x above its own chain.
All 67 anchors verified.


Claude-Session: https://claude.ai/code/session_019wkwbhrEoE5KW9A1CKBmcA

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-09-02 16:40:18 -07:00
Auree Aubert be823b3fcb Generate the cost table, and stop omitting the native actions (#111)
* Generate the cost table, and stop omitting the native actions

The credits price list was hand-kept. The first attempt to generate it read
`connection integration list`, which is connector-only — so its own header
claimed "every credits-based action in the cargo catalog" while silently
omitting every billed native action:

    sendEmail    0.1   fixed
    modelAsk     0.5   fixed
    fileSearch   0.02 / 1k tokens

`sendEmail` is the whole outbound send path, priced at 0.1 in the mailbox
skill, and it was absent from the canonical price list.

It is now generated by `cargo-ai orchestration action cost-table --raw`
(getcargohq/cargo#5641), which lives beside `action list` and `action execute`
— the surface that spans connector, native, tool and agent. 197 credits-based
actions of the 534 the catalog exposes, up from the 145 the hand-kept table
claimed and the 194 a connector-only generator found.

What the hand-kept table got wrong, now that a generated one can be diffed
against it: 145 actions where there are 197, four prices quoted from memory,
and cost columns that concatenated every tier into an unreadable comma list —
`openAi.instruct` rendered 28 numbers. Per-config pricing moves to its own
section.

Two providers gain playbooks rather than staying unlisted: brightData
(Instagram/TikTok/Facebook/YouTube by URL, the catalog's only non-LinkedIn,
non-X social coverage) and proxycurl. An undocumented provider still shows up
in the cost table, so the acceptable-use framing is better stated than implied;
brightData.md opens with the consumer-targeting refusal that gates it. Only
openRouter remains without a playbook, and it has no credits-based actions.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TBfa73ishJJRe4pccyhTAa

* Pin the CLI at 1.0.66, and fix five commands that never existed (#117)

* Pin the CLI at 1.0.66, and fix five commands that never existed

The pin had drifted 19 releases behind npm, and the bundle now teaches
`orchestration action list`, which only exists in 1.0.66. The pin is what the
session-start refresh installs, so leaving it meant an agent following these
skills would reach for a command its CLI did not have.

Checked before moving it, not after: the CLI's whole command surface was diffed
across 1.0.47..1.0.66. The only removals are three billing commands no skill
documents; `update-payment-method`, which the skills do use, replaced one of
them and is still there. Everything else in the range is additive.

That verification then turned up five documented commands that do not exist —
and all five were already broken at the old pin, so this is old debt the bump
surfaced rather than caused:

- `orchestration draft-release {get,update,deploy}` (18 sites) is really
  `orchestration release {get-draft,update-draft,deploy-draft}`.
- `ai template get <slug>` (6 sites) does not exist. `ai template list` already
  returns each template in full, so the fix is to filter that response.
- `action execute --record` (5 sites) is `--data`.
- `storage model list --dataset-uuid` (4 sites): the command takes no options
  at all, and every model carries `datasetUuid`, so filter client-side.
- `storage model get-ddl --model-uuid <uuid>` takes the uuid positionally.

Also folds in the skills half of getcargohq/cargo#5740: `get-output-schema`
takes an action plus an optional `--data` rather than demanding a `config`, so
the object `action list` returns now pastes into all four action commands
unchanged. The gotcha row about the 400 becomes a note about `--data`, which is
the part worth knowing.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TBfa73ishJJRe4pccyhTAa

* Mark --data on get-output-schema as CLI >= 1.0.67

getcargohq/cargo#5740 ships --data in CLI 1.0.67, one above the pin this PR
sets. The config-less --action works on the pinned 1.0.66 as soon as that
backend deploys; --data needs the next release, so it carries a version marker
like every other post-pin flag in the bundle.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* Document the execution charge the pack said did not exist (#118)

Every node execution bills 0.01 credits (1 per 100) — structural natives
and errored executions included. Three places in the pack said otherwise,
and they reinforced each other:

- troubleshooting.md described executions[].creditsUsedCount as "native
  nodes are zero", accurate about the field but read as pricing;
  play-optimize-credits.md restated it and cited it as the authority.
- The generated cost table prices actions, and structural natives are
  excluded from `action list` entirely, so branch/filter/switch/variables
  appear in no price list here — read as free.
- cargo/SKILL.md said "Everything else is free" outright.

Verified live: `billing usage get-metrics --unit orchestration.executions`
returns success/error as execution counts, reconciling row-for-row with
`SELECT execution_status, count() FROM spans`. spans.execution_credits_used_count
reads 0 on natives that billed, so the charge is attributed to no node and
per-node profiling under-counts every graph.

Two adjacent bugs fixed while verifying:

- `--unit credits` was documented and 400s. The flag takes exactly
  billing.credits | orchestration.executions | storage.records, and with
  no --unit all three interleave in one items[] array with different
  meanings for `count`.
- The example slugs `enrichment` / `ai_message` were invented (real:
  integration.<slug>.action.<action>, native.<action>, success/error,
  insert), as was `.totalUsage` — the response has one key, `metrics`.

Estimates now carry two terms: (provider cost × records) + (nodes ×
records / 100), measured on the pilot rather than inferred from the graph.

cargo-billing 1.1.0 -> 2.0.0 (agents relearn --unit and the slug shapes),
cargo-orchestration 1.11.0, cargo-gtm 1.19.0, cargo-diagnostics 1.4.0,
cargo 1.24.0 + the three plugin manifests.

Still upstream: `orchestration action cost-table` generates the header
"The other 337 actions ... cost no credits" — unfixable from this repo.


Claude-Session: https://claude.ai/code/session_01AbUvyTQMDABiexZgQCsGoe

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>

* Source the cost table from action list, not a bespoke generator

`orchestration action cost-table` is being removed from the CLI: it read
`action list` twice and added no data, and the markdown it generated was
its only consumer. `action list` already returns a `credits` array on every
billed action, so the table is regenerated from that directly.

Regeneration is now two calls (`--kind connector`, `--kind native`) plus
the three cost shapes documented in the header, so a reader can render the
table without the generator's price-formatting logic. Notably `fixedCost`
adds to the metered rate rather than replacing it — the trap that made a
0.175 + 0.025/item search read as 0.025.

Two fixes that fall out of owning the header again:

- The opening line claimed the other 337 actions "cost no credits". True
  of provider price, false of anything that runs in a workflow. It was
  flagged as unfixable while the CLI generated it; it now states no
  *provider* price and points at the execution charge.
- `stage-action-map.md` still carried 194/310 from the connector-only
  generation, against 197/337 everywhere else.

Co-Authored-By: Auree Aubert <16732193+aureeaubert@users.noreply.github.com>
Co-Authored-By: replicas-connector[bot] <replicas-connector[bot]@users.noreply.github.com>

Co-authored-by: Auree Aubert <aureeaubert@users.noreply.github.com>

* Fix PACKAGE_EDITS patterns to match regenerated cost table format

Co-authored-by: Auree Aubert <aureeaubert@users.noreply.github.com>

* Add PACKAGE_EDITS rule to remove extractEventAttendees from stage-action-map.md

Co-authored-by: Auree Aubert <aureeaubert@users.noreply.github.com>

---------

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
Co-authored-by: replicas-connector[bot] <replicas-connector[bot]@users.noreply.github.com>
Co-authored-by: Auree Aubert <aureeaubert@users.noreply.github.com>
Co-authored-by: Cursor Agent <cursoragent@cursor.com>
2026-09-01 16:28:25 -07:00
Auree Aubert aead4ddc20 Search for actions, and config stopped shouting (#115)
* Cargo has a first-party MCP, and `config` stopped shouting

Tracks the platform-MCP branch in the CLI repo: a first-party MCP server at
`/mcp`, a new `orchestration action list`, and `config` split off the top-level
action type. Two of those three contradict sentences this bundle stated as fact.

- The router, `cargo-ai`, and the glossary all said there is no first-party
  Cargo MCP server. There is one now, at `mcp.getcargo.io/mcp`, with a fixed
  operate-the-workspace toolset. Both surfaces — platform and curated — are
  documented, and the routing rule they exist for is unchanged.
- `cargo-ai mcp` with no `--server` now bridges the platform MCP rather than
  resolving "the workspace's only MCP server". Same command, different server
  by CLI version, so it is in the gotchas table.
- New `orchestration action list <keywords>`: free, searches connector, native,
  tool, and agent actions in one call, and returns a ready `action` object with
  `connectorUuid` resolved plus the action's credit costs.
- `config` is optional on execute/execute-batch and still required on nodes,
  alerts, play health actions, and get-output-schema. The dangerous half is the
  deleted guard: misplaced inputs are now dropped silently and the action runs
  with none.
- Nine documents were telling agents to do exactly that. The four LLM playbooks,
  the prompt-library index, and three GTM recipes put `model`/`advancedSettings`/
  `output` (or `customerId`, `spreadsheetId`) in the action's `config`; all now
  put inputs in `--data`/`--records`. The ads recipe also loses two
  `execute-batch --model-uuid --filter` calls against flags that do not exist.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TBfa73ishJJRe4pccyhTAa

Co-authored-by: Auree Aubert <aureeaubert@users.noreply.github.com>

* Drop `config` from every top-level action, and lead with action search

The platform-MCP work shipped while this PR was open — CLI 1.0.66 is on npm and
the platform MCP answers at mcp.getcargo.io/mcp — so the hedging this branch was
written with ("newer backends accept…", "stays valid on any version") is now
just the rule.

- `config` is gone from 272 execute / execute-batch examples across 79 files.
  That is the shape `action list` returns, so a search result pastes straight
  into a run. Nodes, alert `--actions`, play `healthAlertActions`, and agent /
  MCP-server `--actions` keep theirs; the strip was scoped around them.
- `get-output-schema` is the exception and still requires `config` — verified
  live: the action object from `action list` fails 400 at `action.config`. The
  CLI's own help examples for that command omit it and therefore all 400. It is
  now a gotcha row, and those examples keep `"config": {}` on purpose.
- `connection action search` shipped in 1.0.36 and no skill had ever mentioned
  it. cargo-connection now opens with both searches and a table for choosing:
  `action list` by default, `action search` for `--credits-only` and
  `--category`. `integration list` / `integration get` drop to what they are
  good at — the integration, and the schema of an action already picked.
- Removed a phantom command: `connection integration list-actions` has never
  existed, and cost-discipline.md was recommending it as a free lookup.
- cargo-mcp gains the one config rule that surface needs: pass the action object
  as-is, never with a config — `get_action_schema` supplies the empty one, which
  makes MCP safer here than the CLI.

Verified against the live workspace at 1.0.66: a config-less `action execute`
returns status success at 0 credits, and `get-output-schema` without `config`
returns 400.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TBfa73ishJJRe4pccyhTAa

* Fix the strip's leftovers, and bump the router so it actually ships

An audit of the 272-example strip turned up one real defect and a set of
phrasings the strip left behind, plus a packaging bug that would have made the
router's half of this PR a no-op.

- `cargo/SKILL.md` was still at 1.22.0, the version main already publishes, so
  its 14 changed lines — including both new critical rules and both new gotcha
  rows — would have been skipped at publish. Bumped to 1.23.0, plugin manifests
  follow.
- `guides/writing-outreach.md` still declared the action shape as
  `integrationSlug + actionSlug + config: {}` directly above an example whose
  config had been stripped. Every sibling "Action shape" line had been rewritten;
  this one was missed.
- Seven places said the action's config "is empty" or "stays empty" where the
  rule is now that there is no config key at all. Normalised, including the
  deliberate contrast in cargo-observability, where alert actions do require one.
- The report template in cargo-workspace-management modelled the old shape in a
  copyable `action execute` string, and cited `config.portalId required` as the
  symptom. Both corrected.
- perplexity's `searchContextSize` is an input, not a "config cost lever" — the
  same rewrite had moved it into `advancedSettings` in `--records`.

Verified clean afterwards: no execute example retains a config, no
get-output-schema example lost one, no node/alert/agent/mcp-server action lost
one, and every JSON block still parses.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TBfa73ishJJRe4pccyhTAa

---------

Co-authored-by: Auree Aubert <aureeaubert@users.noreply.github.com>
Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-27 16:42:39 -07:00
Auree Aubert 8b36982db4 cargo-orchestration 1.7.0: draw the workflow (#100)
* cargo-orchestration 1.7.0: draw the workflow

Nothing in the bundle told an agent to show a node graph as a picture. The
only nudge was one line in interaction.md — "a compact node-flow sketch or
table beats prose" — which left the format to the model, so the plan gate
asked users to approve a graph they had to reconstruct from prose. Every
surface these skills print into renders Mermaid.

- references/node-diagram.md: when to draw one (plan gate, "what does this
  play do", trace reporting), when not to, the shape/edge mapping per node
  kind, cost marking, and the rules that make a diagram true.
- scripts/workflow-to-mermaid.ts: zero-dep TS (Node >= 22.18, 6 fixture
  cases) taking release get / get-draft / template get / an ad-hoc run get /
  a raw node array. Flags: --title, --direction, --paid, --highlight.
- Two doc defects found against a live workspace: release get's documented
  nodes[] was a {uuid, slug, name} summary of the full graph it actually
  returns, and run get carries nodes XOR releaseUuid depending on whether
  the run came from a deployed release.
- Node slugs are not unique within a release (six `variables` in one shipped
  waterfall), so anything walking the graph keys on uuid. Recorded as router
  gotchas, with the knock-on for {{nodes.<slug>...}} ambiguity.
- Call sites wired: plan gate and presenting defaults, router rules,
  nodes.md, the diagnostics trace runbook, and cdk plan.
- CI runs fixtures for every cargo-*/scripts/*.ts, not only cargo-gtm's.

Verified against CLI 1.0.52: every diagram in the reference is script output
from a real release, and each parses under mermaid 11.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* Move the diagram generator into the CLI

`cargo-ai orchestration node diagram` replaces the skill script the reference
was prototyped against. It belongs next to `node validate` — same input, same
free/runs-nothing character — and the sequence now reads validate → diagram →
deploy without leaving the CLI.

- scripts/workflow-to-mermaid.ts and its fixtures deleted; the CI fixture glob
  goes back to cargo-gtm/scripts/*.ts.
- node-diagram.md documents the command: one source per call (--nodes / --file
  / --workflow-uuid / --draft / --release-uuid / --run-uuid), the JSON shape,
  and reading `warnings` out loud rather than drawing over a broken graph.
- --run-uuid absorbs the nodes-XOR-releaseUuid split, so the diagnostics
  runbook no longer has to explain which kind of run it was handed.
- Requires CLI >= 1.0.54 (getcargohq/cargo#5580); the cli-version pin moves in
  the follow-up that ships with that release.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* Refresh skill-metadata content hashes after rebase

The rebase onto main took both sides of the version conflicts in cargo/SKILL.md
and cargo-orchestration/SKILL.md (this branch's 1.20.0 / 1.7.0, which stay ahead
of main's 1.19.2 / 1.6.3), which left the recorded contentHash in the two
skill-metadata.json files stale. Regenerated with skills-metadata.mjs --write;
skills-lint is back to 0 errors.

Co-Authored-By: Auree Aubert <16732193+aureeaubert@users.noreply.github.com>
Co-Authored-By: replicas-connector[bot] <replicas-connector[bot]@users.noreply.github.com>

---------

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
Co-authored-by: replicas-connector[bot] <replicas-connector[bot]@users.noreply.github.com>
Co-authored-by: Auree Aubert <16732193+aureeaubert@users.noreply.github.com>
2026-08-14 18:06:35 -07:00
Auree Aubert 0d3981a8b7 cargo-diagnostics 1.1.0: find the run when all you have is a symptom (#97)
* cargo-diagnostics 1.1.0: find the run when all you have is a symptom

`orchestration run list` requires --workflow-uuid and has no "most recent
run" form, and run-trace.md § 0 — the one place documenting how to find a
run — already assumed a workflow_uuid in hand. Asked to "look at the last
run", an agent has nothing to call and reports the node inputs/outputs as
inaccessible. They aren't: orchestration SQL over `runs` takes no filter.

- run-trace.md § 0 rewritten as a discovery ladder ordered by what the user
  hands you: no UUID (unfiltered `runs`), a company/domain (record_title
  ILIKE), a play by name (play list -> workflowUuid -> filter).
- Explicit instruction not to give up at `run list`, in the runbook and in
  the diagnostics routing section.
- Error rows for the discovery step, both hit while verifying against CLI
  1.0.52: `SELECT * FROM runs` exceeds the 50-column read cap (51 columns),
  and `runs` has no play_uuid / name / trigger-source column.
- States what the UI editor does not change: CLI, scheduled, and UI-triggered
  runs all land in `runs`. One that doesn't is a bug to report.
- Same caveat at the other two doors: cargo-orchestration troubleshooting
  and two rows in the router's gotchas table.

Every documented query was run against CLI 1.0.52 before being written down.
No CLI change needed — the surfaces existed, they just weren't reachable
from the question a user asks.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* Bump the Codex and Cursor manifests, regenerate skill metadata

The plugin version mirrors the router's, and .claude-plugin was the only one
of the three I bumped. Regenerates the three stale skill-metadata.json files
alongside it. skills-lint is clean locally.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-14 13:04:19 -07:00
Auree Aubert 8afa8ecd95 Close the ClawHub security-audit documentation gaps (cargo 1.18.2) (#84)
* Close the ClawHub security-audit documentation gaps (cargo 1.18.2)

The automated audit of the published bundle returned Review with five
findings. Three were real documentation gaps — places where the bundle
assumed the reader had the whole thing in context. No behavior changes.

- use-cases.md §6 opened on `token create` as a bare numbered step. The
  "shown once → secrets manager" rule lived in ~10 other files but not
  this one, so an agent loading only the use-cases reference never saw
  it. Added token handling, least-privilege scoping, and a confirm-first
  note on the steps that change who can access the workspace.
- README.md and cargo/SKILL.md now say what `curl … install.sh | sh`
  actually is, how to read it first, and the by-hand equivalent.
  sessions.md already pointed at the installer source; the two
  more-read files did not. The router also tells the agent never to run
  it on the user's behalf without asking.
- "Why the pin" now documents cli-version as the reason session-start
  refresh is not a blind auto-update, tells the agent to surface a
  global npm install rather than doing it silently, and marks the pin
  read-only.

The other two findings need no change: the flagged egress is the
product's own API, and the script-fetching match is the same installer.

Plugin manifests bumped in lockstep (linter enforces they mirror the
router). skills-lint clean, llms.txt and trigger slugs in sync, routing
evals 81/81 core.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* Make the audit response survive an actual audit

Review of the 1.18.2 branch found the trust paragraph pointing readers at
`apps/backend/src/http/routes/install.sh` in `getcargohq/cargo` — a private
repo. Every external reader following that gets a 404, from the one paragraph
whose entire job is making `curl | sh` auditable. Removed from README.md and
cargo/SKILL.md; neither now sends anyone somewhere they cannot go.

`curl … | less` followed by `curl … | sh` is two fetches, and the server can
serve different bytes to the second, so reading first guarantees nothing about
what runs. Replaced with download-once-then-execute in both files.

The use-case gate named the wrong steps: step 9 is `folder create` (no access
change) and step 2 is `role list` (read-only). The steps that actually grant
access are 1 (`token create`) and 3 (`user create`), so an agent was pausing on
a benign organizational step and skipping a credential mint.

Also: README pointed "below" at the plugin install, which is above it — now an
anchor link; and cargo-workspace-management/SKILL.md still inlined the bare
pipe-to-shell command the rest of this change set was written to caveat.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-12 15:36:31 -07:00
replicas-connector[bot] 8ec848ca0f fix(cargo-orchestration): trigger plays with kind "filter", not the generated segment (#68)
* fix(cargo-orchestration): trigger plays with kind "filter", not the generated segment

Every play-triggering example told the agent to take `segmentUuid` from
`play list` and pass it to `batch create --data '{"kind":"segment",...}'`. That
UUID is the play's internally generated segment, whose record count is never
populated, so the batch is always rejected — as `segmentLinkedToPlay`, or as a
misleading `noRecords` on older backends that sends you off debugging a filter
that was never the problem.

This matters more here than in the hosted docs: agents driving the CLI emit these
commands automatically, so the broken recipe fails without a human ever reading
it. A customer hit exactly this and lost most of a day to it.

Switched every play example to `{"kind":"filter","modelUuid":"<play.modelUuid>"}`,
which queries the model directly with no record-count gate and enrols every row
by default.

`{"kind":"segment"}` itself is fine and is left documented — it takes a
standalone segment from `segmentation segment list`. Only the instruction to feed
it a play's generated segment was wrong, so the distinction is now spelled out
rather than the kind removed.

`references/filter-syntax.md` is untouched: its `kind: "segment"` is a filter
condition, unrelated to batch data kinds.

Bumps cargo-orchestration 1.5.1 → 1.6.0 and cargo 1.15.0 → 1.16.0, since
ClawHub publish skips skills whose version is unchanged.

Co-Authored-By: Auree Aubert <16732193+aureeaubert@users.noreply.github.com>
Co-Authored-By: replicas-connector[bot] <replicas-connector[bot]@users.noreply.github.com>
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>

* chore: regenerate skill-metadata.json after rebase

Co-authored-by: Auree Aubert <aureeaubert@users.noreply.github.com>

* fix: include filter property in kind=filter examples

All batch create examples with kind='filter' now include the explicit
filter property. An empty filter {'conjonction':'and','groups':[]}
matches all rows in the model.

Co-authored-by: Auree Aubert <aureeaubert@users.noreply.github.com>

---------

Co-authored-by: replicas-connector[bot] <replicas-connector[bot]@users.noreply.github.com>
Co-authored-by: Auree Aubert <16732193+aureeaubert@users.noreply.github.com>
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: Auree Aubert <aureeaubert@users.noreply.github.com>
2026-08-12 10:51:02 -07:00
Auree Aubert 3708f8c955 Agent discoverability: trigger-shaped descriptions, routing evals, standalone bootstrap (#77)
* Agent discoverability: trigger-shaped descriptions, routing evals, standalone bootstrap

The `description` field is the only text an agent weighs before deciding
whether to load a skill. Everything else in the bundle is invisible until
that decision is already made — and twelve of the seventeen descriptions
read as "Manage <CLI nouns> using the Cargo CLI", which matches a user who
is already thinking in Cargo's object model rather than one stating a job.

This rebuilds that layer and, for the first time, tests it.

Routing
- Every description rewritten to a four-part template: job in the user's
  words -> literal quoted trigger phrases -> proper nouns -> an explicit
  `Skip when:` pointing at the sibling skill that owns the adjacent case.
- Integration and provider names are generated, not hand-maintained.
  sync-trigger-slugs.ts fills cargo-gtm's `Providers:` list from the
  playbook tree and cargo-connection's `Integrations:` list from a
  committed catalog snapshot (138 integrations, 50 credits-based).
  `--refresh` re-pulls from a logged-in CLI; `--check` gates CI.
- evals/routing.jsonl (92 prompts) + routing-eval.ts, wired into CI.
  Structural tier asserts the template and that each skill keeps >=5 terms
  unique to it; lexical tier requires the expected skill to rank first;
  an opt-in --llm tier asks a real model to route from descriptions alone.
  Deep paraphrases are tagged "hard" and reported rather than gated — a
  lexical proxy cannot judge them fairly.

Standalone installs
- `skills add --skill <one>` is a supported path and the registry lists
  each skill separately, but thirteen skills' only install instructions
  were a relative link to ../cargo/references/prerequisites.md, which does
  not exist in a single-skill install. Every SKILL.md now has a
  self-contained Bootstrap section, enforced by the linter.

Coverage
- New capability skill cargo-segmentation — the segmentation CLI domain,
  previously uncovered while segments were load-bearing in most recipes.
  Verified against the live CLI, including the flag traps.
- Three cargo-gtm recipes: source-planning (probe and cost candidate
  sources per *hit* before any fan-out), ads-audience-activation (Google
  Customer Match / LinkedIn Matched Audiences), review-and-iterate (human
  review of judgment output, kept as an eval set).
- Router gains a "these skills vs a workspace MCP server" section: Cargo
  has no first-party MCP server — a workspace builds one and serves it
  over `cargo-ai mcp` — so the routing rule is scale and reproducibility.

Index and hygiene
- llms.txt now lists every recipe and provider playbook with a generated
  summary: 17 entries -> ~80 job-named addressable URLs.
- Router trimmed ~80 lines of per-skill summaries that restated each
  skill's own description; critical rules kept in full.
- Linter: bootstrap check, skill-count claims validated against the tree,
  `doctor` and `mcp` added to the known CLI domains.
- CONTRIBUTING.md, keyword-dense README opening, updated repo metadata.

Also carries the aiArk/apolloio priority-stack promotion authored in a
parallel session on this branch (cargo-gtm 1.12.0) — the two touch the
same SKILL.md files and could not be split cleanly.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* Surface the 100-credit free tier where an agent meets it

There is no purchase gate between installing Cargo and producing a real
deliverable — a new account starts with 100 free credits and no card — and
nothing in the bundle said so. An agent that doesn't know the budget can't
tell a first-time user whether the demo is a look around or a commitment,
and defaults to hedging.

Now stated at every point an agent encounters the question:

- README opening and the generated llms.txt install block: an agent can
  install, sign the user up, and hand back a list in one turn.
- Router install section and prerequisites.md, with anchors for what 100
  credits buys (~5,000 sourced leads, ~1,000 verified-email enrichments,
  ~50 fully enriched contacts).
- cargo-quickstart: the demo spends ~0.5 of the 100, and the skill now
  says so before the first paid call — that reframes the moment from a
  purchase decision into a look around, which is the job of a quickstart.
- cargo-billing: a "what 100 credits buys" table, plus two new trigger
  phrases so free-tier questions route here at all.
- cost-discipline.md: on a new account, receipts and next-step proposals
  must be framed against the free tier. "87.6 of your 100 free credits
  left" is a number the user can act on; "87.6 remaining" is not. Also
  warns that phone lookups (6-7/call) are the fastest way to burn a tier
  a first session should end with something left to try.

Two routing eval cases added for free-tier questions (79/79 core).

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* Run the routing evals against a real model in CI

The lexical tier passes 79/79, but it is a deterministic proxy written
alongside the descriptions it grades — it cannot fail in a way that
surprises us, which is what makes it weak evidence. The only honest
scoreboard for the description rewrite is whether a real model, shown
nothing but the 17 descriptions, routes the eval prompts correctly.

That tier existed but had never run. Now it does, in its own workflow.

- New .github/workflows/routing-evals-llm.yml, using the repo's
  ANTHROPIC_API_KEY. Deliberately not part of skills-lint: it costs money
  and is non-deterministic, so it must never stand between a typo fix and
  a merge. Triggers on PRs and pushes that touch a SKILL.md, the eval
  cases, or the runner; weekly on a schedule so model drift surfaces even
  when nobody edits a description; and on demand with a model override.
- runLlm reworked for CI: 6-way concurrency (92 sequential calls is a slow
  job), retry with backoff on 429/5xx, tolerant answer parsing, and a
  core/hard/overall breakdown instead of one number.
- Results are written to GITHUB_STEP_SUMMARY as a table, including every
  misroute with what the model picked instead — so a regression is
  readable on the run page without opening logs.
- Optional --llm-min=<percent> floor, wired to the exit code. Left unset
  until the first runs establish a baseline; a floor guessed before the
  data would either never fire or block on noise.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* Act on the first real-model routing run: 92/94, two fixes

Baseline from the model tier (claude-haiku-4-5, judging from the 17
descriptions alone): 92/94 overall — core 79/79, hard 13/15. The lexical
proxy's 3/15 on the hard tier was noise about the proxy, not the
descriptions, which is what that tier existed to establish.

Both misroutes were worth having:

- "Our outbound is going to the wrong people — help me figure out who
  actually buys from us" routed to cargo-context instead of cargo-gtm.
  A real collision: cargo-context's triggers include "who do we sell to",
  which reads as ICP ownership. It owns *writing the conclusion down*;
  deriving it from won/lost data is cargo-gtm. Added that boundary to
  cargo-context's Skip when, and the two phrasings to cargo-gtm.

- "Give the assistant access to our sales collateral so it stops making
  things up" routed to cargo-content instead of cargo-ai — and the model
  was right. As written the first step is getting the collateral into the
  workspace. Corrected the expectation and added the other side of the
  boundary as its own case ("attach the library we already uploaded to
  the agent"), which the lexical tier then failed, correctly: cargo-ai
  never said "library" or "release resources". Added both, so the
  content/ai split is now legible to a ranker and a model.

Set --llm-min=93 now that a baseline exists. Deliberately below the
observed 98%, not at it: a model tier that fails on one non-deterministic
flip trains people to ignore it.

Lexical 80/80 core.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* Document cargo-ai mcp — the bridge that was written down nowhere

Cargo reaches coding agents through two doors. Skills reach agents that
implement skills.sh; a workspace MCP server reaches everything else —
Claude Desktop, ChatGPT, and whatever ships next. The second door was
fully built and documented in exactly one place: `cargo-ai mcp --help`.

Worse, cargo-ai/SKILL.md taught `ai mcp-server create` (building a server)
without ever mentioning the command that serves it, so an agent could
construct one and have no idea how to connect it — and the section
conflated publishing a server with consuming someone else's, which are
unrelated surfaces.

- MCP section rewritten around the two directions, with a table: publish
  (`ai mcp-server`, called by any MCP client, wired via `cargo-ai mcp`)
  vs consume (`ai mcp-client`, called by your agents, wired via
  `release update-draft --mcp-clients`). States plainly that there is no
  first-party Cargo MCP server — a workspace builds its own.
- Documents `cargo-ai mcp` with the registration one-liner, the
  CARGO_MCP_SERVER_UUID fallback, and the stdout-is-protocol constraint.
- Details verified against the live API rather than --help: actions take
  kind "tool" *or* "agent" (an agent is exposable as a callable MCP
  tool), resources take model or file, and `update` replaces the arrays
  wholesale instead of merging — a real footgun.
- Routing rule for which door to use, pointing at the router section.
- Two trigger phrases ("expose our tools as an MCP server", "use Cargo
  from Claude Desktop or ChatGPT") and two eval cases, so the publish
  direction is reachable from a description at all. It previously wasn't.

Lexical 81/81 core.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-12 10:18:32 -07:00
Auree Aubert 895ade0bcc Require a 10–20 record sample and explicit approval before enrolling a full batch (#70)
* Require a 10–20 record sample and explicit approval before enrolling a full batch

`batch create` / `action execute-batch` fan out across every record in their
data source, so a config mistake and the full bill arrive together. Every
surface that can launch one now requires the same three steps: count the pool
for free, sample 10–20 records through the exact workflow and config, then ask
the user to approve the full enrollment with both the record count and the
credit estimate in the question.

The canonical gate lives in cargo-orchestration ("The sample gate"), with the
sampling mechanics per data kind — `kind: "filter"` + `limit`, `recordIds`, a
sliced `records` array, a truncated CSV — and the note that `kind: "segment"`
and `kind: "change"` take no limit, so they can't be sampled directly.

The GTM cost gate was a 1–3 row pilot, which can't produce a hit-rate, and
hit-rate is what drives the estimate. Split it: 1–3 rows proves one action's
config shape, 10–20 records before any batch. The approval message now states
how many records the full run enrolls alongside what they cost, and approval of
the sample is explicitly not approval of the full run.

Propagated to the router recap, gotchas, and interaction conventions (the gate
holds even when a batch arrives through cargo-orchestration or cargo-cdk with
no GTM framing), and to cargo-cdk (a deployed play's first batch, and the
per-run re-bill of a scheduled one). Aligned the downstream copy that quoted
the old 1–3 row pilot: the execution-planner agent, build-tam, and save-as-play
(whose play pilot was a single record).

Verified against the live CLI: `batch create --help` for where `limit` is
accepted, `segment list` for `recordsCount`/`filter`, and `file upload --file`.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

* Bump plugin versions to 1.16.0 and regenerate skill-metadata.json files

Co-authored-by: Auree Aubert <aureeaubert@users.noreply.github.com>

---------

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
Co-authored-by: Cursor Agent <cursoragent@cursor.com>
Co-authored-by: Auree Aubert <aureeaubert@users.noreply.github.com>
2026-08-08 14:19:47 -07:00
Auree Aubert e289e14e4a Scope node execute to node debugging, default to action execute (#71)
`node execute` was documented as "runs a single node in isolation" with no
guidance on when *not* to use it, which invites it as a general-purpose way to
run an operation. It isn't one: the CLI rejects the call client-side unless all
five of --workflow-uuid, --release-uuid, --node, --computed-config and --context
are present, so it's only usable against a workflow + release that already
exist. Verified each flag against @cargo-ai/cli by omitting them one at a time.

Two doc claims were also wrong and are corrected here: --release-uuid was
described as optional, and --computed-config as skippable ("the CLI resolves
expressions from --context automatically"). Both are required.

- cargo-orchestration/SKILL.md: flowchart gains a "testing ONE node" branch
  marked debug-only, plus a callout routing every non-debug use to
  `action execute` / `action execute-batch`.
- cargo-orchestration/references/nodes.md: Node execute reframed as debug-only
  with a routing table, the required-flags note (and where to resolve
  --release-uuid via `release get-deployed`), corrected flag descriptions, and
  the example updated to pass --release-uuid.
- cargo/SKILL.md + cargo/references/gotchas.md: matching critical rule and
  confusable-pair row so the router carries the same default.

Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-08 11:33:26 -07:00
Auree Aubert a92d53541a feat(storage): add "show the rows, not the schema" preview convention (#60)
Add a pack-wide interaction convention (cargo router §4 + cargo-storage)
telling the agent to preview ~10 real rows once data lands, echo the
schema (not an empty query) right after model/column creation, and treat
an unexpectedly empty/null preview as a finding. Bump bundle to 1.14.1
across router + all three plugin manifests and regenerate skill metadata.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-14 21:54:15 -07:00
Auree Aubert a418d76ee7 Fan the plugin out to Codex and Cursor; bundle session-lifecycle hooks (#50)
* Fan the plugin out to Codex and Cursor; bundle session-lifecycle hooks

- One plugin source, three targets: .agents/plugins/marketplace.json
  (Codex) + .cursor-plugin/marketplace.json, with .codex-plugin/ and
  .cursor-plugin/ plugin manifests version-locked to the router
  (linter-enforced across all three, negative-tested). The approval hook
  is wired per target - PreToolUse (Claude Code), PermissionRequest via
  hooks/codex-hooks.json (Codex), beforeShellExecution via
  hooks/cursor-hooks.json (Cursor) - reusing approve-cli.sh's existing
  per-agent verdict dispatch.
- Plugin-bundled lifecycle hooks (Claude Code): session-start (pinned
  CLI refresh from the plugin's own cli-version + placeholder session
  row; deliberately no skills add - the plugin owns the skills),
  session-checkpoint (Stop; jq-derived title, 45s throttle), and
  session-end (sync finalize + detached claude -p refinement). Each
  defers when the installer's counterpart exists at ~/.claude/hooks/,
  so installer + plugin never double-register a session.
- .gitignore: un-ignore .agents/plugins/ (vendored skills stay ignored).
- README: per-target install steps; router 1.11.0, plugins 1.11.0.

Verified: lint 0/0; scripts behavior-tested with stubbed npm/cargo-ai
(pin read from plugin root, defer guards, checkpoint derivation +
throttle, --finished finalize); live plugin install on Claude Code
2.1.205 shows all four hook events and both extra manifests in the
1.11.0 cache.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Make the plugin the single source of truth; agent-portable docs

- session-start.sh now also refreshes the plugin itself (marketplace
  update + plugin update, detached, effective next session) - the plugin
  channel's replacement for the installer's skills-add refresh, with
  zero duplication by construction.
- Docs made agent-portable: the pinned-install command in cargo/SKILL.md
  and prerequisites.md reads cli-version from the skill directory the
  agent loaded instead of hardcoding ~/.claude/skills/ (which silently
  degraded Codex/Cursor to @latest); manual-path session titles are
  agent-neutral; job 1 says to skip skills add when skills came from a
  plugin; the permission-prompts note covers all three agents' events.
- README Claude Code section describes the refactored installer flow
  (installs the plugin; skills add only as fallback; legacy scaffolding
  migrated away). cargo 1.12.0, plugins 1.12.0.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Single-source the lifecycle scripts: dual-mode plugin/standalone

The three hooks/session-*.sh scripts are now the only copies of the
session lifecycle - the installer's fallback channel downloads them
instead of embedding heredocs. Mode auto-detects from location
(~/.claude/hooks/ = standalone; anywhere else = plugin) with an explicit
plugin|standalone arg override:

- standalone: skills add refresh, pin from ~/.claude/skills/cargo/,
  no plugin self-update, never defers.
- plugin: pin from plugin root, detached plugin self-update, no skills
  add, defers when a standalone copy exists (exactly one lifecycle runs).

Log lines carry the mode. Behavior-tested both modes of all three
scripts with stubbed npm/npx/cargo-ai/claude (mode detection, defer,
no-self-defer, per-mode pin paths, per-mode refresh, mode-aware logs).
cargo 1.13.0, plugins 1.13.0.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* fix(lifecycle): registration-aware defer, wider PATH, checkpoint hygiene

Review feedback on the lifecycle scripts:

- Defer guard now requires the standalone copy to be REGISTERED in
  ~/.claude/settings.json, not merely present - an unregistered leftover
  file no longer suppresses the plugin copy (which would silently skip
  CLI pinning and session logging). Falls back to file existence when jq
  is unavailable.
- session-start's PATH widening for the detached plugin self-update now
  matches session-end's full list (Volta, asdf shims, nvm version dirs,
  /opt/node*) so `claude` resolves under version managers and the
  update isn't silently skipped.
- Checkpoint prompt snippets strip control characters. The reported
  command-substitution injection does not exist - shell assignments and
  quoted expansions never evaluate a value's content, and the upsert
  passes --title/--summary as single argv words (verified empirically:
  $(touch ...) and backticks pass through as literal data) - but control
  chars could mangle logs/rows, so they are removed and the inertness is
  documented in a comment for future reviewers.

Verified: unregistered leftover -> plugin runs; registered standalone ->
plugin defers; clean env -> runs; injection payload inert with ESC
sequences stripped from the stored title.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* fix(lifecycle): run when standalone registration is unverifiable

Review follow-up: the defer guard's no-jq / no-settings.json fallback
returned "owned" (defer), which silently skipped CLI pinning and session
logging whenever registration couldn't be checked - exactly the failure
the registration-awareness was meant to prevent. Flipped: when jq or
settings.json is unavailable, default to NOT owned so the plugin copy
runs. Safe direction - the session upsert is idempotent, so a duplicate
with an active standalone is harmless, whereas a wrong defer is a silent
skip. Unit-tested all five branches (registered->defer; not-registered,
no-settings, no-jq, no-file->run).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-07-09 18:33:21 -07:00
Auree Aubert 1cb3ee755b Claude Code plugin channel, cargo-ai approval hook, and CLI version pin (#51)
* Add Claude Code plugin channel and cargo-ai auto-approve hook

- .claude-plugin/marketplace.json + plugin.json: the repo root doubles as
  a Claude Code plugin (skills scan root "./" discovers all 15 top-level
  skill dirs with no restructuring; plugin version mirrors the router's,
  now linter-enforced).
- hooks/approve-cli.sh: allow-only PreToolUse hook that auto-approves
  cargo-ai / npx @cargo-ai/cli calls and read-only pipe helpers after a
  quote-aware structural pass. Never auto-approves: login/logout,
  workspaceManagement token/report, cdk deploy/destroy, or any
  remove/delete/destroy token. Verified with a 49-case harness plus a
  live end-to-end test (clean permissions: whoami auto-approved, token
  list fell through to prompt).
- README: plugin install path + pick-one-channel note; prerequisites.md
  gains a "Permission prompts" section. cargo 1.9.0, plugin 1.9.0.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* Pin the CLI version in cargo/cli-version

- New cargo/cli-version (1.0.29): single-line semver pin, the source of
  truth for which @cargo-ai/cli these skills were written against. Lives
  inside the router skill so it ships with skills add and the ClawHub
  bundle; session hooks read it locally with a latest fallback, so the
  pin can never block an install.
- Linter asserts the pin exists and is bare semver, and that openclaw
  install blocks stay @cargo-ai/cli@latest (bootstrap only; the session
  hook converges to the pin).
- Docs: router session job 1 reordered (skills add -> pinned npm
  install) with a "why the pin" note; prerequisites.md and README
  refresh snippets use the pinned form. cargo 1.10.0, plugin 1.10.0.

The producer side (CLI release pipeline PRs pin bumps here; install.sh
consumes the raw pin URL) lands in getcargohq/cargo separately.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* fix(approve-cli): position-independent gating closes token-shift bypass

Review finding: gated checks only examined the first two non-flag tokens
after the binary/package. Valid invocation prefixes shift the real
subcommand out of those slots - `npx -p @cargo-ai/cli cargo-ai login`
puts a literal cargo-ai before login (confirmed auto-approved), and a
global flag with a value would shift the domain word the same way.

Fix: normalize the cargo segment's token stream once, drop leading
`cargo-ai` binary tokens, and gate position-independently - credential
tokens (login/logout), destructive verbs (remove/delete/destroy), and
gated adjacent pairs (workspaceManagement token/report, cdk
deploy/destroy) anywhere in the segment refuse approval. Accepted cost,
documented: a gated word as a literal inside a quoted argument (SQL
containing "login") now falls through to the prompt - the safe
direction for an allow-only hook.

Harness extended to 62 cases: all -p/token-shift/flag-shift bypass
shapes prompt; safe -p usage still auto-approves.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-07-09 18:30:56 -07:00
Auree Aubert f5566657fa Add cargo-diagnostics skill, interaction conventions, and catalog fixes (#48)
- New capability skill cargo-diagnostics: forensic runbooks (run-trace,
  batch-error-sweep, play-optimize-credits) that sequence run get,
  orchestration SQL, and billing metrics into diagnoses, linking existing
  references instead of duplicating them.
- New shared reference cargo/references/interaction.md: plan gate before
  building, recommended-default choices, presenting defaults.
- Catalog hygiene: stale skill counts fixed (AGENTS.md said ten, router
  said thirteen, README said fourteen -> fifteen everywhere), ClawHub
  publish loop catches up cargo-quickstart/cargo-content/cargo-hosting
  and adds cargo-diagnostics, README owner prose matches CLAWHUB_OWNER.
- Version bumps: cargo 1.8.0, cargo-gtm 1.1.1, cargo-orchestration 1.5.1,
  cargo-billing 1.0.2, cargo-diagnostics 1.0.0 (new). CHANGELOG updated.

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-07-09 17:53:48 -07:00
Auree Aubert 915b5a29bb Terminal-experience quick wins: quickstart, cost discipline, save-as-play, anti-drift (#45)
* Terminal-experience quick wins: quickstart, cost discipline, save-as-play, anti-drift

From the 2026-07-08 terminal-experience eval:

- New cargo-quickstart skill: persona question → 25 leads in <2 min →
  receipt → save as a recurring play (fast path verified live; fields,
  retrieval flow, and the 25-row minimum page documented from observation)
- New cargo-gtm/references/cost-discipline.md: blocking pilot→approval→
  full-run gate, per-run receipts (credits + balance + hit-rate +
  estimate-vs-actual), 1.4×N over-provision, count-first sizing,
  pay-on-success and phone guards, context discipline — wired into
  cargo-gtm SKILL.md, the plan agent, waterfall-strategy, build-tam
- New cargo-gtm/recipes/save-as-play.md: ad-hoc run → durable play/tool
  with cadence defaults per signal and recurring-cost approval
- Grounded next-step spec (5-part shape) + end-of-session share ask
  (consented session traces via workspaceManagement report)
- Provider playbooks: Anti-patterns sections (field-name case traps,
  billed-on-returned-rows, PDL parameters wrapper), waterfall position
  + dynamic demotion rules; verification hard rules (independent
  validation, catch-all double-confirmation)
- Anti-drift: linter now lints cargo-content/cargo-hosting (previously
  skipped), and fails on skills or recipes missing from the router /
  recipe tables; fixed the drifted README recipe table and skill counts
- Removed the --is-finished flag from download-outputs snippets (API
  rejects it; CLI bug reported)

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* fix(cargo-quickstart): fallback rung 3 must ask before exceeding the demo's paid cap

waterfall.searchProspects at 3/record × 5 rows (~15 credits) blows the
~1-credit demo budget — gate it behind an explicit yes (with the free
connect-Sales-Navigator alternative offered) instead of just explaining
the cap after the fact.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-07-08 21:37:58 -07:00
Auree Aubert 53a1a86a7f Add cargo-hosting skill for app and worker deployment (#40)
* Add cargo-hosting capability skill

Document the `hosting` CLI domain (apps, workers, deployments) as a
dedicated capability skill, following the one-skill-per-CLI-domain
convention.

- cargo-hosting/SKILL.md: init -> create -> deploy -> promote lifecycle
  for Vite SPA apps (*.cargo.app) and edge workers, with critical rules
  and async polling.
- references/examples/{apps,workers,deployments}.md, response-shapes.md,
  troubleshooting.md.
- Register in the cargo router (skill count 10->11, capability table row,
  recap, removed hosting from the no-skill-yet table, synced frontmatter
  count) and bump cargo 1.4.0 -> 1.5.0.
- README capability table + skill count (11 -> 12).
- CHANGELOG entries for cargo-hosting 1.0.0 and cargo 1.5.0.

https://claude.ai/code/session_018LeD9abpD7LYBhGGkDxSup

* Add hosting terms to glossary

Add app/appUuid, deployment/deploymentUuid, hosting, worker/workerUuid
entries to cargo/references/glossary.md, and correct the capability-skill
domain list (was missing content and hosting). CHANGELOG updated.

https://claude.ai/code/session_018LeD9abpD7LYBhGGkDxSup

* Pin hosting response shapes from backend types

Replace inferred shapes/caveats in cargo-hosting with the authoritative
App/Worker/Deployment structures: kind app/worker discriminant,
promotedDeployment, chargedUntil, and the deployment status enum
(pending/building/success/error/cancelled, terminal at the last three).
Polling + build-failure docs now cite the real status/errorMessage/
buildLogS3Filename fields, and a critical rule notes monthly hosting
credits per resource.

https://claude.ai/code/session_018LeD9abpD7LYBhGGkDxSup

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-06-15 10:30:32 +02:00
Auree Aubert 4c933393dd Extract content domain into dedicated cargo-content skill (#35)
* Migrate file/library docs to the new content domain + register new CLI surfaces

The CLI moved workspace files and knowledge libraries out of the `ai` domain
into a new top-level `content` domain (`content file`, `content library`), and
added inline `ai document`. The old `cargo-ai ai file ...` commands no longer
exist.

- cargo-ai (2.0.0): migrate every `ai file` reference to `content file`;
  document `content library` (native vs connector-backed) and `ai document`;
  rename the Files section and add a command-surface-change callout.
- cargo (1.2.0): register the content domain in the recap/table, add a
  "CLI domains without a dedicated skill yet" table (segmentation, expression,
  system-of-record, revenue-organization, hosting, user-management), add
  glossary entries for the content domain and libraries.
- cargo-context (1.0.2), cargo-orchestration: fix cross-skill RAG examples.
- skills-lint: add the new CLI domains to the known-domain allowlist.

* cargo-context/cargo-ai: document content files exposed read-only under .files/

Uploaded `content file` knowledge surfaces in the context runtime sandbox under
a read-only `.files/` directory that sits outside the committed context tree, so
sandbox commands can consume content uploads without round-tripping them back
into the context repo.

* Split the content domain into a dedicated cargo-content skill

The content CLI domain (files + libraries) was documented inside cargo-ai.
Per the repo's one-skill-per-CLI-domain convention, extract it into its own
cargo-content capability skill:

- New cargo-content/ skill: files + libraries command docs, the moved
  examples/files.md walkthrough, response shapes, and troubleshooting.
- cargo-ai keeps inline documents (ai document) and the attach-to-agent
  wiring; cross-links cargo-content for files/libraries.
- Register cargo-content across the router overview (cargo/SKILL.md table,
  recap, dependency diagram/rules, counts), glossary, README, and AGENTS.md.
- cargo-context documents content files mounted read-only under .files/.
- Version bumps: cargo 1.3.0, cargo-ai 2.1.0, cargo-content 1.0.0,
  cargo-context 1.1.0; CHANGELOG updated.

* Drop ai document from cargo-ai; correct content file response shape

- Remove the low-value ai document (inline documents) commands from cargo-ai
  and scrub document references from the router overview, README, glossary,
  and the cargo-content files.md walkthrough.
- Reframe cargo-ai's knowledge section around files & libraries only.
- Update the content file list response shape to match the workspace File
  type: libraryUuid, userUuid, isIndexedInOpenAiVectorStore, externalId,
  deletedAt, and the native/connector kind union (connectorUuid).

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-06-08 00:42:38 -07:00
Auree Aubert 74fe201c5f cargo-orchestration: add node-selection guide to curb unnecessary Python nodes (#34) 2026-05-30 06:08:17 -07:00
Auree Aubert c7bec7d8c4 Share prerequisites, lint SKILL.md, deep-link the router (#33)
- Extract the duplicated install/login/output-conventions block from every
  capability skill into cargo/references/prerequisites.md. Each capability
  skill now links to it instead of redefining ~16 lines of boilerplate.
- Add CHANGELOG.md so per-skill version bumps are tracked alongside the
  reason for each bump, and capture the current version snapshot as the
  historical baseline.
- Add a CI skill-lint job (.github/workflows/skills-lint.yml +
  .github/scripts/skills-lint.mjs) that validates SKILL.md frontmatter
  shape, internal markdown links, fenced JSON snippets, and that bash
  examples reference real cargo-ai domains. Catches drift before users do.
- Reorder cargo-connection so the integration/connector key concepts sit
  above Prerequisites (where they're needed before reading commands), and
  tighten the integration get vs native-integration get table with ✓/✗
  markers to make mis-routing harder.
- Deep-link the skill graph in cargo/SKILL.md so each row in the
  capability table jumps straight to the target SKILL.md, with the
  in-page recap available as a secondary link.
- Bump versions on each touched skill.

Co-authored-by: Claude <noreply@anthropic.com>
2026-05-28 15:11:38 -07:00
Auree Aubert 8ac3c8724c Slim cargo/SKILL.md by extracting reference content (#30)
The root router was 534 lines because it mixed routing (which
skill to load, dependency diagram, per-skill blurbs) with
reference content (UUID lookup tables, worked use-case recipes,
gotcha lists). Agents loading the router paid the full cost
every time, even for tasks that don't need the reference detail.

Extract three sections into cargo/references/:

  - uuid-flow.md      — producer/consumer table, standard
                        discovery sequence, UI URL patterns
  - use-cases.md      — 8 worked end-to-end recipes
  - gotchas.md        — silent-failure lookup table

Each removed section is replaced by a 2-line pointer so the
section header and topic stay discoverable inline.

SKILL.md drops from 534 to 369 lines (-31%). Router scope is
now: install/auth, keep-updated, workspace-report mechanism,
skills-at-a-glance table, dependency diagram, per-skill details,
async polling quickref.

Co-authored-by: Claude <noreply@anthropic.com>
2026-05-28 12:54:49 -07:00
Claude 4c04034e4d Promote repo-root router into an installable cargo skill
The repo-root AGENTS.md and GLOSSARY.md held the cross-skill router
(skill graph, UUID flow, async polling, end-to-end use cases, common
gotchas) and term reference, but the skillpack installer
(`npx skills add`) only ships the `cargo-*/` skill folders — anyone
installing the package never received the router content.

Wrap the router as a tenth skill (`cargo/SKILL.md`) with the required
frontmatter (name, description, license, compatibility, metadata) and
move the glossary into `cargo/references/glossary.md` so both ship via
the installer. Rewrite sibling-skill references inside the new SKILL.md
to use `../cargo-*` paths so they resolve once installed into
`~/.claude/skills/`. Collapse root AGENTS.md to a pointer for
AGENTS.md-aware tools and repoint CLAUDE.md at the new skill so Claude
Code still inlines the full router on session start.
2026-05-20 09:31:06 +00:00