Compare commits

...
27 Commits
Author SHA1 Message Date
shinyobjectz e2c4056347 Skills: the check works in a public checkout. The retired-word glossary is read only where it is (RAEA_GLOSSARY, else docs/skills.glossary.md), and a section's source may be in the maintainers' checkout (RAEA_LIVE), since both are private now 2026-11-07 13:43:45 -08:00
shinyobjectz 3932de270b Skills: files.md regenerated from the public tree (the private signer's ~/.raea rows are gone) 2026-11-07 13:42:17 -08:00
shinyobjectz 11fd9d763e PF5: public CI on GitHub's hosted runners (guard, L0's repo-wide gates, a fresh clone's cargo check on macOS and Linux)
The cutover's first commit should have carried this file: the split moved it to .github/workflows/ci.yml, then removed
raea-dev's own CI at the same path along with the private paths. Every pull request and push to main now runs the
names-and-secrets guard, the repo-wide gates and cargo check --locked of raea-cli.
2026-11-07 13:40:32 -08:00
shane 3381690416 raea is developed here now (public-first)
This repository was an export of a private one; from this commit on it is where raea is developed. Contributions:
CONTRIBUTING.md.
2026-11-07 13:36:50 -08:00
shane cc729f2b25 Merge public PR #11 from JimGHTB12: check: flashing past WCAG 2.3.1 is a P1
Landed in raea through the private development repository with JimGHTB12 as author (a later export). This merge brings the original commits into this repository's history so they're credited here; it changes no files.
2026-11-07 09:47:07 -08:00
shane e8876bbe32 Merge public PR #10 from JimGHTB12: check: a freeze that runs to the end of the file is found
Landed in raea through the private development repository with JimGHTB12 as author (a later export). This merge brings the original commits into this repository's history so they're credited here; it changes no files.
2026-11-07 09:47:07 -08:00
shane 89cd67f664 Merge public PR #7 from tobitege: security updates, and the Windows build and raea play fixed
Landed in raea through the private development repository with tobitege as author (a later export). This merge brings the original commits into this repository's history so they're credited here; it changes no files.
2026-11-07 09:47:07 -08:00
shane b271b3b26c Merge public PR #5 from knowsuchagency: check: a voice ending a sentence isn't a dead stop
Landed in raea through the private development repository with knowsuchagency as author (export 1dff4f0). This merge brings the original commits into this repository's history so they're credited here; it changes no files.
2026-11-07 09:47:07 -08:00
shane 29cd01fd1b Merge public PR #3 from kumanday: raea render PAGE.html works from an install, and HTML pages animate
Landed in raea through the private development repository with kumanday as author (export 1dff4f0). This merge brings the original commits into this repository's history so they're credited here; it changes no files.
2026-11-07 09:47:06 -08:00
shane 12e7e30e19 Merge public PR #2 from kumanday: render --alpha: transparent PNGs for overlays
Landed in raea through the private development repository with kumanday as author (export 1dff4f0). This merge brings the original commits into this repository's history so they're credited here; it changes no files.
2026-11-07 09:47:06 -08:00
shane b6f91baa7f Merge public PR #1 from kumanday: Stills of a 2D composition skip the whole-timeline 3D pass
Landed in raea through the private development repository with kumanday as author (export 1dff4f0). This merge brings the original commits into this repository's history so they're credited here; it changes no files.
2026-11-07 09:47:06 -08:00
shane d3c399b4d5 raea origin/main 2026-11-07 01:29:24 -08:00
shane bd1ccec7f9 Post releases to the raea Discord 2026-11-06 23:20:31 -08:00
shinyobjectz c6243796a3 raea a6df6e9b3 2026-11-06 21:07:12 -08:00
shinyobjectz 6153823132 raea aa607870a 2026-11-06 21:00:07 -08:00
tobitege c88adb4695 raea play on Windows: plain paths for home() and the bundler's folders, a junction for the work folder's node_modules
Three Windows bugs stopped `raea play` before its first frame:

- raea-io-home: home() canonicalized the tree it came from, which on
  Windows gives a verbatim \\?\C:\ path. The lite entry imports
  bevy-react's bridge.ts by that path, and Rolldown can't resolve it
  ("Could not resolve '\\?\C:\...\bridge.ts'"). home() now drops the
  prefix before a drive path, as src() already did.
- raea-bundle: EditResolve canonicalized its folders the same way, so no
  importer (named without the prefix) was ever under the work folder. A
  live game's own `import "react"` went to the engine's React instead of
  the live runtime its tsconfig paths name: "not a function" at the
  first frame.
- raea-runtime-bundle: the work folder's node_modules link was made on
  Unix only, so lite/parts' ../../node_modules/bevy-react/src/bridge
  resolved nothing on Windows. It is a junction there now (no rights
  needed, as raea-io-npm links packages), removed before the work folder
  so the engine's packages are never touched.

Each has a regression test that fails without its fix.
2026-11-06 05:34:34 +01:00
James DimachkieandClaude Opus 5.5 08c4294a7f check: fix a missed strobe and a false red flash in the flash rule
A patch strobing while its background dimmed could leave the saved extreme stale, because the
window's mean outweighed the patch. Extremes now advance on the pixels that are swinging. And a colour
crossing the saturation line by one level read as a jump from zero; red's value now runs on through
the line, and a change counts when either end of it is saturated. Both found by the Codex review
on this PR.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-05 20:30:02 -08:00
James DimachkieandClaude Opus 5.5 94d344e268 check: flashing past WCAG 2.3.1 is a P1
raea check said "nothing to fix" on a render of six full-frame white flashes a second.
Flashing like that can cause seizures, and nothing in the floor looked for it. The new rule
counts pairs of opposing changes in the same pixels, in overlapping windows a third of the
frame wide and high, for general and saturated-red flashes, and fails past three a second.
Every decoded frame counts on its exact timestamp. A file FFmpeg can't decode is refused and
decode errors are a finding, rather than either reading as clean. It's a screen, not a
certification, and it says so.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-05 20:04:18 -08:00
James DimachkieandClaude Opus 5.5 16db1fe214 check: measure a trailing freeze on the clock the filter reads
A stream's duration is a length, not an end time. With video starting 2 s after the sound, a 6 s
freeze at the end read as 4 s, which drops it from P1 to P2. FFmpeg's filters count from the file's
first stream, so the picture's end is now its start relative to that plus its length. Found by the
Codex review on this PR.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-05 20:03:18 -08:00
tobitege 3e7134bb68 deps: gpu-allocator and gilrs-core on windows 0.62, so wgpu-hal's DX12 backend builds on Windows
gpu-allocator 0.28 accepts windows 0.53 to 0.62 and was resolved to 0.54
(the one cpal and gilrs-core pull in), while wgpu-hal 30 hands it
windows 0.62 types: `cargo build -p raea-cli` on Windows failed in
wgpu-hal's dx12/suballocation.rs with ten "expected ID3D12Device, found a
different ID3D12Device" errors. gilrs-core (windows 0.44 to 0.62) moves
to 0.62 with it; cpal 0.15 keeps 0.54.
2026-11-06 04:55:36 +01:00
James DimachkieandClaude Opus 5.5 a819751fb5 check: a freeze that runs to the end of the file is found
FFmpeg's freezedetect logs freeze_duration when the picture moves again, so a
freeze still running at the last frame has only a freeze_start. The rule counted
a freeze when it saw the duration, so a film frozen to its end passed with "nothing
holds still". Footage that runs out before the composition ends looks like this.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
2026-11-05 19:46:28 -08:00
tobitege c365631a59 deps: security updates for tokio, rustls-webpki, wasmtime, zstd, ruzstd and undici
Lockfile updates within the existing version ranges, found by checking
the lockfiles against RustSec and the GitHub Advisory Database:

- tokio 1.54.1, rustls-webpki 0.103.16, webpki-roots and
  webpki-root-certs 1.0.11, zstd 0.13.4 / zstd-safe 7.4.0
- wasmtime 48.0.8 (root lock and engine/sandbox/wsx), wsx now asks for
  48.0.8 at least
- ruzstd 0.9 in raea-io-assets, with bevy_image 0.20.1 (and the Bevy
  crates it needs at 0.20.1), so one ruzstd builds again; bevy stays
  pinned at =0.20.0
- sdk/shell: undici 7.30.1 through an override (just-bash 3.6.0 pins
  guarded-fetch 0.1.3, which pins undici 7.29.0)
2026-11-06 04:19:27 +01:00
Stephan Fitzpatrick f246af81be check: a voice ending a sentence isn't a dead stop; bands read in dBFS
`raea check` flagged its-a-race at 13.36 s ("the lows: a steady sound at
-0 dB stops dead") on both the Metal and llvmpipe exports. Nothing is cut
there: it's mid-segment, the mix follows race.wav at a constant +11.5 dB
through it, and the speaker ends "AI became a thing." and pauses. Dense
speech's lows held within 2.6 dB (the steadiness limit is 3), fell 12 dB
in one step and stayed down, so the rule took the voice for a cut bed.

- dead_stops: a stop now has to start from the bed's level (within 6 dB
  one or two steps before) and be gone by the next step (DROP under the
  bed). A word's tail comes back up after its first drop; a cut source
  doesn't. This also stops it flagging the last step of a 100 ms fade.
  It only adds conditions, so it finds nothing the old rule didn't.
- levels: the bands were 10*log10(|X|^2/N), about 16.5 dB over dBFS
  (hence "-0 dB" for lows at about -17 dBFS). They now read mean square
  through Parseval and the Hann window's power, so a tone reads the same
  in its band as in the mix. The band floor goes from -65 (old scale,
  about -81.5 dBFS) to -80 dBFS.
- The message says dBFS and names a fade long enough (100 ms) for a bed.
- Tests: the real 10 ms levels of its-a-race at 12-14 s (not flagged, and
  a bed cut under that voice still is), a cut partway through a step,
  a 100 ms fade, and bands in dBFS. The old code fails all three new
  assertions.

Claude-Session: https://claude.ai/code/session_01LJ21XqsPxtVd2swKwbVMa7
2026-11-05 19:38:27 +00:00
Leonardo Gonzalez 30c80d9a1f render --alpha: transparent PNGs for overlays
A frame or a folder of PNGs kept transparent where the composition draws nothing, for an overlay in another
editor's timeline. Three places made every frame opaque: the program's camera cleared to black, composite.k
packed alpha 255, and the PNG writer took the composite as it came. Now --alpha clears to #00000000,
composite.k (and composite_tex.k, both from gen.py) carries coverage through the clips and the overlay and packs
it, and the PNG folder writer makes the premultiplied composite straight. Over an opaque background every new step
keeps alpha at 255, so renders without the flag are the same pixels as before. A video output with --alpha is
refused with the ffmpeg line that makes ProRes 4444 from the folder.
2026-11-05 05:06:18 -05:00
Leonardo Gonzalez 8a365c13be HyperFrames pages: the timeline registry made before their scripts, the size read from the root element
Every HyperFrames page registers its timeline with window.__timelines["main"] = tl. HyperFrames' runtime makes
that object before the page's scripts run; raea's didn't, so each such script threw at that line and the page
never moved. And a page whose <head> styles name [data-composition-id=...] in a selector was sized from that
selector (no data-width there, so 1920 x 1080) instead of its root element.
2026-11-05 05:02:34 -05:00
Leonardo Gonzalez 6e7bbad157 raea render PAGE.html: the HTML runtime from raea's files, bundled in process 2026-11-05 05:02:34 -05:00
Leonardo Gonzalez 2774a34db1 Stills of a 2D piece skip the 3D rows' pass over the whole timeline
A still (--frame, --at, a PNG folder) first stepped React through every frame of the composition to find 3D,
even for a piece with none: 16 s before an 80 s film's single still, against ~2 s for the frame itself. The
frames asked for are now looked at first, each on its own (frames are pure); when none shows 3D their render
needs no rows and the pass is skipped. A still with 3D steps the timeline as before.
2026-11-05 04:23:09 -05:00
654 changed files with 34800 additions and 1963 deletions

No files matched your search

+106
View File
@@ -0,0 +1,106 @@
# raea's public CI (docs/public-first.feature PF5), on GitHub's hosted runners only: it runs code from pull requests,
# so it never touches a self-hosted machine. What needs this Mac's GPU, VideoToolbox or audio (P26, UI parity, the
# sound gates) stays the maintainers' L1/L2 (docs/agents.md); this is the part anyone can read and rerun.
# every pull request and push to main guard (names and secrets), L0's repo-wide gates, cargo check of the engine
name: ci
on:
pull_request:
push:
branches: [main]
workflow_dispatch:
permissions:
contents: read
concurrency:
group: ci-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
CARGO_TERM_COLOR: never
CARGO_INCREMENTAL: "0"
jobs:
guard:
# what this change adds names no home folder, agent path or session, and holds no secret (tools/public-guard.sh)
runs-on: ubuntu-24.04
timeout-minutes: 10
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: gitleaks
run: |
curl -fsSL https://github.com/gitleaks/gitleaks/releases/download/v8.30.1/gitleaks_8.30.1_linux_x64.tar.gz | tar -xz -C /usr/local/bin gitleaks
- name: public-guard
run: |
base=${{ github.event.pull_request.base.sha || github.event.before }}
git cat-file -e "$base^{commit}" 2>/dev/null || base=$(git rev-list --max-parents=0 HEAD | tail -1)
bash tools/public-guard.sh range "$base..HEAD"
gates:
# L0's repo-wide steps (tools/agents/check's list, the ones that need no GPU)
runs-on: ubuntu-24.04
timeout-minutes: 45
steps:
- uses: actions/checkout@v4
with:
submodules: true
lfs: false
- uses: oven-sh/setup-bun@v2
with:
bun-version: 1.4.2
- name: tools
run: |
rustup show active-toolchain
cargo install --locked cargo-shear cargo-dupes
- name: layers
run: bash tools/layers.sh
- name: names
run: bash tools/names.sh
- name: size
run: bash tools/size.sh
- name: one-version
run: bash tools/one-version.sh
- name: no-void
run: bash tools/no-void.sh
- name: dupes
run: bash tools/dupes.sh
- name: unused dependencies
run: cargo shear --color never --deny-warnings
- name: tasks
run: bash tools/rask.sh check
- name: sdk coverage
run: bash tools/sdk-coverage --check
- name: sdk props
run: bash tools/sdk-props.sh --check
- name: taxonomy
run: bash tools/taxonomy.sh --check
engine:
# a fresh clone builds as the README says (public #14): the toolchain from rust-toolchain.toml, --locked
strategy:
fail-fast: false
matrix:
os: [macos-15, ubuntu-24.04]
runs-on: ${{ matrix.os }}
timeout-minutes: 120
steps:
- uses: actions/checkout@v4
with:
lfs: false
- name: Linux libraries
if: runner.os == 'Linux'
run: sudo apt-get update && sudo apt-get install -y cmake ninja-build libasound2-dev libfontconfig1-dev libvulkan-dev libudev-dev
- name: macOS tools
if: runner.os == 'macOS'
run: brew install cmake ninja
- uses: oven-sh/setup-bun@v2
with:
bun-version: 1.4.2
- uses: Swatinem/rust-cache@v2
- name: cargo check
run: cargo check --locked -p raea-cli --tests
- name: unit tests (the crates with no GPU or media device)
run: cargo test --locked -p raea-io-media -p raea-core-fonts -p raea-native
+44
View File
@@ -0,0 +1,44 @@
# Posts every published release to #releases in the raea Discord. Engine releases (v* tags) ping the "release pings"
# role that members pick in onboarding. Other releases, such as the web modules, post without a ping.
# Needs the repository secret DISCORD_RELEASES_WEBHOOK (the #releases webhook) and the variable DISCORD_RELEASE_ROLE
# (that role's id). Without the secret it skips.
name: discord
on:
release:
types: [published]
permissions: {}
jobs:
announce:
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- name: Post the release to #releases
env:
WEBHOOK: ${{ secrets.DISCORD_RELEASES_WEBHOOK }}
ROLE: ${{ vars.DISCORD_RELEASE_ROLE }}
TAG: ${{ github.event.release.tag_name }}
NAME: ${{ github.event.release.name }}
URL: ${{ github.event.release.html_url }}
BODY: ${{ github.event.release.body }}
PRE: ${{ github.event.release.prerelease }}
run: |
[ -n "$WEBHOOK" ] || { echo "no DISCORD_RELEASES_WEBHOOK secret, so nothing to post"; exit 0; }
ping=""
if [[ $TAG == v* && -n $ROLE ]]; then ping="<@&$ROLE> "; fi
kind="release"; [[ $PRE == true ]] && kind="pre-release"
install=""
if [[ $TAG == v* ]]; then install=$'\n\nInstall or update: `curl -fsSL https://raea.io/install | sh` (macOS, Linux), or `irm https://raea.io/install.ps1 | iex` (Windows).'; fi
notes="$BODY"
if (( ${#notes} > 3500 )); then notes="${notes:0:3500}"$'…\n\nThe full notes are on GitHub.'; fi
payload=$(jq -n --arg ping "$ping" --arg tag "$TAG" --arg name "${NAME:-$TAG}" --arg url "$URL" \
--arg notes "$notes$install" --arg kind "$kind" --arg role "$ROLE" '{
content: "\($ping)raea \($tag) is out (\($kind)).",
allowed_mentions: { roles: (if $ping == "" then [] else [$role] end) },
embeds: [{ title: $name, url: $url, description: $notes, color: 16053488,
footer: { text: "github.com/shinyobjectz/raea" } }]
}')
curl -fsS -H "Content-Type: application/json" -d "$payload" "$WEBHOOK?wait=true" -o /dev/null
echo "posted $TAG"
+91
View File
@@ -0,0 +1,91 @@
# A release, built here where anyone can read how (public #6; docs/public-first.feature PF5): for a v* tag, macOS on
# Apple Silicon and Linux on x86_64 are built from the tag on GitHub's runners, packed by tools/release.sh, checked by
# tools/release-check.sh, attested (anyone can check a download with
# `gh attestation verify raea-VERSION-macos-arm64.tar.gz -R shinyobjectz/raea`) and attached to the tag's release.
# Windows builds in windows.yml's release mode. The release's notes and whether it's a pre-release are set by hand.
name: release
on:
push:
tags: ["v*"]
workflow_dispatch:
inputs:
tag:
description: the tag to build (v0.1.0-canary.4)
required: true
type: string
permissions:
contents: write
id-token: write
attestations: write
env:
CARGO_TERM_COLOR: never
CARGO_INCREMENTAL: "0"
TAG: ${{ inputs.tag || github.ref_name }}
jobs:
build:
strategy:
fail-fast: false
matrix:
include:
- os: macos-15
lib: libraea_bundle.dylib
extra: raea-perceive
- os: ubuntu-24.04
lib: libraea_bundle.so
extra: ""
runs-on: ${{ matrix.os }}
# a cold thin-LTO build of raea-cli with the plugin catalog is the long part; GitHub's own limit is 6 hours
timeout-minutes: 340
steps:
- uses: actions/checkout@v4
with:
ref: ${{ env.TAG }}
submodules: true
lfs: false
- name: Linux libraries
if: runner.os == 'Linux'
run: sudo apt-get update && sudo apt-get install -y cmake ninja-build libasound2-dev libfontconfig1-dev libvulkan-dev libudev-dev mesa-vulkan-drivers xvfb
- name: macOS tools
if: runner.os == 'macOS'
run: brew install cmake ninja
- uses: oven-sh/setup-bun@v2
with:
bun-version: 1.4.2
- name: The runtime's packages
run: for d in sdk/react/js sdk/react/tw; do (cd "$d" && bun install --frozen-lockfile); done
- name: Models (pinned by URL and sha256 in tools/release/models.tsv)
run: |
while IFS=$'\t' read -r path url sha; do
case $path in ''|'#'*) continue ;; esac
mkdir -p "$HOME/.local/share/raea-models/$(dirname "$path")"
curl -fsSL "$url" -o "$HOME/.local/share/raea-models/$path"
echo "$sha $HOME/.local/share/raea-models/$path" | shasum -a 256 -c -
done < tools/release/models.tsv
- name: Build
run: |
feat=$(bash tools/bevy-plugins.sh features sdk/raea/bench/bevy-plugins)
cargo build --profile dist --locked -p raea-cli --bin raea --no-default-features --features "$feat"
cargo build --profile dist --locked -p raea-rune-host
cargo build --profile dist --locked -p raea-page-host --features window
if [ -n "${{ matrix.extra }}" ]; then cargo build --profile dist --locked -p ${{ matrix.extra }}; fi
mkdir ship
cp target/dist/raea target/dist/${{ matrix.lib }} target/dist/raea-rune-host target/dist/raea-page-host ship/
if [ -n "${{ matrix.extra }}" ]; then cp target/dist/${{ matrix.extra }} ship/; fi
- name: Pack and check (tools/release.sh)
run: |
v=${TAG#v}
if [ "$RUNNER_OS" = Linux ]; then xvfb-run -a -s "-screen 0 1280x1024x24" bash tools/release.sh "$v" ship HEAD
else bash tools/release.sh "$v" ship HEAD; fi
- uses: actions/attest-build-provenance@v2
with:
subject-path: dist/raea-*.tar.gz
- name: Attach to the release
env:
GH_TOKEN: ${{ github.token }}
run: |
gh release view "$TAG" >/dev/null 2>&1 || gh release create "$TAG" --prerelease --title "raea ${TAG#v}" --notes "Built by .github/workflows/release.yml; notes follow."
gh release upload "$TAG" dist/raea-*.tar.gz dist/raea-*.tar.gz.sha256 --clobber
+3 -1
View File
@@ -81,7 +81,7 @@ content/**/*.db
content/**/*.bak
content/**/*.physics.json
# local footage catalogues and eval takes (client data on Shane's drives, from the host app's era): never committed; raea
# local footage catalogues and eval takes (client data, kept off git): never committed; raea
# keeps no UGC data (10-24), so they're for moving out of the repo, not into it
engine/media/library/
engine/media/real/
@@ -101,3 +101,5 @@ sdk/raea/.scratch-*/
# the Tripo CLI writes its last task id into the directory it runs in
.tripo/
# tools/bevy-parity links each example folder's assets/ to Bevy's checkout at run time (an absolute, per-machine path)
/sdk/raea/bench/bevy-parity/**/assets
+3
View File
@@ -0,0 +1,3 @@
[submodule "tools/rask"]
path = tools/rask
url = https://github.com/shinyobjectz/rask.git
+16
View File
@@ -0,0 +1,16 @@
# Contributing
raea is a canary release, and it changes a lot from day to day. The best way to help right now is to file an issue.
Every one gets read, and a good bug report usually gets fixed sooner than a pull request can be reviewed against code
that has moved on.
- **Bugs:** say what you ran, what happened, and what you expected. Include the raea version (`raea --version`), your
OS and machine, and the smallest page or composition that shows the problem. Comparing against a reference render,
such as the same page in a browser, and naming the frame where it differs helps a lot.
- **Ideas and questions:** open an issue and describe what you're trying to make.
## Pull requests
Pull requests are taken case by case. Open an issue first and say what you'd like to change, so we can agree on it
before you spend time on code. A contribution that lands keeps you as the author of your commits in this repository's
history.
Generated
+141 -1
View File
@@ -10530,6 +10530,7 @@ dependencies = [
"num-traits",
"once_cell",
"petgraph",
"pp-rs",
"rustc-hash 1.1.0",
"serde",
"spirv",
@@ -13176,6 +13177,15 @@ version = "0.2.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "4a6394b9e965e73d0a289ee54f589087e2c676aedf60885baf52c76b771e4958"
[[package]]
name = "pp-rs"
version = "0.2.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "bb458bb7f6e250e6eb79d5026badc10a3ebb8f9a15d1fff0f13d17c71f4d6dee"
dependencies = [
"unicode-xid",
]
[[package]]
name = "ppv-lite86"
version = "0.2.21"
@@ -13615,6 +13625,18 @@ dependencies = [
"winit",
]
[[package]]
name = "raea-app-judge"
version = "0.1.0"
dependencies = [
"base64 0.22.1",
"image",
"raea-io-home",
"raea-runtime-bundle",
"serde_json",
"ureq 2.12.1",
]
[[package]]
name = "raea-app-media"
version = "0.1.0"
@@ -13645,6 +13667,18 @@ dependencies = [
"winit",
]
[[package]]
name = "raea-app-solid"
version = "0.1.0"
dependencies = [
"raea-app-judge",
"raea-core-meshcheck",
"raea-core-shape",
"raea-core-solidinfo",
"raea-runtime-bundle",
"serde_json",
]
[[package]]
name = "raea-app-targets"
version = "0.1.0"
@@ -13885,8 +13919,10 @@ dependencies = [
"raea-app-check",
"raea-app-ci",
"raea-app-game",
"raea-app-judge",
"raea-app-media",
"raea-app-play",
"raea-app-solid",
"raea-app-targets",
"raea-app-tools",
"raea-app-workspace",
@@ -13956,14 +13992,44 @@ dependencies = [
"wuff",
]
[[package]]
name = "raea-core-grow"
version = "0.1.0"
dependencies = [
"raea-core-sdf",
]
[[package]]
name = "raea-core-k"
version = "0.1.0"
[[package]]
name = "raea-core-meshcheck"
version = "0.1.0"
dependencies = [
"serde_json",
]
[[package]]
name = "raea-core-place"
version = "0.1.0"
dependencies = [
"serde_json",
]
[[package]]
name = "raea-core-program"
version = "0.1.0"
[[package]]
name = "raea-core-review"
version = "0.1.0"
dependencies = [
"bevy",
"raea-core-scene",
"serde_json",
]
[[package]]
name = "raea-core-scene"
version = "0.1.0"
@@ -13973,16 +14039,32 @@ dependencies = [
"serde_json",
]
[[package]]
name = "raea-core-sdf"
version = "0.1.0"
[[package]]
name = "raea-core-shape"
version = "0.1.0"
dependencies = [
"manifold-rust",
"raea-core-fonts",
"raea-core-grow",
"raea-core-sdf",
"serde_json",
"skrifa 0.44.0",
]
[[package]]
name = "raea-core-solidinfo"
version = "0.1.0"
dependencies = [
"manifold-rust",
"raea-core-place",
"raea-core-shape",
"serde_json",
]
[[package]]
name = "raea-core-wire"
version = "0.1.0"
@@ -14091,6 +14173,7 @@ name = "raea-io-gen"
version = "0.1.0"
dependencies = [
"image",
"raea-core-meshcheck",
"raea-io-gen-comfy",
"raea-io-gen-core",
"raea-io-home",
@@ -14396,6 +14479,7 @@ dependencies = [
"raea-sys-page",
"raea-sys-parity",
"raea-sys-post",
"raea-sys-procmat",
"raea-sys-rt",
"raea-sys-sampler",
"raea-sys-screen",
@@ -14403,6 +14487,7 @@ dependencies = [
"raea-sys-splat",
"raea-sys-sprite",
"raea-sys-text3d",
"raea-sys-three-shader",
"raea-sys-volume",
"raea-sys-wear",
"serde_json",
@@ -14420,24 +14505,47 @@ dependencies = [
"wgpu",
]
[[package]]
name = "raea-rune-bevy"
version = "0.1.0"
dependencies = [
"bevy",
"rune",
"wgpu",
]
[[package]]
name = "raea-rune-host"
version = "0.1.0"
dependencies = [
"bevy",
"png 0.18.1",
"raea-core-wire",
"raea-io-net-calls",
"raea-io-os",
"raea-rune-bevy",
"raea-rune-js",
"raea-rune-look",
"raea-rune-media",
"raea-rune-page",
"raea-runtime-bundle-lib",
"raea-runtime-jsengine",
"rune",
"serde",
"serde_json",
]
[[package]]
name = "raea-rune-js"
version = "0.1.0"
dependencies = [
"raea-core-wire",
"raea-io-net-calls",
"raea-io-os",
"raea-rune-page",
"raea-runtime-jsengine",
"serde_json",
]
[[package]]
name = "raea-rune-look"
version = "0.1.0"
@@ -14511,6 +14619,7 @@ name = "raea-runtime-bundle-lib"
version = "0.1.0"
dependencies = [
"libloading",
"raea-io-home",
"serde_json",
]
@@ -14522,6 +14631,7 @@ dependencies = [
"bevy",
"image",
"manifold-rust",
"raea-core-place",
"raea-core-scene",
"raea-core-shape",
"raea-io-media",
@@ -14594,6 +14704,7 @@ dependencies = [
"bevy",
"image",
"raea-core-program",
"raea-core-review",
"raea-core-scene",
"raea-gpu-device",
"raea-io-assets",
@@ -14605,6 +14716,7 @@ dependencies = [
"raea-runtime-page",
"raea-runtime-react",
"raea-runtime-scene",
"raea-runtime-scene3d",
"raea-runtime-sound",
"raea-runtime-view",
"raea-sys-contact",
@@ -14743,6 +14855,7 @@ dependencies = [
"raea-core-shape",
"raea-sys-frame",
"raea-sys-material",
"raea-sys-three-shader",
"serde",
"serde_json",
]
@@ -14786,8 +14899,10 @@ version = "0.1.0"
dependencies = [
"bevy",
"raea-core-program",
"raea-core-review",
"raea-core-scene",
"raea-runtime-look",
"raea-sys-procmat",
"raea-sys-wear",
"serde_json",
]
@@ -14973,6 +15088,7 @@ name = "raea-sys-contact"
version = "0.1.0"
dependencies = [
"bevy",
"raea-core-meshcheck",
"raea-core-scene",
"raea-core-shape",
"serde_json",
@@ -15269,6 +15385,16 @@ dependencies = [
"raea-sys-frame",
]
[[package]]
name = "raea-sys-procmat"
version = "0.1.0"
dependencies = [
"bevy",
"raea-core-program",
"raea-sys-frame",
"serde_json",
]
[[package]]
name = "raea-sys-rt"
version = "0.1.0"
@@ -15363,6 +15489,18 @@ dependencies = [
"serde_json",
]
[[package]]
name = "raea-sys-three-shader"
version = "0.1.0"
dependencies = [
"bevy",
"image",
"naga",
"raea-sys-material",
"raea-sys-sampler",
"serde_json",
]
[[package]]
name = "raea-sys-tone"
version = "0.1.0"
@@ -20180,6 +20318,8 @@ dependencies = [
"once_cell",
"rustls",
"rustls-pki-types",
"serde",
"serde_json",
"url",
"webpki-roots 0.26.11",
]
+12
View File
@@ -10,6 +10,12 @@ members = [
"core/program",
"core/scene",
"core/shape",
"core/meshcheck",
"core/sdf",
"core/grow",
"core/solidinfo",
"core/review",
"core/place",
"core/wire",
"io/net",
"io/net/calls",
@@ -20,6 +26,7 @@ members = [
"systems/sampler",
"systems/parity",
"systems/shader",
"systems/three-shader",
"engine/bevy-calls",
"engine/bevy-adapters",
"engine/bevy-plugins",
@@ -39,6 +46,8 @@ members = [
"engine/rune/media",
"engine/rune/look",
"engine/rune/style",
"engine/rune/bevy",
"engine/rune/js",
"engine/page/stage",
"engine/page/window",
"io/trace",
@@ -76,6 +85,7 @@ members = [
"systems/tweak",
"systems/filters",
"systems/wear",
"systems/procmat",
"systems/page",
"systems/page-net",
"systems/frame",
@@ -133,6 +143,8 @@ members = [
"apps/workspace",
"apps/ci",
"apps/tools",
"apps/judge",
"apps/solid",
"apps/media",
"apps/targets",
"apps/game",
+201
View File
@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+25
View File
@@ -0,0 +1,25 @@
Copyright (c) 2017 Pierre Chifflier
Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the
Software without restriction, including without
limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software
is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice
shall be included in all copies or substantial portions
of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+25
View File
@@ -0,0 +1,25 @@
Copyright (c) 2017 Pierre Chifflier
Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the
Software without restriction, including without
limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software
is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice
shall be included in all copies or substantial portions
of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
+20
View File
@@ -0,0 +1,20 @@
asn1-rs-impl 0.2.0 ships no licence file of its own. Its Cargo.toml declares MIT/Apache-2.0, by Pierre Chifflier <[email protected]>.
---- Apache-2.0: the text is LICENSES/texts/Apache-2.0.txt ----
---- MIT ----
Copyright (c) Pierre Chifflier <[email protected]>
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the Software without restriction, including without limitation the
rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit
persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the
Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+1 -1
View File
@@ -199,4 +199,4 @@ MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
OR IN CONNECTION WITH THE USE OR an agent session OF THIS SOFTWARE.
OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+1 -1
View File
@@ -257,7 +257,7 @@ AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
an agent session OF THIS SOFTWARE.
PERFORMANCE OF THIS SOFTWARE.
MIT License
-----------
@@ -1,4 +1,3 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
+201
View File
@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+201
View File
@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+201
View File
@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+25
View File
@@ -0,0 +1,25 @@
Copyright (c) 2017 Pierre Chifflier
Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the
Software without restriction, including without
limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software
is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice
shall be included in all copies or substantial portions
of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
@@ -1,41 +1,4 @@
Copyright (c) 2016 est31 <[email protected]> and contributors
Licensed under MIT or Apache License 2.0,
at your option.
The full list of contributors can be obtained by looking
at the VCS log (originally, this crate was git versioned,
there you can do "git shortlog -sn" for this task).
MIT License
-----------
The MIT License (MIT)
Copyright (c) 2016 est31 <[email protected]> and contributors
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Apache License, version 2.0
---------------------------
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
@@ -212,3 +175,28 @@ Apache License, version 2.0
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright 2024 Jacob Pratt et al.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+19
View File
@@ -0,0 +1,19 @@
Copyright (c) 2024 Jacob Pratt et al.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
+176
View File
@@ -0,0 +1,176 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
+23
View File
@@ -0,0 +1,23 @@
Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the
Software without restriction, including without
limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software
is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice
shall be included in all copies or substantial portions
of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
+1 -1
View File
@@ -12,5 +12,5 @@ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR an agent session OF
TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
THIS SOFTWARE.
+1 -1
View File
@@ -8,5 +8,5 @@ REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR an agent session OF
TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
THIS SOFTWARE.
+177
View File
@@ -0,0 +1,177 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
@@ -1,4 +1,4 @@
MIT License
Copyright (c) Jacob Pratt
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
-36
View File
@@ -1,36 +0,0 @@
NOTE:
The full list of contributors can be obtained by looking
at the VCS log (originally, this crate was git versioned,
there you can do "git shortlog -sn" for this task).
License text
------------
Copyright (c) 2016-2017 est31 <[email protected]> and contributors
Copyright (c) 2002-2015 Xiph.org Foundation
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
- Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
- Neither the name of the Xiph.org Foundation nor the names of its
contributors may be used to endorse or promote products derived from
this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION
OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+201
View File
@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+25
View File
@@ -0,0 +1,25 @@
Copyright (c) 2017 Pierre Chifflier
Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the
Software without restriction, including without
limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software
is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice
shall be included in all copies or substantial portions
of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
+21
View File
@@ -0,0 +1,21 @@
The MIT License (MIT)
Copyright (c) 2016 Jonathan Creekmore
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
+202
View File
@@ -0,0 +1,202 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright 2023 Jacob Pratt et al.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+19
View File
@@ -0,0 +1,19 @@
Copyright (c) 2023 Jacob Pratt et al.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright 2019-2020 CreepySkeleton <[email protected]>
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
@@ -0,0 +1,21 @@
MIT License
Copyright (c) 2019-2020 CreepySkeleton
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright 2019-2020 CreepySkeleton <[email protected]>
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
@@ -0,0 +1,21 @@
MIT License
Copyright (c) 2019-2020 CreepySkeleton
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
@@ -0,0 +1,25 @@
Copyright (c) 2017 Pierre Chifflier
Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the
Software without restriction, including without
limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software
is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice
shall be included in all copies or substantial portions
of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
@@ -11,5 +11,5 @@ WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR an agent session OF
ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
THIS SOFTWARE.
+1 -1
View File
@@ -11,5 +11,5 @@ WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR an agent session OF
ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF
THIS SOFTWARE.
+201
View File
@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+28
View File
@@ -0,0 +1,28 @@
Copyright (c) 2016-2026 The RustCrypto Project Developers
Copyright (c) 2016 Artyom Pavlov
Copyright (c) 2009-2013 Mozilla Foundation
Copyright (c) 2006-2009 Graydon Hoare
Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the
Software without restriction, including without
limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software
is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice
shall be included in all copies or substantial portions
of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
+201
View File
@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+23
View File
@@ -0,0 +1,23 @@
Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the
Software without restriction, including without
limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software
is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice
shall be included in all copies or substantial portions
of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
+177
View File
@@ -0,0 +1,177 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
+19
View File
@@ -0,0 +1,19 @@
Copyright (c) Jacob Pratt et al.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
+177
View File
@@ -0,0 +1,177 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
+19
View File
@@ -0,0 +1,19 @@
Copyright (c) Jacob Pratt et al.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
+177
View File
@@ -0,0 +1,177 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
+19
View File
@@ -0,0 +1,19 @@
Copyright (c) Jacob Pratt et al.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
+201
View File
@@ -0,0 +1,201 @@
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
1. Definitions.
"License" shall mean the terms and conditions for use, reproduction,
and distribution as defined by Sections 1 through 9 of this document.
"Licensor" shall mean the copyright owner or entity authorized by
the copyright owner that is granting the License.
"Legal Entity" shall mean the union of the acting entity and all
other entities that control, are controlled by, or are under common
control with that entity. For the purposes of this definition,
"control" means (i) the power, direct or indirect, to cause the
direction or management of such entity, whether by contract or
otherwise, or (ii) ownership of fifty percent (50%) or more of the
outstanding shares, or (iii) beneficial ownership of such entity.
"You" (or "Your") shall mean an individual or Legal Entity
exercising permissions granted by this License.
"Source" form shall mean the preferred form for making modifications,
including but not limited to software source code, documentation
source, and configuration files.
"Object" form shall mean any form resulting from mechanical
transformation or translation of a Source form, including but
not limited to compiled object code, generated documentation,
and conversions to other media types.
"Work" shall mean the work of authorship, whether in Source or
Object form, made available under the License, as indicated by a
copyright notice that is included in or attached to the work
(an example is provided in the Appendix below).
"Derivative Works" shall mean any work, whether in Source or Object
form, that is based on (or derived from) the Work and for which the
editorial revisions, annotations, elaborations, or other modifications
represent, as a whole, an original work of authorship. For the purposes
of this License, Derivative Works shall not include works that remain
separable from, or merely link (or bind by name) to the interfaces of,
the Work and Derivative Works thereof.
"Contribution" shall mean any work of authorship, including
the original version of the Work and any modifications or additions
to that Work or Derivative Works thereof, that is intentionally
submitted to Licensor for inclusion in the Work by the copyright owner
or by an individual or Legal Entity authorized to submit on behalf of
the copyright owner. For the purposes of this definition, "submitted"
means any form of electronic, verbal, or written communication sent
to the Licensor or its representatives, including but not limited to
communication on electronic mailing lists, source code control systems,
and issue tracking systems that are managed by, or on behalf of, the
Licensor for the purpose of discussing and improving the Work, but
excluding communication that is conspicuously marked or otherwise
designated in writing by the copyright owner as "Not a Contribution."
"Contributor" shall mean Licensor and any individual or Legal Entity
on behalf of whom a Contribution has been received by Licensor and
subsequently incorporated within the Work.
2. Grant of Copyright License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
copyright license to reproduce, prepare Derivative Works of,
publicly display, publicly perform, sublicense, and distribute the
Work and such Derivative Works in Source or Object form.
3. Grant of Patent License. Subject to the terms and conditions of
this License, each Contributor hereby grants to You a perpetual,
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
(except as stated in this section) patent license to make, have made,
use, offer to sell, sell, import, and otherwise transfer the Work,
where such license applies only to those patent claims licensable
by such Contributor that are necessarily infringed by their
Contribution(s) alone or by combination of their Contribution(s)
with the Work to which such Contribution(s) was submitted. If You
institute patent litigation against any entity (including a
cross-claim or counterclaim in a lawsuit) alleging that the Work
or a Contribution incorporated within the Work constitutes direct
or contributory patent infringement, then any patent licenses
granted to You under this License for that Work shall terminate
as of the date such litigation is filed.
4. Redistribution. You may reproduce and distribute copies of the
Work or Derivative Works thereof in any medium, with or without
modifications, and in Source or Object form, provided that You
meet the following conditions:
(a) You must give any other recipients of the Work or
Derivative Works a copy of this License; and
(b) You must cause any modified files to carry prominent notices
stating that You changed the files; and
(c) You must retain, in the Source form of any Derivative Works
that You distribute, all copyright, patent, trademark, and
attribution notices from the Source form of the Work,
excluding those notices that do not pertain to any part of
the Derivative Works; and
(d) If the Work includes a "NOTICE" text file as part of its
distribution, then any Derivative Works that You distribute must
include a readable copy of the attribution notices contained
within such NOTICE file, excluding those notices that do not
pertain to any part of the Derivative Works, in at least one
of the following places: within a NOTICE text file distributed
as part of the Derivative Works; within the Source form or
documentation, if provided along with the Derivative Works; or,
within a display generated by the Derivative Works, if and
wherever such third-party notices normally appear. The contents
of the NOTICE file are for informational purposes only and
do not modify the License. You may add Your own attribution
notices within Derivative Works that You distribute, alongside
or as an addendum to the NOTICE text from the Work, provided
that such additional attribution notices cannot be construed
as modifying the License.
You may add Your own copyright statement to Your modifications and
may provide additional or different license terms and conditions
for use, reproduction, or distribution of Your modifications, or
for any such Derivative Works as a whole, provided Your use,
reproduction, and distribution of the Work otherwise complies with
the conditions stated in this License.
5. Submission of Contributions. Unless You explicitly state otherwise,
any Contribution intentionally submitted for inclusion in the Work
by You to the Licensor shall be under the terms and conditions of
this License, without any additional terms or conditions.
Notwithstanding the above, nothing herein shall supersede or modify
the terms of any separate license agreement you may have executed
with Licensor regarding such Contributions.
6. Trademarks. This License does not grant permission to use the trade
names, trademarks, service marks, or product names of the Licensor,
except as required for reasonable and customary use in describing the
origin of the Work and reproducing the content of the NOTICE file.
7. Disclaimer of Warranty. Unless required by applicable law or
agreed to in writing, Licensor provides the Work (and each
Contributor provides its Contributions) on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
implied, including, without limitation, any warranties or conditions
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
PARTICULAR PURPOSE. You are solely responsible for determining the
appropriateness of using or redistributing the Work and assume any
risks associated with Your exercise of permissions under this License.
8. Limitation of Liability. In no event and under no legal theory,
whether in tort (including negligence), contract, or otherwise,
unless required by applicable law (such as deliberate and grossly
negligent acts) or agreed to in writing, shall any Contributor be
liable to You for damages, including any direct, indirect, special,
incidental, or consequential damages of any character arising as a
result of this License or out of the use or inability to use the
Work (including but not limited to damages for loss of goodwill,
work stoppage, computer failure or malfunction, or any and all
other commercial damages or losses), even if such Contributor
has been advised of the possibility of such damages.
9. Accepting Warranty or Additional Liability. While redistributing
the Work or Derivative Works thereof, You may choose to offer,
and charge a fee for, acceptance of support, warranty, indemnity,
or other liability obligations and/or rights consistent with this
License. However, in accepting such obligations, You may act only
on Your own behalf and on Your sole responsibility, not on behalf
of any other Contributor, and only if You agree to indemnify,
defend, and hold each Contributor harmless for any liability
incurred by, or claims asserted against, such Contributor by reason
of your accepting any such warranty or additional liability.
END OF TERMS AND CONDITIONS
APPENDIX: How to apply the Apache License to your work.
To apply the Apache License to your work, attach the following
boilerplate notice, with the fields enclosed by brackets "[]"
replaced with your own identifying information. (Don't include
the brackets!) The text should be enclosed in the appropriate
comment syntax for the file format. We also recommend that a
file or class name and description of purpose be included on the
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+25
View File
@@ -0,0 +1,25 @@
Copyright (c) 2017 Pierre Chifflier
Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the
Software without restriction, including without
limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software
is furnished to do so, subject to the following
conditions:
The above copyright notice and this permission notice
shall be included in all copies or substantial portions
of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
+423
View File
@@ -17,3 +17,426 @@ muxide: vendor/muxide, MIT OR Apache-2.0 (its LICENSE-MIT and LICENSE-APACHE).
animato (MIT OR Apache-2.0), usvg and resvg (Apache-2.0 OR MIT), mediabunny (MPL-2.0, used unmodified), manifold-rust
(Apache-2.0), Bevy (MIT OR Apache-2.0) and the other crates and packages in each Cargo.lock and package.json, each under its own licence.
The Windows build (docs/ports.feature PT20) adds: junction 1.4.2 (MIT, node_modules' links in io/npm) and windows-sys
0.61.2 (Microsoft, MIT OR Apache-2.0, in io/trace); every build has dunce 1.0.5 (CC0-1.0 OR MIT-0 OR Apache-2.0, plain
paths for Windows in runtime/bundle). It ships none of Microsoft's C runtime or SDK files: the runtime comes from the
Microsoft Visual C++ Redistributable, installed on the machine.
The native target (engine/rune, docs/targets.feature) builds on Rune (https://github.com/anomalyco/rune, Copyright
2026 Anomaly, MIT; LICENSES/rune-0.0.1/repository-LICENSE): rune, rune-kit and their crates, by a pinned rev.
---- the plugin catalog's crates (tools/licenses.sh; don't edit by hand) ----
The plugin catalog (engine/bevy-plugins, built with tools/bevy-plugins.sh) and the native target's host (engine/rune,
raea-rune-host) bring in these crates beyond raea's own build. Each is under its own licence, its files in
LICENSES/<crate>-<version>/.
accesskit_atspi_common 0.21.1: MIT OR Apache-2.0
accesskit_consumer 0.39.2: MIT OR Apache-2.0
accesskit_macos 0.27.2: MIT OR Apache-2.0
accesskit_unix 0.24.1: MIT OR Apache-2.0
accesskit_windows 0.35.2: MIT OR Apache-2.0
accesskit 0.25.2: MIT OR Apache-2.0
aead 0.5.2: MIT OR Apache-2.0
aeronet_io 0.22.0-rc.1: MIT OR Apache-2.0
aeronet_steam 0.22.0-rc.1: MIT OR Apache-2.0
aeronet_tokio_runtime 0.22.0-rc.1: MIT OR Apache-2.0
aeronet_websocket 0.22.0-rc.1: MIT OR Apache-2.0
aeronet_webtransport 0.22.0-rc.1: MIT OR Apache-2.0
anes 0.1.6: MIT OR Apache-2.0
ansi-parser 0.9.1: MPL-2.0
any_vec 0.15.0: MIT OR Apache-2.0
arbitrary-chunks 0.4.1: Apache-2.0 OR MIT
ariadne 0.6.0: MIT
aseprite-loader 0.4.2: MIT OR Apache-2.0
asn1-rs-derive 0.6.0: MIT OR Apache-2.0
asn1-rs-impl 0.2.0: MIT/Apache-2.0
asn1-rs 0.7.2: MIT OR Apache-2.0
async-process 2.5.0: Apache-2.0 OR MIT
async-recursion 1.2.0: MIT OR Apache-2.0
async-signal 0.2.14: Apache-2.0 OR MIT
atomic-arena 0.1.2: MIT OR Apache-2.0
atomic-polyfill 1.0.3: MIT OR Apache-2.0
atspi-common 0.13.0: Apache-2.0 OR MIT
atspi-proxies 0.13.0: Apache-2.0 OR MIT
atspi 0.29.0: Apache-2.0 OR MIT
atterate 0.0.2: MIT OR Apache-2.0
avian_derive 0.2.3: MIT OR Apache-2.0
avian2d 0.8.0: MIT OR Apache-2.0
avian3d 0.8.0: MIT OR Apache-2.0
aws-lc-rs 1.18.2: ISC AND (Apache-2.0 OR ISC)
aws-lc-sys 0.46.0: ISC AND (Apache-2.0 OR ISC) AND Apache-2.0 AND MIT AND BSD-3-Clause AND (Apache-2.0 OR ISC OR MIT) AND (Apache-2.0 OR ISC OR MIT-0)
az 1.3.0: MIT/Apache-2.0
basis-universal-sys 0.3.1: MIT OR Apache-2.0
basis-universal 0.3.1: MIT OR Apache-2.0
better-bae-macros 0.1.9: MIT
better-bae 0.1.9: MIT
bevy_aseprite_ultra 0.10.0: MIT
bevy_asset_loader_derive 0.28.1: MIT OR Apache-2.0
bevy_asset_loader 0.28.1: MIT OR Apache-2.0
bevy_common_assets 0.18.0: MIT OR Apache-2.0
bevy_console_derive 0.6.0: MIT
bevy_console 0.19.0: MIT
bevy_easings 0.20.0: MIT OR Apache-2.0
bevy_ecs_ldtk_macros 0.16.0: MIT OR Apache-2.0
bevy_ecs_ldtk 0.16.0: MIT OR Apache-2.0
bevy_ecs_tiled 0.14.0: MIT
bevy_ecs_tilemap 0.20.0: MIT
bevy_egui 0.43.1: MIT
bevy_enhanced_input_macros 0.27.0: MIT OR Apache-2.0
bevy_enhanced_input 0.27.0: MIT OR Apache-2.0
bevy_enoki 0.8.0: MIT
bevy_flair_core_macros 0.9.0: MIT OR Apache-2.0
bevy_flair_core 0.9.0: MIT OR Apache-2.0
bevy_flair_css_parser 0.9.0: MIT OR Apache-2.0
bevy_flair_style 0.9.0: MIT OR Apache-2.0
bevy_flair 0.9.0: MIT OR Apache-2.0
bevy_flipbook 0.1.0: MIT
bevy_ghx_grid 0.10.0: MIT OR Apache-2.0
bevy_ghx_proc_gen 0.10.0: MIT OR Apache-2.0
bevy_hanabi 0.20.0-dev: MIT OR Apache-2.0
bevy_heavy 0.6.0: MIT OR Apache-2.0
bevy_http_client 0.12.0: MIT OR Apache-2.0
bevy_hui 0.8.0: MIT OR Apache-2.0
bevy_kira_audio 0.27.1: MIT OR Apache-2.0
bevy_light_2d 0.11.0: MIT
bevy_lookup_curve 0.13.0: MIT OR Apache-2.0
bevy_materialize 0.12.0: MIT OR Apache-2.0
bevy_mod_debugdump 0.17.0: MIT OR Apache-2.0
bevy_northstar 0.8.0: MIT
bevy_obj 0.20.0: MIT OR Apache-2.0
bevy_pancam 0.22.0: MIT OR Apache-2.0
bevy_panorbit_camera 0.36.0: MIT OR Apache-2.0
bevy_prng 0.16.0: MIT OR Apache-2.0
bevy_quinnet 0.22.0: MIT OR Apache-2.0
bevy_rand 0.16.0: MIT OR Apache-2.0
bevy_rapier2d 0.37.0: Apache-2.0
bevy_rapier3d 0.37.0: Apache-2.0
bevy_replicon 0.45.2: MIT OR Apache-2.0
bevy_simple_tilemap 0.21.0: MIT/Apache-2.0
bevy_skein 0.7.0-rc.1: MIT OR Apache-2.0
bevy_smud 0.15.0: MIT OR Apache-2.0
bevy_sprite3d 10.1.0: MIT
bevy_spritesheet_animation 8.0.1: MIT
bevy_time_runner 0.8.0: MIT OR Apache-2.0
bevy_transform_interpolation 0.6.0: MIT OR Apache-2.0
bevy_trauma_shake 0.9.0: MIT OR Apache-2.0
bevy_trenchbroom_macros 0.15.0: MIT OR Apache-2.0
bevy_trenchbroom 0.15.0: MIT OR Apache-2.0
bevy_tween 0.14.1: MIT OR Apache-2.0
bevy_tweening 0.16.0: MIT OR Apache-2.0
bevy_vector_shapes 0.14.0: MIT OR Apache-2.0
bevy_vox_scene 0.23.0: MIT
bevy-inspector-egui-derive 0.38.0: MIT OR Apache-2.0
bevy-inspector-egui 0.38.0: MIT OR Apache-2.0
bevy-settings 0.20.0: MIT OR Apache-2.0
bevy-tnua-avian3d 0.13.0: MIT OR Apache-2.0
bevy-tnua-macros 0.3.0: MIT OR Apache-2.0
bevy-tnua-physics-integration-layer 0.14.0: MIT OR Apache-2.0
bevy-tnua 0.33.0: MIT OR Apache-2.0
bevy-yoleck-macros 0.10.0: MIT OR Apache-2.0
bevy-yoleck 0.34.0: MIT OR Apache-2.0
big_space 0.14.0-rc.0: MIT OR Apache-2.0
bitfield-macros 0.19.5: MIT OR Apache-2.0
bitfield 0.19.5: MIT OR Apache-2.0
block-mesh 0.2.0: MIT OR Apache-2.0
block-pseudorand 0.1.2: Apache-2.0 OR MIT
cast 0.3.0: MIT OR Apache-2.0
chacha20 0.9.1: Apache-2.0 OR MIT
chacha20poly1305 0.10.1: Apache-2.0 OR MIT
chiapos-chacha8 0.1.0: Apache-2.0 OR MIT
ciborium-io 0.2.2: Apache-2.0
ciborium-ll 0.2.2: Apache-2.0
ciborium 0.2.2: Apache-2.0
cipher 0.4.4: MIT OR Apache-2.0
claxon 0.4.3: Apache-2.0
convert_case 0.11.0: MIT
copyless 0.1.5: MIT OR Apache-2.0
criterion-plot 0.5.0: MIT/Apache-2.0
criterion 0.5.1: Apache-2.0 OR MIT
cssparser-color 0.5.0: MPL-2.0
cssparser 0.37.0: MPL-2.0
csv-core 0.1.13: Unlicense/MIT
csv 1.4.0: Unlicense/MIT
ctt-astcenc 0.5.0: (MIT OR Apache-2.0 OR Zlib) AND Apache-2.0
ctt-bc7enc-rdo-prebuilt 0.5.0: (MIT OR Apache-2.0) AND Apache-2.0
ctt-bc7enc-rdo 0.5.0: (MIT OR Apache-2.0 OR Zlib) AND Apache-2.0
ctt-compressonator 0.5.0: (MIT OR Apache-2.0 OR Zlib) AND MIT
ctt-etcpak 0.5.0: (MIT OR Apache-2.0 OR Zlib) AND BSD-3-Clause
ctt-intel-texture-compressor-prebuilt 0.5.0: (MIT OR Apache-2.0) AND MIT
ctt-intel-texture-compressor 0.5.0: (MIT OR Apache-2.0) AND MIT
ctt 0.5.0: MIT OR Apache-2.0 OR Zlib
dashmap 6.2.1: MIT
default-struct-builder 0.5.1: MIT OR Apache-2.0
deluxe-core 0.5.0: MIT
deluxe-macros 0.5.0: MIT
deluxe 0.5.0: MIT
der_derive 0.8.0: Apache-2.0 OR MIT
der-parser 10.0.0: MIT OR Apache-2.0
deranged 0.5.9: MIT OR Apache-2.0
derive-getters 0.5.0: MIT
deterministic-hash 1.0.2: MIT
disjoint-sets 0.4.2: MIT/Apache-2.0
dot_vox 5.2.0: MIT
dyn-clone 1.0.20: MIT OR Apache-2.0
dyn-eq 0.1.3: MPL-2.0
dyn-hash 1.0.0: MIT OR Apache-2.0
earcut 0.4.5: ISC
ecolor 0.36.2: MIT OR Apache-2.0
egui 0.36.2: MIT OR Apache-2.0
ehttp 0.5.0: MIT OR Apache-2.0
emath 0.36.2: MIT OR Apache-2.0
endi 1.1.1: MIT
endian-type 0.1.2: MIT
enumflags2_derive 0.7.12: MIT OR Apache-2.0
enumflags2 0.7.12: MIT OR Apache-2.0
epaint_default_fonts 0.36.2: (MIT OR Apache-2.0) AND OFL-1.1 AND Ubuntu-font-1.0
epaint 0.36.2: MIT OR Apache-2.0
fast_image_resize 6.1.0: MIT OR Apache-2.0
fastbloom 0.17.0: MIT OR Apache-2.0
fastnoise-lite 1.1.1: MIT
fearless_simd 0.4.1: Apache-2.0 OR MIT
fid-rs 0.2.0: MIT OR Apache-2.0
file-id 0.2.3: MIT OR Apache-2.0
fixed 1.31.0: MIT/Apache-2.0
flagset 0.4.7: Apache-2.0
float_next_after 2.0.0: MIT
float-cmp 0.10.0: MIT
float-ord 0.3.2: MIT / Apache-2.0
fs_extra 1.3.0: MIT
fsevent-sys 4.1.0: MIT
futures-timer 3.0.4: MIT/Apache-2.0
fuzzy-matcher 0.3.7: MIT
geo-types 0.7.20: MIT OR Apache-2.0
geo 0.33.1: MIT OR Apache-2.0
geographiclib-rs 0.2.7: MIT
ghx_grid 0.10.0: MIT OR Apache-2.0
ghx_proc_gen 0.10.0: MIT OR Apache-2.0
glam_matrix_extras 0.4.0: MIT OR Apache-2.0
glam 0.19.0: MIT OR Apache-2.0
glifo 0.2.0: Apache-2.0 OR MIT
gloo-timers 0.3.0: MIT OR Apache-2.0
governor 0.10.4: MIT
hash32 0.2.1: MIT OR Apache-2.0
heapless 0.7.17: MIT OR Apache-2.0
heck 0.4.1: MIT OR Apache-2.0
httlib-huffman 0.3.4: MIT
i_float 1.16.0: MIT
i_key_sort 0.10.3: MIT
i_overlay 4.5.2: MIT OR Apache-2.0
i_shape 1.18.0: MIT
i_tree 0.18.0: MIT
ilattice 0.1.0: MIT OR Apache-2.0
imagesize 0.13.0: MIT
inout 0.1.4: MIT OR Apache-2.0
interpolation 0.3.0: MIT
is-terminal 0.4.17: MIT
ispc-build-utils 0.5.0: MIT OR Apache-2.0 OR Zlib
itertools 0.10.5: MIT/Apache-2.0
iyes_progress 0.18.0: MIT OR Apache-2.0
jzon 0.12.5: MIT/Apache-2.0
kira 0.12.1: MIT OR Apache-2.0
kqueue-sys 1.1.2: MIT
kqueue 1.2.1: MIT
kurbo 0.11.3: Apache-2.0 OR MIT
leafwing_input_manager_macros 0.17.0: MIT OR Apache-2.0
leafwing-input-manager 0.22.0: MIT OR Apache-2.0
lightyear_aeronet 0.31.0: MIT OR Apache-2.0
lightyear_avian2d 0.31.0: MIT OR Apache-2.0
lightyear_avian3d 0.31.0: MIT OR Apache-2.0
lightyear_connection 0.31.0: MIT OR Apache-2.0
lightyear_core 0.31.0: MIT OR Apache-2.0
lightyear_crossbeam 0.31.0: MIT OR Apache-2.0
lightyear_deterministic_replication 0.31.0: MIT OR Apache-2.0
lightyear_frame_interpolation 0.31.0: MIT OR Apache-2.0
lightyear_inputs_bei 0.31.0: MIT OR Apache-2.0
lightyear_inputs_leafwing 0.31.0: MIT OR Apache-2.0
lightyear_inputs_native 0.31.0: MIT OR Apache-2.0
lightyear_inputs 0.31.0: MIT OR Apache-2.0
lightyear_interpolation 0.31.0: MIT OR Apache-2.0
lightyear_link 0.31.0: MIT OR Apache-2.0
lightyear_messages 0.31.0: MIT OR Apache-2.0
lightyear_metrics 0.31.0: MIT OR Apache-2.0
lightyear_netcode 0.31.0: MIT OR Apache-2.0
lightyear_p2p 0.31.0: MIT OR Apache-2.0
lightyear_prediction 0.31.0: MIT OR Apache-2.0
lightyear_raw_connection 0.31.0: MIT OR Apache-2.0
lightyear_replication 0.31.0: MIT OR Apache-2.0
lightyear_serde 0.31.0: MIT OR Apache-2.0
lightyear_steam 0.31.0: MIT OR Apache-2.0
lightyear_sync 0.31.0: MIT OR Apache-2.0
lightyear_tools 0.31.0: MIT OR Apache-2.0
lightyear_transport 0.31.0: MIT OR Apache-2.0
lightyear_udp 0.31.0: MIT OR Apache-2.0
lightyear_utils 0.31.0: MIT OR Apache-2.0
lightyear_web 0.31.0: MIT OR Apache-2.0
lightyear_websocket 0.31.0: MIT OR Apache-2.0
lightyear_webtransport 0.31.0: MIT OR Apache-2.0
lightyear 0.31.0: MIT OR Apache-2.0
linked-hash-map 0.5.6: MIT/Apache-2.0
louds-rs 0.7.0: MIT OR Apache-2.0
lz4_flex 0.13.1: MIT
memoffset 0.9.1: MIT
meshopt 0.6.2: MIT OR Apache-2.0
metis-sys 0.3.2: MIT OR Apache-2.0
metis 0.2.2: MIT OR Apache-2.0
metrics-util 0.20.4: MIT
metrics 0.24.6: MIT
mint 0.5.9: MIT
mock_instant 0.6.1: 0BSD
moonshine-save 0.8.0: MIT
moonshine-util 0.6.0: MIT
nanorand 0.6.1: Zlib
ndarray 0.15.6: MIT OR Apache-2.0
ndcopy 0.3.0: MIT OR Apache-2.0
ndshape 0.3.0: MIT OR Apache-2.0
nibble_vec 0.1.0: MIT
nohash-hasher 0.2.0: Apache-2.0 OR MIT
noise 0.9.0: Apache-2.0/MIT
noisy_bevy 0.15.0: MIT
nonzero_ext 0.3.0: Apache-2.0
notify-debouncer-full 0.7.0: MIT OR Apache-2.0
notify-types 2.1.0: MIT OR Apache-2.0
notify 8.2.0: CC0-1.0
ntapi 0.4.3: Apache-2.0 OR MIT
num-conv 0.2.2: MIT OR Apache-2.0
obvhs 0.4.0: MIT OR Apache-2.0
octets 0.3.7: BSD-2-Clause
oid-registry 0.8.1: MIT OR Apache-2.0
oneshot 0.1.13: MIT OR Apache-2.0
oorandom 11.1.5: MIT
opaque-debug 0.3.1: MIT OR Apache-2.0
opuscule 0.2.2: MPL-2.0
ordered-stream 0.2.0: MIT OR Apache-2.0
owo-colors 4.4.0: MIT
parry2d-f64 0.31.1: Apache-2.0
parry2d 0.31.1: Apache-2.0
parry3d-f64 0.31.1: Apache-2.0
partition 0.1.2: MIT OR Apache-2.0
path-slash 0.2.1: MIT
pem 3.0.6: MIT
pem 4.0.0: MIT
plotters-backend 0.3.7: MIT
plotters-svg 0.3.7: MIT
plotters 0.3.7: MIT
pollster 1.0.1: Apache-2.0/MIT
poly1305 0.8.0: Apache-2.0 OR MIT
polyanya 0.18.0: MIT OR Apache-2.0
postcard-derive 0.2.2: MIT OR Apache-2.0
powerfmt 0.2.1: MIT OR Apache-2.0
proc-macro-crate 1.3.1: MIT OR Apache-2.0
proc-macro-error-attr 1.0.4: MIT OR Apache-2.0
proc-macro-error-attr3 3.1.1: MIT OR Apache-2.0
proc-macro-error 1.0.4: MIT OR Apache-2.0
proc-macro-error3 3.1.1: MIT OR Apache-2.0
quake-map 0.6.1: CC0-1.0 OR MIT OR Apache-2.0
quanta 0.12.6: MIT
quick-xml 0.31.0: MIT
quick-xml 0.38.4: MIT
radix_trie 0.2.1: MIT
rand_xorshift 0.3.0: MIT OR Apache-2.0
rand_xoshiro 0.7.0: MIT OR Apache-2.0
rapidhash 4.5.1: MIT OR Apache-2.0
rapier2d 0.36.1: Apache-2.0
rcgen 0.14.10: MIT OR Apache-2.0
rdst 0.20.14: Apache-2.0 OR MIT
rerecast 0.5.0: MIT OR Apache-2.0
resvg 0.45.1: Apache-2.0 OR MIT
ringbuffer 0.16.0: MIT
rmp-serde 1.3.1: MIT
rmp 0.8.15: MIT
rstar 0.12.2: MIT OR Apache-2.0
rtrb 0.3.5: MIT OR Apache-2.0
rune-kit 0.0.1: MIT
rune-motion 0.1.0: MIT
rune-staging 0.0.1: MIT
rune-taffy 0.0.1: MIT
rune 0.0.1: MIT
rusticata-macros 4.1.0: MIT/Apache-2.0
rustls-native-certs 0.8.5: Apache-2.0 OR ISC OR MIT
rustls-pemfile 2.2.0: Apache-2.0 OR ISC OR MIT
rustls-platform-verifier-android 0.2.0: MIT OR Apache-2.0
rustls-platform-verifier 0.7.1: MIT OR Apache-2.0
seahash 4.1.0: MIT
selectors 0.38.0: MPL-2.0
serde_arrays 0.2.0: MIT OR Apache-2.0
serde_flexitos 0.2.2: Apache-2.0
serde_regex 1.2.0: MIT OR Apache-2.0
serde_repr 0.1.21: MIT OR Apache-2.0
serde_yaml 0.9.34+deprecated: MIT OR Apache-2.0
servo_arc 0.4.3: MIT OR Apache-2.0
sha2 0.11.1: MIT OR Apache-2.0
sif-itree 0.4.1: MIT OR Apache-2.0
sketches-ddsketch 0.3.1: Apache-2.0
smart-default 0.7.1: MIT
spinning_top 0.3.0: MIT/Apache-2.0
spki 0.8.1: Apache-2.0 OR MIT
steamworks-sys 0.13.0: MIT / Apache-2.0
steamworks 0.13.1: MIT / Apache-2.0
strip-ansi-escapes 0.2.1: Apache-2.0/MIT
strsim 0.10.0: MIT
strum_macros 0.27.2: MIT
strum 0.27.2: MIT
svgtypes 0.15.3: Apache-2.0 OR MIT
symphonia-codec-alac 0.5.5: MPL-2.0
symphonia-format-caf 0.5.5: MPL-2.0
syn 1.0.109: MIT OR Apache-2.0
sysinfo 0.39.6: MIT
tikv-jemalloc-sys 0.5.4+5.3.0-patched: MIT/Apache-2.0
tikv-jemallocator 0.5.4: MIT/Apache-2.0
tiled 0.16.0: MIT
time-core 0.1.9: MIT OR Apache-2.0
time-macros 0.2.32: MIT OR Apache-2.0
time 0.3.55: MIT OR Apache-2.0
tinytemplate 1.2.1: Apache-2.0 OR MIT
tls_codec_derive 0.4.2: Apache-2.0 OR MIT
tls_codec 0.4.2: Apache-2.0 OR MIT
tokio-tungstenite 0.30.0: MIT
toml_datetime 0.6.11: MIT OR Apache-2.0
toml_edit 0.19.15: MIT OR Apache-2.0
trie-rs 0.4.2: MIT OR Apache-2.0
uds_windows 1.2.1: MIT
unicode-general-category 1.1.0: Apache-2.0
universal-hash 0.5.1: MIT OR Apache-2.0
unsafe-libyaml 0.2.11: MIT
urlencoding 2.1.3: MIT
usvg 0.45.1: Apache-2.0 OR MIT
vello_common 0.1.0: Apache-2.0 OR MIT
vello_cpu 0.1.0: Apache-2.0 OR MIT
vleue_navigator 0.17.0: MIT OR Apache-2.0
voracious_radix_sort 1.2.0: MIT
vox_bake 0.1.0: MIT
vte 0.14.1: Apache-2.0 OR MIT
web-sys-async-io 0.6.0: MIT
web-sys-stream-utils 0.2.6: MIT
web-wt-sys 0.3.1: MIT
winnow 0.5.40: MIT
wobj 0.3.1: MIT OR Apache-2.0
wtransport-proto 0.7.2: MIT OR Apache-2.0
wtransport 0.7.2: MIT OR Apache-2.0
wyrand 0.5.0: Apache-2.0 OR MIT
x509-cert 0.3.0: Apache-2.0 OR MIT
x509-parser 0.18.1: MIT OR Apache-2.0
xkbcommon 0.9.0: MIT
xwt-core 0.10.0: MIT
xwt-web 0.22.1: MIT
xwt-wtransport 0.20.1: MIT
xxhash-rust 0.8.19: BSL-1.0
yansi 1.0.1: MIT OR Apache-2.0
yasna 0.6.0: MIT OR Apache-2.0
zbus_macros 5.19.0: MIT
zbus_macros 6.2.1: MIT
zbus_names 4.3.4: MIT
zbus_utils 6.1.0: MIT
zbus_xml 5.2.1: MIT
zbus-lockstep-macros 0.5.2: MIT
zbus-lockstep 0.5.2: MIT
zbus 5.19.0: MIT
zbus 6.2.1: MIT
zcheapstr 1.1.0: MIT
zruntime 0.2.2: MIT
zstd-safe 7.4.0: BSD-3-Clause
zstd-sys 2.1.2+zstd.1.5.7: BSD-3-Clause
zstd 0.13.4: BSD-3-Clause
zvariant_derive 5.15.0: MIT
zvariant_utils 4.2.0: MIT
zvariant 5.15.0: MIT
---- end of the plugin catalog's crates ----
+15
View File
@@ -0,0 +1,15 @@
[package]
name = "raea-app-judge"
version = "0.1.0"
edition = "2024"
license = "FSL-1.1-ALv2"
publish = false
description = "raea judge: a review's sheets judged by clef-omni on a frozen rubric, the pass decided in code, calibrated against the person's eye before it gates"
[dependencies]
raea-io-home = { path = "../../io/home" }
serde_json = "1"
raea-runtime-bundle = { path = "../../runtime/bundle" }
ureq = { version = "2", features = ["json"] }
base64 = "0.22"
image = { version = "0.25", default-features = false, features = ["png", "jpeg"] }
+149
View File
@@ -0,0 +1,149 @@
//! A judge that is an agent CLI rather than clef-omni: `raea judge DIR --by kimi|claude` (Shane, 11-06: "use claude or
//! kimi cli as the judge"). Each call is a new session, run in DIR with only the sheets to look at (kimi's media tool;
//! claude with Read alone), given the fresh-context judge prompt (sdk/guides/craft/bevy/prompts.md section 3) and
//! never the code or the builder's notes. It answers JSON: the seven scores 0-10, the blind read and every defect named;
//! the pass, done and stall are still decided in code (rubric::pass, progress). `raea judge eye DIR --by kimi` records
//! its reading as the eye clef is calibrated against.
use std::path::Path;
use serde_json::{Map, Value, json};
use crate::rubric::SCORES;
pub const BY: [&str; 2] = ["kimi", "claude"];
/// The judge prompt: the sheets by name, the brief's words, and the JSON to answer.
pub fn prompt(dir: &Path, brief: &Value, target: Option<&Path>) -> String {
let words = ["look", "logline", "notDoing"].iter().filter_map(|k| brief.get(*k).map(|v| format!("{k}: {}", v.as_str().map(str::to_string).unwrap_or_else(|| v.to_string())))).collect::<Vec<_>>().join("; ");
let target = target.map(|t| format!(" The target picture, what it must read as, is {}.", t.display())).unwrap_or_default();
format!(
"You review a 3D scene from images only, as the person who will use it would. You have never seen how it was built and you never will. \
Judge what is in the pixels; do not guess at intentions. Only look at images; change no file.\n\n\
PART 1, BLIND: open {d}/hero-colour.png first, one frame. In one sentence: what place is this, what time, what era? List five objects you can name. \
Is it a photograph or a render, and which three tells decided it?\n\n\
PART 2, SCORED. The brief: \"{words}\".{target} This round's sheets: {d}/colour.png and {d}/clay.png, each six tiles, left to right, top to bottom: \
hero, front, right, top, iso, low (0.3 m off the floor). Clay is every surface light grey and matte. Open both.\n\n\
Score each 0-10 (5 = a believable draft; 7 = a production base an artist would accept; 9 = indistinguishable from real). Halves are allowed.\n\
- composition: camera, framing, layout, the position and scale of every major object.\n\
- form, judged on CLAY: silhouettes read at a glance; parts have real thickness; nothing blobby, melted or a primitive standing in for a thing; repeated things vary.\n\
- assembly, judged on CLAY first: nothing floats, sinks, pokes through or rests on the wrong thing; joints touch; the low tile shows the feet.\n\
- materials: every surface reads as its real material, with wear where use puts it; nothing a flat default colour.\n\
- light: motivated by the place's own sources; exposure and contrast believable.\n\
- detail: close views hold real geometry or texture, not a smooth stand-in; printed matter reads.\n\
- world: one coherent real place; nothing off-era or invented beyond the brief.\n\n\
Then list the defects, most damaging first: at most 8, each field one short sentence. \"blocking\" means someone using this scene would notice it in the views it will be seen in. \
Name exactly what gives it away (not \"the dryer looks fake\" but \"the dryer door is a flat disc with no rim or glass depth\").\n\n\
End your answer with only this JSON, nothing after it:\n\
{{\"blind\": {{\"place\": \"\", \"objects\": [], \"photo\": \"yes|no\", \"tells\": []}}, \
\"scores\": {{\"composition\": 0, \"form\": 0, \"assembly\": 0, \"materials\": 0, \"light\": 0, \"detail\": 0, \"world\": 0}}, \
\"defects\": [{{\"tile\": \"\", \"where\": \"\", \"wrong\": \"\", \"real\": \"\", \"fix\": \"\", \"level\": \"blocking|detail\"}}], \
\"show_as_is\": \"\"}}",
d = dir.display()
)
}
/// The last JSON object in the text that has scores (an agent may think aloud, or draft the JSON twice).
pub fn last_verdict(text: &str) -> Option<Value> {
let starts: Vec<usize> = text.match_indices('{').map(|(i, _)| i).collect();
for &s in starts.iter().rev() {
let mut de = serde_json::Deserializer::from_str(&text[s..]).into_iter::<Value>();
if let Some(Ok(v)) = de.next()
&& v.get("scores").is_some_and(Value::is_object)
{
return Some(v);
}
}
None
}
/// The verdict read into the judge's own shape: scores (0-10, the seven categories), defects (present, level, named
/// by what is wrong), the blind read's photo (1 a photo, 0 a render) and the agent's own words.
pub fn read(v: &Value) -> (Map<String, Value>, Vec<Value>, Value) {
let mut scores = Map::new();
for (k, _, _) in SCORES {
if let Some(x) = v["scores"][k].as_f64().filter(|x| (0.0..=10.0).contains(x)) {
scores.insert(k.into(), json!(x));
}
}
let defects = v["defects"].as_array().into_iter().flatten().filter(|d| d["wrong"].as_str().is_some_and(|w| !w.trim().is_empty())).map(|d| {
let level = if d["level"].as_str().unwrap_or("").starts_with("block") { "blocking" } else { "detail" };
let wrong = d["wrong"].as_str().unwrap_or("");
json!({"defect": wrong.chars().take(80).collect::<String>(), "present": true, "level": level, "sheet": d["tile"], "asked": wrong,
"where": d["where"], "real": d["real"], "fix": d["fix"]})
}).collect();
let photo = match v["blind"]["photo"].as_str() {
Some(p) if p.starts_with('y') => json!(1.0),
Some(p) if p.starts_with('n') => json!(0.0),
_ => Value::Null,
};
(scores, defects, photo)
}
/// One fresh judging session by `by` over DIR's sheets: its verdict JSON. Its steps stream (kimi's stream-json), each
/// said on stderr as it comes, so a watcher sees it working through a judgement that can take minutes.
pub fn ask(by: &str, dir: &Path, brief: &Value, target: Option<&Path>) -> Result<Value, String> {
use std::io::BufRead as _;
let dir = dir.canonicalize().map_err(|e| format!("judge: {}: {e}", dir.display()))?;
let p = prompt(&dir, brief, target);
let mut cmd = match by {
"kimi" => {
let mut c = std::process::Command::new("kimi");
c.args(["-p", &p, "--output-format", "stream-json"]);
c
}
"claude" => {
let mut c = std::process::Command::new("claude");
c.args(["-p", &p, "--allowedTools", "Read", "--output-format", "stream-json", "--verbose"]);
c
}
o => return Err(format!("judge: --by {o}: the judges are clef (the default), {}", BY.join(", "))),
};
let mut child = cmd.current_dir(&dir).stdout(std::process::Stdio::piped()).stderr(std::process::Stdio::piped()).spawn()
.map_err(|e| format!("judge: couldn't run {by}: {e} (is the {by} CLI installed and signed in?)"))?;
let mut said = Vec::new();
let mut last = String::new();
for line in std::io::BufReader::new(child.stdout.take().ok_or("judge: no output pipe")?).lines().map_while(Result::ok) {
let Ok(v) = serde_json::from_str::<Value>(&line) else { continue };
said.extend(texts(&v));
let step = match (v["role"].as_str(), v["type"].as_str()) {
(Some("tool") | Some("user"), _) => "looked at a picture".to_string(),
(Some("assistant"), _) | (_, Some("assistant")) => texts(&v).last().map_or_else(|| "thinking".into(), |t| t[..t.floor_char_boundary(100)].to_string()),
_ => continue,
};
if step != last {
eprintln!("judge ({by}): {}", step.replace('\n', " "));
last = step;
}
}
let out = child.wait_with_output().map_err(|e| format!("judge: {by}: {e}"))?;
let text = said.join("\n");
if !out.status.success() && last_verdict(&text).is_none() {
return Err(format!("judge: {by} failed: {}", String::from_utf8_lossy(&out.stderr).lines().rev().find(|l| !l.trim().is_empty()).unwrap_or("no output")));
}
last_verdict(&text).ok_or_else(|| format!("judge: {by} answered no verdict JSON: {}", text.trim().chars().rev().take(300).collect::<String>().chars().rev().collect::<String>()))
}
/// The words in one streamed line: kimi's {role: assistant, content: "..."}; claude's {type: assistant, message:
/// {content: [{type: text, text}]}} and its final {type: result, result}.
fn texts(v: &Value) -> Vec<String> {
let mut out = Vec::new();
if v["role"] == "assistant"
&& let Some(s) = v["content"].as_str()
{
out.push(s.to_string());
}
for c in v["message"]["content"].as_array().into_iter().flatten() {
if c["type"] == "text"
&& let Some(s) = c["text"].as_str()
{
out.push(s.to_string());
}
}
if v["type"] == "result"
&& let Some(s) = v["result"].as_str()
{
out.push(s.to_string());
}
out
}
+37
View File
@@ -0,0 +1,37 @@
//! One clef-omni call on Workers AI (as apps/app/host/critique.ts makes it): the state paragraph, the questions by id,
//! the images as data URLs (each made a JPEG at most 1600 px wide first). Keys: CLOUDFLARE_ACCOUNT_ID and
//! CLOUDFLARE_API_TOKEN from raea's settings (the environment, then ~/.raea/env).
use std::path::PathBuf;
use base64::Engine as _;
use serde_json::{Value, json};
fn jpeg(p: &PathBuf) -> Result<String, String> {
let img = image::open(p).map_err(|e| format!("{}: {e}", p.display()))?;
let img = if img.width() > 1600 { img.resize(1600, u32::MAX, image::imageops::FilterType::Triangle) } else { img };
let mut buf = std::io::Cursor::new(Vec::new());
img.to_rgb8().write_to(&mut buf, image::ImageFormat::Jpeg).map_err(|e| e.to_string())?;
Ok(format!("data:image/jpeg;base64,{}", base64::engine::general_purpose::STANDARD.encode(buf.into_inner())))
}
/// The answers by question id, and the call's cost in dollars ($0.15 a million input tokens).
pub fn ask(state: &str, questions: &Value, images: &[PathBuf]) -> Result<(Value, f64), String> {
let (Some(acct), Some(token)) = (raea_io_home::setting("CLOUDFLARE_ACCOUNT_ID"), raea_io_home::setting("CLOUDFLARE_API_TOKEN")) else {
return Err("judge: clef-omni on Workers AI needs CLOUDFLARE_ACCOUNT_ID and CLOUDFLARE_API_TOKEN (the environment or ~/.raea/env)".into());
};
let imgs: Vec<String> = images.iter().map(jpeg).collect::<Result<_, _>>()?;
let body = json!({"state": state, "questions": questions, "images": imgs});
let url = format!("https://api.cloudflare.com/client/v4/accounts/{acct}/ai/run/@cf/cloudflare/clef-omni");
let res = ureq::post(&url).set("authorization", &format!("Bearer {token}")).timeout(std::time::Duration::from_secs(180)).send_json(body);
let j: Value = match res {
Ok(r) => r.into_json().map_err(|e| format!("clef: {e}"))?,
Err(ureq::Error::Status(code, r)) => return Err(format!("clef: HTTP {code}: {}", r.into_string().unwrap_or_default().chars().take(300).collect::<String>())),
Err(e) => return Err(format!("clef: {e}")),
};
if j["success"] != true {
return Err(format!("clef: {}", j["errors"].to_string().chars().take(300).collect::<String>()));
}
let cost = j["result"]["usage"]["input_tokens"].as_f64().unwrap_or(0.0) * 0.15 / 1e6;
Ok((j["result"]["answers"].clone(), cost))
}
+150
View File
@@ -0,0 +1,150 @@
//! Shane's eye, the judge's calibration. `raea judge eye DIR form=5 light=7 ... [--pass yes|no]` records his scores for a
//! round the judge has already judged (DIR/judge.json), with the judge's raw scores beside them, in
//! ~/.raea/judge/eye.jsonl. `raea judge calibrate` fits, per category, a line from the judge's score to his
//! (least squares), and says how often the mapped judge's pass agrees with his. The judge gates only once it has 10
//! rounds or more, some passed by the eye and some not, and agrees on 8 in 10 or better; until then `gating` is false and its verdict is advice
//! (clef has rated almost everything acceptable: docs/craft-system.md). `raea judge eye DIR --by kimi|claude` records a
//! fresh agent session's reading instead (Shane, 11-06), each row saying whose eye it is.
use std::path::PathBuf;
use serde_json::{Map, Value, json};
use crate::rubric::{SCORES, pass};
fn home() -> PathBuf {
raea_io_home::env_path("RAEA_JUDGE_DIR", ".raea/judge")
}
/// The calibration in force, if one was made.
pub fn calibration() -> Option<Value> {
serde_json::from_str(&std::fs::read_to_string(home().join("calibration.json")).ok()?).ok()
}
/// The judge's scores mapped through the calibration's lines, kept to 0-10.
pub fn apply(c: &Value, scores: &mut Map<String, Value>) {
for (k, v) in scores.iter_mut() {
if let (Some(x), Some(a), Some(b)) = (v.as_f64(), c["maps"][k]["a"].as_f64(), c["maps"][k]["b"].as_f64()) {
*v = json!(((a * x + b).clamp(0.0, 10.0) * 100.0).round() / 100.0);
}
}
}
pub fn record(args: &[String]) -> Result<String, String> {
let dir = args.get(2).map(PathBuf::from).ok_or("raea judge eye DIR CATEGORY=SCORE... [--pass yes|no]")?;
let verdict: Value = serde_json::from_str(&std::fs::read_to_string(dir.join("judge.json")).map_err(|_| format!("judge eye: no {}: judge the round first (raea judge {})", dir.join("judge.json").display(), dir.display()))?).map_err(|e| e.to_string())?;
// an agent's reading as the eye (`--by kimi`): a fresh session's scores, and its pass by the same rule in code
if let Some(by) = args.iter().position(|a| a == "--by").and_then(|i| args.get(i + 1)) {
let v = crate::agent::ask(by, &dir, &json!({}), None)?;
let (eye, defects, _) = crate::agent::read(&v);
if eye.len() < SCORES.len() {
return Err(format!("judge eye: {by} scored only {} of {} categories", eye.len(), SCORES.len()));
}
let eye_pass = pass(&eye, &defects).0;
let row = json!({"dir": verdict["dir"], "by": by, "judge": verdict["raw"], "judge_pass": verdict["pass"], "defects": verdict["defects"], "eye": eye, "eye_pass": eye_pass, "eye_defects": defects});
append(&row)?;
let shown: Vec<String> = eye.iter().map(|(k, v)| format!("{k} {v}")).collect();
return Ok(format!("APPLIED {by}'s eye on {} recorded ({}): {}; raea judge calibrate fits clef to it", dir.display(), if eye_pass { "a pass" } else { "not yet" }, shown.join(", ")));
}
let mut eye = Map::new();
let mut said_pass = None;
let mut i = 3;
while i < args.len() {
if args[i] == "--pass" {
said_pass = Some(matches!(args.get(i + 1).map(String::as_str), Some("yes" | "true" | "y")));
i += 2;
continue;
}
let (k, v) = args[i].split_once('=').ok_or_else(|| format!("judge eye: {:?} isn't CATEGORY=SCORE", args[i]))?;
if !SCORES.iter().any(|s| s.0 == k) {
return Err(format!("judge eye: no category {k}: {}", SCORES.iter().map(|s| s.0).collect::<Vec<_>>().join(", ")));
}
let x: f64 = v.parse().ok().filter(|x| (0.0..=10.0).contains(x)).ok_or_else(|| format!("judge eye: {k} is a score 0-10, got {v:?}"))?;
eye.insert(k.into(), json!(x));
i += 1;
}
if eye.is_empty() {
return Err("judge eye: give your scores, e.g. composition=6 form=5 assembly=7 materials=4 light=6 detail=5 world=6".into());
}
// his pass: as he says it, else the same rule on his scores with the judge's defects
let eye_pass = said_pass.unwrap_or_else(|| pass(&eye, verdict["defects"].as_array().map(Vec::as_slice).unwrap_or(&[])).0);
let row = json!({"dir": verdict["dir"], "by": "shane", "judge": verdict["raw"], "judge_pass": verdict["pass"], "defects": verdict["defects"], "eye": eye, "eye_pass": eye_pass});
append(&row)?;
Ok(format!("APPLIED your eye on {} recorded ({}): raea judge calibrate fits the judge to it", dir.display(), if eye_pass { "a pass" } else { "not yet" }))
}
/// One eye row onto ~/.raea/judge/eye.jsonl; a newer reading of the same round by the same eye replaces the older.
fn append(row: &Value) -> Result<(), String> {
std::fs::create_dir_all(home()).map_err(|e| e.to_string())?;
let path = home().join("eye.jsonl");
let mut rows: Vec<Value> = std::fs::read_to_string(&path).unwrap_or_default().lines().filter_map(|l| serde_json::from_str(l).ok()).filter(|r: &Value| !(r["dir"] == row["dir"] && whose(r) == whose(&row))).collect();
rows.push(row.clone());
std::fs::write(&path, rows.iter().map(Value::to_string).collect::<Vec<_>>().join("\n") + "\n").map_err(|e| e.to_string())
}
/// Least squares y = a x + b; flat x (one value) maps by the mean offset.
fn fit(xy: &[(f64, f64)]) -> (f64, f64) {
let n = xy.len() as f64;
let (mx, my) = (xy.iter().map(|p| p.0).sum::<f64>() / n, xy.iter().map(|p| p.1).sum::<f64>() / n);
let sxx: f64 = xy.iter().map(|p| (p.0 - mx).powi(2)).sum();
if sxx < 1e-9 {
return (1.0, my - mx);
}
let a = xy.iter().map(|p| (p.0 - mx) * (p.1 - my)).sum::<f64>() / sxx;
(a, my - a * mx)
}
/// The fit over rows of {judge, eye, defects, eye_pass}: per-category maps and errors, and the pass agreement.
pub fn fit_rows(rows: &[Value]) -> Value {
let mut maps = Map::new();
for (k, _, _) in SCORES {
let xy: Vec<(f64, f64)> = rows.iter().filter_map(|r| Some((r["judge"][k].as_f64()?, r["eye"][k].as_f64()?))).collect();
if xy.len() < 2 {
continue;
}
let (a, b) = fit(&xy);
let mae = |f: &dyn Fn(f64) -> f64| xy.iter().map(|(x, y)| (f(*x) - y).abs()).sum::<f64>() / xy.len() as f64;
let r2 = |x: f64| (x * 1000.0).round() / 1000.0;
maps.insert(k.into(), json!({"a": r2(a), "b": r2(b), "n": xy.len(), "maeRaw": r2(mae(&|x| x)), "maeMapped": r2(mae(&|x| (a * x + b).clamp(0.0, 10.0)))}));
}
let cal = json!({"maps": maps});
let mut agree = 0;
for r in rows {
let mut s = r["judge"].as_object().cloned().unwrap_or_default();
apply(&cal, &mut s);
let p = pass(&s, r["defects"].as_array().map(Vec::as_slice).unwrap_or(&[])).0;
if Value::Bool(p) == r["eye_pass"] {
agree += 1;
}
}
let n = rows.len();
let agreement = if n == 0 { 0.0 } else { agree as f64 / n as f64 };
// agreement means something only when the eye passed some rounds and failed others: all fails agree trivially
let passes = rows.iter().filter(|r| r["eye_pass"] == true).count();
let both = passes > 0 && passes < n;
json!({"maps": maps, "rounds": n, "eyePasses": passes, "agreement": (agreement * 1000.0).round() / 1000.0, "gate": n >= 10 && agreement >= 0.8 && both})
}
pub fn calibrate(args: &[String]) -> Result<String, String> {
let rows: Vec<Value> = std::fs::read_to_string(home().join("eye.jsonl")).unwrap_or_default().lines().filter_map(|l| serde_json::from_str(l).ok()).collect();
if rows.is_empty() {
return Err("judge calibrate: no rounds with your eye yet (raea judge eye DIR form=5 ...)".into());
}
let mut cal = fit_rows(&rows);
let mut eyes: Vec<String> = rows.iter().map(whose).map(str::to_string).collect();
eyes.sort();
eyes.dedup();
cal["eyes"] = json!(eyes);
std::fs::write(home().join("calibration.json"), serde_json::to_string_pretty(&cal).unwrap_or_default()).map_err(|e| e.to_string())?;
if args.iter().any(|a| a == "--json") {
return Ok(serde_json::to_string_pretty(&cal).unwrap_or_default());
}
let mut t: Vec<String> = cal["maps"].as_object().into_iter().flatten().map(|(k, m)| format!("{k:<12} eye = {} x judge {:+} (off by {} raw, {} mapped, {} rounds)", m["a"], m["b"], m["maeRaw"], m["maeMapped"], m["n"])).collect();
t.push(format!("agreement on the pass: {} over {} rounds (eyes: {}); {}", cal["agreement"], cal["rounds"], eyes.join(", "), if cal["gate"] == true { "the judge gates now".to_string() } else if cal["rounds"].as_u64() >= Some(10) && cal["agreement"].as_f64() >= Some(0.8) { format!("advice only: the eye passed {} of {} rounds, and agreement means something only with passes and fails both (judge a scene that is good)", cal["eyePasses"], cal["rounds"]) } else { "advice only until 10 rounds agree 8 in 10, with passes and fails both".to_string() }));
Ok(t.join("\n"))
}
/// Whose eye a row records: Shane's when it doesn't say.
fn whose(r: &Value) -> &str {
r["by"].as_str().unwrap_or("shane")
}
+171
View File
@@ -0,0 +1,171 @@
//! `raea judge`: a review's sheets (`raea render --review DIR`) judged by clef-omni on the frozen rubric (rubric.rs),
//! fresh every round and blind to the code, with the pass decided here in code. Until it is calibrated against Shane's
//! eye (`raea judge eye`, `raea judge calibrate`, eye.rs) its verdict is advice: `gating` says which.
//!
//! raea judge DIR [--by clef|kimi|claude] [--brief brief.ts] [--target T.png] [--json] [--dry]
//! raea judge eye DIR composition=6 form=5 ... [--pass yes|no] (or --by kimi: an agent's reading as the eye)
//! raea judge calibrate [--json]
//!
//! DIR/judge.json is the verdict; DIR's parent's judge.log.jsonl holds every round's, so "done" (two passes in a row,
//! each a fresh call) and the stall (the mean up by less than a point over two rounds) are read from it.
mod agent;
mod clef;
mod eye;
pub mod rubric;
pub use agent::BY;
use std::path::{Path, PathBuf};
use raea_runtime_bundle::flag;
use serde_json::{Value, json};
pub const USAGE: &str = "raea judge DIR [--by clef|kimi|claude] [--brief brief.ts] [--target T.png] [--json] [--dry] | judge eye DIR (CATEGORY=SCORE ... [--pass yes|no] | --by kimi|claude) | judge calibrate [--json] (a --review folder's sheets judged blind: clef-omni on the frozen rubric, or a fresh kimi or claude session on the judge prompt; the pass decided in code; clef advises until calibrated against your eye or an agent's)";
/// The brief's words, from `raea spec brief.ts --as brief` (look, logline, notDoing), or nothing.
fn brief_of(path: Option<&str>) -> Result<Value, String> {
let Some(p) = path else { return Ok(json!({})) };
let exe = std::env::current_exe().map_err(|e| e.to_string())?;
let out = std::process::Command::new(exe).args(["spec", p, "--as", "brief"]).output().map_err(|e| e.to_string())?;
let text = String::from_utf8_lossy(&out.stdout);
let start = text.find('{').ok_or_else(|| format!("judge: {p} didn't read as a brief: {}", String::from_utf8_lossy(&out.stderr).lines().last().unwrap_or("")))?;
let v: Value = serde_json::from_str(&text[start..]).map_err(|e| format!("judge: {p}: {e}"))?;
Ok(v.get("brief").cloned().unwrap_or(v))
}
/// The rounds judged so far beside this one (DIR's parent's judge.log.jsonl).
fn log_of(dir: &Path) -> PathBuf {
dir.parent().unwrap_or(dir).join("judge.log.jsonl")
}
/// Done and stall, from the log's rounds (oldest first), in code.
pub fn progress(rounds: &[Value]) -> Value {
let passes = rounds.iter().rev().take_while(|r| r["pass"] == true).count();
let means: Vec<f64> = rounds.iter().filter_map(|r| r["mean"].as_f64()).collect();
let stall = means.len() >= 3 && {
let best_before = means[..means.len() - 2].iter().cloned().fold(f64::MIN, f64::max);
let best_now = means[means.len() - 2..].iter().cloned().fold(f64::MIN, f64::max);
best_now - best_before < 1.0
};
// the same blocking defect present in the last two rounds
let named = |r: &Value| -> Vec<String> { rubric::blocking(r["defects"].as_array().map(Vec::as_slice).unwrap_or_default()).into_iter().map(str::to_string).collect() };
let again: Vec<String> = match rounds {
[.., a, b] => named(a).into_iter().filter(|d| named(b).contains(d)).collect(),
_ => Vec::new(),
};
json!({"rounds": rounds.len(), "passesInARow": passes, "done": passes >= 2, "stall": stall || !again.is_empty(), "again": again})
}
pub fn cli(args: &[String]) -> Result<String, String> {
match args.get(1).map(String::as_str) {
Some("eye") => return eye::record(args),
Some("calibrate") => return eye::calibrate(args),
Some(_) => {}
None => return Err(USAGE.into()),
}
let dir = PathBuf::from(&args[1]);
let (colour, clay, hero) = (dir.join("colour.png"), dir.join("clay.png"), dir.join("hero-colour.png"));
for f in [&colour, &clay] {
if !f.is_file() {
return Err(format!("judge: no {} (make the sheets with raea render EDIT.tsx --review {})", f.display(), dir.display()));
}
}
let brief = brief_of(flag(args, "--brief").as_deref())?;
let target = flag(args, "--target").map(PathBuf::from);
let dry = args.iter().any(|a| a == "--dry");
let by = flag(args, "--by").unwrap_or_else(|| "clef".into());
if by != "clef" {
if dry {
return Ok(agent::prompt(&dir, &brief, target.as_deref()));
}
let v = agent::ask(&by, &dir, &brief, target.as_deref())?;
let (scores, defects, photo) = agent::read(&v);
return finish(args, &dir, scores.clone(), scores, defects, photo, 0.0, &by, false, json!({"blind": v["blind"], "show_as_is": v["show_as_is"]}));
}
let mut calls = Vec::new();
for (sheet, img) in [("colour", &colour), ("clay", &clay)] {
let mut images = vec![img.clone()];
if sheet == "colour" {
images.extend(target.clone());
}
calls.push((sheet, rubric::state(sheet, &brief), rubric::questions(sheet), images));
}
if hero.is_file() {
calls.push(("blind", "One frame. Judge only what is in the pixels.".into(), rubric::blind(), vec![hero.clone()]));
}
if dry {
let shown: Vec<Value> = calls.iter().map(|(s, st, q, im)| json!({"sheet": s, "state": st, "questions": q, "images": im.iter().map(|p| p.display().to_string()).collect::<Vec<_>>()})).collect();
return Ok(serde_json::to_string_pretty(&json!({"would_ask": shown})).unwrap_or_default());
}
let mut scores = serde_json::Map::new();
let mut defects = Vec::new();
let mut photo = Value::Null;
let mut cost = 0.0;
for (sheet, st, q, images) in &calls {
let (answers, c) = clef::ask(st, q, images)?;
cost += c;
if *sheet == "blind" {
photo = json!(answers["photo"]["noul"].as_f64().map(|p| (p * 1000.0).round() / 1000.0));
continue;
}
let (s, d) = rubric::read(&answers);
scores.extend(s);
defects.extend(d.into_iter().map(|mut x| {
x["sheet"] = json!(sheet);
x
}));
}
let raw = scores.clone();
let cal = eye::calibration();
if let Some(c) = &cal {
eye::apply(c, &mut scores);
}
let gating = cal.as_ref().is_some_and(|c| c["gate"] == true);
finish(args, &dir, scores, raw, defects, photo, cost, "clef", !gating, json!({"calibrated": cal.is_some()}))
}
/// The verdict decided in code, written (DIR/judge.json for clef, DIR/judge.BY.json for an agent; every round in the
/// log), and said. `advice` marks a judge not yet trusted to gate (clef before calibration).
#[allow(clippy::too_many_arguments)]
fn finish(args: &[String], dir: &Path, scores: serde_json::Map<String, Value>, raw: serde_json::Map<String, Value>, defects: Vec<Value>, photo: Value, cost: f64, by: &str, advice: bool, extra: Value) -> Result<String, String> {
let (pass, why) = rubric::pass(&scores, &defects);
let vals: Vec<f64> = scores.values().filter_map(Value::as_f64).collect();
let mean = if vals.is_empty() { 0.0 } else { (vals.iter().sum::<f64>() / vals.len() as f64 * 100.0).round() / 100.0 };
let model = if by == "clef" { "@cf/cloudflare/clef-omni".to_string() } else { format!("{by} cli") };
let mut verdict = json!({"dir": dir.display().to_string(), "by": by, "scores": scores, "raw": raw, "mean": mean, "defects": defects, "photo": photo,
"pass": pass, "why": why, "gating": !advice, "cost": cost, "model": model});
if let (Some(v), Some(e)) = (verdict.as_object_mut(), extra.as_object()) {
v.extend(e.clone());
}
let log = log_of(dir);
let mut rounds: Vec<Value> = std::fs::read_to_string(&log).unwrap_or_default().lines().filter_map(|l| serde_json::from_str(l).ok()).filter(|r: &Value| r["dir"] != verdict["dir"]).collect();
rounds.push(verdict.clone());
verdict["progress"] = progress(&rounds);
let file = if by == "clef" { "judge.json".to_string() } else { format!("judge.{by}.json") };
std::fs::write(dir.join(file), serde_json::to_string_pretty(&verdict).unwrap_or_default()).map_err(|e| e.to_string())?;
let lines: Vec<String> = rounds.iter().map(|r| serde_json::to_string(&json!({"dir": r["dir"], "pass": r["pass"], "mean": r["mean"], "defects": r["defects"]})).unwrap_or_default()).collect();
std::fs::write(&log, lines.join("\n") + "\n").map_err(|e| e.to_string())?;
if cost > 0.0 {
let _ = std::process::Command::new("antsy").args(["spend", &format!("{cost:.6}"), "raea judge (clef-omni)"]).output();
}
if args.iter().any(|a| a == "--json") {
return Ok(serde_json::to_string_pretty(&verdict).unwrap_or_default());
}
let who = if by == "clef" { String::new() } else { format!("({by}) ") };
let mut t = vec![format!("{} {who}{}{}", if pass { "PASS" } else { "NOT YET" }, if advice { "(advice: the judge isn't calibrated against your eye yet) " } else { "" }, why.join("; "))];
t.push(format!("scores: {}", scores.iter().map(|(k, v)| format!("{k} {v}")).collect::<Vec<_>>().join(", ")));
for d in verdict["defects"].as_array().into_iter().flatten().filter(|d| d["present"] == true) {
if by == "clef" {
t.push(format!(" {:<8} {} (p {}, {} sheet): {}", d["level"].as_str().unwrap_or(""), d["defect"].as_str().unwrap_or(""), d["p"], d["sheet"].as_str().unwrap_or(""), d["asked"].as_str().unwrap_or("")));
} else {
t.push(format!(" {:<8} {} tile: {} (fix: {})", d["level"].as_str().unwrap_or(""), d["sheet"].as_str().unwrap_or(""), d["asked"].as_str().unwrap_or(""), d["fix"].as_str().unwrap_or("")));
}
}
let p = &verdict["progress"];
t.push(format!("round {}: {} passes in a row{}{}; ${cost:.4}", p["rounds"], p["passesInARow"], if p["done"] == true { ", done" } else { "" }, if p["stall"] == true { ", stalled: change the approach for the part, not the dose" } else { "" }));
Ok(t.join("\n"))
}
#[cfg(test)]
mod tests;
+133
View File
@@ -0,0 +1,133 @@
//! The frozen rubric (the 11-06 prompt pack, section 3, in clef-omni's native question types): a 0-10 score per category
//! as an ordered six-level rubric, and every named defect as a yes/no question, so a defect is a probability rather
//! than prose. clef-omni answers questions, not essays; the defects it can name are the ones asked. Nothing here says
//! where the pass line is (the loop decides, in code: `pass`).
use serde_json::{Value, json};
/// The six levels each category is scored on, lowest first (clef's `score`: the probability-weighted level), read as
/// 0, 2, 4, 6, 8, 10.
fn levels(what: &str) -> Value {
json!([
format!("0: no {what} to speak of; broken or missing"),
format!("2: {what} is crude: primitives and placeholders"),
format!("4: {what} is a rough draft, plainly unfinished"),
format!("6: {what} is a believable draft"),
format!("8: {what} is a production base an artist would accept"),
format!("10: {what} is indistinguishable from the real thing"),
])
}
/// (id, the sheet it is judged on, the question)
pub const SCORES: [(&str, &str, &str); 7] = [
("composition", "colour", "Composition: the camera, framing and layout; every major object's position and scale against the brief's space."),
("form", "clay", "Form, judged on these grey clay tiles: silhouettes read at a glance, parts have real thickness, nothing blobby or melted, no primitive standing in for a thing, repeated things vary."),
("assembly", "clay", "Assembly, judged on these grey clay tiles: nothing floats, sinks, pokes through or rests on the wrong thing; joints touch; the low tile shows the feet resting."),
("materials", "colour", "Materials: every surface reads as its real material with wear where use puts it; nothing a flat default colour; glass is glass."),
("light", "colour", "Light: motivated by the place's own sources; exposure and contrast believable; no surface implausibly dark or bright."),
("detail", "colour", "Detail: close surfaces hold real geometry or texture at that distance, not smooth stand-ins; printed matter reads."),
("world", "colour", "World: one coherent real place matching the brief; nothing off-era, no real brands, nothing invented beyond the brief."),
];
/// (id, sheet, the yes/no question, blocking when yes)
pub const DEFECTS: [(&str, &str, &str, bool); 12] = [
("floating", "clay", "Does any object float above the surface it should rest on, with a visible gap under it?", true),
("intersecting", "clay", "Does any object pass through another object, a wall or the floor?", true),
("blobby", "clay", "Is any object a blobby, melted or lumpy shape where the real thing has crisp form?", true),
("stand_in", "clay", "Is any object just a plain box, ball or cylinder standing in for a more detailed real thing?", true),
("clones", "clay", "Are several copies of one thing identical and evenly spaced in an obviously artificial way?", false),
("flat_colour", "colour", "Is any large surface a flat, uniform default colour with no texture, variation or wear?", true),
("plastic", "colour", "Do the surfaces look like shiny uniform plastic or CG rather than their real materials?", true),
("garbled_text", "colour", "Is any visible text garbled, tiled or unreadable where it should read?", false),
("too_dark", "colour", "Is the scene so dark that important objects are hard to see?", true),
("too_bright", "colour", "Is the scene washed out, with large areas blown to white?", true),
("brands", "colour", "Is a real brand name or logo visible?", true),
("not_doing", "colour", "Does the scene show anything the brief says it must not contain?", true),
];
/// The paragraph clef reads before the sheet: what it is looking at, and the brief's words (no code, no log, no line).
pub fn state(sheet: &str, brief: &Value) -> String {
let look = brief["look"].as_str().unwrap_or("");
let logline = brief["logline"].as_str().unwrap_or("");
let not: Vec<&str> = brief["notDoing"].as_array().into_iter().flatten().filter_map(Value::as_str).collect();
let tiles = "six tiles of one 3D scene, left to right and top to bottom: hero (the shot's own camera), front, right, top, iso, and low (a camera 0.3 m off the floor)";
let what = if sheet == "clay" { format!("The image is {tiles}, rendered in clay: every surface plain grey, so only form and assembly show.") } else { format!("The image is {tiles}, in full colour.") };
let target = if sheet == "colour" { " A second image, when given, is the target picture the scene should read as." } else { "" };
let mut s = format!("{what}{target} Judge only what is in the pixels, as the person who will use the scene would.");
if !logline.is_empty() || !look.is_empty() {
s.push_str(&format!(" The brief: {logline} Look: {look}."));
}
if !not.is_empty() {
s.push_str(&format!(" The scene must not contain: {}.", not.join("; ")));
}
s
}
/// The questions for one sheet, by id.
pub fn questions(sheet: &str) -> Value {
let mut q = serde_json::Map::new();
for (id, on, ask) in SCORES {
if on == sheet {
q.insert(format!("score_{id}"), json!({"type": "score", "instructions": ask, "criteria": levels(id)}));
}
}
for (id, on, ask, _) in DEFECTS {
if on == sheet {
q.insert(format!("defect_{id}"), json!({"type": "noul", "instructions": ask}));
}
}
Value::Object(q)
}
/// The blind read on the hero tile alone: is this a photograph (reported, never gated, until calibrated).
pub fn blind() -> Value {
json!({"photo": {"type": "noul", "instructions": "Is this a photograph of a real place, rather than a computer render?"}})
}
/// clef's answers read into scores (0-10) and defects (probability of yes, blocking ones flagged).
pub fn read(answers: &Value) -> (serde_json::Map<String, Value>, Vec<Value>) {
let mut scores = serde_json::Map::new();
let mut defects = Vec::new();
for (id, _, _) in SCORES {
if let Some(a) = answers.get(format!("score_{id}")) {
let level = a["score"].as_f64().unwrap_or(0.0);
scores.insert(id.into(), json!((level * 2.0 * 100.0).round() / 100.0));
}
}
for (id, _, ask, blocking) in DEFECTS {
if let Some(a) = answers.get(format!("defect_{id}")) {
let p = a["noul"].as_f64().unwrap_or(0.0);
defects.push(json!({"defect": id, "p": (p * 1000.0).round() / 1000.0, "present": p >= 0.5, "level": if blocking { "blocking" } else { "detail" }, "asked": ask}));
}
}
(scores, defects)
}
/// The loop's pass, in code: no blocking defect present, the lowest score 6 or more and the mean 7 or more (raea's
/// 0-10 scale; the prompt pack's line). Scores mapped by a calibration first, when there is one.
pub fn pass(scores: &serde_json::Map<String, Value>, defects: &[Value]) -> (bool, Vec<String>) {
let vals: Vec<f64> = scores.values().filter_map(Value::as_f64).collect();
let mut why = Vec::new();
let blocking = blocking(defects);
if !blocking.is_empty() {
why.push(format!("blocking: {}", blocking.join(", ")));
}
let min = vals.iter().cloned().fold(f64::INFINITY, f64::min);
let mean = if vals.is_empty() { 0.0 } else { vals.iter().sum::<f64>() / vals.len() as f64 };
if vals.len() < SCORES.len() {
why.push(format!("only {} of {} categories scored", vals.len(), SCORES.len()));
}
if min < 6.0 {
let low: Vec<String> = scores.iter().filter(|(_, v)| v.as_f64().is_some_and(|x| x < 6.0)).map(|(k, _)| k.clone()).collect();
why.push(format!("below a draft: {}", low.join(", ")));
}
if mean < 7.0 {
why.push("the whole is under a production base".into());
}
(why.is_empty(), why)
}
/// The blocking defects present, by name.
pub fn blocking(defects: &[Value]) -> Vec<&str> {
defects.iter().filter(|d| d["present"] == true && d["level"] == "blocking").filter_map(|d| d["defect"].as_str()).collect()
}
+72
View File
@@ -0,0 +1,72 @@
use super::*;
use serde_json::json;
fn scores(v: f64) -> serde_json::Map<String, Value> {
rubric::SCORES.iter().map(|s| (s.0.to_string(), json!(v))).collect()
}
#[test]
fn the_pass_is_code_and_a_blocking_defect_holds_it() {
assert!(rubric::pass(&scores(7.5), &[]).0);
assert!(!rubric::pass(&scores(6.5), &[]).0, "mean under 7");
let mut s = scores(8.0);
s.insert("form".into(), json!(5.0));
let (ok, why) = rubric::pass(&s, &[]);
assert!(!ok && why.iter().any(|w| w.contains("form")));
let d = vec![json!({"defect": "floating", "present": true, "level": "blocking"})];
assert!(!rubric::pass(&scores(9.0), &d).0);
// the questions hold no pass line
let q = format!("{}{}", rubric::questions("colour"), rubric::questions("clay"));
assert!(!q.contains("mean") && !q.contains(">= 6"));
}
#[test]
fn answers_are_read_and_rounds_say_done_and_stall() {
let a = json!({"score_form": {"score": 3.5}, "defect_floating": {"noul": 0.8}});
let (s, d) = rubric::read(&a);
assert_eq!(s["form"], 7.0);
assert_eq!(d[0]["present"], true);
let r = |p: bool, m: f64| json!({"pass": p, "mean": m, "defects": []});
assert_eq!(progress(&[r(false, 5.0), r(true, 7.2), r(true, 7.4)])["done"], true);
assert_eq!(progress(&[r(false, 5.0), r(false, 5.3), r(false, 5.6)])["stall"], true);
assert_eq!(progress(&[r(false, 4.0), r(false, 5.3), r(false, 6.1)])["stall"], false);
}
#[test]
fn calibration_maps_a_lenient_judge_onto_the_eye() {
// the judge says 8 to everything the eye gives 5, and 9 to what the eye gives 8
let row = |j: f64, e: f64, p: bool| json!({"judge": scores(j), "eye": scores(e), "eye_pass": p, "defects": []});
let rows: Vec<Value> = (0..12).map(|i| if i % 2 == 0 { row(8.0, 5.0, false) } else { row(9.0, 8.0, true) }).collect();
let cal = eye::fit_rows(&rows);
assert_eq!(cal["agreement"], 1.0);
assert_eq!(cal["gate"], true);
assert!((cal["maps"]["form"]["a"].as_f64().unwrap() - 3.0).abs() < 1e-6);
let few = eye::fit_rows(&rows[..4]);
assert_eq!(few["gate"], false, "too few rounds to gate");
// an eye that failed everything agrees with a judge that fails everything, which proves nothing
let fails: Vec<Value> = (0..12).map(|_| row(3.0, 2.0, false)).collect();
let all_fail = eye::fit_rows(&fails);
assert_eq!(all_fail["agreement"], 1.0);
assert_eq!(all_fail["gate"], false, "no pass among the eye's rounds");
}
#[test]
fn an_agent_verdict_is_read_from_the_end_of_its_thinking() {
// an agent thinks aloud, may draft the JSON twice, and ends with the one it means
let text = r#"• Looking at the sheets... draft: {"scores": {"form": 1}} then the answer:
{"blind": {"place": "office", "objects": [], "photo": "no", "tells": []},
"scores": {"composition": 6, "form": 5.5, "assembly": 7, "materials": 4, "light": 6, "detail": 5, "world": 6, "vibes": 9},
"defects": [{"tile": "iso", "where": "left", "wrong": "the desks are plain boxes", "real": "a desk has legs", "fix": "model legs", "level": "blocking"},
{"tile": "low", "wrong": "", "level": "detail"}],
"show_as_is": "no"}"#;
let v = crate::agent::last_verdict(text).unwrap();
let (scores, defects, photo) = crate::agent::read(&v);
assert_eq!(scores.len(), 7, "only the seven categories, each 0-10");
assert_eq!(scores["form"], serde_json::json!(5.5));
assert_eq!(defects.len(), 1, "a defect with nothing wrong named is dropped");
assert_eq!(defects[0]["level"], "blocking");
assert_eq!(photo, serde_json::json!(0.0));
let (pass, why) = crate::rubric::pass(&scores, &defects);
assert!(!pass && why[0].starts_with("blocking"));
assert!(crate::agent::last_verdict("no json here").is_none());
}
+1 -1
View File
@@ -58,5 +58,5 @@ pub fn frames(out: &Path, size: (u32, u32), fps: f64, quality: Option<f32>, audi
None => None,
};
let stats = enc.finish(sound.as_ref())?;
Ok(json!({"wrote": out, "frames": frames, "seconds": round3(secs), "width": w, "height": h, "fps": round3(fps), "bytes": stats.bytes, "sound": sound.is_some(), "credentials": if raea_io_media::SIGNS { "signed" } else { "unsigned" }}))
Ok(json!({"wrote": out, "frames": frames, "seconds": round3(secs), "width": w, "height": h, "fps": round3(fps), "bytes": stats.bytes, "sound": sound.is_some(), "credentials": if raea_io_media::signs() { "signed" } else { "unsigned" }}))
}
+18
View File
@@ -0,0 +1,18 @@
[package]
name = "raea-app-solid"
version = "0.1.0"
edition = "2024"
license = "FSL-1.1-ALv2"
publish = false
description = "raea solid info and raea solid view: a solid file run, its parts measured (raea-core-solidinfo), and its review sheets in colour and clay"
[dependencies]
raea-core-solidinfo = { path = "../../core/solidinfo" }
serde_json = "1"
# --set's and the CLI's flags, read as the bundler reads them
raea-runtime-bundle = { path = "../../runtime/bundle" }
# `raea judge`, dispatched with `raea solid` (verb())
raea-app-judge = { path = "../judge" }
# `raea solid export`: the solid built, written as .glb and read back (core/shape), named and coloured (core/meshcheck)
raea-core-shape = { path = "../../core/shape" }
raea-core-meshcheck = { path = "../../core/meshcheck" }
+128
View File
@@ -0,0 +1,128 @@
//! `raea solid export FILE.ts -o OUT.glb [--set k=v,...] [--part NAME] [--colour #RRGGBB]` (docs/blender.feature BL1):
//! a solid written as one .glb, metres, y up, so a Blender step can take it (bake.py for real UVs and baked maps, a
//! cloth to fall on). The solid stays the source: the .glb is made again from it whenever it changes. An empty solid,
//! or one solid info finds an error in, is refused with the findings. The file is read back and measured against the
//! solid (volume, pieces, box, within 0.5%), and a licence sidecar is written beside it.
use std::path::Path;
use raea_core_shape::Manifold;
use raea_core_solidinfo::{Measured, measure};
use raea_runtime_bundle::flag;
use serde_json::{Value, json};
/// How far the read-back may differ, as a share of the solid's own value.
const TOLERANCE: f64 = 0.005;
/// `#RRGGBB` as linear RGBA.
fn linear(hex: &str) -> Result<[f64; 4], String> {
let h = hex.trim_start_matches('#');
let c = |i: usize| u8::from_str_radix(h.get(i..i + 2).unwrap_or(""), 16).map_err(|_| format!("--colour takes #RRGGBB, got {hex:?}"));
let lin = |v: u8| {
let s = v as f64 / 255.0;
if s <= 0.04045 { s / 12.92 } else { ((s + 0.055) / 1.055).powf(2.4) }
};
if h.len() != 6 {
return Err(format!("--colour takes #RRGGBB, got {hex:?}"));
}
Ok([lin(c(0)?), lin(c(2)?), lin(c(4)?), 1.0])
}
/// The read-back's differences from the solid, each over the tolerance: none when they match.
pub(crate) fn differences(a: &Measured, b: &Measured) -> Vec<String> {
let mut d = Vec::new();
let off = |x: f64, y: f64, of: f64| (x - y).abs() > TOLERANCE * of.abs().max(1e-9);
if off(a.volume, b.volume, a.volume) {
d.push(format!("volume {} m³ read back as {}", a.volume, b.volume));
}
if a.pieces != b.pieces {
d.push(format!("{} pieces read back as {}", a.pieces, b.pieces));
}
let span = (0..3).map(|k| a.max[k] - a.min[k]).fold(0.0, f64::max);
if (0..3).any(|k| off(a.min[k], b.min[k], span) || off(a.max[k], b.max[k], span)) {
d.push(format!("box {:?}..{:?} read back as {:?}..{:?}", a.min, a.max, b.min, b.max));
}
d
}
/// Solid info's findings at one level, as it prints them: all of them, or one part's alone.
fn said(info: &Value, level: &str, part: Option<&str>) -> Vec<String> {
let mine = |f: &&Value| f["level"] == level && part.is_none_or(|p| f["part"].as_str() == Some(p));
info["found"].as_array().into_iter().flatten().filter(mine).map(|f| format!("{level:<8} {}", f["says"].as_str().unwrap_or(""))).collect()
}
pub fn export(file: &Path, parts: &[(String, String)], info: &Value, args: &[String]) -> Result<String, String> {
let out = flag(args, "-o").filter(|o| o.ends_with(".glb")).ok_or("raea solid export FILE.ts -o OUT.glb: give the .glb to write")?;
let part = flag(args, "--part");
let chosen: Vec<&(String, String)> = parts.iter().filter(|(n, _)| part.as_deref().is_none_or(|p| p == n)).collect();
if chosen.is_empty() {
return Err(format!("solid export: no part {} (the file's parts: {})", part.unwrap_or_default(), parts.iter().map(|p| p.0.as_str()).collect::<Vec<_>>().join(", ")));
}
// refused on solid info's errors: the whole's, or the part's alone when one is asked for
let errors = said(info, "error", part.as_deref());
if !errors.is_empty() {
return Err(format!("solid export: refused, solid info finds errors:\n{}", errors.join("\n")));
}
let solids = chosen.iter().map(|(_, e)| raea_core_shape::solid(e)).collect::<Result<Vec<Manifold>, String>>()?;
let m = solids.into_iter().reduce(|a, b| a.union(&b)).ok_or("solid export: no part to write")?;
let mine = measure(&m);
if mine.empty {
return Err("solid export: refused, the solid is empty".into());
}
if let Some(dir) = Path::new(&out).parent().filter(|d| !d.as_os_str().is_empty()) {
std::fs::create_dir_all(dir).map_err(|e| format!("{}: {e}", dir.display()))?;
}
raea_core_shape::export(&m, &out, "glb")?;
// its name, and a material when a colour is given (bake.py multiplies its AO into it)
let g = raea_core_meshcheck::Glb::read(&out)?;
let mut j = g.json.clone();
let name = part.clone().unwrap_or_else(|| file.file_stem().and_then(|s| s.to_str()).unwrap_or("solid").to_string());
j["nodes"][0]["name"] = json!(name);
j["meshes"][0]["name"] = json!(name);
j["asset"]["generator"] = json!("raea solid export");
if let Some(c) = flag(args, "--colour") {
j["materials"] = json!([{"name": name, "pbrMetallicRoughness": {"baseColorFactor": linear(&c)?, "metallicFactor": 0.0, "roughnessFactor": 0.8}}]);
j["meshes"][0]["primitives"][0]["material"] = json!(0);
}
std::fs::write(&out, g.with_json(&j)?).map_err(|e| format!("{out}: {e}"))?;
// read back: the file a scene and Blender will load, measured against the solid
let (v, t) = raea_core_shape::read_glb(&out)?;
let back = measure(&raea_core_shape::from_mesh(&v, &t)?);
let diff = differences(&mine, &back);
if !diff.is_empty() {
return Err(format!("solid export: {out} doesn't read back as the solid: {}", diff.join("; ")));
}
let side = json!({"source": format!("raea solid export {}{}", file.display(), part.as_ref().map(|p| format!(" --part {p}")).unwrap_or_default()), "license": "built in code for this project", "credit": ""});
std::fs::write(format!("{out}.json"), serde_json::to_string_pretty(&side).unwrap_or_default()).map_err(|e| e.to_string())?;
let r = |x: f64| (x * 1e5).round() / 1e5;
let mut t = vec![format!(
"APPLIED {out}: {} triangles, {} m³, {} x {} x {} m, {} piece(s); read back the same (within {}%); licence in {out}.json",
mine.tris, r(mine.volume), r(mine.max[0] - mine.min[0]), r(mine.max[1] - mine.min[1]), r(mine.max[2] - mine.min[2]), mine.pieces, TOLERANCE * 100.0
)];
t.extend(said(info, "warning", None));
Ok(t.join("\n"))
}
#[cfg(test)]
mod tests {
#[test]
fn a_solid_reads_back_as_itself() {
let m = raea_core_shape::solid("minus(box(0.4, 0.3, 0.2), cylinder(0.05, 0.4))").unwrap();
let dir = std::env::temp_dir().join(format!("raea-solid-export-{}", std::process::id()));
std::fs::create_dir_all(&dir).unwrap();
let out = dir.join("x.glb");
raea_core_shape::export(&m, out.to_str().unwrap(), "glb").unwrap();
let (v, t) = raea_core_shape::read_glb(out.to_str().unwrap()).unwrap();
let back = raea_core_solidinfo::measure(&raea_core_shape::from_mesh(&v, &t).unwrap());
let mine = raea_core_solidinfo::measure(&m);
assert!(super::differences(&mine, &back).is_empty(), "{:?}", super::differences(&mine, &back));
// a mismatch is named
let mut off = raea_core_solidinfo::measure(&m);
off.volume *= 1.1;
off.pieces = 2;
assert_eq!(super::differences(&off, &back).len(), 2);
let _ = std::fs::remove_dir_all(&dir);
assert_eq!(super::linear("#ffffff").unwrap(), [1.0, 1.0, 1.0, 1.0]);
assert!(super::linear("red").is_err());
}
}
+196
View File
@@ -0,0 +1,196 @@
//! `raea solid info FILE.ts [--json] [--set k=v,...] [--expect E.json] [--walk]`: the file's solid measured
//! (raea-core-solidinfo). FILE.ts exports `default`: a Solid, an object of named Solids (the parts), or a function
//! of the params returning either; and optionally `params`, each a number, a boolean, or `[low, high, default]`. The
//! file is run by `raea run` (a wrapper that prints each part's shape expression), then measured natively. --set
//! builds it at other params and says what moved from the defaults; --walk moves each ranged param alone to each end
//! and says which break it (more pieces, empty) and which reach no geometry. FILE.expect.json beside it is read when
//! --expect isn't given. Errors exit 1, as scene lint. A part's `role` comes from the file's `roles` export ({body:
//! "contain"}), its `at` from the line that names it. `raea solid view` takes its pictures (view.rs); `raea solid export`
//! writes it as a .glb for a Blender step (export.rs). Its `needs` export ({textured: true}) asks for what solids can't
//! give yet: real UVs and baked maps name bake.py (docs/blender.feature BL14).
use std::path::{Path, PathBuf};
use raea_runtime_bundle::flag;
use serde_json::{Map, Value, json};
mod export;
mod view;
pub const USAGE: &str = "raea solid info FILE.ts [--json] [--set k=v,...] [--expect E.json] [--walk] (volume, box, pieces, genus per part; joints; predictions and mutants)\n raea solid view FILE.ts -o DIR [--set k=v,...] [--json] (the solid's parts in colour and clay from fixed cameras)\n raea solid export FILE.ts -o OUT.glb [--set k=v,...] [--part NAME] [--colour #RRGGBB] (the solid as one .glb for a Blender step, read back and checked)";
thread_local! {
/// the last run file's `roles` and `needs` exports
static META: std::cell::RefCell<Value> = const { std::cell::RefCell::new(Value::Null) };
}
/// The file run with these params: (the params it used, its spec, each part's expression).
fn made(file: &Path, set: &Map<String, Value>) -> Result<(Value, Value, Vec<(String, String)>), String> {
let dir = std::env::temp_dir().join(format!("raea-solid-{}", std::process::id()));
std::fs::create_dir_all(&dir).map_err(|e| e.to_string())?;
let w = dir.join("info.ts");
let src = format!(
r#"import {{ print }} from "raea/native";
import * as m from {file:?};
const spec: Record<string, unknown> = (m as any).params ?? {{}};
const set: Record<string, unknown> = {set};
const p: Record<string, unknown> = {{}};
for (const [k, v] of Object.entries(spec)) p[k] = Array.isArray(v) ? v[2] : (v && typeof v === "object" && "default" in (v as any)) ? (v as any).default : v;
for (const [k, v] of Object.entries(set)) {{ if (!(k in spec)) throw new Error(`--set ${{k}}: the file's params are ${{Object.keys(spec).join(", ") || "none"}}`); p[k] = v; }}
const made = typeof (m as any).default === "function" ? (m as any).default(p) : (m as any).default;
if (!made) throw new Error("the file exports no default solid");
const parts = typeof made.expr === "string" ? {{ solid: made }} : made;
const exprs: Record<string, string> = {{}};
for (const [k, v] of Object.entries(parts)) {{ if (typeof (v as any)?.expr !== "string") throw new Error(`part ${{k}} is not a Solid`); exprs[k] = (v as any).expr; }}
print("RAEA_SOLID_INFO " + JSON.stringify({{ params: p, spec, parts: exprs, roles: (m as any).roles ?? {{}}, needs: (m as any).needs ?? {{}} }}));
"#,
file = file.display().to_string(),
set = Value::Object(set.clone()),
);
std::fs::write(&w, src).map_err(|e| e.to_string())?;
let exe = std::env::current_exe().map_err(|e| e.to_string())?;
let run = std::process::Command::new(exe).arg("run").arg(&w).current_dir(&dir).output().map_err(|e| e.to_string())?;
let _ = std::fs::remove_dir_all(&dir);
let out = String::from_utf8_lossy(&run.stdout).to_string();
let Some(line) = out.lines().find_map(|l| l.strip_prefix("RAEA_SOLID_INFO ")) else {
let err = format!("{}{out}", String::from_utf8_lossy(&run.stderr));
return Err(format!("solid info: {} didn't run: {}", file.display(), err.lines().rev().find(|l| !l.trim().is_empty()).unwrap_or("no output")));
};
let v: Value = serde_json::from_str(line).map_err(|e| e.to_string())?;
let parts: Vec<(String, String)> = serde_json::from_value::<std::collections::BTreeMap<String, String>>(v["parts"].clone()).unwrap_or_default().into_iter().collect();
META.with(|r| *r.borrow_mut() = json!({"roles": v["roles"], "needs": v["needs"]}));
Ok((v["params"].clone(), v["spec"].clone(), parts))
}
/// Textures asked of a solid: a solid's UVs are box projections, so real UVs and baked maps come from Blender (the
/// solid exported, then bake.py), and the gap is one to build into solids.
fn textured(out: &mut Value, file: &Path) {
let stem = file.file_stem().and_then(|s| s.to_str()).unwrap_or("solid");
let f = raea_core_meshcheck::blender::fix("bake.py", &format!("media/{stem}.glb media/{stem}-baked.glb --into-colour"));
let run = format!("raea solid export {} -o media/{stem}.glb --colour #RRGGBB && {}", file.display(), f["run"].as_str().unwrap_or(""));
let says = format!("its file asks for textures (needs.textured), and a solid's UVs are box projections: export it and bake real UVs and maps; fix: {run}");
if let Some(a) = out["found"].as_array_mut() {
a.push(json!({"check": "textures", "level": "warning", "says": says, "fix": {"blender": "bake.py", "run": run}}));
}
out["warnings"] = json!(out["warnings"].as_u64().unwrap_or(0) + 1);
}
fn parse_set(s: &str) -> Result<Map<String, Value>, String> {
let mut m = Map::new();
for kv in s.split(',').filter(|x| !x.trim().is_empty()) {
let (k, v) = kv.split_once('=').ok_or_else(|| format!("--set takes k=v,..., got {kv:?}"))?;
let v = v.trim();
let val = match v {
"true" => json!(true),
"false" => json!(false),
n => json!(n.parse::<f64>().map_err(|_| format!("--set {k}: a number, true or false, got {n:?}"))?),
};
m.insert(k.trim().to_string(), val);
}
Ok(m)
}
/// `raea solid ...` and `raea judge ...`, the scene loop's verbs (engine/cli hands them over), or None for another verb.
pub fn verb(args: &[String]) -> Option<Result<String, String>> {
match args.first().map(String::as_str) {
Some("solid") => Some(cli(args)),
Some("judge") => Some(raea_app_judge::cli(args)),
_ => None,
}
}
pub fn cli(args: &[String]) -> Result<String, String> {
let (Some(verb @ ("info" | "view" | "export")), Some(file)) = (args.get(1).map(String::as_str), args.get(2)) else { return Err(USAGE.into()) };
let file = PathBuf::from(file).canonicalize().map_err(|e| format!("{file}: {e}"))?;
let json_out = args.iter().any(|a| a == "--json");
let set = flag(args, "--set").map(|s| parse_set(&s)).transpose()?.unwrap_or_default();
let expect_path = flag(args, "--expect").map(PathBuf::from).or_else(|| {
let p = file.with_extension("expect.json");
p.is_file().then_some(p)
});
let expect: Option<Value> = expect_path.as_ref().map(|p| std::fs::read_to_string(p).map_err(|e| format!("{}: {e}", p.display())).and_then(|t| serde_json::from_str(&t).map_err(|e| format!("{}: {e}", p.display())))).transpose()?;
let (params, spec, parts) = made(&file, &set)?;
let mut out = raea_core_solidinfo::info(&parts, expect.as_ref())?;
out["file"] = json!(file.display().to_string());
let src = std::fs::read_to_string(&file).unwrap_or_default();
let meta = META.with(|r| r.borrow().clone());
for p in out["parts"].as_array_mut().into_iter().flatten() {
let name = p["part"].as_str().unwrap_or("").to_string();
if let Some(role) = meta["roles"][&name].as_str() {
p["role"] = json!(role);
}
if let Some(line) = crate::view::at(&src, &name) {
p["at"] = json!({"file": file.display().to_string(), "line": line});
}
}
if meta["needs"]["textured"] == true {
textured(&mut out, &file);
}
if verb == "export" {
return export::export(&file, &parts, &out, args);
}
if verb == "view" {
let dir = crate::view::out_dir(args).ok_or("raea solid view FILE.ts -o DIR: give the folder for the sheets")?;
return crate::view::view(&file, &set, &out, &dir, json_out);
}
out["params"] = params;
if let Some(p) = &expect_path {
out["expect"]["file"] = json!(p.display().to_string());
}
if !set.is_empty() {
out["set"] = Value::Object(set.clone());
let (_, _, base) = made(&file, &Map::new())?;
let was = raea_core_solidinfo::info(&base, None)?;
let from = set.iter().map(|(k, v)| format!("{k}={v}")).collect::<Vec<_>>().join(",");
out["delta"] = raea_core_solidinfo::delta(&from, &was["solid"], &out["solid"]);
}
if args.iter().any(|a| a == "--walk") {
let base = if set.is_empty() { out["solid"].clone() } else { raea_core_solidinfo::info(&made(&file, &Map::new())?.2, None)?["solid"].clone() };
let mut walk = Vec::new();
for (k, v) in spec.as_object().into_iter().flatten() {
let ends: Vec<Value> = match v {
Value::Array(a) if a.len() >= 2 => vec![a[0].clone(), a[1].clone()],
Value::Bool(b) => vec![json!(!b)],
_ => continue,
};
for end in ends {
let mut one = Map::new();
one.insert(k.clone(), end.clone());
let row = match made(&file, &one).and_then(|(_, _, p)| raea_core_solidinfo::info(&p, None)) {
Ok(r) => {
let (verdict, says) = raea_core_solidinfo::walk_verdict(&base, &r["solid"]);
json!({"param": k, "value": end, "verdict": verdict, "says": says, "volume": r["solid"]["volume"], "size": r["solid"]["box"]["size"]})
}
Err(e) => json!({"param": k, "value": end, "verdict": "broken", "says": e}),
};
if row["verdict"] == "broken" {
let says = format!("{k} = {end}: {}", row["says"].as_str().unwrap_or("broken"));
out["found"].as_array_mut().unwrap().push(json!({"check": "walk", "level": "warning", "says": says}));
out["warnings"] = json!(out["warnings"].as_u64().unwrap_or(0) + 1);
}
walk.push(row);
}
}
out["walk"] = json!(walk);
}
let errors = out["errors"].as_u64().unwrap_or(0);
let text = if json_out {
serde_json::to_string_pretty(&out).unwrap_or_default()
} else {
let s = &out["solid"];
let mut t: Vec<String> = out["found"].as_array().into_iter().flatten().filter(|f| !matches!(f["level"].as_str(), Some("ok"))).map(|f| format!("{:<8} {}{}", f["level"].as_str().unwrap_or(""), f["part"].as_str().map(|p| format!("{p}: ")).unwrap_or_default(), f["says"].as_str().unwrap_or(""))).collect();
for p in out["parts"].as_array().into_iter().flatten() {
t.push(format!("part {}: {} m³, size {}, {} pieces, genus {}", p["part"].as_str().unwrap_or(""), p["volume"], p["box"]["size"], p["pieces"], p["genus"]));
}
for w in out["walk"].as_array().into_iter().flatten() {
t.push(format!("walk {} = {}: {}{}", w["param"].as_str().unwrap_or(""), w["value"], w["verdict"].as_str().unwrap_or(""), w["says"].as_str().map(|s| format!(" ({s})")).unwrap_or_default()));
}
t.push(format!("solid: {} m³, size {} m, {} pieces, genus {}, {} triangles; {errors} errors, {} warnings", s["volume"], s["box"]["size"], s["pieces"], s["genus"], s["tris"], out["warnings"]));
t.join("\n")
};
if errors > 0 {
println!("{text}");
std::process::exit(1);
}
Ok(text)
}
+143
View File
@@ -0,0 +1,143 @@
//! `raea solid view FILE.ts -o DIR [--set k=v,...]`: one solid's review sheets (research note agent-tool-surface.md's
//! `solid view`). The file's parts are put in a small scene, each on its own clay-friendly colour, on a slab under
//! a key and fill light, with a hero camera from the front-right corner, and `raea render --review` takes the fixed
//! views of it in colour and clay. It prints a sidecar: the sheets, the solid's box, whether it is in more than one
//! piece, and solid info's findings, so one call gives the numbers and the pictures. The judge reads the sheets only.
use std::path::{Path, PathBuf};
use serde_json::{Map, Value, json};
const COLOURS: [&str; 8] = ["#c9b79c", "#8fa6b8", "#b48a78", "#9cb48a", "#b8a46a", "#a08cb4", "#7fb0a8", "#c4a0a0"];
/// The scene the sheets are taken of: the file's parts (built with `set` over its params), a slab under them, lights
/// and a camera from the box.
fn scene(file: &Path, set: &Map<String, Value>, lo: [f64; 3], hi: [f64; 3]) -> String {
let c = [(lo[0] + hi[0]) / 2.0, (lo[1] + hi[1]) / 2.0, (lo[2] + hi[2]) / 2.0];
let r = (((hi[0] - lo[0]).powi(2) + (hi[1] - lo[1]).powi(2) + (hi[2] - lo[2]).powi(2)).sqrt() / 2.0).max(0.02);
let d = r / (20f64.to_radians().sin()) * 1.1;
let k = 1.0 / 3f64.sqrt();
let eye = [c[0] + d * k, c[1] + d * k * 0.7, c[2] + d * k];
let slab = ((hi[0] - lo[0]).max(hi[2] - lo[2]) * 0.8).max(0.05);
let thick = (r * 0.02).max(0.002);
format!(
r##"import {{ AbsoluteFill, Composition, registerRoot }} from "raea";
import {{ Cuboid }} from "raea/3d";
import {{ StandardMaterial }} from "raea/pbr";
import {{ Mesh3d }} from "raea/mesh";
import {{ AmbientLight, DirectionalLight }} from "raea/light";
import {{ Transform }} from "raea/transform";
import {{ Camera3d }} from "raea/camera";
import * as m from {file:?};
const spec: Record<string, unknown> = (m as any).params ?? {{}};
const p: Record<string, unknown> = {{}};
for (const [k, v] of Object.entries(spec)) p[k] = Array.isArray(v) ? v[2] : (v && typeof v === "object" && "default" in (v as any)) ? (v as any).default : v;
Object.assign(p, {set});
let parts: Record<string, any> | null = null;
const get = () => {{
if (parts) return parts;
const made = typeof (m as any).default === "function" ? (m as any).default(p) : (m as any).default;
return (parts = typeof made?.expr === "string" ? {{ solid: made }} : made);
}};
const COLOURS = {colours:?};
function View() {{
return (
<AbsoluteFill style={{{{ background: "#1c1c1e" }}}}>
<Camera3d transform={{Transform.fromXyz({ex}, {ey}, {ez}).lookingAt([{cx}, {cy}, {cz}])}} projection={{{{ Perspective: {{ fov: (40 * Math.PI) / 180 }} }}}} />
<AmbientLight brightness={{250}} />
<DirectionalLight transform={{Transform.fromXyz({lx}, {ly}, {lz}).lookingAt([{cx}, {cy}, {cz}])}} illuminance={{9000}} shadow_maps_enabled />
<Mesh3d transform={{Transform.fromXyz({cx}, {sy}, {cz})}}><Cuboid half_size={{[{slab}, {thick}, {slab}]}} /><StandardMaterial base_color="#55565a" perceptual_roughness={{0.9}} /></Mesh3d>
{{Object.entries(get()).map(([k, s], i) => (
<Mesh3d key={{k}} shape={{s}}><StandardMaterial base_color={{COLOURS[i % COLOURS.length]}} perceptual_roughness={{0.6}} /></Mesh3d>
))}}
</AbsoluteFill>
);
}}
registerRoot(() => <Composition id="solid" component={{View}} width={{1280}} height={{960}} fps={{30}} durationInFrames={{1}} />);
"##,
// relative, as the scene sits beside it: an absolute import is bundled with its raea imports left external
file = format!("./{}", file.file_stem().and_then(|s| s.to_str()).unwrap_or("solid")),
set = Value::Object(set.clone()),
colours = COLOURS,
ex = eye[0],
ey = eye[1],
ez = eye[2],
cx = c[0],
cy = c[1],
cz = c[2],
lx = c[0] + d * 0.6,
ly = c[1] + d,
lz = c[2] + d * 0.8,
sy = lo[1] - thick,
slab = slab,
thick = thick,
)
}
/// The sheets made and the sidecar said, from the file's solid info (`info`, its JSON).
pub(crate) fn view(file: &Path, set: &Map<String, Value>, info: &Value, out: &Path, json_out: bool) -> Result<String, String> {
let b = &info["solid"]["box"];
let v3 = |k: &str| -> Result<[f64; 3], String> {
let a = b[k].as_array().filter(|a| a.len() == 3).ok_or("solid view: the solid is empty: nothing to look at")?;
Ok([a[0].as_f64().unwrap_or(0.0), a[1].as_f64().unwrap_or(0.0), a[2].as_f64().unwrap_or(0.0)])
};
let (lo, hi) = (v3("min")?, v3("max")?);
std::fs::create_dir_all(out).map_err(|e| format!("{}: {e}", out.display()))?;
// the scene sits beside the file, so its import resolves as the file's own do
let tsx = file.with_file_name(format!(".{}.view.tsx", file.file_stem().and_then(|s| s.to_str()).unwrap_or("solid")));
std::fs::write(&tsx, scene(file, set, lo, hi)).map_err(|e| format!("{}: {e}", tsx.display()))?;
let exe = std::env::current_exe().map_err(|e| e.to_string())?;
let run = std::process::Command::new(exe).arg("render").arg(&tsx).arg("--review").arg(out).current_dir(tsx.parent().unwrap_or(Path::new("."))).output().map_err(|e| e.to_string())?;
let said = format!("{}{}", String::from_utf8_lossy(&run.stdout), String::from_utf8_lossy(&run.stderr));
if !run.status.success() || !out.join("colour.png").is_file() {
// the scene is left for a look: what failed is in it or in the file
let why: Vec<&str> = said.lines().filter(|l| l.contains("Error") || l.contains("REFUSED") || l.contains("error")).take(3).collect();
return Err(format!("solid view: the review render of {} failed: {}", tsx.display(), if why.is_empty() { said.lines().rev().find(|l| !l.trim().is_empty()).unwrap_or("no output").to_string() } else { why.join(" | ") }));
}
let _ = std::fs::remove_file(&tsx);
let review: Value = serde_json::from_str(&std::fs::read_to_string(out.join("review.json")).unwrap_or_default()).unwrap_or(Value::Null);
let found: Vec<Value> = info["found"].as_array().into_iter().flatten().filter(|f| f["level"] != "ok").cloned().chain(review["found"].as_array().into_iter().flatten().cloned()).collect();
let side = json!({
"file": file.display().to_string(), "set": set, "sheets": {"colour": out.join("colour.png"), "clay": out.join("clay.png")},
"box": info["solid"]["box"], "disjoint": info["solid"]["pieces"].as_u64().unwrap_or(0) > 1,
"parts": info["parts"].as_array().into_iter().flatten().enumerate().map(|(i, p)| json!({"part": p["part"], "colour": COLOURS[i % COLOURS.len()]})).collect::<Vec<_>>(),
"tiles": review["tiles"], "errors": info["errors"], "found": found,
"caption": format!("{} Each part in its own colour on the colour sheet (parts[].colour).", review["caption"].as_str().unwrap_or("")),
});
std::fs::write(out.join("view.json"), serde_json::to_string_pretty(&side).unwrap_or_default()).map_err(|e| e.to_string())?;
if json_out {
return Ok(serde_json::to_string_pretty(&side).unwrap_or_default());
}
let mut t = vec![format!("APPLIED {} and {} (hero, front, right, top, iso, low), the sidecar in {}", out.join("colour.png").display(), out.join("clay.png").display(), out.join("view.json").display())];
t.push(format!("parts: {}", side["parts"].as_array().into_iter().flatten().map(|p| format!("{} {}", p["part"].as_str().unwrap_or(""), p["colour"].as_str().unwrap_or(""))).collect::<Vec<_>>().join(", ")));
for f in &found {
t.push(format!(" {}: {}", f["level"].as_str().unwrap_or(""), f["says"].as_str().unwrap_or("")));
}
Ok(t.join("\n"))
}
/// Where a part is named in the file: the first line that gives it as a key or a binding (`body:`, `const body =`).
pub(crate) fn at(src: &str, part: &str) -> Option<usize> {
let word = |l: &str, i: usize| i == 0 || !l[..i].ends_with(|c: char| c.is_alphanumeric() || c == '_');
src.lines().position(|l| {
l.match_indices(part).any(|(i, _)| {
let rest = l[i + part.len()..].trim_start();
word(l, i) && (rest.starts_with(':') || (rest.starts_with('=') && !rest.starts_with("==")) || rest.starts_with(','))
})
}).map(|n| n + 1)
}
pub(crate) fn out_dir(args: &[String]) -> Option<PathBuf> {
args.iter().position(|a| a == "-o").and_then(|i| args.get(i + 1)).map(PathBuf::from)
}
#[cfg(test)]
mod tests {
#[test]
fn a_part_is_found_where_it_is_named() {
let src = "import x from 'y';\nconst body = a();\nreturn { body, handle: h, handlebar: 2 };\n";
assert_eq!(super::at(src, "body"), Some(2));
assert_eq!(super::at(src, "handle"), Some(3));
assert_eq!(super::at(src, "spout"), None);
}
}
+1 -1
View File
@@ -71,7 +71,7 @@ pub fn host(args: &[String]) -> Result<String, String> {
// the app's folder (relative media and fonts) and the CSS it imported (its @font-face rules), T3d
let sheet = script.with_extension("css");
std::fs::write(&sheet, css).map_err(|e| format!("{}: {e}", sheet.display()))?;
let dir = p.canonicalize().ok().and_then(|c| c.parent().map(Path::to_path_buf)).unwrap_or_default();
let dir = p.canonicalize().ok().map(raea_io_home::plain).and_then(|c| c.parent().map(Path::to_path_buf)).unwrap_or_default();
extra.extend(["--base".to_string(), dir.display().to_string(), "--css".to_string(), sheet.display().to_string()]);
} else {
handed.push(a.clone());
+1 -1
View File
@@ -22,7 +22,7 @@ pub struct Built {
/// `app` bundled into `dir` (made if missing): app.js and app.css (Tailwind's, for the classes the app's folder uses, after
/// any CSS the app imports)
pub fn build(app: &Path, dir: &Path) -> Result<Built, String> {
let app = app.canonicalize().map_err(|e| format!("{}: {e}", app.display()))?;
let app = raea_io_home::plain(app.canonicalize().map_err(|e| format!("{}: {e}", app.display()))?);
std::fs::create_dir_all(dir).map_err(|e| format!("{}: {e}", dir.display()))?;
let (js, imported) = raea_runtime_bundle::inproc::app::bundle(&app, &raea_io_home::home())?;
let folder = app.parent().unwrap_or(Path::new("."));
-4
View File
@@ -6,10 +6,6 @@ license = "FSL-1.1-ALv2"
publish = false
description = "The `raea` verbs that run raea's model tools: sao, tokensynth, setup-audio, sounds, splat, song and gen"
[features]
# a made sound signed as generated (raea's own API; the public engine goes without)
service = []
[dependencies]
raea-io-assets = { path = "../../io/assets" }
# generation flows: made.app, fal, Replicate, OpenRouter, Modal, ComfyUI (`raea gen`)
+21 -1
View File
@@ -7,7 +7,7 @@ use std::process::Command;
type R<T> = Result<T, String>;
pub const USAGE: &str = "raea setup blender [--check] [--download] (find Blender or download the LTS into ~/.raea/tools/blender, and install its MCP add-on)\n raea blender run SCRIPT.py [ARGS...] (blender --background --python SCRIPT.py -- ARGS, headless)";
pub const USAGE: &str = "raea setup blender [--check] [--download] (find Blender or download the LTS into ~/.raea/tools/blender, and install its MCP add-on)\n raea blender run SCRIPT.py [ARGS...] (blender --background --python SCRIPT.py -- ARGS, headless; blender/X.py missing from the project is copied from the library: convert, decimate, repair, split, bake, rig, cloth)";
/// The LTS series raea downloads; the newest patch in blender.org/release/Blender<LTS>/ is taken. Moved when Blender
/// ships a new LTS (blender.org/download/lts).
@@ -189,6 +189,25 @@ pub fn setup(args: &[String]) -> R<String> {
Ok(format!("{head} {v} ({from})\n {}\n {add}\n headless: raea blender run SCRIPT.py; live: start Blender and the agent's `blender` MCP server connects (raea skills install adds it)", bin.display()))
}
/// The library's scripts (sdk/guides/craft/bevy/blender: convert, decimate, repair, split, bake, rig, cloth): a fix
/// names `blender/X.py`, and the first run copies the library's X.py into the project's blender/ folder, where it is
/// kept with the project and edited for it (docs/blender.feature, Background). A script already there is never replaced.
fn library(script: &str) -> R<()> {
let p = Path::new(script);
let (Some(name), Some(dir)) = (p.file_name(), p.parent()) else { return Ok(()) };
if p.exists() || dir.file_name().is_none_or(|d| d != "blender") {
return Ok(());
}
let from = raea_io_home::home().join("sdk/guides/craft/bevy/blender").join(name);
if !from.is_file() {
return Ok(());
}
std::fs::create_dir_all(dir).map_err(|e| format!("{}: {e}", dir.display()))?;
std::fs::copy(&from, p).map_err(|e| format!("{}: {e}", p.display()))?;
eprintln!("copied the library's {} into {} (it is the project's now: edit it there)", name.to_string_lossy(), dir.display());
Ok(())
}
/// `raea blender run SCRIPT.py [ARGS...]`: the script in a windowless Blender, its args after `--` (sys.argv), its
/// output passed through. Exits as Blender's Python did: --python-exit-code makes an uncaught error fail the run.
pub fn blender(args: &[String]) -> R<String> {
@@ -196,6 +215,7 @@ pub fn blender(args: &[String]) -> R<String> {
return Err(format!("usage: {USAGE}"));
}
let script = args.get(2).ok_or_else(|| format!("which script: {USAGE}"))?;
library(script)?;
if !Path::new(script).is_file() {
return Err(format!("no script {script}"));
}
+2
View File
@@ -121,6 +121,8 @@ fn deliver(from: &Path, to: &Path) -> R<()> {
std::fs::create_dir_all(d).map_err(|e| format!("{}: {e}", d.display()))?;
}
std::fs::copy(from, to).map_err(|e| format!("{}: {e}", to.display()))?;
// signed as generated, when this program signs (raea_io_media::sign)
raea_io_media::sign::sign_file(to, raea_io_media::sign::Made::Generated);
Ok(())
}
+1 -1
View File
@@ -10,7 +10,7 @@ description = "Bevy's own examples, built against raea's Bevy with the parity pr
# the feature list engine/render's bevy has (its bevy-all: dfg_lut and bluenoise_texture too, which stock Bevy's defaults
# leave out; without the DFG table rough surfaces at grazing angles take less ambient, many_cubes' box srgb 64 for 88), so the
# examples build against the Bevy raea already compiled, and winit: the examples open a window (raea's renders don't), and bevy_scene: Bevy 0.20's examples write their scenes in BSN
bevy = { version = "=0.20.0", default-features = false, features = ["std", "default_app", "default_font", "multi_threaded", "3d_bevy_render", "ui_bevy_render", "png", "jpeg", "tonemapping_luts", "ktx2", "zstd_rust", "smaa_luts", "experimental_pbr_pcss", "area_light_luts", "dfg_lut", "bluenoise_texture", "bevy_gilrs", "bevy_winit", "bevy_scene"] }
bevy = { version = "=0.20.0", default-features = false, features = ["std", "default_app", "default_font", "multi_threaded", "3d_bevy_render", "ui_bevy_render", "png", "jpeg", "tonemapping_luts", "ktx2", "zstd_rust", "smaa_luts", "experimental_pbr_pcss", "area_light_luts", "dfg_lut", "bluenoise_texture", "bevy_gilrs", "bevy_winit", "bevy_scene", "bevy_camera_controller", "free_camera", "pan_camera", "pan_orbit_camera", "bevy_gizmos", "bevy_gizmos_render", "bevy_state", "picking", "mesh_picking", "sprite_picking", "ui_picking", "hdr", "exr", "webp", "bevy_dev_tools", "bevy_ui_widgets", "bevy_feathers", "bevy_audio", "vorbis", "wav", "mp3", "morph_animation", "bevy_input_focus", "custom_cursor", "serialize", "reflect_functions", "pbr_multi_layer_material_textures"] }
raea-sys-parity = { path = "../../systems/parity" }
# Bevy's examples' own dependencies (bevy v0.20.0's dev-dependencies)
argh = "0.1.12"
+52
View File
@@ -4,3 +4,55 @@ stress_tests/many_cubes
3d/3d_scene
stress_tests/many_lights
stress_tests/many_foxes
animation/animated_mesh
shader/extended_material
3d/orthographic
3d/parenting
2d/mesh2d
2d/sprite
transforms/3d_rotation
2d/sprite_flipping
2d/move_sprite
2d/transparency_2d
transforms/translation
transforms/scale
3d/texture
shader/animate_shader
2d/sprite_sheet
3d/pbr
3d/animated_material
camera/pan_camera_controller
camera/camera_orbit
camera/projection_zoom
2d/sprite_animation
2d/sprite_tile
3d/vertex_colors
3d/spherical_area_lights
3d/fog_volumes
3d/bloom_3d
transforms/transform
3d/transparency_3d
animation/eased_motion
animation/color_animation
3d/rect_light
3d/shadow_caster_receiver
3d/spotlight
transforms/align
3d/3d_viewport_to_world
3d/atmospheric_fog
2d/rotate_to_cursor
movement/smooth_follow
3d/mesh_ray_cast
3d/rotate_environment_map
2d/mesh2d_alpha_mode
2d/mesh2d_vertex_color_texture
3d/lightmaps
ui/styling/transparency_ui
ui/layout/fixed_node
ui/images/image_node
ui/text/font_weights
ui/text/font_variations
ui/text/text_background_colors
ui/text/strikethrough_and_underline
ui/scroll_and_overflow/overflow
ui/images/ui_texture_atlas
+21
View File
@@ -0,0 +1,21 @@
// lib/rand.ts against chacha20 0.10.2 and rand 0.10.3's own output (a scratch crate printing ChaCha8Rng::seed_from_u64(
// 19878367467713), spotlight.rs's seed: its first words, the words after the first refill of its 64-word buffer, and
// random_range(-5.0..5.0) as f32 bits).
import { expect, test } from "bun:test";
import { ChaCha8Rng } from "./rand";
const bits = (x: number) => new Uint32Array(new Float32Array([x]).buffer)[0]!.toString(16).padStart(8, "0");
test("ChaCha8Rng's words and random_range are the crates' own", () => {
const r = ChaCha8Rng.seed_from_u64(19878367467713n);
const w = Array.from({ length: 70 }, () => r.next_u32());
expect(w.slice(0, 4)).toEqual([2045446710, 148267730, 2984187155, 4078822190]);
expect(w.slice(64, 70)).toEqual([3322331382, 1283986520, 4195170605, 2259972292, 328924921, 2056473586]);
const g = ChaCha8Rng.seed_from_u64(19878367467713n);
expect(Array.from({ length: 6 }, () => bits(g.random_range(-5, 5)))).toEqual(["be734680", "c094f406", "3ff95b64", "408fe55a", "c0396a22", "bf7365c0"]);
});
test("random_dir3 is bevy_math's random::<Dir3>() (align.rs's seed)", () => {
const r = ChaCha8Rng.seed_from_u64(19878367467712n);
expect([r.random_dir3().map(bits), r.random_dir3().map(bits)]).toEqual([["be848688", "3e9c2559", "3f6aa088"], ["bf2dc30a", "beef6b4a", "bf10f4e8"]]);
});
+76
View File
@@ -0,0 +1,76 @@
// The random numbers Bevy's examples draw (30 of them seed a ChaCha8Rng): chacha20 0.10's ChaCha8Rng, seeded by
// rand_core 0.10's seed_from_u64 (PCG32 filling the 32-byte key), and rand 0.10's random_range over an f32 range (23
// random bits as a float in [1, 2), less 1, times the span, plus the low end, in f32). Checked against the crates'
// own output (bench/bevy-parity/lib/rand.test.ts).
const M64 = (1n << 64n) - 1n;
/** rand_core's seed_from_u64: eight PCG32 outputs, the key's words */
function seedWords(seed: bigint): number[] {
let state = seed & M64;
const words: number[] = [];
for (let i = 0; i < 8; i++) {
state = (state * 0x5851f42d4c957f2dn + 0xa17654e46fbe17f3n) & M64;
const xorshifted = Number((((state >> 18n) ^ state) >> 27n) & 0xffffffffn);
const rot = Number(state >> 59n);
words.push(((xorshifted >>> rot) | (xorshifted << ((32 - rot) & 31))) >>> 0);
}
return words;
}
const rotl = (x: number, n: number) => ((x << n) | (x >>> (32 - n))) >>> 0;
/** chacha20's ChaCha8Rng: the key from the seed, a 64-bit block counter, stream 0, four blocks buffered at a time */
export class ChaCha8Rng {
private state: number[];
private buf: number[] = [];
private at = 64;
private constructor(key: number[]) {
this.state = [0x61707865, 0x3320646e, 0x79622d32, 0x6b206574, ...key, 0, 0, 0, 0];
}
static seed_from_u64(seed: number | bigint): ChaCha8Rng {
return new ChaCha8Rng(seedWords(BigInt(seed)));
}
private block(): number[] {
const x = this.state.slice();
const qr = (a: number, b: number, c: number, d: number) => {
x[a] = (x[a]! + x[b]!) >>> 0; x[d] = rotl(x[d]! ^ x[a]!, 16);
x[c] = (x[c]! + x[d]!) >>> 0; x[b] = rotl(x[b]! ^ x[c]!, 12);
x[a] = (x[a]! + x[b]!) >>> 0; x[d] = rotl(x[d]! ^ x[a]!, 8);
x[c] = (x[c]! + x[d]!) >>> 0; x[b] = rotl(x[b]! ^ x[c]!, 7);
};
for (let i = 0; i < 4; i++) {
qr(0, 4, 8, 12); qr(1, 5, 9, 13); qr(2, 6, 10, 14); qr(3, 7, 11, 15);
qr(0, 5, 10, 15); qr(1, 6, 11, 12); qr(2, 7, 8, 13); qr(3, 4, 9, 14);
}
const out = x.map((v, i) => (v + this.state[i]!) >>> 0);
// the 64-bit block counter, words 12 and 13
this.state[12] = (this.state[12]! + 1) >>> 0;
if (this.state[12] === 0) this.state[13] = (this.state[13]! + 1) >>> 0;
return out;
}
next_u32(): number {
if (this.at >= 64) {
this.buf = [...this.block(), ...this.block(), ...this.block(), ...this.block()];
this.at = 0;
}
return this.buf[this.at++]!;
}
/** rand's random_range(low..high) for f32 */
random_range(low: number, high: number): number {
const f = Math.fround;
const bits = (this.next_u32() >>> 9) | 0x3f800000;
const v = new Float32Array(new Uint32Array([bits]).buffer)[0]!;
return f(f(f(v - 1) * f(high - low)) + low);
}
/** bevy_math's random::<Dir3>() (sample_unit_sphere_boundary): z in [-1, 1], an angle in [-PI, PI] (rand's inclusive
* range is the same draw as the half-open one) */
random_dir3(): [number, number, number] {
const f = Math.fround;
const pi = f(Math.PI);
const z = this.random_range(-1, 1);
const a = this.random_range(-pi, pi);
const c = f(Math.sqrt(f(1 - f(z * z))));
return [f(f(Math.sin(a)) * c), f(f(Math.cos(a)) * c), z];
}
}
@@ -0,0 +1,19 @@
// lib/smooth_follow.ts against bevy_math 0.20's own run of smooth_follow.rs's systems (a scratch crate on bevy_math,
// rand 0.10.3 and chacha20 0.10.2): target, follower and the point it heads for, as f32 bits, at the frames probed.
import { expect, test } from "bun:test";
import { smoothFollow } from "./smooth_follow";
const bits = (x: number) => new Uint32Array(new Float32Array([x]).buffer)[0]!.toString(16).padStart(8, "0");
const TRUTH: Record<number, string> = {
1: "3d52f770 bd155d9a bd5eea76 3add526d bff7c2a6 bae9db9a 3fe0971c bf9f02e4 bfed4fac",
10: "3f03daa6 bebab4ff bf0b5289 3dacaa0c bfbf128a bdb671af 3fe0971c bf9f02e4 bfed4fac",
30: "3fc5c7fb bf8c07c1 bfd0fbd0 3f15a9de bf93288f bf1e23fe 3fe0971c bf9f02e4 bfed4fac",
60: "3e238854 be540699 bf9deedd 3f4e07ea bf5eefa2 bf98e54a bfda49d4 3f807360 bf0237b0",
90: "bfda49d4 3f807360 bf0237b0 beb3c37b 3d0ca65c bf6db132 bff66ebc 3fe101ec bf700c38",
120: "bf55f53e 3f3ed6e3 bf90ffa1 bf86169e 3f4f3053 bf74ccb4 be807650 3e4ed200 bf9e67e8",
180: "be967d1e 3f35c1b6 bc528d20 be611fd8 3f01e743 3d52d8c0 bfa6ca70 3f520018 bfc64714",
};
test("smoothFollow is bevy_math's run, bit for bit", () => {
for (const [frame, want] of Object.entries(TRUTH)) expect(`${frame} ${smoothFollow(Number(frame)).flat().map(bits).join(" ")}`).toBe(`${frame} ${want}`);
});
+37
View File
@@ -0,0 +1,37 @@
// examples/movement/smooth_follow.rs's two systems in f32, on the harness's clock (an update a frame, none of it on the
// first): move_target walks the blue sphere at 5 m/s to a point Cuboid(4 m).sample_interior draws from the example's
// ChaCha8Rng (seed 68941654987813521), drawing the next once it's there (Dir3::new fails on a zero vector), and
// move_follower smooth_nudges the red one towards it at decay rate 2 (bevy_math's VectorSpace::lerp, self * (1 - t) +
// rhs * t). Checked against bevy_math's own run (lib/smooth_follow.test.ts).
import { ChaCha8Rng } from "./rand";
export type V3 = [number, number, number];
const f = Math.fround;
const sub = (a: V3, b: V3): V3 => [f(a[0] - b[0]), f(a[1] - b[1]), f(a[2] - b[2])];
/** glam's Vec3::length: sqrt of the dot, summed x, y, z in order */
const length = (v: V3) => f(Math.sqrt(f(f(f(v[0] * v[0]) + f(v[1] * v[1])) + f(v[2] * v[2]))));
/** the spheres after the updates up to frame `frame`: [target, follower, the point it's heading for] */
export function smoothFollow(frame: number): [V3, V3, V3] {
const rng = ChaCha8Rng.seed_from_u64(68941654987813521n);
const dtFull = f(16_666_667e-9);
let target: V3 = [0, 0, 0];
let pos: V3 = [0, 0, 0];
let follow: V3 = [0, -2, 0];
for (let k = 0; k <= frame; k++) {
const dt = k === 0 ? 0 : dtFull;
const d = sub(pos, target);
const len = length(d);
if (Number.isFinite(len) && len > 0) {
const dir: V3 = [f(d[0] / len), f(d[1] / len), f(d[2] / len)];
const m = Math.min(len, f(dt * 5));
target = [f(target[0] + f(dir[0] * m)), f(target[1] + f(dir[1] * m)), f(target[2] + f(dir[2] * m))];
} else {
pos = [rng.random_range(-2, 2), rng.random_range(-2, 2), rng.random_range(-2, 2)];
}
const t = f(1 - f(Math.exp(f(-2 * dt))));
const keep = f(1 - t);
follow = [0, 1, 2].map((i) => f(f(follow[i]! * keep) + f(target[i]! * t))) as V3;
}
return [target, follow, pos];
}
+52
View File
@@ -3,3 +3,55 @@ stress_tests/many_cubes --benchmark --instance-count 10000 30,60
3d/3d_scene - 5,10
stress_tests/many_lights - 30,60
stress_tests/many_foxes --sync 30,60
animation/animated_mesh - 30,60
shader/extended_material - 30,60
3d/orthographic - 10
3d/parenting - 30,60
2d/mesh2d - 10
2d/sprite - 10
transforms/3d_rotation - 30,60
2d/sprite_flipping - 10
2d/move_sprite - 30,120
2d/transparency_2d - 10
transforms/translation - 60,180
transforms/scale - 60,300
3d/texture - 10
shader/animate_shader - 30,60
2d/sprite_sheet - 30,60
3d/pbr - 30,60
3d/animated_material - 30,60
camera/pan_camera_controller - 10
camera/camera_orbit - 10
camera/projection_zoom - 30
2d/sprite_animation - 12,30,60
2d/sprite_tile - 30,300
3d/vertex_colors - 10
3d/spherical_area_lights - 10
3d/fog_volumes - 10,60
3d/bloom_3d - 10,60
transforms/transform - 10,120
3d/transparency_3d - 10,90
animation/eased_motion - 60,150,240
animation/color_animation - 30,120,200
3d/rect_light - 10
3d/shadow_caster_receiver - 10
3d/spotlight - 10,90
transforms/align - 10,30
3d/3d_viewport_to_world - 5,10
3d/atmospheric_fog - 5,10
2d/rotate_to_cursor - 5,10
movement/smooth_follow - 30,120
3d/mesh_ray_cast - 300,900
# 3d/rotate_environment_map - 5,60 (out until raea renders its clearcoat normal map by default: raea-sys-material's multi-layer feature, off as Bevy's three clearcoat samplers pass Metal's 16 for <Material> and froxel glass; with it on, it passes at 0.9993)
2d/mesh2d_alpha_mode - 5,10
3d/lightmaps - 5,10
ui/styling/transparency_ui - 5,10
ui/layout/fixed_node - 5,10
ui/images/image_node - 5,10
ui/text/font_weights - 5,10
ui/text/font_variations - 5,10
ui/text/text_background_colors - 5,10
ui/text/strikethrough_and_underline - 5,10
ui/scroll_and_overflow/overflow - 5,10
ui/images/ui_texture_atlas - 5,10
2d/mesh2d_vertex_color_texture - 10
1 # path example arguments (- for none) frames probed (docs/control.feature FC0a; tools/bevy-parity)
3 3d/3d_scene - 5,10
4 stress_tests/many_lights - 30,60
5 stress_tests/many_foxes --sync 30,60
6 animation/animated_mesh - 30,60
7 shader/extended_material - 30,60
8 3d/orthographic - 10
9 3d/parenting - 30,60
10 2d/mesh2d - 10
11 2d/sprite - 10
12 transforms/3d_rotation - 30,60
13 2d/sprite_flipping - 10
14 2d/move_sprite - 30,120
15 2d/transparency_2d - 10
16 transforms/translation - 60,180
17 transforms/scale - 60,300
18 3d/texture - 10
19 shader/animate_shader - 30,60
20 2d/sprite_sheet - 30,60
21 3d/pbr - 30,60
22 3d/animated_material - 30,60
23 camera/pan_camera_controller - 10
24 camera/camera_orbit - 10
25 camera/projection_zoom - 30
26 2d/sprite_animation - 12,30,60
27 2d/sprite_tile - 30,300
28 3d/vertex_colors - 10
29 3d/spherical_area_lights - 10
30 3d/fog_volumes - 10,60
31 3d/bloom_3d - 10,60
32 transforms/transform - 10,120
33 3d/transparency_3d - 10,90
34 animation/eased_motion - 60,150,240
35 animation/color_animation - 30,120,200
36 3d/rect_light - 10
37 3d/shadow_caster_receiver - 10
38 3d/spotlight - 10,90
39 transforms/align - 10,30
40 3d/3d_viewport_to_world - 5,10
41 3d/atmospheric_fog - 5,10
42 2d/rotate_to_cursor - 5,10
43 movement/smooth_follow - 30,120
44 3d/mesh_ray_cast - 300,900
45 # 3d/rotate_environment_map - 5,60 (out until raea renders its clearcoat normal map by default: raea-sys-material's multi-layer feature, off as Bevy's three clearcoat samplers pass Metal's 16 for <Material> and froxel glass; with it on, it passes at 0.9993)
46 2d/mesh2d_alpha_mode - 5,10
47 3d/lightmaps - 5,10
48 ui/styling/transparency_ui - 5,10
49 ui/layout/fixed_node - 5,10
50 ui/images/image_node - 5,10
51 ui/text/font_weights - 5,10
52 ui/text/font_variations - 5,10
53 ui/text/text_background_colors - 5,10
54 ui/text/strikethrough_and_underline - 5,10
55 ui/scroll_and_overflow/overflow - 5,10
56 ui/images/ui_texture_atlas - 5,10
57 2d/mesh2d_vertex_color_texture - 10
+1 -1
View File
@@ -2,7 +2,7 @@
//! any headless Bevy program sets them, then raea in one RaeaPlugin: raea's plugins (RaeaPlugins, Scene3dPlugin), React
//! (ReactPlugin, running the bundle in this App's World), ScenePlugin, which turns React's <Canvas3D> tree into the
//! scene's rows, and raea-page's PagePlugin and WorldPagePlugin, which draw its HTML layer on Blitz over the scene's
//! camera. No Engine and no second App: the App is the founder's own. --scene-only leaves the page out (the 3D alone). The
//! camera. No Engine and no second App: the App is the user's own. --scene-only leaves the page out (the 3D alone). The
//! frame is saved as a PNG, to compare with raea's own render on the Blitz page (RAEA_PAGE=blitz).
//!
//! --window draws into a window in place of an image (S6a's window target): a winit window made here, never shown and
+19
View File
@@ -0,0 +1,19 @@
#!/bin/sh
# Every lightspeed harness in turn (docs/lightspeed.feature), each timing step in its own turn at the shared lock on a
# quiet machine (bench/lightspeed/lib.sh), then the scoreboard. The iPhone rows need the phone unlocked; they're
# skipped with a note when it isn't.
# bench/lightspeed/all.sh [quick] quick: 30 s game runs and 2 repeats instead of 60 s and 3
# Build first: raea (sdk/react/) and void (apps/legacy/shell/), release.
cd "$(dirname "$0")"
secs=60; runs=3
[ "${1:-}" = quick ] && { secs=30; runs=2; }
status=0
bash startup.sh --runs $((runs + 2)) || status=1
bash feel.sh --seconds $secs || status=1
bash jsheap.sh pong pong-stepfold pong-view --seconds 12 --runs $runs || status=1
bash export.sh --runs $runs || status=1
bash quality.sh || status=1
bash gpumem.sh || status=1
bash energy.sh --seconds 30 || status=1
bash ../scoreboard.sh
exit $status
+87
View File
@@ -0,0 +1,87 @@
// The ANIMATE fixture's twin, written the way agents write today: interpolate and spring per frame, the same timings.
import { AbsoluteFill, Composition, Easing, Sequence, interpolate, registerRoot, spring, useCurrentFrame, useVideoConfig } from "raea";
const INK = "#14121f", PAPER = "#fbf7ef", ACCENT = "#ff5a7a";
const OUT = Easing.out(Easing.cubic), IN = Easing.in(Easing.cubic);
const c = { extrapolateLeft: "clamp", extrapolateRight: "clamp" } as const;
const GROUPS: { from: number; words: [string, number, number][] }[] = [
{ from: 0, words: [["Your", 0, 8], ["afternoon", 8, 22], ["slump", 22, 40]] },
{ from: 44, words: [["has", 0, 6], ["a", 6, 10], ["new", 10, 20]] },
{ from: 70, words: [["enemy.", 0, 30]] },
{ from: 110, words: [["Steeped", 0, 14], ["twenty", 14, 26], ["hours,", 26, 46]] },
{ from: 160, words: [["smooth,", 0, 18], ["never", 18, 28], ["bitter.", 28, 52]] },
{ from: 220, words: [["Twelve", 0, 12], ["grams", 12, 22], ["protein,", 22, 44]] },
{ from: 270, words: [["zero", 0, 12], ["added", 12, 22], ["sugar.", 22, 48]] },
{ from: 330, words: [["Crack", 0, 12], ["one", 12, 18], ["open.", 18, 44]] },
{ from: 390, words: [["Finish", 0, 14], ["the", 14, 18], ["list.", 18, 46]] },
{ from: 450, words: [["First", 0, 12], ["case", 12, 22], ["half", 22, 30]] },
{ from: 486, words: [["off.", 0, 40]] },
];
function Caption({ words, length }: { words: [string, number, number][]; length: number }) {
const f = useCurrentFrame();
const s = interpolate(f, [0, 4, 8], [0.92, 1.03, 1], { ...c, easing: OUT });
const o = Math.min(interpolate(f, [0, 3], [0, 1], { ...c, easing: OUT }), interpolate(f, [length - 6, length], [1, 0], { ...c, easing: IN }));
return (
<AbsoluteFill style={{ justifyContent: "flex-end", alignItems: "center", paddingBottom: 220 }}>
<div style={{ display: "flex", opacity: o, transform: `scale(${s})`, backgroundColor: PAPER, borderRadius: 32, padding: "18px 28px", fontFamily: "Helvetica", fontWeight: 900, fontSize: 64, color: INK }}>
{words.map(([w, a, b], i) => {
const k = interpolate(f, [a, a + 3, b, b + 3], [0, 1, 1, 0], { ...c, easing: OUT });
return <span key={i} style={{ padding: "2px 12px", margin: "0 2px", borderRadius: 999, backgroundColor: `rgba(255, 90, 122, ${k})` }}>{w}</span>;
})}
</div>
</AbsoluteFill>
);
}
const chip = { display: "inline-flex", alignItems: "center", gap: 14, backgroundColor: INK, color: PAPER, borderRadius: 999, padding: "12px 30px 12px 14px", fontFamily: "Helvetica", fontWeight: 900, fontSize: 48, marginBottom: 14 } as const;
const num = { minWidth: 120, textAlign: "center", backgroundColor: ACCENT, color: INK, borderRadius: 999, padding: "4px 18px" } as const;
function Badge({ i, children }: { i: number; children: React.ReactNode }) {
const f = useCurrentFrame();
const at = 110 + i * 24, ex = 430 + i * 2;
const x = interpolate(f, [at, at + 8], [-64, 0], { ...c, easing: OUT }) + interpolate(f, [ex, ex + 8], [0, -64], { ...c, easing: IN });
const o = Math.min(interpolate(f, [at, at + 5], [0, 1], { ...c, easing: OUT }), interpolate(f, [ex + 3, ex + 8], [1, 0], { ...c, easing: IN }));
return <div style={{ opacity: o, transform: `translateX(${x}px)` }}>{children}</div>;
}
function Badges() {
const f = useCurrentFrame();
const n = Math.round(interpolate(f, [124, 154], [0, 20], { ...c, easing: OUT }));
return (
<div style={{ position: "absolute", left: 56, top: 120, display: "flex", flexDirection: "column", alignItems: "flex-start" }}>
<Badge i={0}><div style={chip}><span style={num}>{n}</span> HRS STEEPED</div></Badge>
<Badge i={1}><div style={chip}><span style={num}>12</span> G PROTEIN</div></Badge>
<Badge i={2}><div style={chip}><span style={num}>0</span> G SUGAR</div></Badge>
</div>
);
}
function Card() {
const f = useCurrentFrame();
const { fps } = useVideoConfig();
const y = interpolate(f, [0, 10], [80, 0], { ...c, easing: OUT });
const s = spring({ frame: f, fps, from: 0.86, to: 1, durationInFrames: 18, config: { damping: 15, stiffness: 120 } });
const t = interpolate(f, [18, 22, 26], [0.6, 1.08, 1], { ...c, easing: OUT });
const fillW = interpolate(f, [20, 50], [0, 100], { ...c, easing: OUT });
const wipe = interpolate(f, [18, 30], [100, 0], { ...c, easing: Easing.inOut(Easing.cubic) });
const cta = interpolate(f, [24, 30], [0, 1], { ...c, easing: OUT });
return (
<AbsoluteFill style={{ alignItems: "center", justifyContent: "center", paddingBottom: 200 }}>
<div style={{ opacity: interpolate(f, [0, 5], [0, 1], { ...c, easing: OUT }), transform: `translateY(${y}px) scale(${s})`, width: 860, backgroundColor: PAPER, borderRadius: 44, padding: 52, display: "flex", flexDirection: "column", gap: 26 }}>
<div style={{ opacity: interpolate(f, [18, 21], [0, 1], c), transform: `scale(${t})`, fontFamily: "Helvetica", fontWeight: 900, fontSize: 96, color: INK, lineHeight: 1 }}>First case half off</div>
<div style={{ height: 26, borderRadius: 13, backgroundColor: "#e9e2d6", overflow: "hidden" }}><div style={{ width: `${fillW}%`, height: 26, borderRadius: 13, backgroundColor: ACCENT }} /></div>
<div style={{ height: 8, backgroundColor: INK, clipPath: `inset(0% ${wipe}% 0% 0%)` }} />
<div style={{ opacity: cta, fontFamily: "Helvetica", fontSize: 44, color: INK }}>brightside.coffee</div>
</div>
</AbsoluteFill>
);
}
export default function Edit() {
return (
<AbsoluteFill style={{ backgroundColor: "#3b2f5c" }}>
<AbsoluteFill style={{ background: "linear-gradient(160deg, #3b2f5c, #1d1730)" }} />
<Badges />
<Sequence from={450} durationInFrames={150} name="card"><Card /></Sequence>
{GROUPS.map((g, i) => {
const length = (GROUPS[i + 1]?.from ?? 600) - g.from;
return <Sequence key={i} from={g.from} durationInFrames={length}><Caption words={g.words} length={length} /></Sequence>;
})}
</AbsoluteFill>
);
}
registerRoot(() => <Composition id="twin" component={Edit} width={1080} height={1920} fps={30} durationInFrames={600} />);
+29
View File
@@ -0,0 +1,29 @@
// COLOUR: flat patches of known sRGB values, the colour-accuracy fixture of lightspeed's Q3
// (bench/lightspeed/export.sh): primaries and secondaries at full and half strength, a grey ramp, skin tones and the
// near-black and near-white steps where range and matrix mistakes show first. Rendered, encoded and decoded back, each
// patch's centre must come back as the value it was painted with.
import { AbsoluteFill, Composition, registerRoot } from "raea";
export const PATCHES = [
"#ff0000", "#00ff00", "#0000ff", "#00ffff", "#ff00ff", "#ffff00",
"#800000", "#008000", "#000080", "#008080", "#800080", "#808000",
"#000000", "#101010", "#404040", "#808080", "#c0c0c0", "#ffffff",
"#050505", "#f5f5f5", "#e0ac69", "#8d5524", "#c68642", "#ffdbac",
];
const COLS = 6;
const W = 1920;
const H = 1080;
function Patches() {
const w = W / COLS;
const h = H / (PATCHES.length / COLS);
return (
<AbsoluteFill style={{ background: "#000000" }}>
{PATCHES.map((c, i) => (
<div key={i} style={{ position: "absolute", left: (i % COLS) * w, top: Math.floor(i / COLS) * h, width: w, height: h, background: c }} />
))}
</AbsoluteFill>
);
}
registerRoot(() => <Composition id="colour" component={Patches} width={W} height={H} fps={30} durationInFrames={30} />);
+50
View File
@@ -0,0 +1,50 @@
#!/bin/bash
# R6, energy (docs/lightspeed.feature): watts while playing pong and playing a timeline (the legacy app's idle
# stage retired with apps/legacy).
#
# bench/lightspeed/energy.sh [--seconds 30]
#
# Without root (powermetrics needs it), from two counters (`raea ci energy`):
# process watts the process's own energy (proc_pid_rusage's ri_energy_nj, rusage_info_v6: the CPU energy the kernel
# attributes to it) over the run past its first 5 s. GPU energy isn't attributed per process, so this is
# the CPU's part; it's the row's value
# system watts the whole Mac's input power (the battery controller's SystemPowerIn, mW) sampled each second: context
# only, since everything else running counts too; with the load recorded beside it
# pong raea play pong --offscreen at its 120 fps, keys pressed as gate.sh presses them
# timeline titles played from its bake (--baked), 30 fps
. "$(dirname "$0")/lib.sh"
H=bench/lightspeed/energy.sh
set -o pipefail
GAMES=$ROOT/sdk/react/bench/games
TIMELINES=$ROOT/sdk/react/bench/timelines
seconds=30
while [ $# -gt 0 ]; do
case $1 in
--seconds) seconds=$2; shift ;;
*) echo "usage: bench/lightspeed/energy.sh [--seconds S]" >&2; exit 2 ;;
esac
shift
done
seconds=$(pyf "$seconds")
# the play runs 2 s past the watch (Python: str(seconds + 2))
secs2=$(pyf "$(awk -v s="$seconds" 'BEGIN { print s + 2 }')")
# the watch's raw numbers rounded as the rows keep them
rounded() { LS_JQ -c 'include "lib"; {process_w: (.process_w | pyround(3)), system_w: (.system_w | if . == null then null else pyround(1) end), span_s: (.span_s | pyround(1))}'; }
# motion EDIT MODE: play it (MODE --input or --baked) and watch its energy
motion() {
(cd "$ROOT/sdk/react" && RAEA_AUDIO_MUTE=1 RAEA_INPUT_KEYS="" "$MOTION" ci energy --seconds "$seconds" -- "$MOTION" play "$1" \
--offscreen --size 1280x720 --seconds "$secs2" "$2") | rounded
}
trap cleanup_turn EXIT
turn_begin energy
pong=$(motion "$GAMES/pong/edit.tsx" --input) || { turn_end; exit 1; }
timeline=$(motion "$TIMELINES/titles/edit.tsx" --baked) || { turn_end; exit 1; }
turn_end
res=$(jq -nc --argjson p "$pong" --argjson t "$timeline" '{pong: $p, timeline: $t}')
record R6 "$(echo "$res" | LS_JQ -c 'include "lib"; "\(.pong.process_w | pyf) / \(.timeline.process_w | pyf)"')" \
"W (CPU, process) pong / timeline" "$res" $H
+195
View File
@@ -0,0 +1,195 @@
#!/bin/bash
# Throughput and export fidelity (docs/lightspeed.feature): T1, T2, T4 and Q3.
#
# bench/lightspeed/export.sh [--runs 3] [--only T1,T2,T4,Q3]
#
# T1 ts1 (the 20 s, 595-frame 1080x1920 edit on real footage) rendered to MP4, warm: wall time, p50 of RUNS, with the
# render's own split (frames, sound, finish) from RAEA_TIMES
# T2 bench/lightspeed/t3d600 (a lit cube under moving text, 1080x1920, 600 frames) rendered to MP4, warm
# T4 batch: titles (600 frames, no footage) rendered by K processes at once, for K = 1, 2, 4, 8 (2K renders each):
# renders per hour and how it scales from K = 1
# Q3 VMAF of ts1's MP4 against the same frames rendered losslessly (PNG), pooled mean and the worst frame; and
# colour: bench/lightspeed/colour's patches rendered to MP4, decoded with the matrix and range the file declares,
# each patch's centre against the value it was painted with (worst channel error, 8-bit; `raea ci
# patches`), plus the tags. Both for the default export (H.264, 8-bit) and for `render --10bit` (HEVC Main10).
# Q3.colour is the 10-bit export's (the exact one; 8-bit limited range's own round trip errs up to 2), with the
# H.264 export's in its detail; Q3.vmaf is the default export's, with the 10-bit export's in its detail. The colour
# decode is swscale with full_chroma_int+accurate_rnd: its default 10-bit -> RGB path errs 3-4 on ideal planes
# (exact with these), and on 8-bit these give the exact round trip's own floor
#
# The footage fixtures (ts1, k4) are in RAEA_LIGHTSPEED_FIXTURES (~/Library/Caches/raea-lightspeed/fixtures): ts1's
# footage isn't in git. Wall times come from `raea ci time` (the clock just before the spawn to the exit).
. "$(dirname "$0")/lib.sh"
H=bench/lightspeed/export.sh
TS1=$FIXTURES/ts1/edit.tsx
T3D=$ROOT/bench/lightspeed/t3d600/edit.tsx
TITLES=$ROOT/sdk/react/bench/timelines/titles/edit.tsx
COLOUR=$ROOT/bench/lightspeed/colour/edit.tsx
runs=3; only=T1,T2,T4,Q3
while [ $# -gt 0 ]; do
case $1 in
--runs) runs=$2; shift ;;
--only) only=$2; shift ;;
*) echo "usage: bench/lightspeed/export.sh [--runs N] [--only T1,T2,T4,Q3]" >&2; exit 2 ;;
esac
shift
done
has() { case ",$only," in *",$1,"*) return 0 ;; esac; return 1; }
TMPS=()
trap 'cleanup_turn; [ ${#TMPS[@]} -gt 0 ] && rm -rf "${TMPS[@]}"' EXIT
newtmp() { local d; d=$(mktemp -d "${TMPDIR:-/tmp}/$1XXXXXX"); TMPS+=("$d"); echo "$d"; }
# render EDIT OUT [ARGS...]: prints the wall seconds, a tab, the start (unix ms), a tab, and the render's own split
# (RAEA_TIMES' JSON line, null without it). Every render renders: the export cache (3479eea) would answer a repeat
# in ~0.02 s, which isn't T1, T2 or T4. TIMES=1 asks for the split.
render() {
local edit=$1 out=$2; shift 2
local log=$out.log clock=$out.clock
if [ "${TIMES:-}" = 1 ]; then
RAEA_EXPORT_CACHE=0 RAEA_TIMES=1 "$MOTION" ci time --to "$clock" -- "$MOTION" render "$edit" -o "$out" "$@" > "$log.out" 2> "$log.err"
else
RAEA_EXPORT_CACHE=0 "$MOTION" ci time --to "$clock" -- "$MOTION" render "$edit" -o "$out" "$@" > "$log.out" 2> "$log.err"
fi
if [ $? != 0 ]; then
if [ -s "$log.err" ]; then say_tail "render $edit: " 600 "$log.err" >&2; else say_tail "render $edit: " 600 "$log.out" >&2; fi
return 1
fi
cat "$log.out" "$log.err" > "$log"
jq -r --rawfile t "$log" '"\(.wall_s)\t\(.start_unix_ms)\t\([$t | split("\n")[] | select(startswith("{") and contains("\"frames\"")) | fromjson?] | last | tojson)"' "$clock"
rm -f "$log" "$log.out" "$log.err" "$clock"
}
# timed EDIT RUNS [ARGS...]: a warm render, then RUNS timed ones; their lines (render's) on stdout
timed() {
local edit=$1 n=$2 tmp; shift 2
tmp=$(newtmp lightspeed-export-)
render "$edit" "$tmp/warm.mp4" "$@" > /dev/null || return 1
for i in $(seq 0 $((n - 1))); do TIMES=1 render "$edit" "$tmp/$i.mp4" "$@" || return 1; done
rm -rf "$tmp"
}
t1_t2() {
local d; d=$(newtmp lightspeed-t1t2-)
turn_begin export:T1T2
if has T1; then timed "$TS1" "$runs" > "$d/T1" || { turn_end; return 1; }; fi
if has T2; then timed "$T3D" "$runs" > "$d/T2" || { turn_end; return 1; }; fi
turn_end
for row in T1 T2; do
[ -f "$d/$row" ] || continue
local detail
detail=$(LS_JQ -Rsc 'include "lib"; [split("\n")[] | select(. != "") | split("\t") | {wall: (.[0] | tonumber), split: (.[2] | fromjson)}] as $r
| [$r[].wall] as $w
| {p50_s: ($w | pct(0.5) | pyround(3)), max_s: ($w | max | pyround(3)), runs: ($w | map(pyround(3))),
split: ($r[($r | length) / 2 | floor].split | if . == null then null else
{setup_s: .setup_s, frames_s: (if .times then (.times.ms_per_frame.wall * .frames / 1e3 | pyround(3)) else null end),
sound_s: .sound_s, finish_s: .finish_s, fps: .fps_incl_encode, video: .video} end)}' "$d/$row")
record $row "$(echo "$detail" | LS_JQ -r 'include "lib"; .p50_s | pyf')" s "$detail" $H
done
}
t4() {
local tmp res="" k i w
tmp=$(newtmp lightspeed-batch-)
render "$TITLES" "$tmp/warm.mp4" > /dev/null || return 1
turn_begin export:T4
for k in 1 2 4 8; do
# K workers at once over the 2K renders, as a pool of K threads takes them
local pids=""
for w in $(seq 0 $((k - 1))); do
( for i in $w $((w + k)); do render "$TITLES" "$tmp/k$k-$i.mp4" > "$tmp/k$k-$i.line" || exit 1; done ) &
pids="$pids $!"
done
# the workers only (a bare wait would wait for the turn's watcher too)
for p in $pids; do wait $p; done
for i in $(seq 0 $((2 * k - 1))); do [ -s "$tmp/k$k-$i.line" ] || { turn_end; echo "T4: a render failed (K=$k)" >&2; return 1; }; done
res="$res$(cat "$tmp"/k$k-*.line | LS_JQ -Rsc --argjson k $k 'include "lib";
[split("\n")[] | select(. != "") | split("\t") | {wall: (.[0] | tonumber), start: (.[1] | tonumber)}] as $r
# the batch: the first spawn to the last exit
| ((([$r[] | .start + .wall * 1e3] | max) - ([$r[].start] | min)) / 1e3) as $secs
| {("\($k)"): {renders: (2 * $k), wall_s: ($secs | pyround(2)), per_hour: (2 * $k * 3600 / $secs | pyround(0)),
render_p50_s: ([$r[].wall] | pct(0.5) | pyround(2))}}')"$'\n'
rm -f "$tmp"/k$k-*
done
turn_end
local detail
detail=$(printf '%s' "$res" | LS_JQ -sc --argjson cores "$(getconf _NPROCESSORS_ONLN)" 'include "lib"; add as $by
| (reduce ($by | to_entries[]) as $e (null; if . == null or $e.value.per_hour > .per_hour then $e.value else . end)) as $best
| {by_processes: $by, scaling_vs_1: ($best.per_hour / $by["1"].per_hour | pyround(2)), cores: $cores, best: $best.per_hour}')
record T4 "$(echo "$detail" | jq .best)" "renders/hour (titles, 600 frames)" "$(echo "$detail" | jq -c 'del(.best)')" $H
}
probe_tags() {
ffprobe -v error -select_streams v:0 -show_entries stream=pix_fmt,color_range,color_space,color_transfer,color_primaries,bit_rate \
-of json "$1" | jq -c '.streams[0]'
}
# vmaf MP4 PNGDIR FPS: pooled mean, the 1st percentile, the worst frame
vmaf() {
local mp4=$1 png=$2 fps=$3 log=$2/vmaf.json pf=yuv420p
# a 10-bit file is compared at 10 bits (the reference made 10-bit too), an 8-bit one as before
case $(probe_tags "$mp4" | jq -r '.pix_fmt // ""') in *10*) pf=yuv420p10le ;; esac
if ! nice -n 15 ffmpeg -v error -i "$mp4" -framerate "$fps" -i "$png/frame-%05d.png" \
-filter_complex "[0:v]setpts=PTS-STARTPTS,format=$pf[d];[1:v]scale=out_color_matrix=bt709:out_range=tv,format=$pf,setpts=PTS-STARTPTS[r];[d][r]libvmaf=log_fmt=json:log_path=$log:n_threads=4" \
-f null - 2> "$png/vmaf.err"; then
say_tail "vmaf: " 400 "$png/vmaf.err" >&2; return 1
fi
LS_JQ -c 'include "lib"; ([.frames[].metrics.vmaf] | sort) as $v
| (reduce .frames[] as $f (null; if . == null or $f.metrics.vmaf < .metrics.vmaf then $f else . end)) as $worst
| {mean: (.pooled_metrics.vmaf.mean | pyround(2)), p1: ($v[($v | length) / 100 | floor] | pyround(2)), min: ($v[0] | pyround(2)),
worst_frame: $worst.frameNum, frames: ($v | length)}' "$log"
}
# colour TMP [ARGS...]: the colour fixture rendered (ARGS: --10bit), decoded as its tags say, each patch against its value
colour() {
local tmp=$1; shift
local mp4=$tmp/colour.mp4 tags matrix rng
render "$COLOUR" "$mp4" "$@" > /dev/null || return 1
tags=$(probe_tags "$mp4")
matrix=$(echo "$tags" | jq -r '{"bt709": "bt709", "smpte170m": "bt601", "bt470bg": "bt601", "bt2020nc": "bt2020"}[.color_space // ""] // "bt709"')
rng=$(echo "$tags" | jq -r 'if (.color_range // "tv") == "tv" then "tv" else "pc" end')
ffmpeg -v error -i "$mp4" -vf "select=eq(n\\,15),scale=in_color_matrix=$matrix:in_range=$rng:out_range=pc:flags=full_chroma_int+accurate_rnd,format=rgb24" \
-frames:v 1 -f rawvideo - > "$tmp/colour.rgb" 2> /dev/null
# the patches as painted: the "#rrggbb" strings from PATCHES to the file's first "];"
local hexes
hexes=$(jq -rn --rawfile s "$COLOUR" '($s | split("PATCHES")) as $p
| if ($p | length) < 2 or ($p[0] | contains("];")) then empty
else ("PATCHES" + ($p[1:] | join("PATCHES"))) | split("];")[0] | [match("\"#([0-9a-f]{6})\""; "g") | .captures[0].string][] end')
"$MOTION" ci patches "$tmp/colour.rgb" 1920 1080 6 $hexes > "$tmp/patches.json" || return 1
jq -c --argjson tags "$tags" --arg as "$matrix $rng" --argjson bytes "$(stat -f %z "$mp4")" '
(reduce .patches[] as $p ({}; .[$p[0]] = {want: $p[1], got: $p[2], err: $p[3]})) as $errs
| {worst_err_8bit: .worst, tags: $tags, decoded_as: $as, bytes: $bytes,
worst_patches: ([$errs | to_entries[] | [.key, .value.err]] | sort_by(-.[1]) | .[:5]), patches: $errs}' "$tmp/patches.json"
}
q3() {
local tmp mp4 mp4_10 png w8 w10 vm vm10 col8 col
tmp=$(newtmp lightspeed-q3-)
mp4=$tmp/ts1.mp4; mp4_10=$tmp/ts1-10bit.mp4; png=$tmp/png
mkdir -p "$png"
turn_begin export:Q3
w8=$(render "$TS1" "$mp4") || { turn_end; return 1; }; w8=${w8%%$'\t'*}
w10=$(render "$TS1" "$mp4_10" --10bit) || { turn_end; return 1; }; w10=${w10%%$'\t'*}
render "$TS1" "$png" > /dev/null || { turn_end; return 1; }
vm=$(vmaf "$mp4" "$png" 30) || { turn_end; return 1; }
vm=$(echo "$vm" | LS_JQ -c --argjson tags "$(probe_tags "$mp4")" --argjson b "$(stat -f %z "$mp4")" --argjson w "$w8" \
'include "lib"; .tags = $tags | .bytes = $b | .render_s = ($w | pyround(2))')
vm10=$(vmaf "$mp4_10" "$png" 30) || { turn_end; return 1; }
vm10=$(echo "$vm10" | LS_JQ -c --argjson tags "$(probe_tags "$mp4_10")" --argjson b "$(stat -f %z "$mp4_10")" --argjson w "$w10" \
'include "lib"; .tags = $tags | .bytes = $b | .render_s = ($w | pyround(2))')
vm=$(echo "$vm" | jq -c --argjson t "$vm10" '.ten_bit = $t')
rm -rf "$png" # 1.4 GB of frames
col8=$(colour "$tmp") || { turn_end; return 1; }
col=$(colour "$tmp" --10bit) || { turn_end; return 1; }
col=$(echo "$col" | jq -c --argjson c "$col8" '.h264_8bit = ($c | {worst_err_8bit, tags, decoded_as, bytes, worst_patches})')
turn_end
record Q3.vmaf "$(echo "$vm" | LS_JQ -r 'include "lib"; .mean | pyf')" "VMAF mean (ts1, MP4 vs lossless frames; --10bit in detail)" "$vm" $H
record Q3.colour "$(echo "$col" | jq .worst_err_8bit)" "worst patch error /255 (render --10bit, HEVC Main10; H.264 8-bit in detail)" "$col" $H
}
status=0
if has T1 || has T2; then t1_t2 || exit 1; fi
if has T4; then t4 || exit 1; fi
if has Q3; then q3 || exit 1; fi
exit $status
+136
View File
@@ -0,0 +1,136 @@
#!/bin/bash
# The feel rows and the GC rows (docs/lightspeed.feature): F1, F2, F3, F4, F6, R1, R2.
#
# bench/lightspeed/feel.sh [--seconds 60] [--only games,gc,scrub]
#
# games sdk/react/bench/games/gate.sh SECONDS pong platformer arena3d (the 3D one), offscreen at 120 fps with keys
# pressed: F1 input to present p99 (offscreen; the in-window gate, apps/legacy/shell/bench/gates.py, went with the
# Dioxus window in 222ed773: void's bevy_ui window measures input to frame through sdk/ui/conformance),
# F2 work p99 and p99.9, F3 missed frames, F6 hitches (frames past
# the first second over 2 ms)
# gc pong again with JSC_logGC=1 (lib.jq's gc parse): R2 collections a minute and the worst pause, R1's JS layer as
# the garbage freed a frame (the other layers aren't counted yet: ZeroHeap Z1)
# scrub 60 shuffled seeks of ts1 (1080x1920) and k4 (4K) from their bakes (play --scrub, as
# sdk/react/bench/video/gate.sh): F4 scrub p99
. "$(dirname "$0")/lib.sh"
H=bench/lightspeed/feel.sh
REACT=$ROOT/sdk/react
seconds=60; only=games,gc,scrub
while [ $# -gt 0 ]; do
case $1 in
--seconds) seconds=$2; shift ;;
--only) only=$2; shift ;;
*) echo "usage: bench/lightspeed/feel.sh [--seconds S] [--only games,gc,scrub]" >&2; exit 2 ;;
esac
shift
done
# Python's float: the harness passed str(float) on (60 -> 60.0)
seconds=$(pyf "$seconds")
has() { case ",$only," in *",$1,"*) return 0 ;; esac; return 1; }
games() {
local tmp out
tmp=$(mktemp -d "${TMPDIR:-/tmp}/lightspeed-feel-XXXXXX")
turn_begin feel:games
out=$(cd "$REACT" && TMPDIR=$tmp sh bench/games/gate.sh "$seconds" pong platformer arena3d 2> /dev/null)
turn_end
# Python's str.strip()
say "$(printf '%s' "$out" | awk '{ l[NR] = $0 } END { s = 1; while (s <= NR && l[s] ~ /^[ \t\r]*$/) s++; e = NR; while (e >= s && l[e] ~ /^[ \t\r]*$/) e--
for (i = s; i <= e; i++) { x = l[i]; if (i == s) sub(/^[ \t\r]+/, "", x); if (i == e) sub(/[ \t\r]+$/, "", x); print x } }')"
local files=()
for g in pong platformer arena3d; do
[ -f "$tmp/raea-games-gate/$g.json" ] && files+=("$g" "$tmp/raea-games-gate/$g.json")
done
local per rows
per=$(for ((i = 0; i < ${#files[@]}; i += 2)); do jq -c --arg g "${files[i]}" '{($g): .}' "${files[i + 1]}"; done | LS_JQ -sc 'include "lib";
add // {} | map_values(
{input_p99_ms: (.input_to_present_ms.p99 | pyround(2)), input_p99_frames: (.input_to_present_ms.p99_frames | pyround(2)),
work_p99_ms: (.work_ms.p99 | pyround(2)), work_p999_ms: ((.work_ms.p999 // 0) | pyround(2)),
missed: .missed_vs_display, presented: .presented,
work_p50_ms: (.work_ms.p50 | pyround(2)), hitches: (.hitches_over_2ms // {} | .count),
hitch_max_ms: ((.hitches_over_2ms // {} | .max // 0) | pyround(2)),
first_hitches: ((.hitches_over_2ms // {} | .first // [])[:6])})')
if [ "$per" = "{}" ]; then echo "feel: no game ran (gate.sh: $out)" >&2; rm -rf "$tmp"; return 1; fi
# a hitch is a frame over 2 ms in a game whose frames are well under it; a game whose median frame is already near
# 2 ms (arena3d's 3D frame, ~3 ms) is F2's steady cost, not first-use stalls, so it's listed, not counted
rows=$(echo "$per" | LS_JQ -c --arg s "$seconds" 'include "lib";
def worst($k): [.[][$k]] | max;
(with_entries(select((.value.work_p50_ms // 0) < 1.5))) as $first
| ([keys[] as $k | select($first | has($k) | not) | $k] | sort) as $steady
| ([$first[].hitch_max_ms] | if length == 0 then 0 else max end) as $hmax
| {F1: (worst("input_p99_ms") | pyf),
F2: ("\(worst("work_p99_ms") | pyf) / \(worst("work_p999_ms") | pyf)" | tojson),
F3: ([.[].missed] | add | tostring),
F3u: "missed frames in \($s | tonumber | fixed(0)) s x \(length) games",
F6: ("\([$first[].hitches] | add // 0) (max \(if ($first | length) == 0 then "0" else $hmax | pyf end) ms)"
+ (if ($steady | length) > 0 then "; \($steady | join(", ")) steady over 2 ms, in F2" else "" end) | tojson)}')
rm -rf "$tmp"
record F1 "$(echo "$rows" | jq -r .F1)" "ms input to present p99, offscreen 120 fps (worst game)" "$per" $H
record F2 "$(echo "$rows" | jq -r .F2)" "ms work p99 / p99.9 (worst game)" "$per" $H
record F3 "$(echo "$rows" | jq -r .F3)" "$(echo "$rows" | jq -r .F3u)" "$per" $H
record F6 "$(echo "$rows" | jq -r .F6)" "hitches over 2 ms past the first second" "$per" $H
}
gc() {
local s=$1 tmp detail
tmp=$(mktemp -d "${TMPDIR:-/tmp}/lightspeed-gc-XXXXXX")
turn_begin feel:gc
(cd "$REACT" && JSC_logGC=1 RAEA_AUDIO_MUTE=1 "$MOTION" play bench/games/pong/edit.tsx --input --offscreen --size 1280x720 \
--seconds "$s" --json "$tmp/pong.json" > "$tmp/out" 2> "$tmp/err")
turn_end
cat "$tmp/out" "$tmp/err" > "$tmp/all"
detail=$(LS_JQ -c --rawfile t "$tmp/all" 'include "lib";
[$t | match("START \\w (\\d+)kb => (\\w+),.*?=> (\\d+)kb, p=([0-9.]+)ms \\(max [0-9.]+\\), cycle ([0-9.]+)ms END\\]"; "g")
| [.captures[].string]] as $gcs
| [$gcs[][3] | tonumber] as $pauses
| ([$gcs[] | (.[0] | tonumber) - (.[2] | tonumber)] | add // 0) as $freed
| {collections: ($gcs | length), per_minute: (($gcs | length) * 60 / .seconds | pyround(1)),
pause_max_ms: ($pauses | max // 0), pause_total_ms: ($pauses | add // 0 | pyround(1)),
freed_kb_per_frame: ($freed / ([.presented, 1] | max) | pyround(1)),
kinds: ([$gcs[][1]] | unique), frames: .presented, seconds: .seconds}' "$tmp/pong.json") || { rm -rf "$tmp"; return 1; }
rm -rf "$tmp"
local r2 r1
r2=$(echo "$detail" | LS_JQ -c 'include "lib"; "\(.per_minute | pyf)/min (max pause \(if .collections > 0 then .pause_max_ms | pyf else "0" end) ms)"')
r1=$(echo "$detail" | LS_JQ -c 'include "lib"; "JS \(.freed_kb_per_frame | pyf) KB/frame"')
record R2 "$r2" "JSC collections, pong" "$detail" $H
record R1 "$r1" "garbage a frame, pong (JS layer; others uncounted)" "$detail" $H
}
scrub() {
local res="" name size edit t
t=$(mktemp "${TMPDIR:-/tmp}/lightspeed-scrub.XXXXXX")
turn_begin feel:scrub
for spec in "ts1 1080x1920" "k4 2160x3840"; do
set -- $spec; name=$1; size=$2
edit=$FIXTURES/$name/edit.tsx
if [ ! -f "$edit" ]; then say "F4: $edit missing; skipped"; continue; fi
(cd "$REACT" && RAEA_AUDIO_MUTE=1 "$MOTION" play "$edit" --baked --offscreen --size "$size" --scrub 60 > "$t.out" 2> "$t.err")
cat "$t.out" "$t.err" > "$t"
# the JSON after SCRUBBED: from the first { after it to the text's last }
local j
if ! j=$(jq -c --rawfile t "$t" -n --arg n "$name" '
($t | split("SCRUBBED")) as $p | if ($p | length) < 2 then error("no SCRUBBED") else
($p[1:] | join("SCRUBBED")) as $rest | ($rest | split("{")) as $q
| ("{" + ($q[1:] | join("{"))) as $from | ($from | split("}")) as $r
| ($r[:-1] | join("}") + "}") | fromjson end' 2> /dev/null); then
say_tail "F4 $name: the scrub failed: " 400 "$t"; continue
fi
res="$res$(echo "$j" | LS_JQ -c --arg n "$name" 'include "lib"; {($n): {scrub_p50_ms: (.scrub_ms.p50 | pyround(1)),
scrub_p99_ms: (.scrub_ms.p99 | pyround(1)), scrub_max_ms: (.scrub_ms.max | pyround(1)), first_frame_ms: .first_frame_ms,
seeks: .seeks}}')"$'\n'
done
turn_end
rm -f "$t" "$t.out" "$t.err"
[ -n "$res" ] || return 0
res=$(printf '%s' "$res" | jq -sc add)
record F4 "$(echo "$res" | LS_JQ -c 'include "lib"; [to_entries[] | "\(.key) \(.value.scrub_p99_ms | pyf)"] | join(" / ")')" \
"ms scrub p99 (1080p / 4K)" "$res" $H
}
status=0
if has games; then games || status=1; fi
# Python's min(seconds, 60): the float up to 60, the int 60 past it
if has gc; then gc "$(awk -v s="$seconds" 'BEGIN { print (s + 0 <= 60 ? s : "60") }')" || status=1; fi
if has scrub; then scrub || status=1; fi
exit $status
+33
View File
@@ -0,0 +1,33 @@
#!/bin/bash
# R4, GPU memory per stage (docs/lightspeed.feature).
#
# bench/lightspeed/gpumem.sh
#
# On Apple silicon the GPU's memory is the process's own: footprint(1) files Metal's buffers and textures under its
# "(graphics)" categories (owned, unmapped graphics memory and IOAccelerator). Each stage is played offscreen and read
# 5 s in, once it's steady (`raea ci graphics`):
# pong live, 1280x720
# titles from its bake, 1080x1920
# ts1 from its bake, 1080x1920 (footage: the decoder's surfaces count)
# The value is each stage's graphics memory (dirty, MB). Not timed, so it takes no lock; the load is still recorded.
. "$(dirname "$0")/lib.sh"
H=bench/lightspeed/gpumem.sh
ST_START=$(load1)
res=""
for spec in "pong $ROOT/sdk/react/bench/games/pong/edit.tsx 1280x720 0" \
"titles $ROOT/sdk/react/bench/timelines/titles/edit.tsx 1080x1920 1" \
"ts1 $FIXTURES/ts1/edit.tsx 1080x1920 1"; do
set -- $spec; name=$1; edit=$2; size=$3; baked=$4
if [ ! -f "$edit" ]; then say "R4 $name: $edit missing; skipped"; continue; fi
mode=--input; [ "$baked" = 1 ] && mode=--baked
g=$(cd "$ROOT/sdk/react" && RAEA_AUDIO_MUTE=1 "$MOTION" ci graphics --after 5 -- "$MOTION" play "$edit" --offscreen --size "$size" --seconds 9 $mode) || exit 1
res="$res$(echo "$g" | LS_JQ -c --arg n "$name" 'include "lib";
{($n): {graphics_mb: (.graphics_mb | pyround(1)), footprint_mb: (.footprint_mb | if . == null then null else pyround(1) end),
parts: (reduce .parts[] as $p ({}; .[$p[0]] = ($p[1] | pyround(1))))}}')"$'\n'
done
# memory, not time: the load doesn't change it much
ST_END=$(load1); ST_QUIET=true; ST_OTHERS='[]'
res=$(printf '%s' "$res" | jq -sc 'add // {}')
record R4 "$(echo "$res" | LS_JQ -c 'include "lib"; [to_entries[] | "\(.key) \(.value.graphics_mb | fixed(0))"] | join(" / ")')" \
"MB GPU (graphics footprint) per stage" "$res" $H
+78
View File
@@ -0,0 +1,78 @@
// What a live bundle's own JS allocates a frame (R1's JS layer, lightspeed Z3), without Bevy or a page: the bundle run
// in bun's JavaScriptCore with the bridge stubbed, frames handed to it as raea hands them, and the garbage
// counted from JSC's GC log (BUN_JSC_logGC, as jsheap.sh reads JSC_logGC) between the first and last measured frame.
// Quick and repeatable enough to split a frame's garbage by taking parts of an edit away.
// bun bench/lightspeed/jsalloc.ts BUNDLE.js [--frames 3000] [--warm 240] [--from 600] [--live] [--span N] [--set NAME=JSON]
// BUNDLE is a lite bundle as raea bundles it (RAEA_BUNDLE_CACHE=DIR keeps one in DIR).
const args = process.argv.slice(2);
const opt = (k: string, d: number) => {
const i = args.indexOf(k);
return i >= 0 ? Number(args[i + 1]) : d;
};
const file = args[0];
const FRAMES = opt("--frames", 3000), WARM = opt("--warm", 240), FROM = opt("--from", 600);
const LIVE = args.includes("--live");
if (!file) {
console.error("bun jsalloc.ts BUNDLE.js [--frames N] [--warm N] [--from F]");
process.exit(2);
}
if (!args.includes("--child")) {
// the run, with JSC's GC log on: what each eden collection freed, between the marks
const p = Bun.spawnSync(["bun", import.meta.path, ...args, "--child"], { env: { ...process.env, BUN_JSC_logGC: "1" }, stderr: "pipe", stdout: "pipe" });
const log = p.stderr.toString() + p.stdout.toString();
const from = log.indexOf("jsalloc: measuring"), to = log.indexOf("jsalloc: done");
if (from < 0 || to < 0) {
console.error(log.split("\n").filter((l) => !l.startsWith("[GC")).slice(-12).join("\n"));
process.exit(1);
}
const gc = /START \w (\d+)kb => \w+,.*?=> (\d+)kb, p=([0-9.]+)ms/g;
let freed = 0, n = 0;
for (const m of log.slice(from, to).matchAll(gc)) {
freed += Number(m[1]) - Number(m[2]);
n++;
}
const bridge = /bridge ([0-9.]+) KB/.exec(log.slice(to))?.[1];
console.log(`${file.split("/").pop()}: ${(freed / FRAMES).toFixed(1)} KB a frame (${n} collections over ${FRAMES} frames); bridge ${bridge} KB a frame`);
process.exit(0);
}
let wake: ((m: any) => void) | null = null;
let flushed = 0;
(globalThis as any).__bevyHost = {
op_flush(batch: string) {
flushed += batch.length;
},
op_next_event: () => new Promise((r) => (wake = r)),
op_emit() {},
op_request: () => Promise.resolve(null),
op_animate() {},
};
// --set NAME=JSON: a global set before the bundle runs (globalThis.__raea_lite_bailout=false, say)
for (let i = 0; i < args.length; i++) if (args[i] === "--set") {
const [k, v] = args[i + 1].split("=");
(globalThis as any)[k] = JSON.parse(v);
}
(0, eval)(await Bun.file(file).text());
const tick = () => new Promise<void>((r) => setImmediate(r));
async function frame(f: number) {
await tick();
const w = wake;
wake = null;
if (!w) throw new Error("the bundle isn't waiting for an event");
// --live: as live play sends a frame (live.rs step_inner), with this moment's input; else a timeline's frame number
w({ t: "event", name: "raea-frame", value: LIVE ? { frame: f, input: { keys: [] } } : f });
await tick();
}
for (let i = 0; i < WARM; i++) await frame(FROM + i);
Bun.gc(true);
console.error("jsalloc: measuring");
flushed = 0;
// --span N: the frames FROM .. FROM+N played over and over (live play's first seconds, measured long enough to count)
const SPAN = opt("--span", 0);
for (let i = 0; i < FRAMES; i++) await frame(SPAN > 0 ? FROM + ((WARM + i) % SPAN) : FROM + WARM + i);
console.error("jsalloc: done");
console.error(`bridge ${(flushed / FRAMES / 1024).toFixed(2)} KB a frame`);
process.exit(0);
+82
View File
@@ -0,0 +1,82 @@
#!/bin/bash
# R1's JS layer and R2 (docs/lightspeed.feature): the garbage a frame and the collections, per edit, on the live
# runtime (sdk/react/js/lite: every frame rendered in JS, as a game plays).
#
# bench/lightspeed/jsheap.sh [--seconds 20] [--runs 3] [--label NAME] [EDIT.tsx ...]
#
# Each edit is played offscreen with JSC_logGC=1 (no bake: timelines step their JS each frame too) and its GC log read:
# garbage freed a frame (KB), collections a minute, the worst pause, and JS time a frame (p50, p99). Defaults: the
# animate fixture, its interpolate twin, titles and pong, and pong's Z3 variants. The medians of RUNS go in the rows.
. "$(dirname "$0")/lib.sh"
H=bench/lightspeed/jsheap.sh
# NAME -> edit; Z3's fixtures: pong's step and fold alone (its view renders nothing), its view alone over a frozen state
edit_of() {
case $1 in
animate) echo sdk/react/bench/timelines/animate/edit.tsx ;;
twin) echo bench/lightspeed/animate-twin/edit.tsx ;;
titles) echo sdk/react/bench/timelines/titles/edit.tsx ;;
pong) echo sdk/react/bench/games/pong/edit.tsx ;;
pong-stepfold) echo sdk/react/bench/games/pong/edit.stepfold.tsx ;;
pong-view) echo sdk/react/bench/games/pong/edit.view.tsx ;;
*) echo "$1" ;;
esac
}
seconds=20; runs=3; label=""; names=()
while [ $# -gt 0 ]; do
case $1 in
--seconds) seconds=$2; shift ;;
--runs) runs=$2; shift ;;
--label) label=$2; shift ;;
-*) echo "usage: bench/lightspeed/jsheap.sh [--seconds S] [--runs N] [--label NAME] [EDIT ...]" >&2; exit 2 ;;
*) names+=("$1") ;;
esac
shift
done
seconds=$(pyf "$seconds")
[ ${#names[@]} = 0 ] && names=(animate twin titles pong pong-stepfold pong-view)
TMP=$(mktemp -d "${TMPDIR:-/tmp}/lightspeed-jsheap.XXXXXX")
trap 'cleanup_turn; rm -rf "$TMP"' EXIT
# once EDIT: one run's numbers, a JSON line
once() {
local edit=$1 input=""
case $edit in *games*) input=--input ;; esac
(cd "$ROOT/sdk/react" && JSC_logGC=1 RAEA_AUDIO_MUTE=1 RAEA_ZEROHEAP=1 "$MOTION" play "$edit" $input --offscreen --size 1280x720 \
--seconds "$seconds" --json "$TMP/run.json" > "$TMP/out" 2> "$TMP/err")
cat "$TMP/out" "$TMP/err" > "$TMP/all"
jq -c --rawfile t "$TMP/all" '
[$t | match("START \\w (\\d+)kb => (\\w+),.*?=> (\\d+)kb, p=([0-9.]+)ms \\(max [0-9.]+\\), cycle ([0-9.]+)ms END\\]"; "g")
| [.captures[].string]] as $gcs
| ([.presented, 1] | max) as $frames
| {kb_frame: (([$gcs[] | (.[0] | tonumber) - (.[2] | tonumber)] | add // 0) / $frames),
gc_min: (($gcs | length) * 60 / ([.seconds, 0.1] | max)),
pause_max: ([$gcs[][3] | tonumber] | max // 0.0), js_p50: .js_ms.p50, js_p99: .js_ms.p99,
work_p99: .work_ms.p99, frames: .presented,
# ZeroHeap Z1: Rust allocations a frame applying the ops (raea counting allocator)
rust_apply: (.rust_allocs.apply_per_frame // 0.0), rust_apply_kb: ((.rust_allocs.apply_bytes_per_frame // 0.0) / 1024)}' "$TMP/run.json"
local rc=$?
rm -f "$TMP/run.json"
return $rc
}
res=""
turn_begin jsheap
for n in "${names[@]}"; do
edit=$(edit_of "$n"); case $edit in /*) ;; *) edit=$ROOT/$edit ;; esac
: > "$TMP/runs"
for _ in $(seq 1 "$runs"); do once "$edit" >> "$TMP/runs" || { turn_end; say_tail "$n: the play failed: " 400 "$TMP/err" >&2; exit 1; }; done
med=$(LS_JQ -sc 'include "lib"; . as $runs | reduce ($runs[0] | keys_unsorted[]) as $k ({}; .[$k] = ([$runs[][$k]] | median | pyround(3)))
| .runs_kb_frame = [$runs[].kb_frame | pyround(1)]' "$TMP/runs")
say "$(echo "$med" | LS_JQ -r --arg n "$n" 'include "lib"; "\($n): \(.kb_frame | fixed(1)) KB/frame (\(.runs_kb_frame | pylist)), \(.gc_min | fixed(0)) GC/min, max pause \(.pause_max | fixed(2)) ms, js p50 \(.js_p50 | fixed(3)) / p99 \(.js_p99 | fixed(3)) ms"')"
res="$res$(echo "$med" | jq -c --arg n "$n" '{($n): .}')"$'\n'
done
turn_end
res=$(printf '%s' "$res" | jq -sc add)
lab=""; [ -n "$label" ] && lab=" ($label)"
record R1.js "$(echo "$res" | LS_JQ -c 'include "lib"; [to_entries[] | "\(.key) \(.value.kb_frame | fixed(0))"] | join(" / ")')" \
"KB JS garbage a frame$lab" "$res" $H
record R1.rust "$(echo "$res" | LS_JQ -c 'include "lib"; [to_entries[] | "\(.key) \(.value.rust_apply | fixed(0))"] | join(" / ")')" \
"Rust allocations a frame applying ops$lab" "$res" $H
+22
View File
@@ -0,0 +1,22 @@
# Number formatting for lightspeed's harnesses (bench/lightspeed/*.sh, `jq -L bench/lightspeed 'include "lib"; ...'`), so
# their rows read exactly as the Python harnesses' did (the history in results.jsonl stays comparable):
# pyround($n) Python's round(x, n): half to even on x's exact value (fma takes x * 10^n - the tie without rounding),
# n = 0 for round(x)
# pyf a float as Python's str() writes it (12.0, not 12)
# pystr a number read from JSON as Python's str() writes it: a float if its text has a point or an exponent
# (jq 1.7 keeps a number's text until it's computed with), an int otherwise; null is None
# fixed($n) Python's f"{x:.nf}"
# pct($p) the harnesses' percentile: the sorted list's element round((n - 1) * p)
# median statistics.median
# pylist a list of floats as Python's str() writes it ([1.0, 2.5])
def pyround($n): . as $x | pow(10; $n) as $m | ($x * $m | floor) as $f | fma($x; $m; -($f + 0.5)) as $r
| (if $r > 0 then $f + 1 elif $r < 0 then $f elif ($f % 2) == 0 then $f else $f + 1 end) / $m;
def pyf: if . == null then "None" else (. + 0 | tostring) as $t | if ($t | test("^-?[0-9]+$")) then $t + ".0" else $t end end;
def pystr: if . == null then "None" elif type == "number" then (if (tostring | test("[.eE]")) then pyf else tostring end)
elif type == "boolean" then (if . then "True" else "False" end) else tostring end;
def fixed($n): pyround($n) | tostring | split(".") as $p
| if $n == 0 then $p[0] else $p[0] + "." + ((($p[1] // "") + ([range($n)] | map("0") | join("")))[:$n]) end;
def pct($p): sort as $s | if ($s | length) == 0 then null else $s[(($s | length) - 1) * $p | pyround(0)] end;
def median: sort as $s | ($s | length) as $n | if $n % 2 == 1 then $s[($n - 1) / 2] else ($s[$n / 2 - 1] + $s[$n / 2]) / 2 end;
def pylist: "[" + (map(pyf) | join(", ")) + "]";
+183
View File
@@ -0,0 +1,183 @@
# Shared by lightspeed's harnesses (docs/lightspeed.feature), sourced: the quiet-machine turn at the shared measurement
# lock, the load recorded beside every number, and one results log the scoreboard reads.
#
# Results: ~/Library/Logs/raea/lightspeed/results.jsonl, one line per measured row:
# {"date", "commit", "row", "value", "unit", "detail", "load": {"start", "end"}, "quiet", "others", "harness"}
# "others": other agents' busy antsy jobs seen during the run (any makes it NOT QUIET).
# RAEA_LIGHTSPEED_MOTION: the raea to measure (default target/release/raea under this checkout).
# Bash 3.2 (macOS's /bin/bash, what launchd's CI runs); jq for JSON (lib.jq: Python's rounding, so rows read as the
# Python harnesses' did), awk for arithmetic, and `raea ci` (apps/ci) for what a shell can't time or
# read: milliseconds from a spawn, a process's energy, footprint(1)'s graphics memory.
LS_DIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
ROOT=$(cd "$LS_DIR/../.." && pwd)
MOTION=${RAEA_LIGHTSPEED_MOTION:-$ROOT/target/release/raea}
LOCK=/tmp/raea-measure.lock
LOGDIR=$HOME/Library/Logs/raea/lightspeed
RESULTS=$LOGDIR/results.jsonl
FIXTURES=${RAEA_LIGHTSPEED_FIXTURES:-$HOME/Library/Caches/raea-lightspeed/fixtures}
QUIET=${RAEA_CI_QUIET_LOAD:-6}
# another agent's job counts against a run once it has used this much memory: idle waiters and lock polls (a few MB)
# don't, a build, render, export or model run does
BUSY_MB=100
# set in a turn's environment, so every process the harness starts carries it, even one that leaves the parent chain
# (a helper that detaches is re-parented to launchd): one once marked its run NOT QUIET
MARK=RAEA_LIGHTSPEED_TURN
LS_JQ() { jq -L "$LS_DIR" "$@"; }
say() { echo "$*"; }
# say_tail PREFIX N FILE: PREFIX and the file's last N characters, as print(prefix + text[-N:]) writes them (characters,
# not bytes; the text's own trailing newline kept)
say_tail() { LS_JQ -rn --rawfile t "$3" --argjson n "$2" --arg p "$1" '$p + ($t | .[-$n:])'; }
# a decimal as Python's str(float(...)) writes it: 2.00 -> 2.0, 6 -> 6.0, 2.10 -> 2.1
pyf() {
case $1 in
*.*) echo "$1" | sed -e 's/\(\.[0-9]*[1-9]\)0*$/\1/' -e 's/\.0*$/.0/' ;;
'') echo None ;;
*) echo "$1.0" ;;
esac
}
load1() { sysctl -n vm.loadavg | awk '{print $2}'; }
commit() { git -C "$ROOT" rev-parse --short=9 HEAD 2>/dev/null; }
# Other agents' jobs running now, one name a line: from `antsy board`, those that reached BUSY_MB, leaving out this
# harness's own job (ANTSY_JOB); and raea's own engines run outside antsy (an agent's quick A/B of raea plays):
# raea, raea-game and raea-page-host processes this harness didn't start (not its descendants, not carrying its turn's
# mark) that are busy (BUSY_MB resident, or a quarter of a core). An idle one (a `shell-serve` an exited app left behind,
# ~45 MB at 2-3% of a core) doesn't count.
other_jobs() {
antsy board 2>/dev/null | awk -v me="${ANTSY_JOB:-}" -v busy=$BUSY_MB '
match($0, /^[ \t]*job [^ \t]+ \[[^]]*\] /) {
split(substr($0, 1, RLENGTH), w, " "); name = w[2]
rest = substr($0, RLENGTH + 1)
if (!match(rest, / peak [0-9.]+ (MB|GB)/)) next
split(substr(rest, RSTART + 1, RLENGTH - 1), p, " ")
mb = p[2] * (p[3] == "GB" ? 1024 : 1)
if (name != me && mb >= busy) print name
}'
ps -Ao pid=,ppid=,rss=,pcpu=,comm= 2>/dev/null | awk -v me=$$ -v busy=$BUSY_MB '
$1 ~ /^[0-9]+$/ && $2 ~ /^[0-9]+$/ && NF >= 5 {
n++; pid[n] = $1; ppid[n] = $2; rss[n] = ($3 ~ /^[0-9]+$/) ? $3 : 0; cpu[n] = $4 + 0
c = $0; for (i = 1; i <= 4; i++) sub(/^[ \t]*[^ \t]+/, "", c); sub(/^[ \t]+/, "", c)
k = split(c, parts, "/"); comm[n] = parts[k]
}
END {
mine[me] = 1
do { grew = 0; for (i = 1; i <= n; i++) if (!(pid[i] in mine) && (ppid[i] in mine)) { mine[pid[i]] = 1; grew = 1 } } while (grew)
for (i = 1; i <= n; i++)
if ((comm[i] == "raea" || comm[i] == "raea-game" || comm[i] == "raea-page-host") && !(pid[i] in mine) && (rss[i] / 1024 >= busy || cpu[i] >= 25))
print pid[i], comm[i]
}' | while read -r pid name; do ours "$pid" || echo "$name pid $pid"; done
}
# whether process PID was started inside this harness's turn: its environment carries the turn's mark (ps -E shows the
# environment of the person's own processes)
ours() {
local mark
eval "mark=\${$MARK:-}"
[ -n "$mark" ] || return 1
ps -Ewwo command= -p "$1" 2>/dev/null | grep -qF "$MARK=$mark"
}
# Other agents' busy jobs seen during a run: at the start, every 5 s, and at the end (a 65 s export that began and
# finished inside a game's run once put a 19 ms step on the platformer the load average never showed)
watch_start() {
WATCH_FILE=$(mktemp "${TMPDIR:-/tmp}/lightspeed-watch.XXXXXX")
other_jobs > "$WATCH_FILE"
# the poller stops at its next tick once WATCH_FILE.stop exists (a poll under way finishes, as the Python thread's did)
( trap 'exit 0' TERM; while [ ! -e "$WATCH_FILE.stop" ]; do sleep 5 & wait $!; [ -e "$WATCH_FILE.stop" ] || other_jobs >> "$WATCH_FILE"; done ) &
WATCH_PID=$!
}
# the names seen, as a JSON array: a job's name without antsy's run suffix (stress-r5-9da29 -> stress-r5), sorted, once
watch_end() {
if [ -n "${WATCH_PID:-}" ]; then
: > "$WATCH_FILE.stop"; pkill -TERM -x -P "$WATCH_PID" sleep 2>/dev/null; wait "$WATCH_PID" 2>/dev/null
WATCH_PID=
fi
other_jobs >> "$WATCH_FILE"
sed -E 's/-[0-9a-f]{5}$//' "$WATCH_FILE" | LC_ALL=C sort -u | jq -Rsc 'split("\n") | map(select(. != ""))'
rm -f "$WATCH_FILE" "$WATCH_FILE.stop"
}
HELD_LOCK=0
cleanup_turn() {
[ -n "${WATCH_PID:-}" ] && { : > "$WATCH_FILE.stop"; kill -TERM "$WATCH_PID" 2>/dev/null; pkill -TERM -x -P "$WATCH_PID" sleep 2>/dev/null; rm -f "$WATCH_FILE" "$WATCH_FILE.stop"; }
[ "$HELD_LOCK" = 1 ] && rmdir "$LOCK" 2>/dev/null
HELD_LOCK=0
}
# a harness stopped from outside (antsy, CI's timeout) still gives the lock back
trap 'cleanup_turn; exit 143' TERM
trap 'cleanup_turn; exit 130' INT
trap cleanup_turn EXIT
# turn_begin NAME [WAIT_S] ... turn_end: a measurement's turn. Sets ST_START, then ST_END, ST_OTHERS (a JSON array) and
# ST_QUIET (under QUIET at both ends and no other agent's busy job seen). The user, 2026-10-18: nobody waits for a quiet
# machine; a row is marked with the load it was measured under, and levers are judged by paired A/Bs and by counts (CPU
# time, allocations, frames), which hold under load. So by default there's no wait and no lock. RAEA_LIGHTSPEED_QUIET=1
# (the nightly pass in bench/ci.sh) waits up to WAIT_S (600) for a quiet machine and takes the shared lock;
# RAEA_LIGHTSPEED_LOCK=1 takes the lock alone (a short paired A/B).
turn_begin() {
TURN_NAME=$1
local wait_s=${2:-600} t=0
if [ "${RAEA_LIGHTSPEED_QUIET:-}" = 1 ] || [ "${RAEA_LIGHTSPEED_LOCK:-}" = 1 ]; then
while [ "${RAEA_LIGHTSPEED_QUIET:-}" = 1 ] && awk -v l="$(load1)" -v q="$QUIET" 'BEGIN { exit !(l + 0 >= q + 0) }' && [ $t -lt "$wait_s" ]; do
[ $((t % 60)) = 0 ] && say "$TURN_NAME: waiting for a load under $(pyf "$QUIET") (now $(pyf "$(load1)"), $t s of $wait_s)"
sleep 15; t=$((t + 15))
done
t=0
until mkdir "$LOCK" 2>/dev/null; do
[ $((t % 60)) = 0 ] && say "$TURN_NAME: waiting for the measurement lock ($t s)"
sleep 5; t=$((t + 5))
done
HELD_LOCK=1
fi
TURN_HELD=$(date +%s)
ST_START=$(load1)
export $MARK="$$-$(date +%s)-$RANDOM"
watch_start
}
turn_end() {
unset $MARK
if [ "$HELD_LOCK" = 1 ]; then rmdir "$LOCK" 2>/dev/null; HELD_LOCK=0; local locked=1; else local locked=0; fi
ST_END=$(load1)
ST_OTHERS=$(watch_end)
# quiet only when the load stayed under the line at both ends and no other agent's busy job ran meanwhile: a run the
# machine got busy during isn't clean
if [ "$ST_OTHERS" = "[]" ] && awk -v a="$ST_START" -v b="$ST_END" -v q="$QUIET" 'BEGIN { exit !((a > b ? a : b) + 0 < q + 0) }'; then
ST_QUIET=true
else
ST_QUIET=false
fi
local secs=$(( $(date +%s) - TURN_HELD ))
[ $locked = 1 ] && [ $secs -gt 600 ] && say "$TURN_NAME: held the measurement lock $secs s (over a 10 minute turn)"
return 0
}
# record ROW VALUE UNIT DETAIL HARNESS: one row to results.jsonl, and its line on stdout. VALUE is JSON as Python's str()
# writes it (12.0, "a string", null); DETAIL is JSON. The turn's ST_START, ST_END (empty: null), ST_QUIET, ST_OTHERS.
record() {
local row=$1 value=$2 unit=$3 detail=$4 harness=$5
mkdir -p "$LOGDIR"
# the loads as Python's floats (sysctl's 2.00 -> 2.0)
local start=null end=null
[ -n "${ST_START:-}" ] && start=$(pyf "$ST_START")
[ -n "${ST_END:-}" ] && end=$(pyf "$ST_END")
LS_JQ -nc --arg date "$(date +%Y-%m-%dT%H:%M:%S)" --arg commit "$(commit)" --arg row "$row" --argjson value "$value" \
--arg unit "$unit" --argjson detail "$detail" --argjson start "$start" --argjson end "$end" \
--argjson quiet "${ST_QUIET:-null}" --argjson others "${ST_OTHERS:-[]}" --arg harness "$harness" \
'{date: $date, commit: $commit, row: $row, value: $value, unit: $unit, detail: $detail, load: {start: $start, end: $end},
quiet: $quiet, others: $others, harness: $harness}' >> "$RESULTS"
local shown q=""
shown=$(LS_JQ -rn --argjson v "$value" 'include "lib"; if ($v | type) == "string" then $v else $v | pystr end')
if [ "${ST_QUIET:-}" != true ]; then
q=$(jq -rn --argjson o "${ST_OTHERS:-[]}" 'if ($o | length) > 0 then " (NOT QUIET: other jobs " + ($o | join(", ")) + ")" else " (NOT QUIET)" end')
fi
say "$row: $shown $unit load $( [ "$start" = null ] && echo None || pyf "$start") -> $( [ "$end" = null ] && echo None || pyf "$end")$q"
}
+87
View File
@@ -0,0 +1,87 @@
#!/bin/bash
# The rows CI's gates answer, measured on this tree and quiet (docs/lightspeed.feature): Q1, Q4, T3.
#
# bench/lightspeed/quality.sh [--only replay,timelines,audio]
#
# CI's history can be many commits old or taken on a busy machine; this runs the same gates on HEAD's build, each in its
# own turn at the lock, and reads their numbers with CI's own parser (bench/ci/record.jq):
# replay sdk/react/bench/games/replay.sh: pong and platformer played with logged input, frames against renders
# timelines sdk/react/bench/timelines/check.sh titles: render = baked play (SSIM), bake ms, incremental re-bake ms (T3)
# audio sdk/react/bench/games/audio.sh: tap = bounce, loudness and true peak, clicks (Q4)
# Q1 is the worst SSIM over replay and timelines.
. "$(dirname "$0")/lib.sh"
H=bench/lightspeed/quality.sh
REACT=$ROOT/sdk/react
only=replay,timelines,audio
while [ $# -gt 0 ]; do
case $1 in
--only) only=$2; shift ;;
*) echo "usage: bench/lightspeed/quality.sh [--only replay,timelines,audio]" >&2; exit 2 ;;
esac
shift
done
TMP=$(mktemp -d "${TMPDIR:-/tmp}/lightspeed-quality.XXXXXX")
trap 'cleanup_turn; rm -rf "$TMP"' EXIT
# gate NAME: runs it in its own turn; leaves $TMP/NAME.json ({status, numbers, lines, st: the turn's load and quiet})
gate() {
local name=$1 tmp log t0 secs status rc
tmp=$(mktemp -d "${TMPDIR:-/tmp}/lightspeed-$name-XXXXXX")
log=$tmp/$name.log
turn_begin "quality:$name"
t0=$(date +%s)
case $name in
replay) (cd "$REACT" && TMPDIR=$tmp bash bench/games/replay.sh > "$log.out" 2> "$log.err") ;;
timelines) (cd "$REACT" && TMPDIR=$tmp sh bench/timelines/check.sh titles > "$log.out" 2> "$log.err") ;;
audio) (cd "$REACT" && TMPDIR=$tmp bash bench/games/audio.sh > "$log.out" 2> "$log.err") ;;
*) echo "quality: no gate $name" >&2; turn_end; return 1 ;;
esac
rc=$?
secs=$(( $(date +%s) - t0 ))
turn_end
cat "$log.out" "$log.err" > "$log"
status=PASS; [ $rc = 0 ] || status=FAIL
CI_DATE=$(date +%Y-%m-%dT%H:%M:%S) CI_COMMIT="" CI_TIER=lightspeed \
jq -nc --arg gate "$name" --arg status $status --arg secs "$secs" --arg log "$log" --rawfile text "$log" \
-f "$ROOT/bench/ci/record.jq" > "$TMP/$name.rec"
jq -c --arg s "$ST_START" --arg e "$ST_END" --argjson q "$ST_QUIET" --argjson o "$ST_OTHERS" \
'{status, numbers: (.numbers // {}), lines: (.lines // []), st: {start: $s, end: $e, quiet: $q, others: $o}}' "$TMP/$name.rec" > "$TMP/$name.json"
say "$name: $status $(jq -r '.lines[:4] | join(" | ")' "$TMP/$name.json")"
rm -rf "$tmp"
}
# use_st NAME: the turn of gate NAME is the one a row records
use_st() {
ST_START=$(jq -r .st.start "$TMP/$1.json"); ST_END=$(jq -r .st.end "$TMP/$1.json")
ST_QUIET=$(jq -c .st.quiet "$TMP/$1.json"); ST_OTHERS=$(jq -c .st.others "$TMP/$1.json")
}
IFS=, read -r -a gates <<< "$only"
for g in "${gates[@]}"; do gate "$g" || exit 1; done
got() { [ -f "$TMP/$1.json" ]; }
if got replay || got timelines; then
# every gate run, in the order run (the detail's status lists them all)
q1=$(for g in "${gates[@]}"; do got "$g" && jq -c --arg g "$g" '{($g): .}' "$TMP/$g.json"; done | LS_JQ -sc 'include "lib"; add as $got
| [("replay", "timelines") as $g | select($got[$g]) | $got[$g].numbers | to_entries[]
| select((.value | type) == "object" and (.value | has("worst_ssim"))) | [.value.worst_ssim, "\($g):\(.key)"]] as $ss
| if ($ss | length) == 0 then null else ($ss | min) as $w
| {value: ("\($w[0] | fixed(6)) (\($w[1]))"), detail: {all: $ss, status: ($got | map_values(.status))}} end')
if [ "$q1" != null ]; then
if got replay; then use_st replay; else use_st timelines; fi
record Q1 "$(echo "$q1" | jq -c .value)" "worst SSIM, replay + timelines on HEAD" "$(echo "$q1" | jq -c .detail)" $H
fi
fi
if got timelines; then
use_st timelines
record T3 "$(LS_JQ -c 'include "lib"; "\(.numbers.titles.bake_ms | pystr) / \(.numbers.titles_edited.incremental.ms | pystr)"' "$TMP/timelines.json")" \
"ms bake / incremental re-bake (titles)" "$(jq -c '{numbers, lines}' "$TMP/timelines.json")" $H
fi
if got audio; then
use_st audio
record Q4 "$(LS_JQ -c 'include "lib"; "\(.status) (pong live \(.numbers.pong.live_lufs | pystr) / render \(.numbers.pong.render_lufs | pystr) LUFS, clicks \(.numbers.tones.live_clicks | pystr))"' "$TMP/audio.json")" \
"audio gate on HEAD" "$(jq -c '{numbers, lines}' "$TMP/audio.json")" $H
fi
exit 0
+71
View File
@@ -0,0 +1,71 @@
# One gate's result as a JSON line, with the key numbers read from its log (bench/ci.sh runs this after each gate):
# jq -nc --arg gate GATE --arg status STATUS --arg secs SECONDS --arg log LOG --rawfile text LOG|/dev/null \
# -f bench/ci/record.jq (env: CI_DATE, CI_COMMIT, CI_TIER, CI_LOAD_START, CI_LOAD_END, CI_QUIET, RETRY)
# STATUS is PASS, FAIL, FLAKY or SKIP. The numbers are whatever the gate's PASS/FAIL lines carry (frame time p99s,
# SSIMs, loudness, failing counts, test counts); "lines" keeps those lines verbatim.
# (jq's regexes are Oniguruma's Ruby syntax: ^ and $ match at every line, and . never crosses a newline.)
def num: try tonumber catch null;
def int: tonumber;
# every match's capture groups, as strings (null for a group that didn't take part)
# Python's re.M: a leading ^ and a trailing $ hold at every line
def ml: sub("^\\^"; "(?:\\A|(?<=\\n))") | sub("\\$$"; "(?=\\n|\\z)");
def groups($re): [$text | match($re | ml; "g") | [.captures[].string]];
def first_groups($re): (groups($re) | .[0]) // null;
# Python's round(x, 1): half to even on x's exact value (fma takes x * 10 - the tie without rounding)
def round1: . as $x | ($x * 10 | floor) as $f | fma($x; 10; -($f + 0.5)) as $r
| (if $r > 0 then $f + 1 elif $r < 0 then $f elif ($f % 2) == 0 then $f else $f + 1 end) / 10;
# Python's splitlines, then rstrip
([$text | splits("\r\n|[\n\r\u000b\u000c\u001c\u001d\u001e\u0085\u2028\u2029]")] | if last == "" then .[:-1] else . end | map(sub("\\s+$"; ""))) as $all
| [$all[] | select(test("\\b(PASS|FAIL|FAILED|REGRESSIONS|SKIP)\\b|^gate: |^frames: |failed \\(see|test result:"))] as $lines
| if ($gate | startswith("unit:")) or ($gate | startswith("build:")) then
([groups("test result: \\w+\\. (\\d+) passed")[] | .[0] | int] | add // 0) as $p
| ([groups("(\\d+) failed;")[] | .[0] | int] | add // 0) as $fl
| (if $p > 0 or $fl > 0 then {passed: $p, failed: $fl} else {} end)
| (groups("Finished `release` profile .* in (?:(\\d+)m )?([0-9.]+)s") | last) as $m
| if $m then .cargo_s = ((($m[0] // "0") | int) * 60 + ($m[1] | int) | round1) else . end
| {num: ., lines: $lines}
elif $gate | startswith("games") then
{num: (reduce groups("^(\\w+): (PASS|FAIL)\\s+frames (\\d+) presented, (\\d+) missed; work p99 ([0-9.]+) ms.*?; input p99 ([0-9.]+) frames.*?; rss .*?\\(max (\\d+)\\)")[] as $g
({}; .[$g[0]] = {presented: ($g[2] | int), missed: ($g[3] | int), work_p99_ms: ($g[4] | num),
input_p99_frames: ($g[5] | num), rss_max_mb: ($g[6] | int)})), lines: $lines}
elif $gate == "replay" then
{num: (reduce groups("^(PASS|FAIL) (\\w+):.*\\(worst ([0-9.]+)")[] as $g ({}; .[$g[1]] = {worst_ssim: ($g[2] | num)})), lines: $lines}
elif $gate == "audio" then
{num: ({}
| (first_groups("pong: \\w+\\s+live (-?[0-9.]+) LUFS, true peak (-?[0-9.]+) dBTP; render (-?[0-9.]+) LUFS") as $m
| if $m then .pong = {live_lufs: ($m[0] | num), live_true_peak: ($m[1] | num), render_lufs: ($m[2] | num)} else . end)
| (first_groups("tones: \\w+\\s+live clicks (\\d+) \\(render (\\d+)\\)") as $m
| if $m then .tones = {live_clicks: ($m[0] | int), render_clicks: ($m[1] | int)} else . end)), lines: $lines}
elif $gate == "tone" then
{num: (reduce groups("^(\\w+): (PASS|FAIL)\\s+bounce vs live max diff (\\S+) over ([0-9.]+) s")[] as $g
({}; .[$g[0]] = {max_diff: ($g[2] | num), seconds: ($g[3] | num)})
| (first_groups("ducking: \\w+\\s+the music under the voice (-?[0-9.]+) dB") as $m | if $m then .ducking_db = ($m[0] | num) else . end)),
lines: $lines}
elif $gate == "timelines" then
{num: (reduce ($text | match("^([\\w, ]+?): (PASS|FAIL) .*\\(worst ([0-9.]+)\\)(?:; opened and baked in (\\d+) ms)?" | ml; "g")) as $m ({};
([$m.captures[].string]) as $g
| ({worst_ssim: ($g[2] | num)}
| if $g[3] then .bake_ms = ($g[3] | int) else . end
| (first(($m.string | match("\\((\\d+) of (\\d+) frames stepped, (\\d+) ms\\)")) | [.captures[].string]) // null) as $inc
| if $inc then .incremental = {stepped: ($inc[0] | int), of: ($inc[1] | int), ms: ($inc[2] | int)} else . end) as $e
| .[$g[0] | gsub(", "; "_") | gsub(" "; "_")] = $e)), lines: $lines}
elif $gate | startswith("video") then
{num: (reduce groups("^([\\w.-]+): (PASS|FAIL)\\s+scrub p99 ([0-9.]+) ms.*?missed (\\d+) of (\\d+).*?drift max ([0-9.]+|none).*?rss max (\\d+)")[] as $g
({}; .[$g[0]] = {scrub_p99_ms: ($g[2] | num), missed: ($g[3] | int), presented: ($g[4] | int),
drift_max_ms: ($g[5] | num), rss_max_mb: ($g[6] | int)})), lines: $lines}
elif $gate == "substrate" then
{num: {failing: (first_groups("^gate: (\\d+) failing") | if . then .[0] | int else null end),
passing: ([$text | match("^PASS " | ml; "g")] | length)}, lines: $lines}
elif $gate | startswith("parity") then
([groups("^ (\\S+ @[0-9.]+s: [0-9.]+ -> [0-9.]+)$")[] | .[0]]) as $regs
| {num: (first_groups("frames: (\\d+) exact, (\\d+) ok, (\\d+) fail; cases without result: (\\d+)") as $m
| (if $m then {exact: ($m[0] | int), ok: ($m[1] | int), fail: ($m[2] | int), no_result: ($m[3] | int)} else {} end)
| .regressions = ($regs | length)),
lines: ([$lines[] | select(contains("--") | not)] + $regs[:20])}
else {num: {}, lines: $lines} end
| {date: $ENV.CI_DATE, at: (now | strftime("%Y-%m-%dT%H:%M:%SZ")), commit: $ENV.CI_COMMIT, tier: $ENV.CI_TIER,
gate: $gate, status: $status, attempt: (if ($ENV.RETRY // "") != "" then 2 else 1 end), seconds: ($secs | tonumber | round1),
load: {start: ($ENV.CI_LOAD_START | num), end: ($ENV.CI_LOAD_END | num)},
quiet: ({"true": true, "false": false}[$ENV.CI_QUIET // ""]), numbers: .num, lines: .lines[:40], log: $log}
+155
View File
@@ -0,0 +1,155 @@
# lightspeed's scoreboard (docs/lightspeed.feature, L0): every row's newest value, its target, the gap and the trend.
# bench/scoreboard.sh runs it:
# jq -nr -L bench/lightspeed --rawfile results R --rawfile ci C --argjson evals E --argjson behind B --arg json 0|1 \
# -f bench/lightspeed/scoreboard.jq
# R: ~/Library/Logs/raea/lightspeed/results.jsonl; C: ~/Library/Logs/raea/ci/history.jsonl; E: the legacy app's newest eval run (retired with apps/legacy: null)
# ({file, rows}, or null); B: {commit: commits HEAD is past it} for the CI rows' commits. Sources, newest first:
# results.jsonl the lightspeed harnesses (bench/lightspeed/*.sh): each row's newest value, marked "under load N" when
# the machine was busy, with its newest quiet value beside it (bench/ci.sh's nightly quiet pass)
# history.jsonl bench/ci.sh's gates (Q1, Q2, Q4, T3): quiet results only, marked STALE more than 10 commits behind
# HEAD; quality.sh's newer quiet run of the same gate on this tree wins
# evals the legacy app's newest eval run (Q6; retired with apps/legacy, so null)
# carried the value in lightspeed.feature, for a row no harness could measure yet (the phone locked, say),
# marked as carried
# Rows are ranked by gap weighted by how much a person feels them (feel 4, throughput 3, resources 2, quality 1); a row
# whose newest quiet value is >10% worse than the one before it is flagged REGRESSED.
include "lib";
# a JSON line a line; a line that isn't JSON is skipped
def lines: [split("\n")[] | fromjson? | select(type == "object")];
# the first number in a value's text, as a float
def num: pystr | [match("-?\\d+(?:\\.\\d+)?") | .string] | if length == 0 then null else .[0] | tonumber end;
# Python's str() of a value as the scoreboard shows it
def show: if type == "string" then . else pystr end;
def ljust($n): . + ([range([$n - length, 0] | max)] | map(" ") | join(""));
def rjust($n): ([range([$n - length, 0] | max)] | map(" ") | join("")) + .;
# row: [title, target text, target number (null: none), lower is better]; the number the gap is judged on is value($row)
def ROWS: [
["F1", "input to present p99 (offscreen; window needs consent)", "<= 1 refresh + 1 frame (25 ms at 60 Hz)", 25.0, true],
["F2", "frame work p99 / p99.9, games 120 fps", "p99.9 <= 4 ms", 4.0, true],
["F3", "missed frames, pong + platformer", "0", 0.0, true],
["F4", "scrub p99, 1080p / 4K", "<= 16.7 / 33 ms", 1.0, true],
["F5.game", "spawn to first frame: game", "< 100 ms", 100.0, true],
["F5.timeline", "spawn to first frame: timeline (bake inside)", "< 100 ms", 100.0, true],
["F5.bake", "timeline bake (titles)", "< 100 ms", 100.0, true],
["F6", "first-use hitches over 2 ms", "none", 0.0, true],
["T1", "ts1 export, warm", "<= 1 s", 1.0, true],
["T2", "3D export, 600 frames", "<= 1 s", 1.0, true],
["T3", "bake 20 s edit / incremental re-bake", "<= 50 / 10 ms", 1.0, true],
["T4", "batch renders per hour (titles)", "encoder-bound on every core", 1.0, true],
["R1", "bytes allocated a frame after warmup", "0 every layer", 0.0, true],
["R2", "GC collections during play", "0", 0.0, true],
["R4", "GPU memory per stage", "1 texture per page (~4-8 MB)", 1.0, true],
["R5", "iPhone peak footprint", "<= 200 MB", 200.0, true],
["R7", "exported game size", "<= 65 MB", 65.0, true],
["R6", "CPU watts pong / timeline", "pong halved", null, true],
["Q1", "render = play, worst SSIM", "1.000000 everywhere", 1.0, false],
["Q2", "Chrome parity exact / ok / fail", "all exact", 1.0, false],
["Q3.vmaf", "export VMAF vs lossless (ts1)", ">= 95 (mean and worst)", 95.0, false],
["Q3.colour", "colour patches after encode, worst 8-bit error", "BT.709 exact (0)", 0.0, true],
["Q4", "audio tap = bounce, LUFS, peak, clicks", "exact, -14, 0 clicks", 1.0, false],
["Q5", "Mac = iPhone, byte for byte", "byte-identical", 0.0, true],
["Q6", "agent first-try pass rate", "measured nightly; rising", 1.0, false]
];
def WEIGHT: {"F": 4, "T": 3, "R": 2, "Q": 1};
def CARRIED: {"R7": ["66.77 MB", "sdk/react/bench/games/export.sh app_MB, 9012fdc (2026-10-18)"],
"R5": ["373 MB", "sdk/react/ios probe, 4279d3f (2026-10-17)"],
"Q5": ["frame 0 exact; glyph edges <= 14/255", "sdk/react/ios probe, 4279d3f"]};
# a dict's key a Python lambda would index: missing is an error (the gap is then None)
def key($k): if type == "object" and has($k) then .[$k] else error("KeyError") end;
# the number a row's gap is judged on (an error where Python's lambda raised)
def value($row):
if $row == "F2" then (.value | show | split("/")) as $p | if ($p | length) < 2 then error("IndexError") else $p[1] | num end
elif $row == "F4" then key("detail") as $d
| [(($d.ts1 // {}).scrub_p99_ms // 0) / 16.7, (($d.k4 // {}).scrub_p99_ms // 0) / 33] | max
elif $row == "T3" then key("n") | [.[0] / 50, .[1] / 10] | max
elif $row == "T4" then key("detail") | key("cores") / ([key("scaling_vs_1"), 0.01] | max)
elif $row == "R4" then [key("detail")[] | key("graphics_mb")] | max / 8
elif $row == "Q3.vmaf" then key("detail") | key("min")
elif ($row | IN("Q1", "Q2", "Q4", "Q6")) then key("n")
else .value | num end;
def gap($row):
(ROWS[] | select(.[0] == $row)) as [$_, $title, $target, $tnum, $lower]
| (try value($row) catch null) as $v
| if $v == null or $tnum == null then null
elif $lower then (if $tnum == 0 then (if $v > 0 then 1.0 + $v else 1.0 end) else [$v / $tnum, 1.0] | max end)
elif $v != 0 then [$tnum / $v, 1.0] | max else 99.0 end;
($results | lines) as $res
# each row's newest value, quiet or under load (the user, 2026-10-18: rows are marked with their load, not held for a
# quiet machine), and its newest quiet one beside it when that's older (the nightly pass confirms them)
| (reduce $res[] as $r ({best: {}, prev: {}, quiet: {}};
(if .best[$r.row] then .prev[$r.row] = .best[$r.row] else . end)
| .best[$r.row] = $r
| if $r.quiet then .quiet[$r.row] = $r else . end)) as $s
| ($s.best | map_values(. + {src: ((.harness // "") | split("/") | last)})) as $rows0
# CI's gates: quiet results only (a gate timed on a busy machine says nothing about the code), the newest a gate
| (reduce ($ci | lines)[] as $r ({}; if $r.quiet != false then .[$r.gate] = $r else . end)) as $latest
| ({}
| ($latest.timelines) as $tl
| if $tl and (($tl.numbers // {}) | length) > 0 then
($tl.numbers.titles.bake_ms) as $bake | ($tl.numbers.titles_edited.incremental.ms) as $inc
| if $bake != null and $inc != null then
.T3 = {value: "\($bake | pystr) / \($inc | pystr)", unit: "ms (titles; CI)", n: [$bake, $inc], date: $tl.date,
commit: $tl.commit[:9], quiet: $tl.quiet, src: "ci timelines"} else . end
else . end
| ([("replay", "timelines") as $g | $latest[$g] | select(. and ((.numbers // {}) | length) > 0) as $r
| $r.numbers | to_entries[] | select((.value | type) == "object" and (.value | has("worst_ssim")))
| [.value.worst_ssim, "\($g):\(.key)", $r]]) as $ss
| if ($ss | length) > 0 then ($ss | min_by(.[0:2])) as $w
| .Q1 = {value: "\($w[0] | fixed(6)) (\($w[1]))", unit: "worst SSIM over CI's replay and timelines", n: $w[0],
date: $w[2].date, commit: $w[2].commit[:9], quiet: $w[2].quiet, src: "ci"} else . end
| ([$latest | to_entries[] | select(.key | startswith("parity:")) | .value]) as $par
| if ($par | length) > 0 then
([$par[] | .numbers.exact // 0] | add) as $e | ([$par[] | .numbers.ok // 0] | add) as $o | ([$par[] | .numbers.fail // 0] | add) as $f
| .Q2 = {value: "\($e) / \($o) / \($f)", unit: "exact / ok / fail (\([$par[].gate] | sort | join(", ")))",
n: ($e / ([$e + $o + $f, 1] | max)), date: ([$par[].date] | max), commit: $par[-1].commit[:9],
quiet: (all($par[]; .quiet)), src: "ci"} else . end
| ($latest.audio) as $a
| if $a then ($a.numbers // {}) as $n
| .Q4 = {value: "\($a.status) (pong live \($n.pong.live_lufs | pystr) / render \($n.pong.render_lufs | pystr) LUFS, clicks \($n.tones.live_clicks | pystr))",
unit: "CI audio gate", n: (if $a.status == "PASS" then 1.0 else 0.5 end), date: $a.date, commit: $a.commit[:9],
quiet: $a.quiet, src: "ci"} else . end) as $from_ci
| (if $evals == null then {} else
([$evals.rows[] | select(type == "object" and has("pass") and (.infra | not))]) as $rs
| if ($rs | length) == 0 then {} else ([$rs[] | select(.pass)] | length) as $p | ([$rs[] | .cost_usd // 0] | add) as $cost
| {Q6: {value: "\($p)/\($rs | length) pass", unit: "\($evals.file), $\($cost | fixed(2))", n: ($p / ($rs | length)),
date: "", commit: "", quiet: true, src: "legacy evals"}} end end) as $from_evals
| (reduce (($from_ci + $from_evals) | to_entries[]) as $e ($rows0;
.[$e.key] as $mine
| if $mine and $mine.quiet and (($mine.date // "") >= (($e.value.date // "")[:19])) then . # quality.sh measured it on this tree since
else ($behind[$e.value.commit // ""]) as $b
| .[$e.key] = ($e.value | if $b != null and $b > 10 then .stale = $b else . end) end)) as $rows1
| (reduce (CARRIED | to_entries[]) as $c ($rows1;
if has($c.key) then . else .[$c.key] = {value: $c.value[0], unit: "", quiet: true, src: "carried: \($c.value[1])", carried: true, date: "", commit: ""} end)) as $rows
| [ROWS[] as [$row, $title, $target] | $rows[$row] as $r
| if $r == null then {score: 0, row: $row, title: $title, value: "UNMEASURED", target: $target, gap: "", notes: ""}
else (if $r.carried then null else $r | gap($row) end) as $g
| (if $g then WEIGHT[$row[0:1]] * ($g | log2) else 0 end) as $score
| ([ (if ($r.quiet | not) and ($r.load // {}).start != null then
"under load \([$r.load.start, ($r.load.end // 0)] | max | fixed(0))",
($s.quiet[$row] | select(.) | "(quiet \(.value | show), \(.date[:10]))")
else empty end),
(if $r.carried then "CARRIED" else empty end),
(if $r.stale then "STALE (\($r.stale) commits behind HEAD)" else empty end),
(if $s.prev[$row] then ($s.prev[$row] | gap($row)) as $g0
| if $g and $g0 and $g > $g0 * 1.1 then "REGRESSED (was \($s.prev[$row].value | show))"
elif $g and $g0 and $g < $g0 / 1.1 then "improved (was \($s.prev[$row].value | show))" else empty end
else empty end) ]) as $flag
# r.get("unit", ""): a key that's there with null shows None
| ("\($r.value | show) \(if $r | has("unit") then $r.unit | show else "" end)" | sub("^\\s+"; "") | sub("\\s+$"; "")) as $val
| ("\(($r.date // "")[:16]) \(if $r | has("commit") then $r.commit | show else "" end)" | sub("^\\s+"; "") | sub("\\s+$"; "")) as $when
| {score: $score, row: $row, title: $title, value: $val, target: $target, gap: (if $g then "x\($g | fixed(1))" else "-" end),
notes: (($flag | join(" ")) + (if ($flag | length) > 0 then " " else "" end) + "[\($r.src)\(if $when != "" then " " + $when else "" end)]")}
end] as $table
| if $json == "1" then $table
else ($table | sort_by(-.score)) as $sorted
| ([$table[] | select(.value == "UNMEASURED") | .row]) as $um
| ("row" | ljust(15)) + " " + ("gap" | rjust(6)) + " " + ("score" | rjust(5)) + " " + ("value" | ljust(58)) + " target",
($sorted[] | (.row | ljust(15)) + " " + (.gap | rjust(6)) + " " + (.score | fixed(1) | rjust(5)) + " " + (.value[:58] | ljust(58)) + " " + .target,
("" | ljust(15)) + " " + ("" | rjust(6)) + " " + ("" | rjust(5)) + " " + .title + " " + .notes),
"\n\(($table | length) - ($um | length)) of \($table | length) rows have a value" + (if ($um | length) > 0 then "; unmeasured: \($um | join(", "))" else "" end)
end
+60
View File
@@ -0,0 +1,60 @@
#!/bin/bash
# F5, open to first frame (docs/lightspeed.feature; its legacy-app rows and R3 retired with apps/legacy).
#
# bench/lightspeed/startup.sh [--runs 5]
#
# Every time is measured from the moment the harness spawns the process (or sends the open) to the end of the first
# frame's present, on a quiet machine at the shared lock:
# motion open, game raea play pong --offscreen: spawn to frame 0 presented (play's first_frame_unix_ms
# less `raea ci time`'s clock just before the spawn)
# motion open, timeline the same for titles played from its bake (--baked), so the bake is inside it
# timeline bake the baked play's open_ms alone (React stepped through every frame, the bake written)
. "$(dirname "$0")/lib.sh"
H=bench/lightspeed/startup.sh
GAMES=$ROOT/sdk/react/bench/games
TIMELINES=$ROOT/sdk/react/bench/timelines
runs=5
while [ $# -gt 0 ]; do
case $1 in
--runs) runs=$2; shift ;;
*) echo "usage: bench/lightspeed/startup.sh [--runs N]" >&2; exit 2 ;;
esac
shift
done
TMP=$(mktemp -d "${TMPDIR:-/tmp}/lightspeed-startup.XXXXXX")
trap 'cleanup_turn; rm -rf "$TMP"' EXIT
# motion_first_frame EDIT BAKED: prints "first_ms open_ms"
motion_first_frame() {
local edit=$1 baked=$2 out=$TMP/play.json clock=$TMP/clock.json
rm -f "$out"
local extra=""
[ "$baked" = 1 ] && extra=--baked
RAEA_AUDIO_MUTE=1 "$MOTION" ci time --to "$clock" -- "$MOTION" play "$edit" $extra --offscreen --size 1280x720 --seconds 0.5 \
--json "$out" > "$TMP/play.log" 2> "$TMP/play.err"
if [ $? != 0 ] || [ ! -f "$out" ]; then
say_tail "$edit: play failed: " 400 "$TMP/play.err" >&2; exit 1
fi
jq -r --slurpfile c "$clock" 'if .first_frame_unix_ms then "\(.first_frame_unix_ms - $c[0].start_unix_ms) \(.open_ms)"
else "none" end' "$out" | { read -r a b; [ "$a" = none ] && { echo "raea has no first_frame_unix_ms: rebuild it" >&2; exit 1; }; echo "$a $b"; } || exit 1
}
# summary: {"p50", "max", "runs"} of the numbers on stdin, one a line
summary() { LS_JQ -sc 'include "lib"; {p50: (pct(0.5) | pyround(1)), max: (max | pyround(1)), runs: map(pyround(1))}'; }
pong=$GAMES/pong/edit.tsx; titles=$TIMELINES/titles/edit.tsx
r=$(motion_first_frame "$pong" 0) || exit 1 # warm the file cache and the shader cache: F5 is the warm open
: > "$TMP/game"; : > "$TMP/tl"
turn_begin startup:motion
for _ in $(seq 1 "$runs"); do r=$(motion_first_frame "$pong" 0) || exit 1; echo "${r% *}" >> "$TMP/game"; done
for _ in $(seq 1 "$runs"); do r=$(motion_first_frame "$titles" 1) || exit 1; echo "$r" >> "$TMP/tl"; done
turn_end
game=$(summary < "$TMP/game")
tl=$(awk '{print $1}' "$TMP/tl" | summary)
bake=$(awk '{print $2}' "$TMP/tl" | summary)
p50() { LS_JQ -r 'include "lib"; .p50 | pyf'; }
record F5.game "$(echo "$game" | p50)" ms "$game" $H
record F5.timeline "$(echo "$tl" | p50)" ms "$tl" $H
record F5.bake "$(echo "$bake" | p50)" ms "$bake" $H
+30
View File
@@ -0,0 +1,30 @@
// T3D600: a lit cube turning under moving text, 1080x1920 at 30 fps for 600 frames, lightspeed T2's 3D export
// fixture (bench/lightspeed/export.sh); the 60-frame t3d it grew from is the same scene
import { AbsoluteFill, Composition, registerRoot, useCurrentFrame } from "raea";
import { StandardMaterial } from "raea/pbr";
import { Cuboid, Mesh3d } from "raea/mesh";
import { Quat, Transform } from "raea/transform";
import { AmbientLight, DirectionalLight } from "raea/light";
import { Camera3d } from "raea/camera";
function Edit() {
const f = useCurrentFrame();
return (
<AbsoluteFill style={{ background: "#202040" }}>
<div style={{ position: "absolute", left: 0, top: 0, width: 1080, height: 1920 }}>
<>
<Camera3d transform={Transform.fromXyz(0, 0, 6).lookingAt([0, 0, 0])} projection={{ Perspective: { fov: 0.872664625997165 } }} />
<AmbientLight brightness={160} />
<DirectionalLight transform={Transform.fromXyz(2, 3, 4).lookingAt([0, 0, 0])} illuminance={24000} shadow_maps_enabled />
<Mesh3d transform={Transform.fromXyz(0, 0, 0).withRotation(Quat.fromEuler("XYZ", f * 0.05, f * 0.08, 0))}>
<Cuboid half_size={[1, 1, 1]} />
<StandardMaterial base_color="#e05030" />
</Mesh3d>
</>
</div>
<div style={{ position: "absolute", left: 100, top: 300 + (f % 300) * 4, fontSize: 120, color: "white", fontFamily: "Helvetica" }}>Hello {f}</div>
</AbsoluteFill>
);
}
registerRoot(() => <Composition id="t3d600" component={Edit} width={1080} height={1920} fps={30} durationInFrames={600} />);
+1
View File
@@ -0,0 +1 @@
{"binary":"~/Library/Caches/raea/p26-baseline/bin/raea-motion","sha256":"db30cf97dca8f78486df47c6fb042372ecb4d920d577227d14eb3aea35dc581c","head":"8b812636","date":"2026-10-23T00:43:53Z","dylib_sha256":"cd2ef7c1f26ad10be8d76744520b9ada98f8b7738370c53537e8eaf100351623","dylib_note":"rebuilt 10-22 with the run bundler fixes (exports subpaths, media imports); it resolves imports only, the first capture used libraea_bundle.capture1.dylib"}
+106
View File
@@ -0,0 +1,106 @@
#!/bin/bash
# P26's baseline (docs/ts-native.feature P26): frames of every composition in list.txt rendered by the Blitz page, the
# reference the bevy_ui page must match (SSIM >= 0.98 per frame, fonts and brand styles included).
#
# bench/p26-baseline/capture.sh [RAEA_BIN] (default: the Blitz build kept at
# ~/Library/Caches/raea/p26-baseline/bin, P26_STORE to move it)
#
# For each composition: its length probed (getCompositions, through `raea run`), nine frames rendered with
# --manifest (0 to the last, evenly), and four kept: the first, the middle, the last and the one with the most text in
# its manifest (a composition whose length couldn't be probed is taken as 60 frames: probed false). Kept under $P26_STORE/frames/<slug>/<frame>.png (not in git: the frames are 89 MB; each one's sha256 is in the manifest), each listed in
# manifest.jsonl with the composition, frame, why it was kept, the PNG's sha256 and the binary's. Failures go to failures.txt.
# ONLY=substring limits the list (LIST=file takes the compositions from a file instead): the other compositions'
# entries in manifest.jsonl and failures.txt are kept and the listed ones replaced. Runs one render at a time (the GPU
# is shared). A composition's props, if it takes any, come from props/<slug>/wrap.tsx, a wrapper giving it its documented example props.
set -uo pipefail
HERE=$(cd "$(dirname "$0")" && pwd)
. "$HERE/lib.sh"
ROOT=$(cd "$HERE/../.." && pwd)
# the baseline's home outside the checkout and /tmp (Blitz is deleted at P27, so it can't be made again): the Blitz
# binary and its libraea_bundle.dylib under bin/, the frames under frames/
STORE=${P26_STORE:-$HOME/Library/Caches/raea/p26-baseline}
BIN=${1:-$STORE/bin/raea-motion}
[ -x "$BIN" ] || { echo "capture.sh: no raea at $BIN" >&2; exit 2; }
SHA=$(shasum -a 256 "$BIN" | cut -d' ' -f1)
BIN_SHOWN="~${BIN#"$HOME"}"; [ "${BIN#"$HOME"}" = "$BIN" ] && BIN_SHOWN=$BIN
OUT=$STORE/frames
WORK=$(mktemp -d "${TMPDIR:-/tmp}/p26-baseline.XXXXXX")
trap 'rm -rf "$WORK"' EXIT
mkdir -p "$OUT"
LIST=${LIST:-$HERE/list.txt}
touch "$HERE/manifest.jsonl" "$HERE/failures.txt"
# the compositions this run takes, and the earlier entries kept (everything else's)
picked=$(grep -v '^$' "$LIST" | { [ -n "${ONLY:-}" ] && grep -F -- "$ONLY" || cat; })
if [ -z "${ONLY:-}" ] && [ "$LIST" = "$HERE/list.txt" ]; then
: > "$HERE/manifest.jsonl"; : > "$HERE/failures.txt"
else
for f in manifest.jsonl failures.txt; do
while read -r rel; do
[ -n "$rel" ] || continue
rel=${rel%% #*}; rel=${rel%% @*}
grep -v -F -- "\"composition\":\"$rel\"" "$HERE/$f" | grep -v -F -- "$rel:" > "$WORK/keep" || true
cat "$WORK/keep" > "$HERE/$f"
done <<< "$picked"
done
while read -r rel; do rel=${rel%% #*}; rel=${rel%% @*}; slug=$(echo "$rel" | sed 's#/#__#g; s#\.tsx#@#; s#@$##; s#@\##@#'); [ -n "$rel" ] && rm -rf "$OUT/$slug"; done <<< "$picked"
fi
[ -f "$HERE/binary.json" ] && [ -n "${ONLY:-}${LIST#$HERE/list.txt}" ] || echo "{\"binary\":\"$BIN_SHOWN\",\"sha256\":\"$SHA\",\"dylib_sha256\":\"$(shasum -a 256 "$(dirname "$BIN")/libraea_bundle.dylib" 2>/dev/null | cut -d' ' -f1)\",\"head\":\"$(git -C "$ROOT" rev-parse --short HEAD)\",\"date\":\"$(date -u +%FT%TZ)\"}" > "$HERE/binary.json"
n=0
while read -r rel; do
[ -z "$rel" ] && continue
# list.txt's "path # excluded: why": listed in failures.txt with its reason, not rendered
if [[ "$rel" == *"# excluded:"* ]]; then
echo "${rel%% #*}: EXCLUDED ${rel##*# excluded: }" >> "$HERE/failures.txt"
echo "skip ${rel%% #*}"
continue
fi
# "path @A,B,C": frames to keep besides the four (a screen's picture, a cut's busiest moment)
asked=""
if [[ "$rel" == *" @"* ]]; then asked=${rel##* @}; rel=${rel%% @*}; fi
p26_src "$rel"
# its length: the first registered composition's, else its `config`, else the CLI's default (60 frames)
cat > "$WORK/probe.ts" <<EOF
import * as M from "$src";
import { getCompositions } from "raea";
import { native } from "raea/native";
export default function () {
const c: any = getCompositions().find((x: any) => "$comp" === "" || x.id === "$comp") ?? null;
const cfg: any = (M as any).config ?? {};
native("print" as never, { text: "P26PROBE " + JSON.stringify({ id: c?.id ?? null, frames: c?.durationInFrames ?? cfg.durationInFrames ?? 60 }) } as never);
}
EOF
probe=$(cd "$dir" && "$BIN" run "$WORK/probe.ts" 2>&1 | grep -o 'P26PROBE .*' | head -1 | cut -d' ' -f2-)
total=$(echo "$probe" | jq -r '.frames // 60' 2>/dev/null)
# unprobed: the script bundler couldn't take it (a subpath only the render bundler has); its length is the default
probed=$([ -n "$probe" ] && echo true || echo false)
[[ "$total" =~ ^[0-9]+$ ]] || total=60
[ "$total" -lt 1 ] && total=1
last=$((total - 1))
cands=$({ for i in 0 1 2 3 4 5 6 7 8; do echo $((last * i / 8)); done; echo "$asked" | tr ',' '\n' | grep . | awk -v l=$last '$1 <= l'; } | sort -n | awk '!seen[$0]++' | paste -sd, -)
rm -rf "$WORK/r" && mkdir -p "$WORK/r"
if ! (cd "$dir" && "$BIN" render "$src" ${copt[@]+"${copt[@]}"} --at "$cands" -o "$WORK/r/" --manifest "$WORK/r/m.json") > "$WORK/log" 2>&1; then
echo "$rel: $(grep -E 'REFUSED|error|Error' "$WORK/log" | head -2 | tr '\n' ' ')" >> "$HERE/failures.txt"
echo "MISS $rel"
continue
fi
# the frame with the most text (its manifest's words), among the candidates
texty=$(jq -r '[.frames[] | {f: .frame, n: ([.text[]?.text | length] | add // 0)}] | max_by(.n) | .f' "$WORK/r/m.json" 2>/dev/null)
mid=$(echo "$cands" | tr ',' '\n' | sed -n 5p)
IFS=, read -ra list <<< "$cands"
mkdir -p "$OUT/$slug"
for keep in "0:first" "$mid:middle" "$last:last" "$texty:text" $(echo "$asked" | tr ',' '\n' | grep . | sed 's/$/:asked/'); do
f=${keep%%:*}; why=${keep##*:}
[ -z "$f" ] || [ "$f" = "null" ] && continue
[ -f "$OUT/$slug/$f.png" ] && continue
idx=-1
for i in "${!list[@]}"; do [ "${list[$i]}" = "$f" ] && idx=$i; done
[ $idx -lt 0 ] && continue
png=$(printf "%s/r/frame-%05d.png" "$WORK" "$idx")
[ -f "$png" ] || continue
cp "$png" "$OUT/$slug/$f.png"
echo "{\"composition\":\"$rel\",\"id\":$(echo "$probe" | jq -c '.id' 2>/dev/null | grep . || echo null),\"frame\":$f,\"why\":\"$why\",\"frames\":$total,\"cands\":\"$cands\",\"probed\":$probed,\"file\":\"frames/$slug/$f.png\",\"png_sha256\":\"$(shasum -a 256 "$OUT/$slug/$f.png" | cut -d' ' -f1)\",\"sha256\":\"$SHA\",\"binary\":\"$BIN_SHOWN\",\"page\":\"${RAEA_PAGE:-}\"}" >> "$HERE/manifest.jsonl"
n=$((n + 1))
done
echo "ok $rel ($total frames)"
done <<< "$picked"
echo "P26 baseline: $n frames, $(wc -l < "$HERE/failures.txt" | tr -d ' ') compositions failed (failures.txt)"
+94
View File
@@ -0,0 +1,94 @@
#!/bin/bash
# P26's gate (docs/ts-native.feature P26a): each baseline frame (manifest.jsonl, the last Blitz build's) rendered again
# by raea on the Blitz page (the only page since B5d; P26_PAGE names it in results.jsonl,
# docs/blitz-bevy.feature B2b) and compared, SSIM >= 0.98 a frame.
#
# bench/p26-baseline/compare.sh [RAEA_BIN] (default: target/release/raea)
#
# The frames go to $P26_STORE/bevy/frames/<slug>/<frame>.png beside the baseline's ($P26_STORE: ~/Library/Caches/raea/
# p26-baseline), each frame's SSIM (ffmpeg's, over RGB) to $P26_STORE/bevy/results.jsonl; a composition that didn't
# render is a failure of all its frames. ONLY=substring limits the compositions. MIN=0.98 is the bar. Prints the pass
# rate and the worst frames, and exits 1 when any frame is under the bar (CI's p26 gate reads the exit). One render at
# a time (the GPU is shared).
#
# The floor (10-26, one binary, each row rendered twice): rows repeat at SSIM >= 0.99998 run to run. Most are
# byte-identical or 1/255 apart; look/town and kitchen/wreck differ in about 200 pixels, on house-kit's siding, where
# the outside and inside skins have coincident faces and which one draws on top follows Bevy's draw order for equal
# depths, likely the asset-load order (spawning the models' scenes in a fixed order didn't change it). Coincident faces
# z-fight in any engine: whoever next touches those houses, offset the inner skin.
set -uo pipefail
HERE=$(cd "$(dirname "$0")" && pwd)
. "$HERE/lib.sh"
# pixel checks: no Content Credentials or TrustMark id in the frames (a still's mark changes its pixels each run)
export RAEA_SIGN=0 RAEA_MARK=0
ROOT=$(cd "$HERE/../.." && pwd)
STORE=${P26_STORE:-$HOME/Library/Caches/raea/p26-baseline}
BIN=${1:-$ROOT/target/release/raea}
MIN=${MIN:-0.98}
# a composition whose baseline came from a plugin build (raea-bevy-sdk: hanabi, avian) renders with one: P26_PLUGIN_BIN
# (default sdk/raea/bench/bevy-plugins/motion.sh; it must take `render` as raea does)
PLUGIN_BIN=${P26_PLUGIN_BIN:-$ROOT/sdk/raea/bench/bevy-plugins/motion.sh}
[ -x "$BIN" ] || { echo "compare.sh: no raea at $BIN" >&2; exit 2; }
[ -d "$STORE/frames" ] || { echo "compare.sh: no baseline frames at $STORE/frames" >&2; exit 2; }
# P26_OUT: where this run writes (its frames and results.jsonl), so two runs at once don't write over each other
PAGE=${P26_PAGE:-blitz}
OUT=${P26_OUT:-$STORE/$PAGE}
WORK=$(mktemp -d "${TMPDIR:-/tmp}/p26-compare.XXXXXX")
trap 'rm -rf "$WORK"' EXIT
# the run's own copy of raea (and its bundle library): a rebuild of target/release while it runs doesn't mix two
# binaries into one run's rows
mkdir -p "$WORK/bin" && cp "$BIN" "$WORK/bin/raea" || exit 2
[ -f "$(dirname "$BIN")/libraea_bundle.dylib" ] && cp "$(dirname "$BIN")/libraea_bundle.dylib" "$WORK/bin/"
BIN=$WORK/bin/raea
mkdir -p "$OUT/frames" "$OUT/logs"
RES=$OUT/results.jsonl
: > "$RES"
for rel in $(jq -r '.composition' "$HERE/manifest.jsonl" | awk '!seen[$0]++'); do
[ -n "${ONLY:-}" ] && [[ "$rel" != *"$ONLY"* ]] && continue
p26_src "$rel"
bin=$BIN
jq -r --arg c "$rel" 'select(.composition == $c) | .binary' "$HERE/manifest.jsonl" | grep -qE 'bevy-plugins|bin-avian' && bin=$PLUGIN_BIN
frames=$(jq -r --arg c "$rel" 'select(.composition == $c) | .frame' "$HERE/manifest.jsonl" | sort -n | paste -sd, -)
# rendered at the same nine frames the baseline's render took (capture.sh): a render's 3D rows are keyed by the
# frames it samples, so the kept frames alone would draw another animation (a box springing from scale 0 at frame 0
# was still at 0 at frame 59 when only those two were sampled, in Blitz as here)
total=$(jq -r --arg c "$rel" 'select(.composition == $c) | .frames' "$HERE/manifest.jsonl" | head -1)
last=$((total - 1))
cands=$(jq -r --arg c "$rel" 'select(.composition == $c) | .cands // empty' "$HERE/manifest.jsonl" | head -1)
[ -n "$cands" ] || cands=$(for i in 0 1 2 3 4 5 6 7 8; do echo $((last * i / 8)); done | awk '!seen[$0]++' | paste -sd, -)
rm -rf "$WORK/r" && mkdir -p "$WORK/r" "$OUT/frames/$slug"
# each row's render log kept at $OUT/logs/<slug>.log (a frame that came out black and was redrawn says so there)
if ! (cd "$dir" && RAEA_PAGE=$PAGE "$bin" render "$src" ${copt[@]+"${copt[@]}"} --at "$cands" -o "$WORK/r/") > "$WORK/log" 2>&1; then
cp "$WORK/log" "$OUT/logs/$slug.log"
why=$(grep -E 'REFUSED|error|Error|panicked' "$WORK/log" | head -1 | cut -c1-300)
for f in ${frames//,/ }; do
jq -nc --arg c "$rel" --argjson f "$f" --arg why "$why" '{composition: $c, frame: $f, ssim: null, pass: false, why: $why}' >> "$RES"
done
echo "MISS $rel: $why"
continue
fi
cp "$WORK/log" "$OUT/logs/$slug.log"
IFS=, read -ra list <<< "$cands"
for f in ${frames//,/ }; do
idx=-1
for i in "${!list[@]}"; do [ "${list[$i]}" = "$f" ] && idx=$i; done
got=$(printf "%s/r/frame-%05d.png" "$WORK" "$idx")
ref=$STORE/frames/$slug/$f.png
if [ ! -f "$got" ]; then
jq -nc --arg c "$rel" --argjson f "$f" '{composition: $c, frame: $f, ssim: null, pass: false, why: "no frame came out"}' >> "$RES"
continue
fi
cp "$got" "$OUT/frames/$slug/$f.png"
s=$(ffmpeg -hide_banner -nostats -i "$ref" -i "$got" -lavfi "[0:v]format=rgb24[a];[1:v]format=rgb24[b];[a][b]ssim" -f null - 2>&1 | grep -o 'All:[0-9.]*' | cut -d: -f2)
[ -n "$s" ] || s=0
pass=$(awk -v s="$s" -v m="$MIN" 'BEGIN { print (s >= m) ? "true" : "false" }')
jq -nc --arg c "$rel" --argjson f "$f" --argjson s "$s" --argjson p "$pass" '{composition: $c, frame: $f, ssim: $s, pass: $p}' >> "$RES"
done
echo "ok $rel"
done
n=$(wc -l < "$RES" | tr -d ' ')
ok=$(jq -s '[.[] | select(.pass)] | length' "$RES")
echo "P26: $ok of $n frames at SSIM >= $MIN ($(jq -s '[.[] | .composition] | unique | length' "$RES") compositions)"
echo "worst:"
jq -s -r 'sort_by(.ssim // -1) | .[:15][] | " \(.ssim // "none") \(.composition) @\(.frame)\(if .why then " " + .why else "" end)"' "$RES"
[ "$ok" = "$n" ]
+1
View File
@@ -0,0 +1 @@
examples/games/animated-character.tsx: EXCLUDED a 3D game (no page) whose model, media/RobotExpressive.glb, is not in the checkout; P26 is the page
Loaded 100 of 654 files, more files were not shown because too many files have changed in this diff. Show more