sync-from-downstream

sync-from-downstream is a command for Claude Code from terrene-foundation/kailash-coc-claude-py. It costs 33 tokens per session (1,188 once invoked), scanned A, original, Apache-2.0.

A command for bringing proposed workflow changes from a downstream project into a shared COC template. It cleans, reviews, deduplicates, and relays accepted proposals through a controlled inbox.

In plain words
What is it for?
Use it to ingest downstream proposals, verify the repository type, review entries as data, and forward accepted changes.
Why use it?
It keeps contributions from consumer projects organized and prevents unreviewed or duplicate changes from entering the template.

Command for Claude Code

Written for Claude Code: installed under .claude/. Also seen: reads .claude/ paths.

Good fit Use it to ingest downstream proposals, verify the repository type, review entries as data, and forward accepted changes.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/terrene-foundation/kailash-coc-claude-py/sync-from-downstream
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/terrene-foundation/kailash-coc-claude-py

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for sync-from-downstream

README.md
[![agentmods](https://agentmods.dev/badge/commands/terrene-foundation/kailash-coc-claude-py/sync-from-downstream/github.svg)](https://agentmods.dev/commands/terrene-foundation/kailash-coc-claude-py/sync-from-downstream)
Your own site
<a href="https://agentmods.dev/commands/terrene-foundation/kailash-coc-claude-py/sync-from-downstream"><img src="https://agentmods.dev/badge/commands/terrene-foundation/kailash-coc-claude-py/sync-from-downstream/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for sync-from-downstream

Your own site · 80×15
<a href="https://agentmods.dev/commands/terrene-foundation/kailash-coc-claude-py/sync-from-downstream"><img src="https://agentmods.dev/badge/commands/terrene-foundation/kailash-coc-claude-py/sync-from-downstream.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 33 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,188 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00033 $0.01188
Opus 5 $0.00016 $0.00594
Sonnet 5 $0.00007 $0.00238
Haiku 4.5 $0.00003 $0.00119

Measured 9d ago against content hash f3b532e2535f, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

sync-from-downstream scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/sync-from-downstream.md · 44 lines

How it starts

The opening of the file, as written. The whole thing — 44 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Ingest the downstream upflow inbox INBOUND at a USE template. /sync-from-downstream brings consumer-originated COC-artifact proposals (offered by a downstream coc-project via its /codify Step-7c, as a human-gated PR to .claude/.proposals/inbox/<date>-<slug>.yaml) into this template, then relays accepted entries up to loom on the template's own proposal stream.

Detailed protocol: skills/30-claude-code-patterns/sync-flow.md § Template Inbox Ingest.

Usage: /sync-from-downstream — no target.

Step 0: Verify Repo Class (this verb is for USE templates)

Read .claude/VERSIONtype. /sync-from-downstream is valid ONLY at a USE template (type: coc-use-template). MUST verify the declaration is credible before routing — but verify it against this repo's own declaration, never a hardcoded name list: compare .claude/VERSION::repo (the <owner>/<name> slug the VERSION was authored FOR) against this repo's git remote get-url origin. Names agree → confirmed template. Names disagree on two real git identities → the "Use this template" byte-copy case. .claude/hooks/lib/version-utils.js::classifyTemplateDeclaration is the single predicate; do not re-derive it here.

A hardcoded canonical set (kailash-coc-claude-{py,rs,rb}, kailash-coc-{py,rs}, coc-base / coc-claude-base) survives ONLY as a legacy silencer for canon templates that have not yet been stamped with their own repo — it can never recognize a client-fork template, whose name canon has never heard of, and a fork template must NOT self-mis-classify as a downstream coc-project merely for being absent from a list written at canon. /sync-to-use Step 2 stamps repo when the coc-sync agent runs the stamper as documented — nothing in the engine enforces it, so the list drains only as templates are re-synced by an agent that followed that step. Treat an unstamped template as expected during the migration window, not as evidence it is a copy.

  • coc-use-template (verified) → proceed below.
  • coc-source (loom) → STOP: "this is loom — ingest the upstream streams with /sync-from-build + /sync-from-use."
  • coc-project → STOP: "this is a downstream consumer — pull from your template with /sync-from-template."
  • coc-build → STOP: "BUILD repos receive artifacts via /sync-to-build run at loom."
  • Declaration NOT credible (VERSION::repo names a different repo than this one's git remote) → STOP and report; do NOT silently re-route on a class you just decided to disbelieve. Correcting it is an EXPLICIT, reviewable edit the operator approves: set type: coc-project and populate upstream ({template, template_repo, template_version, synced_at, sdk_packages}.claude/hooks/lib/version-utils.js::computeTemplateDerivedCorrection returns the suggested object; it is PURE and writes nothing), then run /sync-from-template. NEVER rewrite .claude/VERSION silently or as a side effect — it is the repo-CLASS root of trust (bin/lib/manifest-source.mjs::readRepoClass trusts type verbatim), which is why validate-bash-command.js BLOCKS agent writes to it at the Bash boundary.
  • Declaration undetermined (no VERSION::repo, no legacy-list match) → report the ambiguity and ask; do not guess a class.
  • Missing → ask the user what class this repo is.

Read the full file on GitHub · 44 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 44 lines · 33 tokens per session scan A f3b532e2535f

Subscribe to this mod's changes

sync-from-downstream is a command published in the GitHub repository terrene-foundation/kailash-coc-claude-py (12 stars, last pushed 24d ago), licensed Apache-2.0. It adds 33 tokens to every session and 1,188 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.