Skip to content
Merged
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
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,4 +40,4 @@ jobs:
- run: python -m pip install --upgrade pip
- run: python -m pip install -e .
- run: make -f ravel_versions/0.6/Makefile policy-test
- run: make -f ravel_versions/0.6/Makefile build behavioral-test transaction-test component-test decomposition-test negative-test provider-test evaluator-test forge-test receipt-test abi-test compiler-matrix sanitizers
- run: make -f ravel_versions/0.6/Makefile build behavioral-test transaction-test component-test decomposition-test negative-test provider-test evaluator-test forge-test receipt-test abi-test fabric-test compiler-matrix sanitizers
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ RAVEL — the **Recursive Adaptive Vector Execution Lattice** — is an experime

RAVEL operates beneath the technical authority of the Machine-Native Complexity Standard (MNCS) and the Machine-Native Complexity Development Standard (MNCDS). It is not intended to replace a language model, compiler, static analyzer, test framework, or the MNCS Forge. Its role is to decide what evidence should be gathered, what action should follow, and what experience should be retained for later use without redefining the governing status of that evidence.

> **Project status:** RAVEL is research software. Historical RAVEL 0.4 and 0.5 results remain development `FAIL`; RAVEL 0.6 candidate-001 now has digest-bound policy/evaluator surfaces, separately compiled checkpoint and world/provider contracts, branching/ring unity parity, a Forge-governed development configuration, official MNCS bundle/receipt adapters, and lifecycle/memory integration. It remains unfrozen and has not been selection-evaluated, independently evaluated, or promoted. Formal MNCS/MNCDS conformance, independent attestation, protected custody, production safety, and general recursive self-improvement remain `UNKNOWN`.
> **Project status:** RAVEL is research software. Historical RAVEL 0.4 and 0.5 results remain development `FAIL`; RAVEL 0.6 candidate-001 now has digest-bound policy/evaluator surfaces, separately compiled checkpoint and world/provider contracts, branching/ring unity parity, a Forge-governed development configuration, official MNCS bundle/receipt adapters, a bounded local Fabric development path, and lifecycle/memory integration. It remains unfrozen and has not been selection-evaluated, independently evaluated, or promoted. Formal MNCS/MNCDS conformance, independent attestation, protected custody, production safety, and general recursive self-improvement remain `UNKNOWN`.

## Place in the MNCS ecosystem

Expand Down Expand Up @@ -113,6 +113,10 @@ algorithmic superiority. The bounded component surfaces in `src/ravel/world.py`,
`src/ravel/transition.py`, `src/ravel/planning.py`, `src/ravel/checkpoint.py`,
and `src/ravel/mechanism_state.py` provide deterministic provider substitution
and checkpoint fixtures; they do not replace the historical 0.5 source.
`src/ravel/fabric.py` adds the optional public Fabric local-controller path;
`tools/ravel_fabric_reference.py` runs branching/ring parity, replication,
reconciliation, bundle, and replay/negative checks without dispatching selection
or final material.

## Non-goals

Expand Down
26 changes: 26 additions & 0 deletions config/ravel-fabric.example.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Operator-only example. This file contains placeholders, not credentials.
# Fabric network execution is optional and requires pre-staged bundle material.

controller_id = "ravel-development-controller"
state_path = "build/fabric-network/controller.jsonl"
pre_staged_bundle_identity = "sha256:0000000000000000000000000000000000000000000000000000000000000000"

[[workers]]
worker_id = "ravel-development-worker-a"
host = "worker-a.example.invalid"
port = 4433
capabilities = ["os:linux", "python", "compiler:gcc"]
ca_file = "operator-secrets/ca.pem"
client_cert = "operator-secrets/controller.pem"
client_key = "operator-secrets/controller-key.pem"
trust_store = "operator-secrets/trust.json"

[[workers]]
worker_id = "ravel-development-worker-b"
host = "worker-b.example.invalid"
port = 4433
capabilities = ["os:linux", "python", "compiler:clang"]
ca_file = "operator-secrets/ca.pem"
client_cert = "operator-secrets/controller.pem"
client_key = "operator-secrets/controller-key.pem"
trust_store = "operator-secrets/trust.json"
26 changes: 26 additions & 0 deletions docs/ARCHITECTURE.md
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,32 @@ These modules are tested scaffolding and are not claims that RAVEL 0.6 has been
evaluated, selected, independently evaluated, certified, promoted, or made
production-safe.

## Forge and Fabric development path

