Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
docs: correct the recorded-line claim, weaving users, and roadmap his…
…tory

recorded_line has no caller outside its tests. The weaving trace lists
the Cargo consumers on 1e275a9. The in-progress lint rejects extra
issue numbers. Roadmap rows 1.54 through 1.59 are in the history table.

Co-authored-by: Andrew Brown <lazyxeon@users.noreply.github.com>
  • Loading branch information
cursoragent and lazyxeon committed Oct 16, 2026
commit b4b7841f5bfb9f7535fc60e2958593c2e66e884a
2 changes: 1 addition & 1 deletion CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co

## Project Overview

AstraWeave is a **scientific proof of concept**: an AI-native game engine built **iteratively by AI with zero human-written code**. It uses a deterministic ECS architecture where AI agents are first-class citizens. The player-facing game name is Aravath. The workspace contains 141 crates (`cargo metadata --no-deps` at `a10780f4`, 2026-10-16; 58 names start with `astraweave-`, 60 example manifests). #215 did not add a member. #316 caps image decode and confines CLI glTF imports; Ollama constructors stay on loopback unless `allowing_remote` is used. #318 keeps physics and nav proxies off the gameplay script tick. #252 puts the data-driven weaving framework on main. #205 puts the windowed Aravath greybox on main (`aravath_greybox`). #244 puts the 60 Hz traversal sim on main. #215 puts integer forest columns and `ColumnStream` on main. #217 puts the CI burndown on main: `libudev-dev` on the editor-test and sanitizer jobs, per-process audio fixtures, and a finite SPH step in `fluid.wgsl`. `openssl` is gone from the lockfile and stays banned. #327 keeps `net` off the workspace `tokio` dependency. #275 sends a connecting greybox sword hit through `run_aravath_slice`, and the window shows `Cover broke` when the cover bond breaks. #329 calls `BridgeAgent::step` from `Greybox::step`, digs with a sphere `Subtract` brush on `ColumnFns`, and sets the greybox golden to `0a576578512f25d2`. #331 keeps `AIArbiter`, `GoapPlanner`, and `GravityManager` off the deterministic tick. `recorded_line` is the dialogue boundary and does not draw. Deletion follow-ups are #334, #335, and #336. The July 2026 note of 133 members is older. Rust toolchain is pinned at 1.89.0. Determinism replay requires fifteen cross-OS cases (`planner_pure`, `perception_world`, `gameplay_rng`, `fixed64`, `combat_resolve`, `destruction`, `gameplay_qa_aravath_slice`, `nav_reroute`, `causal_bridge`, `scripted_system`, `weaving`, `traversal`, `traversal_deformed`, `worldgen_columns`, `deformed_chunk`). Local fluid sim #253 and render frame budget #216 are in progress and are not on this commit.
AstraWeave is a **scientific proof of concept**: an AI-native game engine built **iteratively by AI with zero human-written code**. It uses a deterministic ECS architecture where AI agents are first-class citizens. The player-facing game name is Aravath. The workspace contains 141 crates (`cargo metadata --no-deps` at `a10780f4`, 2026-10-16; 58 names start with `astraweave-`, 60 example manifests). #215 did not add a member. #316 caps image decode and confines CLI glTF imports; Ollama constructors stay on loopback unless `allowing_remote` is used. #318 keeps physics and nav proxies off the gameplay script tick. #252 puts the data-driven weaving framework on main. #205 puts the windowed Aravath greybox on main (`aravath_greybox`). #244 puts the 60 Hz traversal sim on main. #215 puts integer forest columns and `ColumnStream` on main. #217 puts the CI burndown on main: `libudev-dev` on the editor-test and sanitizer jobs, per-process audio fixtures, and a finite SPH step in `fluid.wgsl`. `openssl` is gone from the lockfile and stays banned. #327 keeps `net` off the workspace `tokio` dependency. #275 sends a connecting greybox sword hit through `run_aravath_slice`, and the window shows `Cover broke` when the cover bond breaks. #329 calls `BridgeAgent::step` from `Greybox::step`, digs with a sphere `Subtract` brush on `ColumnFns`, and sets the greybox golden to `0a576578512f25d2`. #331 keeps `AIArbiter`, `GoapPlanner`, and `GravityManager` off the deterministic tick. `recorded_line` is a pure helper intended as the dialogue boundary. It does not draw, and it has no non-test caller yet. Deletion follow-ups are #334, #335, and #336. The July 2026 note of 133 members is older. Rust toolchain is pinned at 1.89.0. Determinism replay requires fifteen cross-OS cases (`planner_pure`, `perception_world`, `gameplay_rng`, `fixed64`, `combat_resolve`, `destruction`, `gameplay_qa_aravath_slice`, `nav_reroute`, `causal_bridge`, `scripted_system`, `weaving`, `traversal`, `traversal_deformed`, `worldgen_columns`, `deformed_chunk`). Local fluid sim #253 and render frame budget #216 are in progress and are not on this commit.

