Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -325,6 +325,13 @@ The payload is inactive and unqualified. It does not call Claude Code, invoke a
model, use a credential or network, write a target, publish, or activate a
profile.

## Inactive default producer config

`profiles/default/v1/producer-config.json` is an immutable Git payload for the
default producer preference. It grants no capability and does not select a
profile, invoke a model, or contact a provider. Its focused test checks the
config shape and exact Git object identity.

## Inactive local Git materializer protocol

`adapters/local-git-materializer/v1/protocol.jq` defines the pure input, receipt,
Expand Down
13 changes: 13 additions & 0 deletions RESTORE.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,19 @@ with the restored `scripts/core-contract.sh`. No compiled helper is installed or
restored. A future activation must separately qualify and bind a production trusted
parent; restoring these files does not select a live profile.

### Restore the inactive default producer config

Restore the two paths listed under “Inactive default producer config” in
[`ci/required-files.txt`](ci/required-files.txt), then run:

```sh
bash scripts/test/default-producer-config.test.sh
```

The payload records an inactive producer preference. It does not select or
activate a profile and performs no model, credential, provider, publish, or
target operation.

---

## 1. Recreate yshifu (the manager)
Expand Down
4 changes: 4 additions & 0 deletions ci/required-files.txt
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,10 @@ scripts/test/local-git-materializer-adapter.test.sh
adapters/claude-code-producer/v1/normalize.jq
scripts/test/default-claude-code-producer-adapter.test.sh

# Inactive default producer config
profiles/default/v1/producer-config.json
scripts/test/default-producer-config.test.sh

# Inactive provider-neutral local Git materializer protocol
adapters/local-git-materializer/v1/protocol.jq
scripts/test/local-git-materializer-fixtures.sh
Expand Down
1 change: 1 addition & 0 deletions profiles/default/v1/producer-config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"effort_id":"high","model_id":"claude.sonnet","provider_id":"anthropic","schema_version":1}
45 changes: 45 additions & 0 deletions scripts/test/default-producer-config.test.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
#!/usr/bin/env bash
set -euo pipefail
export LC_ALL=C

root=$(CDPATH='' cd -P -- "${BASH_SOURCE[0]%/*}/../.." && pwd -P)
config='profiles/default/v1/producer-config.json'
expected_blob='369159a30c8a0026644c3716e7fc1132206e826c'
sha_file() { /usr/bin/shasum -a 256 "$1" | /usr/bin/awk '{print $1}'; }
fail() { printf 'FAIL: %s\n' "$1" >&2; exit 1; }
pass=0
ok() { pass=$((pass + 1)); printf 'ok %s - %s\n' "$pass" "$1"; }

platform=$(/usr/bin/uname -s):$(/usr/bin/uname -m)
case "$platform" in
Linux:x86_64) asset='jq-linux64'; asset_sha='af986793a515d500ab2d35f8d2aecd656e764504b789b66d7e1a0b727a124c44' ;;
Darwin:x86_64|Darwin:arm64) asset='jq-osx-amd64'; asset_sha='5c0a0a3ea600f302ee458b30317425dd9632d1ad8882259fcaf4e9b868b2b1ef' ;;
*) fail "unsupported jq 1.6 proof platform: $platform" ;;
esac
jq_bin="${TMPDIR:-/tmp}/ystack-portable-core-jq16/$asset"
[ -f "$jq_bin" ] && [ ! -L "$jq_bin" ] &&
[ "$(sha_file "$jq_bin")" = "$asset_sha" ] || fail 'pinned jq 1.6 is required'
jq_command=("$jq_bin")
[ "$platform" != Darwin:arm64 ] || jq_command=(/usr/bin/arch -x86_64 "$jq_bin")
[ "$("${jq_command[@]}" --version)" = jq-1.6 ] || fail jq-version

[ -f "$root/$config" ] && [ ! -L "$root/$config" ] || fail config-file
[ "$(/usr/bin/git -C "$root" hash-object "$config")" = "$expected_blob" ] ||
fail config-blob
index_record=$(/usr/bin/git -C "$root" ls-files --stage --error-unmatch -- "$config")
expected_index=$'100644 369159a30c8a0026644c3716e7fc1132206e826c 0\tprofiles/default/v1/producer-config.json'
[ "$index_record" = "$expected_index" ] ||
fail config-index-anchor
ok 'the config is a tracked immutable Git blob'

"${jq_command[@]}" -e '
type == "object" and
(keys | sort) == ["effort_id","model_id","provider_id","schema_version"] and
.schema_version == 1 and
.provider_id == "anthropic" and
.model_id == "claude.sonnet" and
.effort_id == "high"
' "$root/$config" >/dev/null || fail producer-preference
ok 'the config records the inactive default producer preference'

printf 'default producer config: %s focused checks passed\n' "$pass"