meta.reviews.summary_format

The summary contains these fields:

FieldMeaning
anchorComplete dotted ID of the anchor being validated.
started_at_unix_secondsTime the review was started, in seconds since the Unix epoch.
recorded_at_unix_secondsTime the completed report was recorded; null until recording completes.
schema_versionVersion of the persisted record format.
policy_versionVersion of the rules governing review acceptance.

Freshness is determined by comparing the recorded inputs with current source, as defined by meta.reviews.fragment_freshness.

Read in specification context · design/meta/reviews.md

Implementation

Implemented crates/sage-meta/src/review.rs:82–87

sage_meta::review · lib:sage_meta

#![allow(unused)]
fn main() {
// {anchor}`meta.reviews.summary_format`
#[derive(Serialize, Deserialize)]
#[serde(deny_unknown_fields)]
struct Summary {
    anchor: String,
    started_at_unix_seconds: u64,

}

See more source ↗

Tests and review

Indexed tests and the implementation-completeness and test-adequacy review; no test run is implied.

Implemented sage_meta::start_invalidates_previous_success_and_record_is_required

crates/sage-meta/tests/review.rs · test:review

#![allow(unused)]
fn main() {
#[test]
#[sage::test(meta.reviews.validation_layout)]
#[sage::test(meta.reviews.summary_format)]
#[sage::test(meta.reviews.preparation)]
#[sage::test(meta.reviews.record_required)]
#[sage::test(meta.reviews.recorded_reads)]
#[sage::test(meta.reviews.recording)]
#[sage::test(meta.reviews.decisions)]
fn start_invalidates_previous_success_and_record_is_required() {
    let fixture = Fixture::new();
    assert!(!sage_meta::check(&fixture.0).is_valid());
    fixture.approve();
    assert!(sage_meta::check(&fixture.0).is_valid());
    let input = fixture.start();
    assert_eq!(fixture.input(), input);
    let summary = fixture.summary();
    assert_eq!(summary["anchor"], "demo.rule");
    assert!(summary["started_at_unix_seconds"].as_u64().unwrap() > 0);
    assert!(summary["recorded_at_unix_seconds"].is_null());
    assert_eq!(summary["schema_version"], review::SCHEMA_VERSION);
    assert_eq!(summary["policy_version"], review::POLICY_VERSION);
    assert!(summary.get("input_sha256").is_none());
    assert!(!fixture.0.join("validations/demo.rule/output.json").exists());
    assert!(!sage_meta::check(&fixture.0).is_valid());
    let saved = review::load_saved(&fixture.0.join("validations")).unwrap();
    assert_eq!(saved.reviews.len(), 1);
    assert!(saved.reviews[0].output.is_none());
    fixture.write("helper.txt", "context\n");
    review::capture_read(&fixture.0, "demo.rule", "helper.txt", Selector::WholeFile).unwrap();
    assert!(!sage_meta::check(&fixture.0).is_valid());
    let bytes = std::fs::read(fixture.0.join("validations/demo.rule/input.json")).unwrap();
    review::record(&fixture.0, "demo.rule", &Fixture::report()).unwrap();
    assert_eq!(
        bytes,
        std::fs::read(fixture.0.join("validations/demo.rule/input.json")).unwrap()
    );
    assert!(
        fixture.summary()["recorded_at_unix_seconds"]
            .as_u64()
            .unwrap()
            >= summary["started_at_unix_seconds"].as_u64().unwrap()
    );
    assert!(sage_meta::check(&fixture.0).is_valid());
    assert!(review::record(&fixture.0, "demo.rule", &Fixture::report()).is_err());
    assert!(
        review::capture_read(&fixture.0, "demo.rule", "helper.txt", Selector::WholeFile).is_err()
    );
}
}

See more source ↗

Implemented sage_meta::unsupported_versions_and_mismatched_identity_cannot_pass

crates/sage-meta/tests/review.rs · test:review

#![allow(unused)]
fn main() {
#[test]
#[sage::test(meta.reviews.gate)]
#[sage::test(meta.reviews.summary_format)]
#[sage::test(meta.reviews.review_diagnostics)]
#[sage::test(meta.reviews.staleness)]
#[sage::test(meta.reviews.validation_layout)]
fn unsupported_versions_and_mismatched_identity_cannot_pass() {
    for field in ["schema_version", "policy_version", "anchor"] {
        let fixture = Fixture::new();
        fixture.approve();
        let mut summary = fixture.summary();
        summary[field] = if field == "anchor" {
            "demo.other".into()
        } else {
            999.into()
        };
        fixture.write(
            "validations/demo.rule/summary.json",
            &serde_json::to_string(&summary).unwrap(),
        );
        let report = sage_meta::check(&fixture.0);
        let error = report.ensure_valid().unwrap_err().to_string();
        assert!(error.contains("demo.rule"), "{error}");
        assert!(error.contains("sage-review-checklist/SKILL.md"), "{error}");
        let reason = if field == "anchor" {
            "does not match"
        } else {
            "unsupported schema/policy"
        };
        assert!(error.contains(reason), "{error}");
    }
}
}

See more source ↗

Review: Accepted · final_quality.

Fresh followup review of meta.reviews.summary_format. Preserved the prior input/output, started a fresh review and read the complete claim, sole implementation association and both associated tests. Recaptured all prior additional dependencies: review fixture helpers lines 1–118, fragment_freshness claim, invalid_reports_and_stale_inputs_never_complete_an_active_review, lib.rs and check.rs. Compared all fragments by path/selector and implementation/test metadata. The only differences are a placeholder_status comment association in review.rs and a validation_layout attribute on unsupported_versions_and_mismatched_identity_cannot_pass. No behavior, test assertions, claim, metadata for this anchor or helper changed; no captures were removed. I evaluated that delta against the complete prior assessment and current source rather than blindly refreshing it.

The ordinary Summary association in review.rs accounts for all five fields: anchor is the complete dotted identity; started_at_unix_seconds is u64 seconds from SystemTime duration_since UNIX_EPOCH; recorded_at_unix_seconds is Option<u64> serialized as null initially, then populated during record after output writing; schema_version and policy_version use separate current constants. start validates the anchor against inventory and creates these fields. record loads/validates the summary, preserves the start time and updates recording time; read_summary rejects mismatched identity and unsupported format/policy versions. These paths all lie in the captured associated file. Timestamps serve as metadata, not freshness evidence: input_errors compares current initial fragments and associations and reselects appended fragments for exact source equality. record rejects stale inputs, while shared check orchestration loads and validates saved records and computes acceptance through the same freshness mechanism. The captured fragment_freshness claim provides the referenced detailed rules.

Both ordinary tests have direct substantive assertions. start_invalidates_previous_success_and_record_is_required reads summary JSON and checks demo.rule, positive start time, initially null recording time, both version constants, and no legacy input_sha256. It restarts a successful review, verifies output removal and unfinished loading, appends a dependency read, then records and verifies unchanged input bytes, recording time at least start time, restored validity and rejection of another record/read after completion. unsupported_versions_and_mismatched_identity_cannot_pass independently corrupts each version and the anchor, asserting failure with matching reason, anchor identity and review guidance. The captured supporting stale-input test changes implementation source, requires record failure, verifies captured input bytes stay unchanged and shared validation remains failing; requested edits also remain failing. Thus freshness is checked against source rather than summary time/digest. Detailed selector behavior remains under the explicitly referenced freshness claim.

No TODO/N/A evidence exists for this anchor. All summary requirements and both tests remain accounted for after the two annotation-only changes. No source edits, tests, formatting or workspace build were performed in this followup; executed review start/read, capture comparison and record only. Prior/central execution was not represented as new execution. No requested edits.

Browse meta anchors

116 anchors

Specification anchors and declared coverage
AnchorImplementationTests
meta (116)102 Implemented24 TODO103 Implemented36 TODO
meta.anchors (22)22 Implemented21 Implemented12 TODO
anchor_pagesImplementedImplementedTODO
book_explorerImplementedImplementedTODO
canonical_sourcesImplementedImplementedTODO
meta.anchors.content (7)7 Implemented7 Implemented
blocksImplementedImplemented
explicit_endImplementedImplemented
headingImplementedImplemented
literal_syntaxImplementedImplemented
next_anchorImplementedImplemented
source_endImplementedImplemented
unmatched_endImplementedImplemented
context_navigationImplementedImplementedTODO
evidence_statusImplementedImplementedTODO
explorer_navigationImplementedTODO
implementation_coverageImplementedImplementedTODO
implementation_referencesImplementedImplementedTODO
placeholder_statusImplementedImplementedTODO
point_excerptsImplementedImplementedTODO
region_balanceImplementedImplemented
region_excerptsImplementedImplementedTODO
test_coverageImplementedImplemented
test_referencesImplementedImplemented
unique_namesImplementedImplementedTODO
meta.book (21)10 Implemented18 TODO12 Implemented18 TODO
anchor_movesImplementedTODOImplementedTODO
authorityImplementedTODOImplementedTODO
browser_deliveryTODOImplementedTODO
browser_dependenciesTODOTODO
browser_rust_sourceTODOTODO
browser_searchTODOTODO
browser_serveTODOTODO
browser_structureTODOTODO
chapter_namesImplementedTODOImplementedTODO
crate_ownershipImplementedImplemented
crates_landingImplementedImplemented
entity_linksTODOTODO
index_groupsImplementedTODOImplementedTODO
index_namespace_pagesImplementedImplemented
index_rowsImplementedTODOImplementedTODO
index_statusImplementedTODOImplementedTODO
rfd_changesTODOTODO
sage_chaptersTODOImplementedTODO
self_descriptionTODOTODO
shared_modelImplementedTODOImplementedTODO
source_rolesTODOTODO
meta.contracts (4)4 Implemented3 TODO4 Implemented3 TODO
cache_invocationsImplementedTODOImplementedTODO
correspondenceImplementedImplemented
observation_coverageImplementedTODOImplementedTODO
validated_sessionImplementedTODOImplementedTODO
meta.language (39)39 Implemented39 Implemented
meta.language.calls (2)2 Implemented2 Implemented
declaredImplementedImplemented
forbiddenImplementedImplemented
meta.language.classes (3)3 Implemented3 Implemented
abstract_completeImplementedImplemented
override_signatureImplementedImplemented
single_inheritanceImplementedImplemented
meta.language.contexts (1)1 Implemented1 Implemented
inheritanceImplementedImplemented
meta.language.envelopes (7)7 Implemented7 Implemented
class_callsImplementedImplemented
createsImplementedImplemented
direct_callsImplementedImplemented
leafImplementedImplemented
permissionsImplementedImplemented
readsImplementedImplemented
receiver_callsImplementedImplemented
meta.language.fields (2)2 Implemented2 Implemented
context_stateImplementedImplemented
kindsImplementedImplemented
meta.language.methods (2)2 Implemented2 Implemented
kindsImplementedImplemented
proseImplementedImplemented
meta.language.model (3)3 Implemented3 Implemented
forbidden_pathsImplementedImplemented
inherited_prohibitionsImplementedImplemented
virtual_dispatchImplementedImplemented
meta.language.types (19)19 Implemented19 Implemented
argument_arityImplementedImplemented
declaration_proseImplementedImplemented
enum_variantsImplementedImplemented
field_proseImplementedImplemented
generic_parametersImplementedImplemented
member_commasImplementedImplemented
name_resolutionImplementedImplemented
opaque_representationImplementedImplemented
preludeImplementedImplemented
qualified_namesImplementedImplemented
recursive_valuesImplementedImplemented
struct_fieldsImplementedImplemented
tuplesImplementedImplemented
type_expressionsImplementedImplemented
unique_fieldsImplementedImplemented
unique_parametersImplementedImplemented
unique_variantsImplementedImplemented
unknown_namesImplementedImplemented
variant_proseImplementedImplemented
meta.reviews (27)27 Implemented27 Implemented
claim_textImplementedImplemented
complete_test_setImplementedImplemented
decisionsImplementedImplemented
fragment_associationsImplementedImplemented
fragment_formatImplementedImplemented
fragment_freshnessImplementedImplemented
gateImplementedImplemented
input_formatImplementedImplemented
input_fragmentsImplementedImplemented
output_formatImplementedImplemented
preparationImplementedImplemented
record_requiredImplementedImplemented
recorded_readsImplementedImplemented
recordingImplementedImplemented
review_delegationImplementedImplemented
review_diagnosticsImplementedImplemented
review_instructionsImplementedImplemented
review_scopeImplementedImplemented
selector_claimImplementedImplemented
selector_line_rangeImplementedImplemented
selector_testImplementedImplemented
selector_whole_fileImplementedImplemented
source_representationImplementedImplemented
stalenessImplementedImplemented
summary_formatImplementedImplemented
test_sourceImplementedImplemented
validation_layoutImplementedImplemented
meta.validation (3)3 TODO3 TODO
claim_specific_evidenceTODOTODO
independent_inspectionTODOTODO
review_packetsTODOTODO