RAVEL now has a bounded, optional MNCS Fabric integration for development
evidence. RAVEL creates a versioned semantic `FabricWorkload`; it is not a
Fabric `JobPlan` and it cannot expose selection or final material. Forge remains
the declared workflow/control boundary, and the RAVEL adapter translates the
workload into Fabric's public `LocalController`/`LocalWorker` APIs. Fabric then
owns manifest admission, bounded execution, raw process observations, receipts,
challenge/replay handling, worker identity, and reconciliation.

The local reference path executes the branching and ring provider parity matrix
on two logical workers in one process. Its reconciliation result is retained as
`PASS` when the immutable records agree, but the report explicitly records
`scope=local-in-process-replication` and `independence=UNKNOWN`. Fabric status is
not an RAVEL evaluator result. RAVEL memory retains references to workload,
worker, record, receipt, bundle, and replay identities and stores the resulting
experience as advisory `UNKNOWN` until a RAVEL evaluator answers its own
question.

The optional network adapter is TLS-only and requires operator-provided trust
material, worker capabilities, and an exact pre-staged Fabric manifest identity.
It does not add SSH, plaintext fallback, bundle transfer, sandbox claims, or
protected custody. Native Fabric bundle transfer remains unclaimed, so the
reference report distinguishes `bundle verified`, `pre_staged`, and
`executed=UNKNOWN`.

## Current modular evidence boundary

The generated C candidate has two separately compiled development contracts:
Expand Down
17 changes: 17 additions & 0 deletions docs/EVIDENCE_GUIDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,23 @@ separate evaluator programs cannot by themselves establish:
Those claims require external facts and actors, not stronger wording around
local files.

## Fabric-backed development evidence

Fabric records raw execution observations; they are immutable evidence by
reference, not RAVEL verdicts. A RAVEL workload binds the development candidate,
question, provider, bundle, Fabric manifest, capability requirements, resource
budget, Forge workflow, and development partition. The resulting experience
retains workload, worker, request, record, receipt, bundle, challenge, replay,
result, and resource identities without copying the raw Fabric record.

The local reference report distinguishes `bundle verified`, `pre_staged`, and
`executed=UNKNOWN` because current native Fabric bundle transfer is not claimed.
Two logical workers in one local process are `local-in-process-replication`, not
independent evaluation, protected custody, or R6-06 evidence. Fabric
reconciliation `PASS` answers only the Fabric reconciliation question; the
RAVEL development evaluator remains separate and normally records the imported
observation as `UNKNOWN`.

## Review checklist

Before accepting a RAVEL result or modifying the directory, verify:
Expand Down
82 changes: 82 additions & 0 deletions docs/FABRIC_INTEGRATION.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
# RAVEL and MNCS Fabric

RAVEL uses MNCS Forge and Fabric as sibling layers:

```text
RAVEL semantic question
-> Forge declared development workflow
-> Fabric bounded JobPlan/execution record
-> MNCS receipt and resource facts
-> RAVEL scoped advisory experience
```

## Versioned RAVEL contracts

`ravel-fabric-workload/0.1` is RAVEL's semantic request. It binds the candidate,
experiment, question kind, logical and Fabric manifest bundle identities,
capabilities, resource budget, replication count, provider, development
partition, and Forge workflow. It is not a Fabric `JobPlan`, evaluator result,
promotion request, or selection/final input.

`ravel-fabric-observation/0.1` is a reference to immutable Fabric evidence. It
retains workload, request, worker, record, receipt, bundle, challenge/replay,
result, provider, and resource identities plus Fabric outcome/reason codes. It
does not duplicate the raw execution record and is explicitly
`development observation; not evaluator authority`.

The report schema is
[`ravel-0.6-fabric-observation.schema.json`](../ravel_versions/0.6/ravel-0.6-fabric-observation.schema.json).
The compatibility snapshot is
[`ravel-0.6-family-compatibility-lock.json`](../ravel_versions/0.6/ravel-0.6-family-compatibility-lock.json);
it is evidence about inspected public contracts, not an installation lockfile.

## Local reference backend

`FabricLocalBackend` uses Fabric's public `FabricService`, `LocalController`,
`LocalWorker`, manifest, receipt, challenge/replay, and reconciliation APIs. It
builds a bounded development-only artifact and runs the branching and ring
provider parity task on two logical workers. These workers share a process and
host, so the report labels the scope `local-in-process-replication` and keeps
independence `UNKNOWN`.

The local command is:

```bash
python3 tools/ravel_fabric_reference.py --workspace build/fabric-reference --json
```

The project-local Forge workflow `fabric-reference` invokes the same command.
The `fabric-negative` workflow tests capability mismatch (`UNKNOWN`), wrong
manifest and corrupt record (`FAIL`), idempotent duplicate request, and
conflicting replay. A first valid challenge consumption is `PASS`; consuming
the same challenge again is a Fabric `FAIL` and is retained rather than hidden.

