Commit Graph
30 Commits
Author SHA1 Message Date
glm-5.3-flash 73fdadafdd chore(tasks): wave-2 review gate passes green
- verdict GREEN: wave-3 decomposition unblocked; no blockers, no
  booked findings, zero core changes across wave 2 (verified by
  reading the three commits' file stats)
- ssr proof checked line by line against emit.md posture B: machinery
  equality, fragment composition with render-name rule, escape and
  raw-slot goldens, typed error-page mapping, determinism, hygiene
- code proof checked line by line against emit.md postures A/C and
  ADR-003: document order vs sort/reverse, no-op escaping, rebuild and
  registration-order determinism, two-sink equality; banner gap honest
- stop-and-book ledger clean; ADR-001 generality claim holds on real
  code (both postures served with no core exceptions)
- conformance battery verified as the standing set; AGENTS.md carries
  the standing wasm build and feature-matrix postures
- conventions audit and full verification set re-run clean (51 tests,
  clippy, fmt, doc, wasm release, tree inspection, taskgraph)
- inline fix: checked the battery task's completed-but-unchecked
  acceptance boxes

Verification: cargo test (51 passed), cargo test --all-features,
cargo clippy --all-targets -- -D warnings, cargo fmt --check, cargo
doc --no-deps, cargo build --target wasm32-unknown-unknown --release,
taskgraph validate (18 tasks), handlebars tree default-only
2026-11-07 05:43:43 +00:00
glm-5.3-flash 952f208e27 test(conformance): the standing wave-2 conformance battery
- strict-mode matrix: missing variables (top-level, in {{#each}},
  in {{#if}} then and else branches) fail typed through both
  sinks, never silent; the write sink's no-atomicity contract
  pinned by its row
- error-surface completeness: six failure paths each mapping to
  exactly one typed variant; registrations never half-survive;
  hostile context values render clean through both sinks and both
  escape policies with no panic paths
- two-sink correctness: byte-identical output over the ssr-shaped
  and code-shaped fixture postures, re-exercised over the proof
  fixture files (goldens stay pinned by the proof binaries)
- AGENTS.md: the wasm release build becomes standing and
  unconditional; the feature-matrix coincide-today posture and the
  handlebars feature-inspection posture documented honestly
  (ADR-003, ADR-009)

Verification: cargo test (all green), cargo test --all-features
(identical), clippy -D warnings clean, fmt clean, doc clean, wasm
release build clean, handlebars tree features default-only,
taskgraph validate clean
2026-11-06 20:44:52 +00:00
glm-5.3-flash 3b0483e50f test(code-proof): wave-2 code-shape proof through the public API (posture A/C)
- code-shaped fixture set: writer + validator template kinds over one
  composed partial, no-op escaper, strict mode, all public API
- ADR-004 mappings in builder Rust (kind->call names, struct name,
  string-kind flag, source-quoted literals); templates stay dumb
- document order (not sort/hash/reverse) drives rendered order;
  reordered arrays render in the array's new order
- determinism: byte-identical across repeated renders, registry
  rebuilds, differing registration orders, fresh contexts, and both
  sinks (render vs render_to_write)
- banner stays an emit-layer obligation; no banner assertions in the
  proof (gap recorded in task Notes, honestly)

Verification: cargo test (38 passed), cargo clippy --all-targets --
-D warnings, cargo fmt --check, taskgraph validate
2026-11-06 20:34:42 +00:00
glm-5.3-flash 08803b3d17 test(ssr-proof): wave-2 ssr-html proof through the public API (posture B)
- full consumer-shaped fixture set registered from the test binary via
  register_template/register_partial only (ADR-008 machinery equality
  in three caller-supplied text shapes: fixtures, runtime String,
  inline literal)
- page composes fragment partials; the card fragment registers as its
  own template, renders directly by name, and composes via include
- exact goldens pin html-escape posture (hostile data escaped, = and '
  escapes, raw-output {{& }} slot verbatim)
- strict-mode render failure maps consumer-side to an error page built
  from the typed Error's data, panic-free; source chain reachable
- determinism pinned across repeats, registry rebuilds, fresh
  contexts, and both sinks (byte-identical, ADR-003)
- posture-B hygiene rows: no banner, no filesystem; no core changes
  required (stop-and-book: nothing to book)
2026-11-06 20:31:11 +00:00
glm-5.3-flash a4ec8be3e8 chore(tasks): decompose wave 2 into implementation tasks
- w2-ssr-proof and w2-code-proof: the two consumer-shaped proofs,
  parallel by construction (own test binaries, own fixture modules
  per the wave-1 convention)
- w2-conformance-battery: the standing verification set, ordered
  after the proofs so it consolidates over the final wave-2 tree and
  absorbs any stop-and-book findings; folds the wave-1 gate's
  reminder (b) (wasm build standing, not ad-hoc)
- review-wave-2: the wave gate, depends on all three
- decomposition record added to docs/plans/implementation.md with
  the logistic-ordering rationale; wave-2 status flipped to
  decomposed

Verification: taskgraph validate (18 tasks valid); em-dash grep
clean on all changed files
2026-11-06 20:16:11 +00:00
glm-5.3-flash 0a4aa1eefe chore(tasks): wave-1 review gate passes green
- Landed core verified against core.md's six components and
  ADR-002/003/004/005/008/009 postures, checked in code and tests
  rather than prose
- All four wave-1 interpretations confirmed: alktype removal (ADR-009
  decision 1, tree-verified), context-build arms absent by design
  (ADR-008), render-name rule via set-level bookkeeping, naming
  validation by tests only
- Verification set re-run clean: cargo test (27), clippy -D warnings,
  fmt, doc, wasm release build, taskgraph validate (14)
- Gate verdict green: wave-2 decomposition unblocked; three
  non-blocking reminders carried forward (freeze-inventory
  non_exhaustive decision, standing wasm pin, ADR-009 CI matrix)
2026-11-06 20:11:25 +00:00
glm-5.3-flash 14d8a49611 test(fixtures): wave-1 engine fixture doubles (ssr-shaped and code-shaped)
- ssr double: page template composing header/footer partials under the
  HTML escaper, typed context built by a builder fn per ADR-004; golden
  pins for composition, escaping of hostile interpolation, the trusted
  {{& }} slot, and render-by-partial-name rejection
- code double: struct-writer template under the no-op escaper, typed
  context built from a schema document with kind mapping and
  source-escaped literals in the builder; golden pins for document-order
  arrays and the active preserve_order feature
- fixture assets are include_str! files under tests/fixtures/; fixture
  modules are per-test-binary so wave-2 proofs can grow them
- task file updated to completed with Notes and Summary

Verification: cargo test green (19 lib + 8 fixture tests), clippy
-D warnings clean, cargo fmt --check clean
2026-11-06 20:05:42 +00:00
glm-5.3-flash e361b4181a feat(render): add the TemplateSet render entry point (both sinks, deterministic, strict)
- public TemplateSet::render (String sink) and
  TemplateSet::render_to_write (io::Write sink), synchronous and
  deterministic, both surfacing the wave-1 Error enum
- render-name rule enforced behaviorally: the entry resolves names
  against the set-level bookkeeping before the substrate is
  consulted, so a partial's name or an unknown name is a typed
  Error::Render (substrate TemplateNotFound reason), never a
  rendered partial
- strict-mode missing variable is a typed error in both sinks,
  never silently-empty output; the write sink's streaming
  (non-atomic) semantics on mid-render failure documented
- determinism pinned by tests: byte-identical repeated renders,
  byte-identical output across registry rebuilds in opposite
  registration order, and byte-for-byte agreement between sinks

Verification: cargo test (19 passed), cargo clippy --all-targets
-- -D warnings, cargo fmt --check, cargo doc --no-deps, and
cargo build --target wasm32-unknown-unknown --release all green.
2026-11-06 20:01:57 +00:00
glm-5.3-flash 22f32e6fc5 feat(registry): the set builder per ADR-002/005/008
- TemplateSet: one strict handlebars registry per template set; strict
  mode forced at construction, unparameterizable; enforcement test pins
  missing-variable renders as Error::Render, never empty output
- EscapePolicy::{Html, NoOp}: explicit per-set escaper choice; Html
  leaves the substrate default html_escape, NoOp registers
  handlebars::no_escape; both postures pinned by golden render tests
- typed fallible registration of templates and partials; malformed
  text is Error::Registration, never a panic; failed registration
  leaves bookkeeping untouched
- set-level bookkeeping of template vs partial names (decision 1,
  flagged for the gate): the substrate's register_partial is identical
  to template registration, so the render-name rule cannot delegate to
  it; TemplateSet::is_template exposes the tracking for the
  w1-render-entry rejection
- per-set helper registration seam; zero custom helpers by default,
  pinned by test (unknown helper is a typed render error)
- naming conveventions enforced by tests only, not at registration
  (decision 2, flagged for the gate): consumer-facing engine API
  stays naming-neutral per ADR-001/008

Verification: cargo test (15 pass), clippy -D warnings, fmt --check,
wasm32-unknown-unknown release build

Verification: cargo test (15 pass), clippy --all-targets -D warnings, cargo fmt --check, wasm32-unknown-unknown --release
2026-11-06 19:59:19 +00:00
glm-5.3-flash 02037c4f10 feat(error): the public error enum per core.md error model
- src/error.rs: pub enum Error via thiserror with Registration
  (#[from] TemplateError) and Render (#[from] RenderError) variants;
  substrate errors stay reachable through the source chain
- src/lib.rs re-exports alkgen::Error per convention 10
- six unit tests pin variant mapping, source-chain reachability, and
  operation-naming Display strings
- no catch-all; no context-build arm in this scope (recorded
  interpretation, flagged for the wave-1 gate)

Verification: cargo test, clippy -D warnings, fmt --check, cargo doc,
wasm32-unknown-unknown release build, taskgraph validate (14 tasks)
all green
2026-11-06 19:54:47 +00:00
glm-5.3-flash c678615f2d build(manifest): dep posture per ADR-002/009; drop alktype; declare bast-codegen
- pin handlebars = "6.4" on default features; tree verified free of walkdir and rhai
- remove alktype from deps: no consuming code in v0.1.0, so an optional
  entry would be a dead feature; re-add lands with bast-rust-codecs as
  bast-codegen = ["dep:alktype"] (flagged for the wave-1 gate)
- declare [features] bast-codegen = [] (name reserved per ADR-009, gates nothing)
- package metadata to the text-generation framing (ADR-001): description,
  keywords, and the src/lib.rs crate doc; version stays 0.1.0

Verified: cargo test, clippy -D warnings, fmt --check,
wasm32 release build, taskgraph validate, dep-tree inspection
2026-11-06 19:51:04 +00:00
glm-5.3-flash b154b65bed chore(tasks): decompose wave 1 into implementation tasks
Five implementation tasks plus the gate, per the plan's decomposition
record. Deliberately sequential logistics: all tasks edit the same
small module tree and lib.rs re-exports, each consuming the previous
task's surface.

- w1-manifest: dep pins (handlebars 6.4 default features, thiserror),
  alktype removal, bast-codegen feature name declared
- w1-error-model: the one public enum (registration/parse/render)
- w1-registry-construction: set builder, forced strict mode, escaper
  policy, typed registration, helper seam; two decisions to record
- w1-render-entry: both sinks, deterministic, strict errors
- w1-engine-fixtures: ssr-shaped + code-shaped doubles, golden-pinned
- review-wave-1: the cheap-place gate; dispositions the four recorded
  interpretations

Four interpretations flagged for the gate (alktype removal vs
optional-behind-feature, context-build arms, partial render-target
enforcement, naming validation); recorded in the plan.

Verification: taskgraph validate clean (14 tasks), waves + deps
acyclic, em-dash grep clean
2026-11-06 18:27:28 +00:00
glm-5.3-flash 04e961d689 docs(plans): add wave-based implementation plan
Adopts the sibling wave pattern (alkssh/alkgit) over
decompose-everything-upfront: decompose a wave, implement it, review
gate, decompose the next wave.

Scope authority: v0.1.0 publishes the shared text-generation core
(ADR-001) proven fit for ssr-html via consumer-shaped fixtures through
the public API (ADR-008 machinery equality). Engine-owned template
sets stay out (all three queued targets are OQ-gated); alktype leaves
the dep tree until the bast-codegen set activates.

Waves: 1 core foundations, 2 consumer-shaped proofs + conformance
battery, 3 validation & release (pure-review gate then publish).

Verification: taskgraph validate (14 tasks), em-dash grep clean
2026-11-06 18:27:26 +00:00
glm-5.3-flash 9d57d1612e docs(architecture): review pass: flip specs to reviewed; fix review findings
- Define the fragment-rendering convention: render targets are
  registered templates composing partials; partials are composition
  units (core.md, emit.md posture B)
- Define template kind; trim/restage inline rationale with ADR
  citations (core.md)
- Amend ADR-008: wgsl set ownership resolved engine-owned via OQ-05's
  2026-11-06 resolution
- Add OQ-09: consolidate the untracked bast-rust-codecs detailed-spec
  residue (projection, error shape, writer survey) with paired tracker
  task
- Fix oq-05 tracker name to match the corrected unblocking condition
- Add reviewed-transition rule: deferred OQs with tracker tasks do not
  block reviewed; flip six spec docs draft -> reviewed

Verification: taskgraph validate (8 tasks valid), em-dash grep zero
hits, cargo doc --no-deps clean
2026-11-06 10:33:43 +00:00
glm-5.3-flash 077e52c003 docs(architecture): re-triage OQs to per-target emit policy; fix OQ-05 circular framing
- OQ-01/02/03 re-triaged from open to deferred(scope): partitioning,
  regeneration, and validation strategies are per-target decisions
  owned by each target's emit layer and consumer, not core or
  posture-A-wide policy; session analysis preserved in OQ texts
- OQ-05 ownership decided by applying ADR-008 (engine-owned, ships in
  alkgen, feature-gated, posture C); blocked-on reframed to alkjs
  GPU-layer work so the sequencing is non-circular (alkjs builds on
  the core, never the reverse)
- OQ-06 sequencing clarified; stale far-timeline language dropped
- activation queue recorded (ssr-html, wgsl-jit, then codec sets) in
  targets.md and overview.md, with downstream dev-utility composition
  noted at the overview level
- Preact vs handlebars SSR research outcome recorded in README
- tracker tasks added for oq-01, oq-02, oq-03; oq-05 task updated

Verification: taskgraph validate (7 tasks pass); em-dash grep clean on
touched files; docs-only change, no code touched
2026-11-06 10:06:54 +00:00
glm-5.3-flash a91ea2ec89 docs(architecture): phase 1 base: text-generation core specs, ADRs 001-010, OQ tracker
- overview.md, core.md, emit.md, targets.md: modular spec set for the
  generalized engine (contexts + templates + partials -> text), with
  the three targets (ssr-html, bast-rust-codecs, call-handlers,
  wgsl-jit) as template sets plus emit postures
- ADRs 001-010: one core/template-set split, handlebars 6.4 strict
  substrate, sync/wasm/deterministic posture, typed contexts with
  builders, per-registry escaper, SSR library posture, typed direct
  codecs output contract, template-set ownership, feature gating,
  library-only v1
- open-questions.md: OQ-01..OQ-08 centralized tracker carrying phase-0
  residue (GN-01/02/07/09) with three deferred(scope) entries plus a
  resolved disposition for phase-0 OQ-GN-04
- tasks/architecture/: external-trigger tracker tasks paired with the
  deferred OQs (taskgraph validate passes)
- phase-0.md checklist dispositioned for OQ-GN-04; AGENTS.md lifecycle
  updated to phase 1

Verification: taskgraph validate (4 tasks OK), cargo fmt --check,
cargo test, em-dash grep clean; architecture-reviewer pass returned
zero critical issues
2026-11-06 08:18:43 +00:00
glm-5.3-flash 93d70253d7 docs(phase0): correct the core framing: text generation, not two target classes
Second steer from the 2026-11-06 discussion: the document-vs-code
split carries a false distinction. The core is contexts + templates +
partials to text; HTML, Rust, and WGSL are three data points of the
same shape (handlebars native case, reader POC, alkminer kernel
builder). Per-target residue is only the template set, context shape,
emit posture, and validity pinning. WGSL recorded as confirmed coming
(JS runtime needs codegen generating WGSL); AGENTS.md lifecycle
phrasing aligned.
2026-11-06 07:55:34 +00:00
glm-5.3-flash bbd7d8164b docs(phase0): core generalization steer: one core, three targets
Principal steer: generalize the shared core across HTML generation
(branch 0), Rust codecs (branch 1), and WGSL/wasm-JIT (branch 3
territory); dev-tool emit demoted from the crate's definition to one
projection. Records the core/per-target split and the render-purity
requirement the wasm JIT fixes for Phase 1; refines OQ-GN-09.
2026-11-06 07:51:12 +00:00
glm-5.3-flash 65a8c3e379 chore(deps): bump alktype 0.3.0 to 0.4.0
Skeleton revalidated: cargo test, clippy -D warnings, fmt, and the
wasm32-unknown-unknown release build all pass on 0.4.0.
2026-11-06 06:05:15 +00:00
glm-5.3-flash 5e5c54a869 docs(phase0): record 2026-11-06 unpause for alkforge SSR; adopt no-em-dash convention
- AGENTS.md: adopt alkssh conventions (conventional commits, small
  focused commits, taskgraph section, lifecycle status, verification
  grep gate); add convention 12 (no em dashes in prose, U+2014)
- README.md: note the unpaused status and the alkforge SSR consumer
- phase-0.md: alkforge SSR enters as branch 0 (in-library HTML
  rendering, two target classes bound the core generality), new
  OQ-GN-09 for the SSR library posture, unpause context section,
  alktype 0.4.0 revalidation notes
- reader-poc-summary.md: re-validation note for alktype 0.4.0
  (parity + bench unchanged); em dashes restructured repo-wide
2026-11-06 06:05:15 +00:00
glm-5.3-flash 4a5aee2d0a docs(agents): adopt alkssh-evolved SDD process and agent specs
Adopt the evolved process docs from alkssh (their Phase 0 is the family
reference for SDD practice; adapted here for alkgen):

- sdd_process.md: POC placement two modes (branch mode vs standalone
  scratch project), closed frontmatter enum variants (taskgraph 0.1.3)
  with the three gotchas, impact table, POC specialist finding-first
  deliverables
- agent specs: architect/taskgraph rules for OQ blocker trackers,
  implementation-specialist conventions remapped to alkgen (no async,
  wasm-clean, preserve_order, strict mode), coordinator spawn constraints
  remapped, code-reviewer checks swapped for template/determinism rules,
  poc-specialist two-mode workflow
- all adopted/edited files are em-dash-free (AGENTS.md convention 12)
2026-11-06 06:05:15 +00:00
glm-5.3-flash 5dee37260c docs: typed output validated — 291-322ns, zero deps, parity clean
- (b) direct codecs resolved AND validated: generated types+codecs,
  ReadResult<Packet>, no serde/serde_json/alktype in output
- benchmark: ~10x faster than Value-shaped generated, ~15-20x faster
  than interpreter, ~4x off raw no-alloc baseline (String/Vec allocs)
- F-6: names come from the BAST doc (plan erases $defs names);
  OQ-GN-02 refined: plan for semantics, BAST for names
- V{key} variant naming for numeric discriminator keys
2026-09-09 07:40:56 +00:00
glm-5.3-flash a52c8a6b37 docs: typed-output direction set — russh-sftp shape, (a) vs (b) fork
- branch 1 output contract targets typed Rust structs (no Value
  materialization): the kernel-fusion move, alkminer precedent
- russh-sftp protocol-type shape as target (plain structs, field
  order = decode order, shared cursor codec core)
- fork: (a) serde-derive + generic Deserializer (interop) vs
  (b) generated direct codecs (zero overhead, the 72ns shape)
- follow-up #1 sharpened: typed-output POC renders Packet both ways,
  benchmarks against the raw-decode baseline
2026-09-09 07:23:56 +00:00
glm-5.3-flash b86dadcf77 docs: reader POC complete — OQ-GN-05/06/08 resolved with evidence
- reader-poc-summary.md: plan-driven handlebars codegen validated
  end-to-end (parity-exact vs interpreter, ~1.9x faster, 7 tests)
- OQ-GN-05 resolved: self-contained generated code (a), uniform
  cursor addressing (F-1); OQ-GN-06: serde_json-only dependency
- decomposition finding: 20x-vs-hand-rolled gap is Value allocation,
  not dispatch; output-contract ADR is the big Phase 1 decision
- F-1..F-5 findings; Phase 1 follow-up list
2026-09-09 07:12:01 +00:00
glm-5.3-flash 79c2794a99 docs: phase-0 — OQ-GN-01 resolved: dev tool, static files, module output
- clarification: alkcall is a library others build on; alkgen branches
  1+2 are a dev tool generating static files into downstream projects
  (protocol crates alktty/alktunnels/sftp, cloud integrations vast.ai/
  runpod) from provided schemas (BAST or jsonschema/openapi)
- OQ-GN-01 resolved: module-level output for v1; fragments out
  (defeats dev-tool purpose), crate generation out for v1 (composed
  from modules later if asked). Residue: file partitioning policy
- OQ-GN-06 reframed: generated files land in projects that don't
  depend on alktype today, so dependency footprint is consumer's
  choice, not wire-shaped; leaning self-contained, POC decides
- branch 2 reframed: static counterpart of alkhttp from_* adapters
2026-09-08 08:58:50 +00:00
glm-5.3-flash 0e9bdf65ab docs: phase-0 — OQ-GN-02 direction set: plan-driven contexts
- plans for offsets/sizes (already computed+validated by the engine,
  free at generation time since alktype is already a dep), BAST for
  descriptive metadata; drift risk inverts into ordinary
  dependency-upgrade tracking of alktype's plan API
- residue: exact plan->context projection is the Phase 1 context-
  builder spec task
2026-09-08 08:46:57 +00:00
glm-5.3-flash ea1ef10bc3 docs: phase-0 — resolve OQ-GN-03 posture, calibrate OQ-GN-08 POC
- OQ-GN-03 resolved as posture: interpreter/compiler duplication is
  the point (dynamic vs static deployment profiles); alktype near
  schema-method floor, ~20x off hand-rolled; alkgen's value prop is
  recovering most of that gap. Drift stays the standing risk.
- OQ-GN-08 POC 1 calibration: three-way benchmark (plan-walk vs
  generated vs hand-rolled) doubles as drift check + perf validation;
  OQ-GN-05 boundary reframed as performance trade
2026-09-08 08:44:52 +00:00
glm-5.3-flash 105d553353 docs: phase-0 findings — prior art survey + OQ-GN-01..08
- settled: stack shape, wasm-clean validated, handlebars 6.4 pin,
  strict-mode posture, template-is-code, determinism
- prior art: typebox-rs codegen, alkminer-v1 ShaderBuilder, alktype
  plans as implied spec, alkhttp adapters
- OQs: output unit, context source (BAST vs plans), interpreter/
  compiler duplication cut, delegation boundary, validation strategy,
  POC scope
2026-09-08 08:27:48 +00:00
glm-5.3-flash 3178621adb init: repo skeleton — cargo crate, AGENTS.md, gitignore, licenses
- Cargo.toml: alkgen 0.1.0, deps alktype 0.3.0 + handlebars 6.4 + serde_json
  (preserve_order) + thiserror; empty lib
- AGENTS.md: family-style conventions (wasm-clean, strict templates,
  template-is-code, generated-code hygiene) + reference map
- verified: cargo check/clippy/fmt, wasm32-unknown-unknown release build
2026-09-08 08:27:03 +00:00
glm-5.3-flash a73f197786 init 2026-09-08 07:55:53 +00:00