# c2pa-org/softbinding-algorithm-list architecture

> Architecture diagram of the GitHub repository c2pa-org/softbinding-algorithm-list, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-06-01). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/c2pa-org/softbinding-algorithm-list
- Repository: https://github.com/c2pa-org/softbinding-algorithm-list

## Overview

##### Project type and purpose
- This is not a typical application but an open-source specification repository. It maintains and publishes an authoritative JSON list of “soft binding” algorithms for the C2PA specification, along with a corresponding JSON schema that validates entries.

##### File structure
- Top-level files only:
- softbinding-algorithm-list.json – the array of approved algorithms
- softbinding-algorithm-entry-schema.json – the JSON Schema for validating each entry
- README.md – project description and contribution process
- LICENSE – open-source license information
- No source code, build scripts, or runtime components: the “system” is a data repository and a pull-request process.

##### Key insights from the README
- Developers request additions/amendments by submitting pull requests that add/edit entries in the JSON array and conform to the JSON schema.
- A Technical Working Group (TWG) reviews and approves or rejects changes according to C2PA contribution processes.
- The resulting JSON file is the definitive list used by C2PA-conformant tools to decode soft bindings.

a. Repository (GitHub)
b. JSON Schema (softbinding-algorithm-entry-schema.json)
c. JSON List (softbinding-algorithm-list.json)
d. Contributors (developers of soft binding algorithms)
e. Pull-Request & Review Process (CI/Validation + C2PA TWG)
f. Consumers (C2PA-compliant tools retrieving the list)

##### Relationships & interactions
- Contributors fork/clone → create PR with new/updated entries → JSON validation step (schema) → TWG review → merge into main → consumers fetch updated JSON list.
- The schema component enforces data integrity before any merge.
- Consumers (e.g., watermark decoders) read the list to map `alg` identifiers to algorithm metadata.

##### Architectural patterns/design principles
- Data-centric repository pattern: single source of truth held in version control.
- Schema-driven validation: JSON Schema enforces structure, types, required fields.
- Git-based governance: branching, code (data) reviews, pull requests.

## Diagram (Mermaid)

```mermaid
flowchart TD
    %% Actors
    Contributor["Contributor"]:::actor
    Consumers["Consumers\n(C2PA Tools)"]:::actor

    %% Platform and Data Artifacts
    subgraph "GitHub Repository"
        direction TB
        Repo["GitHub Repository"]:::platform
        README["README.md"]:::data
        LICENSE["LICENSE"]:::data
        Schema["softbinding-algorithm-entry-schema.json"]:::data
        List["softbinding-algorithm-list.json"]:::data
    end

    %% Processes
    SchemaValidator["Schema Validator"]:::process
    TWGReview["TWG Review"]:::process

    %% Workflow
    Contributor -->|create PR| Repo
    Repo -->|validate JSON| SchemaValidator
    SchemaValidator -->|valid submission| TWGReview
    TWGReview -->|approve/reject| Repo
    Repo -->|updates JSON List| List
    List -->|fetched by| Consumers

    %% Click Events
    click Repo "https://github.com/c2pa-org/softbinding-algorithm-list/tree/main//"
    click README "https://github.com/c2pa-org/softbinding-algorithm-list/blob/main//README.md"
    click LICENSE "https://github.com/c2pa-org/softbinding-algorithm-list/tree/main//LICENSE"
    click Schema "https://github.com/c2pa-org/softbinding-algorithm-list/blob/main//softbinding-algorithm-entry-schema.json"
    click List "https://github.com/c2pa-org/softbinding-algorithm-list/blob/main//softbinding-algorithm-list.json"

    %% Styles
    classDef actor fill:#f9f,stroke:#333,stroke-width:2px
    classDef platform fill:#bfb,stroke:#333,stroke-width:2px
    classDef data fill:#bbf,stroke:#333,stroke-width:2px,shape:cylinder
    classDef process fill:#fbf,stroke:#333,stroke-width:2px
```
