Orrery.
← All Stars

public Star · 0.1.0

orrery/patch-capture

Capture a sealed patch digest from before/after caller file snapshots.

Use this when

  • You need to capture patch receipt evidence for a tree node
  • You have before/after manifests and want changed paths plus line stats

Not for

  • Applying patches or writing files
  • Hosting unified diffs as a product surface
  • Unbounded repository walks

Inputs / Outputs

Inputs

NameTypeNotes
before required object snapshot with files[]
after required object snapshot with files[]

Outputs

NameTypeNotes
patch_digest string
changed_paths array
line_stats object
envelope signed-envelope

Example

{
  "method": "tools/call",
  "params": {
    "name": "capture",
    "arguments": {
      "before": {},
      "after": {}
    }
  }
}

Tools

capture Capture a patch receipt from before/after file snapshots or manifest pairs; returns patch_digest, changed paths, and line stats · schema
{
  "type": "object",
  "properties": {
    "before": {
      "type": "object",
      "properties": {
        "files": {
          "type": "array",
          "maxItems": 10000,
          "items": {
            "type": "object",
            "properties": {
              "path": {
                "type": "string",
                "minLength": 1,
                "maxLength": 512
              },
              "sha256": {
                "type": "string",
                "minLength": 64,
                "maxLength": 64
              },
              "size": {
                "type": "integer",
                "minimum": 0
              },
              "content": {
                "type": "string",
                "maxLength": 262144
              }
            },
            "required": [
              "path",
              "sha256",
              "size"
            ],
            "additionalProperties": false
          }
        }
      },
      "required": [
        "files"
      ],
      "additionalProperties": false
    },
    "after": {
      "type": "object",
      "properties": {
        "files": {
          "type": "array",
          "maxItems": 10000,
          "items": {
            "type": "object",
            "properties": {
              "path": {
                "type": "string",
                "minLength": 1,
                "maxLength": 512
              },
              "sha256": {
                "type": "string",
                "minLength": 64,
                "maxLength": 64
              },
              "size": {
                "type": "integer",
                "minimum": 0
              },
              "content": {
                "type": "string",
                "maxLength": 262144
              }
            },
            "required": [
              "path",
              "sha256",
              "size"
            ],
            "additionalProperties": false
          }
        }
      },
      "required": [
        "files"
      ],
      "additionalProperties": false
    }
  },
  "required": [
    "before",
    "after"
  ],
  "additionalProperties": false
}

In constellations