# xaravel/framework architecture

> Architecture diagram of the GitHub repository xaravel/framework, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-22). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/xaravel/framework
- Repository: https://github.com/xaravel/framework

## Overview

Xaravel is a planned TypeScript port of Laravel for Bun; the README says it is still in planning, so the package tree does not establish that the documented framework capabilities are implemented. The strongest visible workflow is conformance engineering: inventory upstream tests, prepare oracle requests and fixtures, then run the harness to compare results. The graph also shows ownership and escalation controls and the Boost framework tooling. Edges reflect README statements or the supplied source index; unsampled package internals and runtime wiring are intentionally not inferred.

Main entry points: [`conformance/harness/harness.ts`](https://github.com/xaravel/framework/blob/main/conformance/harness/harness.ts) (Conformance runner), [`tools/ownership/ownership.ts`](https://github.com/xaravel/framework/blob/main/tools/ownership/ownership.ts) (Edit ownership), [`tools/inventory/inventory.ts`](https://github.com/xaravel/framework/blob/main/tools/inventory/inventory.ts) (Test inventory), [`tools/oracle/oracle.ts`](https://github.com/xaravel/framework/blob/main/tools/oracle/oracle.ts) (Oracle evaluation)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_port["Laravel port"]
  node_packages["Framework packages"]
end

subgraph group_conformance["Conformance"]
  node_inventory["Test inventory<br/>[inventory.ts]"]
  node_harness["Conformance runner<br/>[harness.ts]"]
  node_compare["Result comparison<br/>[compare.ts]"]
  node_junit["JUnit output<br/>[junit.ts]"]
  node_xaraveltests["Ported tests<br/>[xaravel.ts]"]
  node_expectations["Test expectations<br/>[expectations.ts]"]
end

subgraph group_oracle["Upstream oracle"]
  node_oracle["Oracle evaluation<br/>[oracle.ts]"]
  node_requests["Oracle requests<br/>[request.ts]"]
  node_fixtures["Oracle fixtures<br/>[fixtures.ts]"]
  node_upstream["Upstream snapshots<br/>[upstream.ts]"]
end

subgraph group_governance["Port governance"]
  node_ownership["Edit ownership<br/>[ownership.ts]"]
  node_phasegate["Port phase gate<br/>[phase-gate.ts]"]
  node_escalations["Escalation records<br/>[escalations.ts]"]
  node_protected["Protected paths<br/>[protected-paths.ts]"]
  node_pinbump["Upstream pin updates<br/>[pin-bump.ts]"]
end

subgraph group_boost["Boost tooling"]
  node_boostdata["Boost data access<br/>[data.ts]"]
  node_boostserver["Boost server<br/>[server.ts]"]
end

node_maintainer(("Maintainer"))
node_laravel["Laravel suites"]

node_laravel -->|"supplies test cases"| node_inventory
node_laravel -->|"provides snapshots"| node_upstream
node_inventory -->|"feeds test entries"| node_harness
node_expectations -->|"supplies variants"| node_harness
node_ownership -->|"validates manifests"| node_harness
node_harness -->|"compares results"| node_compare
node_compare -->|"writes reports"| node_junit
node_harness -->|"runs port tests"| node_xaraveltests
node_harness -.->|"tests the port"| node_packages
node_upstream -->|"provides pinned inputs"| node_oracle
node_fixtures -->|"prepares evaluations"| node_oracle
node_fixtures -->|"maps request files"| node_requests
node_requests -.->|"encodes inputs"| node_oracle
node_pinbump -->|"reads inventory"| node_inventory
node_pinbump -->|"checks signatures"| node_phasegate
node_ownership -->|"uses phase checks"| node_phasegate
node_ownership -->|"loads escalations"| node_escalations
node_ownership -->|"checks protected paths"| node_protected
node_maintainer -->|"runs conformance"| node_harness
node_maintainer -->|"checks edits"| node_ownership
node_boostserver -->|"uses data access"| node_boostdata

click node_packages "https://github.com/xaravel/framework/tree/main/packages"
click node_inventory "https://github.com/xaravel/framework/blob/main/tools/inventory/inventory.ts"
click node_harness "https://github.com/xaravel/framework/blob/main/conformance/harness/harness.ts"
click node_compare "https://github.com/xaravel/framework/blob/main/conformance/harness/compare.ts"
click node_junit "https://github.com/xaravel/framework/blob/main/conformance/harness/junit.ts"
click node_xaraveltests "https://github.com/xaravel/framework/blob/main/conformance/harness/xaravel.ts"
click node_expectations "https://github.com/xaravel/framework/blob/main/tools/expectations/expectations.ts"
click node_oracle "https://github.com/xaravel/framework/blob/main/tools/oracle/oracle.ts"
click node_requests "https://github.com/xaravel/framework/blob/main/tools/oracle/request.ts"
click node_fixtures "https://github.com/xaravel/framework/blob/main/tools/oracle/fixtures.ts"
click node_upstream "https://github.com/xaravel/framework/blob/main/tools/upstream/upstream.ts"
click node_ownership "https://github.com/xaravel/framework/blob/main/tools/ownership/ownership.ts"
click node_phasegate "https://github.com/xaravel/framework/blob/main/tools/ownership/phase-gate.ts"
click node_escalations "https://github.com/xaravel/framework/blob/main/tools/escalations/escalations.ts"
click node_protected "https://github.com/xaravel/framework/blob/main/tools/protected-paths/protected-paths.ts"
click node_pinbump "https://github.com/xaravel/framework/blob/main/tools/pin-bump/pin-bump.ts"
click node_boostdata "https://github.com/xaravel/framework/blob/main/tools/boost-framework/src/data.ts"
click node_boostserver "https://github.com/xaravel/framework/blob/main/tools/boost-framework/src/server.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_packages toneBlue
class node_inventory,node_harness,node_compare,node_junit,node_xaraveltests,node_expectations toneAmber
class node_oracle,node_requests,node_fixtures,node_upstream toneMint
class node_ownership,node_phasegate,node_escalations,node_protected,node_pinbump toneRose
class node_boostdata,node_boostserver,node_maintainer,node_laravel toneIndigo
```

## Components

### Laravel port

- [Framework packages](https://github.com/xaravel/framework/tree/main/packages): `packages`

### Conformance

- [Test inventory](https://github.com/xaravel/framework/blob/main/tools/inventory/inventory.ts): `tools/inventory/inventory.ts`
- [Conformance runner](https://github.com/xaravel/framework/blob/main/conformance/harness/harness.ts): `conformance/harness/harness.ts`
- [Result comparison](https://github.com/xaravel/framework/blob/main/conformance/harness/compare.ts): `conformance/harness/compare.ts`
- [JUnit output](https://github.com/xaravel/framework/blob/main/conformance/harness/junit.ts): `conformance/harness/junit.ts`
- [Ported tests](https://github.com/xaravel/framework/blob/main/conformance/harness/xaravel.ts): `conformance/harness/xaravel.ts`
- [Test expectations](https://github.com/xaravel/framework/blob/main/tools/expectations/expectations.ts): `tools/expectations/expectations.ts`

### Upstream oracle

- [Oracle evaluation](https://github.com/xaravel/framework/blob/main/tools/oracle/oracle.ts): `tools/oracle/oracle.ts`
- [Oracle requests](https://github.com/xaravel/framework/blob/main/tools/oracle/request.ts): `tools/oracle/request.ts`
- [Oracle fixtures](https://github.com/xaravel/framework/blob/main/tools/oracle/fixtures.ts): `tools/oracle/fixtures.ts`
- [Upstream snapshots](https://github.com/xaravel/framework/blob/main/tools/upstream/upstream.ts): `tools/upstream/upstream.ts`

### Port governance

- [Edit ownership](https://github.com/xaravel/framework/blob/main/tools/ownership/ownership.ts): `tools/ownership/ownership.ts`
- [Port phase gate](https://github.com/xaravel/framework/blob/main/tools/ownership/phase-gate.ts): `tools/ownership/phase-gate.ts`
- [Escalation records](https://github.com/xaravel/framework/blob/main/tools/escalations/escalations.ts): `tools/escalations/escalations.ts`
- [Protected paths](https://github.com/xaravel/framework/blob/main/tools/protected-paths/protected-paths.ts): `tools/protected-paths/protected-paths.ts`
- [Upstream pin updates](https://github.com/xaravel/framework/blob/main/tools/pin-bump/pin-bump.ts): `tools/pin-bump/pin-bump.ts`

### Boost tooling

- [Boost data access](https://github.com/xaravel/framework/blob/main/tools/boost-framework/src/data.ts): `tools/boost-framework/src/data.ts`
- [Boost server](https://github.com/xaravel/framework/blob/main/tools/boost-framework/src/server.ts): `tools/boost-framework/src/server.ts`

### Other components

- **Maintainer**
- **Laravel suites**

## Connections

- Laravel suites → Test inventory: supplies test cases (evidence: `tools/inventory/inventory.ts`)
- Laravel suites → Upstream snapshots: provides snapshots (evidence: `README.md`)
- Test inventory → Conformance runner: feeds test entries (evidence: `conformance/harness/harness.ts`)
- Test expectations → Conformance runner: supplies variants (evidence: `conformance/harness/harness.ts`)
- Edit ownership → Conformance runner: validates manifests (evidence: `conformance/harness/harness.ts`)
- Conformance runner → Result comparison: compares results (evidence: `conformance/harness/harness.ts`)
- Result comparison → JUnit output: writes reports (evidence: `conformance/harness/compare.ts`)
- Conformance runner → Ported tests: runs port tests (evidence: `conformance/harness/harness.ts`)
- Conformance runner → Framework packages: tests the port
- Upstream snapshots → Oracle evaluation: provides pinned inputs (evidence: `tools/oracle/oracle.ts`)
- Oracle fixtures → Oracle evaluation: prepares evaluations (evidence: `tools/oracle/fixtures.ts`)
- Oracle fixtures → Oracle requests: maps request files (evidence: `tools/oracle/fixtures.ts`)
- Oracle requests → Oracle evaluation: encodes inputs (evidence: `tools/oracle/request.ts`)
- Upstream pin updates → Test inventory: reads inventory (evidence: `tools/pin-bump/pin-bump.ts`)
- Upstream pin updates → Port phase gate: checks signatures (evidence: `tools/pin-bump/pin-bump.ts`)
- Edit ownership → Port phase gate: uses phase checks (evidence: `tools/ownership/ownership.ts`)
- Edit ownership → Escalation records: loads escalations (evidence: `tools/ownership/ownership.ts`)
- Edit ownership → Protected paths: checks protected paths (evidence: `tools/ownership/ownership.ts`)
- Maintainer → Conformance runner: runs conformance (evidence: `conformance/harness/harness.ts`)
- Maintainer → Edit ownership: checks edits (evidence: `tools/ownership/ownership.ts`)
- Boost server → Boost data access: uses data access (evidence: `tools/boost-framework/src/server.ts`)