## Network boundary

`FabricNetworkBackend` is optional and TLS-only. `FabricNetworkConfig` requires
operator-supplied CA, client certificate/key, trust store, worker endpoint,
capabilities, and an exact pre-staged Fabric manifest identity. The checked-in
[`ravel-fabric.example.toml`](../config/ravel-fabric.example.toml) contains only
placeholders. RAVEL does not use SSH as a dispatch protocol, does not add a
plaintext fallback, and does not claim native bundle transfer until Fabric
exposes and verifies it.

The report therefore keeps these facts separate:

```text
bundle verified PASS
bundle pre-staged PASS (local artifact root)
archive executed UNKNOWN
receipt/archive probe FAIL (Fabric receipt currently binds its artifact manifest)
Fabric reconciliation PASS (Fabric question only)
RAVEL evaluator separate; normally UNKNOWN
```

The receipt/archive probe is retained as a negative compatibility observation;
it is not rewritten as an official execution binding. Native Fabric bundle
transfer and a receipt adapter that binds the MNCS archive remain a sibling
capability boundary.

Fabric execution is not a sandbox, independent evaluation, protected custody,
MNCS/MNCDS conformance, or promotion authority. Selection and future-final
material are rejected by the workload contract and are not dispatched.
10 changes: 10 additions & 0 deletions docs/PROJECT_MAP.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ regenerating the frozen records.
recorded outcomes.
- [Evidence guide](EVIDENCE_GUIDE.md) explains the evidence layers and claim
boundaries.
- [Fabric integration](FABRIC_INTEGRATION.md) documents the bounded RAVEL /
Forge / Fabric development path and its status boundaries.
- [Architecture gaps](ARCHITECTURE_GAPS.md) records the early design gaps.
- [`../tools/README.md`](../tools/README.md) documents evaluators, digest tools,
mutation checks, runtime capture, and 0.6 candidate derivation.
Expand All @@ -61,6 +63,10 @@ regenerating the frozen records.
freeze/selection infrastructure; it has not consumed selection data.
- `src/ravel/experience.py` binds scoped execution outcomes to advisory memory,
retaining negative and `UNKNOWN` outcomes.
- `src/ravel/fabric.py` defines the development-only Fabric workload and
reference-observation contracts, the public local-controller backend, and an
optional TLS-only network backend; `tools/ravel_fabric_reference.py` runs the
bounded branching/ring matrix.
- `src/ravel/policy.py` is the fail-closed frozen 0.6 policy loader; generated
C constants carry its threshold identity.
- `src/ravel/matched_compute.py` validates raw development comparator counts and
Expand All @@ -74,6 +80,10 @@ regenerating the frozen records.
- `mncs-forge.toml` declares the Forge-governed development workflows;
`src/ravel/mncs_bundles.py` delegates immutable execution-bundle operations
to MNCS when that optional sibling is installed.
- `config/ravel-fabric.example.toml` is a placeholder-only operator template;
`ravel_versions/0.6/ravel-0.6-fabric-observation.schema.json` and the family
compatibility lock version the public evidence boundary without making sibling
checkouts required for ordinary tests.
- `tools/ravel_0_6_decompose.py` losslessly emits generated C component units
and a unity wrapper; `ravel_versions/0.6/ravel_0_6/README.md` documents the
current ABI boundary. `ravel_0_6_checkpoint.[ch]` and
Expand Down
28 changes: 23 additions & 5 deletions docs/PROVIDER_RUNTIME.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,29 @@ normal test suite fail.
The local Forge `0.1.0a2` checkout was inspected and exercised for this
iteration. Its current CLI exposes typed project, provider, verifier, candidate,
workflow, bundle, and lifecycle operations; RAVEL's project-local configuration
declares 13 development workflows in a fresh local Forge ledger; twelve
bounded workflows passed and live family compatibility remained
`UNKNOWN` for unavailable sibling producer checkouts. The project-scoped Forge readiness policy is separate from the frozen
RAVEL preregistration and does not consume selection data. The precedence is
`FAIL > UNKNOWN > PASS`.
declares 17 development workflows. The new Fabric capability and family-lock
workflow passed; the family-lock workflow currently remains `UNKNOWN` because
the inspected Fabric checkout has uncommitted sibling changes. The Fabric
reference workflow passed through Forge after the local reference matrix was
repaired. The project-scoped Forge readiness
policy is separate from the frozen RAVEL preregistration and does not consume
selection data. The precedence is `FAIL > UNKNOWN > PASS`.
`ForgeCliProvider` invokes that JSON interface when explicitly configured and
preserves lifecycle rejection as raw `UNKNOWN`. Forge remains optional for the
core package and is not reimplemented by RAVEL.