### Mandate

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ Checked against `main` at `84d3888a`. Numbers that were not re-measured in this
| **Toolchain** | Rust **1.89.0**, pinned in `rust-toolchain.toml`. Targets: Linux x86_64, Windows MSVC, macOS x86_64 and Apple Silicon. |
| **CI platforms** | Pull-request replay hashes run on `ubuntu-latest`, `windows-latest`, and `macos-latest`. That is the supported cross-OS determinism matrix. It is not a claim that every example window has been run on all three. |
| **Determinism** | Fifteen required replay cases, including `traversal`, `traversal_deformed`, `worldgen_columns`, and `deformed_chunk`. The compare job fails if any case is missing or its SHA-256 differs across the three OS artifacts. See [Determinism](#determinism). |
| **AI rule** | Local LLMs propose. The deterministic simulation validates and executes. `AIArbiter` stays behind `llm_orchestrator` (default off) and is not on `sys_ai_planning` or `sys_spatial_tick`. `GoapPlanner` and `GravityManager` stay off that tick too (#331). `recorded_line` is the dialogue boundary and does not draw. The orchestrator default, when `OLLAMA_MODEL` is unset, is `phi3:medium` (`astraweave-ai`). The Qwen client constant is `qwen3.5:4b`. Ollama constructors keep a loopback URL. A non-loopback URL is replaced with `http://127.0.0.1:11434` unless the caller uses `allowing_remote` (#316). |
| **AI rule** | Local LLMs propose. The deterministic simulation validates and executes. `AIArbiter` stays behind `llm_orchestrator` (default off) and is not on `sys_ai_planning` or `sys_spatial_tick`. `GoapPlanner` and `GravityManager` stay off that tick too (#331). `recorded_line` is a pure helper intended as the dialogue boundary. It does not draw, and it is not wired in yet: the only callers are its own tests. The orchestrator default, when `OLLAMA_MODEL` is unset, is `phi3:medium` (`astraweave-ai`). The Qwen client constant is `qwen3.5:4b`. Ollama constructors keep a loopback URL. A non-loopback URL is replaced with `http://127.0.0.1:11434` unless the caller uses `allowing_remote` (#316). |
| **Assets** | The project rule is **CC0 only**. `assets/README.md` still says "Mixed" and this pass did not re-audit every file's license. |
| **Frame time** | The target is under 11 ms per frame on a GTX 1660 Ti-class GPU. It is not yet measured on that hardware: the GPU timer read 0 ms, and the readback is in progress in #216. Do not treat the older CPU `profiling_demo` times as this measurement. |
| **Coverage and Miri** | Whole-workspace line coverage **57.35%** was measured 2026-06-29 and has not been re-run on the 141-member tree. Miri **1,059** tests, 0 UB, was measured 2026-06-27 across ecs, math, core, and sdk. The February 2026 report records an older, smaller run. Kani proof attributes were **69** on 2026-06-13 and were not re-counted here. |
Expand All @@ -62,7 +62,7 @@ Checked against `main` at `84d3888a`. Numbers that were not re-measured in this
- **Greybox tokio graph (#327).** The workspace `tokio` features are `fs`, `io-util`, `macros`, `rt`, `rt-multi-thread`, `sync`, and `time`. `astraweave-net`, `astraweave-ipc`, and `astraweave-net-ecs` add `net`. `astraweave-blend` adds `process`. `aw_asset_cli` does not depend on tokio. #326 is closed.
- **Greybox combat slice (#275).** `Combat::tick` calls `astraweave_weaving::run_aravath_slice` on a connecting sword hit. The foe loses `40 - sword_hp`. `cover_intact == false` sets `cover_broken`, and the window shows `Cover broke` for 2.5 seconds, once.
- **Greybox showcase (#329).** `ColumnFns` binds `column_gen::surface_height` and the seed material. `FlatColumnBase` stays the unbound terrain, so the required `destruction` replay case is unchanged. The Linux-and-Windows golden moved from `b663da52ea1d566e` to `0a576578512f25d2` because the scripted dig and the bridge route are in the hash. #261, #250, and #249 are still open on the tracker.
- **Off-tick models, GOAP, and gravity (#331).** `llm_dialogue` compiles as a module. `recorded_line` returns a recorded string, or `scripted:` plus the prompt, and does not draw `SimRng`. `sys_ai_planning` and `sys_spatial_tick` do not name `AIArbiter`, `GoapPlanner`, or `LlmDialogueSystem::generate_response`. `PhysicsWorld::step` does not read `GravityManager`. The types remain: `AIArbiter` behind `llm_orchestrator`, `GoapPlanner` in `astraweave-behavior`, and `gravity.rs`. Deletion follow-ups are #334, #335, and #336. #225, #257, #258, and #259 stay open as the off-tick records. No new required replay case.
- **Off-tick models, GOAP, and gravity (#331).** `llm_dialogue` compiles as a module. `recorded_line` returns a recorded string, or `scripted:` plus the prompt, and does not draw `SimRng`. Nothing outside its tests calls it yet. `sys_ai_planning` and `sys_spatial_tick` do not name `AIArbiter`, `GoapPlanner`, or `LlmDialogueSystem::generate_response`. `PhysicsWorld::step` does not read `GravityManager`. The types remain: `AIArbiter` behind `llm_orchestrator`, `GoapPlanner` in `astraweave-behavior`, and `gravity.rs`. Deletion follow-ups are #334, #335, and #336. #225, #257, #258, and #259 stay open as the off-tick records. No new required replay case.
- **Terrain columns and scatter (#215).** `column_gen` is the integer forest record. Height, material, and a prop are functions of `(FOREST_WORLD_SEED, x, z)` with wrapping integer arithmetic. Species and yaw come from `SimRng` on `SIM_SYSTEM_FOREST_SCATTER`. The road stays empty. `worldgen_columns` is the SHA-256 of `worldgen_record()`: three chunks, including a negative coordinate and a road chunk. `deformed_chunk` is the SHA-256 of a sphere brush and one scatter detach on chunk `(-1, 2)`, then the occupancy after that chunk is evicted and loaded again. A `Detach` stays down across that reload. `ColumnStream` is the greybox keep set. The window still fills those chunks from the island heightfield, and its props still come from `aravath_runtime`'s local scatter. The editor climate mesh is the preview. Scene save and the Aravath checkpoint store `worldgen_record()`. Apply Erosion appends destruction commands and leaves that record in place. The CC0 pine-forest files, including Poly Haven `pine_tree_01`, are hashed in `assets/terrain/polyhaven/pine_forest/manifest.json`. KayKit and Kenney stay the greybox props.

## In progress
Expand Down
16 changes: 8 additions & 8 deletions docs/architecture/ai_pipeline.md

Large diffs are not rendered by default.

23 changes: 15 additions & 8 deletions docs/architecture/weaving.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ lifecycle_status: active
integration_status: partial
summary: "weave_tick is on main (#252). The greybox sword hit calls run_aravath_slice (#275). Required replay case weaving hashes NullField until local sim #253."
owns: [astraweave-weaving]
doc_version: "1.6"
last_verified_commit: d6903d3a
doc_version: "1.7"
last_verified_commit: 1e275a9e
---

# Architecture Trace: Weaving / Fate-Weaving System (`astraweave-weaving`)
Expand All @@ -21,8 +21,8 @@ last_verified_commit: d6903d3a
|---|---|
| **System name** | Weaving / Fate-Weaving System (the Veilweaver signature mechanic) |
| **Primary crates** | `astraweave-weaving` |
| **Document version** | 1.6 |
| **Last verified against commit** | `d6903d3a` |
| **Document version** | 1.7 |
| **Last verified against commit** | `1e275a9e` |
| **Last verified date** | 2026-10-16 |
| **Status** | The data-driven cast path is on main (#252). A connecting greybox sword hit calls `run_aravath_slice` (#275). Required replay case `weaving`. `NullField` stands in for the local sim (#253). Anchor-slice helpers are still plain functions. |
| **Owner notes** | Built during the Veilweaver vertical-slice "Weeks 1-5" campaign (see `docs/journey/weeks/WEEK_*` and `docs/archive/projects/veilweaver/`). Naming is heavily overloaded across three independent "weaving" surfaces in the workspace — see §3 and §6. |
Expand Down Expand Up @@ -215,6 +215,12 @@ This crate hosts **two distinct pipelines** that do not call each other. Both ar

| Consumer system | Interface | Data | Notes |
|---|---|---|---|
| `aravath_runtime` | `Combat::tick` | `run_aravath_slice` | Connecting sword hit (#275). |
| `astraweave-gameplay` | `src/weaving.rs` | `compile_legacy`, `LegacyPoints` | Legacy weave bridge. |
| `astraweave-scripting` | `src/sim_mod.rs` | `queue_weave`, `parse_template_toml`, `WeaveScratch` | Mod host enqueue. |
| `astraweave-security` | `src/sandbox.rs` | `parse_template_toml` | Template parse inside the sandbox. |
| `astraweave-core` | `tests/replay_hash.rs` | `weaving_case_bytes` | Required replay row `weaving`. The dependency is a normal Cargo dep; production `src/` does not call the crate. |
| `examples/aravath_weave` | `src/main.rs` | `queue_weave`, `weave_tick`, `NullField` | Headless stamp demo. |
| `examples/advanced_content_demo` | `use astraweave_weaving::*;` (`main.rs:1`) | `Quest`, `QuestReward`, `QuestState`, `quest_types::*` | Demonstrates 5 quest scenarios (escort/defend/timetrial/boss/collect). Non-runtime example. |
| `examples/veilweaver_quest_demo` | `use astraweave_weaving::VeilweaverLevel;` (`main.rs:11`) | `VeilweaverLevel`, anchor repair, quest chain | Console walkthrough of the anchor/Echo/quest slice. Non-runtime example. |
| (intended) external renderer | `ui/*`, `particles/*` data structs | HUD state, feedback floats, particle pools | No in-crate renderer; egui `render()` is `#[cfg(any())]`-disabled in `ui/echo_hud.rs`. |
Expand Down Expand Up @@ -399,8 +405,8 @@ This is a pure-CPU logic crate; performance is benchmark-tracked but not a runti
- **Mutation testing:** Covered in the workspace mutation-testing campaign (see `docs/current/MUTATION_TESTING_AUDIT.md` and `docs/journey/daily/WEAVING_TEST_SPRINT_*`). `mutation_resistant_comprehensive_tests.rs` exists in both `src/` and `tests/`.
- **Benchmarks:** `benches/weaving_benchmarks.rs`, `benches/integration_benchmarks.rs` (criterion). Results in `docs/masters/MASTER_BENCHMARK_REPORT.md`.
- **Miri:** Not applicable (no `unsafe`; `#![forbid(unsafe_code)]`).
- **Manual validation:** Console playthrough via `examples/veilweaver_quest_demo` and `examples/advanced_content_demo`.
- **Important caveat (Key Lesson 8):** High test/bench coverage does NOT imply runtime wiring. This crate has zero library consumers; its tests validate logic, not integration into a running game loop.
- **Manual validation:** Console playthrough via `examples/veilweaver_quest_demo` and `examples/advanced_content_demo`. Headless stamps via `examples/aravath_weave`.
- **Important caveat (Key Lesson 8):** High test/bench coverage does not by itself mean every module is on a game tick. Cargo consumers on `1e275a9e` are `aravath_runtime`, `astraweave-gameplay`, `astraweave-scripting`, `astraweave-security`, `astraweave-core` (replay test), `examples/aravath_weave`, `examples/advanced_content_demo`, and `examples/veilweaver_quest_demo`. The anchor-slice helpers are still plain functions.

---

Expand All @@ -422,17 +428,18 @@ This is a pure-CPU logic crate; performance is benchmark-tracked but not a runti

| Version | Date | Notes |
|---|---|---|
| 1.7 | 2026-10-16 | Restamp `1e275a9e`. Cargo consumers are the greybox, gameplay, scripting, security, the core replay test, `aravath_weave`, and the two older quest examples. |
| 1.6 | 2026-10-16 | Greybox caller. `Combat::tick` calls `run_aravath_slice` and the window shows `Cover broke` when `cover_intact` is false. |
| 1.3 | 2026-10-15 | Scenario 1 gameplay QA. File map rows for `aravath.rs`, `gameplay_qa.rs`, and the RON. Invariant 11. |

**Update this doc when:**
- A consumer beyond the two examples adopts `astraweave-weaving` (this would flip its wired status — update §1 and §4).
- A new `Cargo.toml` consumer appears, or one of the eight listed in §4 drops the dependency. Update §4 and the verification command below.
- Either of the duplicate repair/currency paths in §6 is unified, or a duplicate enum (`AbilityType`/`CombatEvent`) is reconciled.
- The `systems/*` functions gain real ECS signatures (would change §2/§6 traps and §11).
- Stability/decay/repair constants in `anchor.rs` or the adjudicator budget/cooldown defaults change (would affect §8 invariants).

**Verification process:**
- `rg 'astraweave-weaving' --type toml` to recheck the consumer set (currently only `examples/advanced_content_demo`, `examples/veilweaver_quest_demo`).
- `rg 'astraweave-weaving' --type toml` to recheck the consumer set. On `1e275a9e` that is `aravath_runtime`, `astraweave-gameplay`, `astraweave-scripting`, `astraweave-security`, `astraweave-core`, `examples/aravath_weave`, `examples/advanced_content_demo`, and `examples/veilweaver_quest_demo`. The crate's own manifest and the workspace member list are not consumers.
- `rg 'pub enum AbilityType|pub (enum|struct) CombatEvent' astraweave-weaving/src` to recheck the naming collisions.
- Spot-check the two pipelines in §2 against current `patterns.rs`/`intents.rs`/`adjudicator.rs` and `systems/`.
- Stamp the new commit hash and date in the Metadata table after verification.
Expand Down
2 changes: 1 addition & 1 deletion docs/campaigns/doc-truth/CLOSED_VOCABULARY_LINT.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ The union of acted + kept occurrences is the complete closed-vocabulary inventor

- Both `required` lists in `.github/workflows/determinism-replay.yml` must agree, and `README.md` must name each case.
- `README.md` must state that the under-11 ms GTX 1660 Ti frame budget is not yet measured, that assets are CC0, that local LLMs propose, and that the deterministic simulation validates.
- `README.md` must have a `## In progress` section listing #253 and #216, and that section must not call the work shipped, landed, or merged. #217, #275, #327, #252, #205, #215, and #244 are on main and are not in that list.
- `README.md` must have a `## In progress` section listing #253 and #216, and no other issue number. That section must not call the work shipped, landed, or merged. #217, #275, #327, #252, #205, #215, and #244 are on main and are not in that list.
- Player-facing files (`README.md`, `CONTRIBUTING.md`, `docs/README.md`, `docs/QUICKSTART.md`, `docs/guides/**/*.md`) must not use the retired game title. `veilweaver_` crate names and the archive directory `projects/veilweaver` are allowed.

## Frame-time carve-out (D.3.1) — why `2.70 ms` is NOT in Vocabulary A
Expand Down
Loading
Loading