## Fabric execution substrate

`ravel.fabric.FabricLocalBackend` is the development reference implementation.
It uses only the public MNCS Fabric service/controller/worker boundary and
delegates bundle construction to the official MNCS execution-bundle tooling.
The reference matrix executes both providers with two logical local workers.
Fabric reconciliation passes for matching immutable records; RAVEL records the
replication scope and does not call it independence.

`FabricNetworkBackend` is optional and unavailable without explicit operator
TLS configuration. It requires a matching pre-staged Fabric manifest and never
falls back to SSH or unauthenticated transport. Missing capabilities, missing
trust material, conflicting replays, and incomplete bundle execution facts stay
`UNKNOWN` or `FAIL` according to the governing contract; they are not converted
to RAVEL success.
38 changes: 37 additions & 1 deletion mncs-forge.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ root = "."
[paths]
candidates = []
generated = ["build"]
contracts = ["ravel_versions/0.4", "ravel_versions/0.5", "ravel_versions/0.6/ravel-0.6-preregistration.json", "ravel_versions/0.6/ravel-0.6-preregistration.schema.json"]
contracts = ["ravel_versions/0.4", "ravel_versions/0.5", "ravel_versions/0.6/ravel-0.6-preregistration.json", "ravel_versions/0.6/ravel-0.6-preregistration.schema.json", "ravel_versions/0.6/ravel-0.6-fabric-observation.schema.json", "ravel_versions/0.6/ravel-0.6-family-compatibility-lock.json"]
references = ["docs", "README.md"]
evaluators = ["src/ravel/development_evaluator.py"]
acceptance_policies = ["ravel_versions/0.6/ravel-0.6-forge-development-policy.json", "ravel_versions/0.6/ravel-0.6-preregistration.json"]
Expand Down Expand Up @@ -152,3 +152,39 @@ command = ["python3", "tools/ravel_bundle_check.py"]
provider_protocol = false
subject = "project"
disclosure = "compact"

[[workflows]]
name = "fabric-capabilities"
category = "inspection"
mode = "development"
command = ["python3", "tools/ravel_forge_check.py", "fabric-capabilities"]
provider_protocol = false
subject = "project"
disclosure = "compact"

[[workflows]]
name = "fabric-reference"
category = "differential_behavior"
mode = "development"
command = ["python3", "tools/ravel_forge_check.py", "fabric-reference"]
provider_protocol = false
subject = "project"
disclosure = "compact"

[[workflows]]
name = "fabric-negative"
category = "mutation"
mode = "development"
command = ["python3", "tools/ravel_forge_check.py", "fabric-negative"]
provider_protocol = false
subject = "project"
disclosure = "compact"

[[workflows]]
name = "family-compatibility-lock"
category = "inspection"
mode = "development"
command = ["python3", "tools/ravel_forge_check.py", "family-compatibility-lock"]
provider_protocol = false
subject = "project"
disclosure = "compact"
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ where = ["src"]
"ravel_versions/0.6/ravel-0.6-preregistration.schema.json",
"ravel_versions/0.6/ravel-0.6-transaction.schema.json",
"ravel_versions/0.6/ravel-0.6-matched-compute.schema.json",
"ravel_versions/0.6/ravel-0.6-fabric-observation.schema.json",
"ravel_versions/0.6/ravel-0.6-family-compatibility-lock.json",
]

[tool.pytest.ini_options]
Expand Down
5 changes: 4 additions & 1 deletion ravel_versions/0.6/Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
CC ?= cc
CFLAGS ?= -std=c11 -O3 -Wall -Wextra -Werror -pedantic

.PHONY: build behavioral-test transaction-test component-test policy-test decomposition-test negative-test provider-test evaluator-test forge-test receipt-test abi-test compiler-matrix sanitizers
.PHONY: build behavioral-test transaction-test component-test policy-test decomposition-test negative-test provider-test evaluator-test forge-test receipt-test abi-test fabric-test compiler-matrix sanitizers

build:
@set -e; out=$$(mktemp -d); python3 tools/ravel_0_6_build.py build --output-dir "$$out"; \
Expand Down Expand Up @@ -40,6 +40,9 @@ receipt-test:
abi-test:
python3 -m unittest tests/test_ravel_0_6_decomposition.py tests/test_mncs_bundles.py

fabric-test:
python3 -m unittest tests/test_ravel_fabric.py

compiler-matrix:
@set -eu; for compiler in gcc clang; do \
if command -v "$$compiler" >/dev/null 2>&1; then \
Expand Down
Loading
Loading