Skip to content

chore: measure session bundle size and cold-start budget #1336

Closed

Description

@Astro-Han

Timeboxed spike; output is a decision record, not production code.

Questions to answer

  1. Bundle p50/p99 size on a real coding session (state root + workspace, typical node_modules/.git present).
  2. Per-message cold-start budget for interactive chat: hydrate + boot + first token.
  3. node_modules/.git policy: reinstall per activation vs bundle vs bake into the image.
  4. KV class decision: S3-with-CAS-class vs alternatives; value size limits; whether manifest/blob offload is needed at v1 scale.
  5. Compression implementation note for Node (native binding / wasm / external binary), feeding the versioned image work.

Findings feed the bundle format and image work items in #1286.

Activity

  1. changed the title [-]Spike: measure session bundle size and cold-start budget[/-] [+]chore: measure session bundle size and cold-start budget[/+] on Jul 22, 2026
  2. Nyvo-io commented on Jul 22, 2026

    @Nyvo-io
    Contributor

    I would like to take this timeboxed measurement spike as the next slice after #1338.

    PR #1349 is open for the state/config root boundary. Issue #1337 is already assigned, so #1336 is the next unassigned child issue that directly informs the Session Bundle format and image work. I will keep this to a reproducible decision record with measured bundle sizes, cold-start timings, dependency policy recommendations, KV constraints, and compression options; no production runtime code.

  3. Astro-Han commented on Jul 22, 2026

    @Astro-Han
    ContributorAuthor

    Assigned to @Nyvo-io. Look forward for your result!

  4. Nyvo-io commented on Jul 22, 2026

    @Nyvo-io
    Contributor

    Implemented and opened upstream PR #1353: #1353

    The timeboxed decision record adds a reproducible Node 24 measurement harness and records the current recommendation:

    • 32 MiB compressed inline bundle cap with manifest/blob offload.
    • node_modules excluded from Session Bundle state and handled by the versioned image plus lockfile cache.
    • .git excluded from the bundle and handled by repository materialization or a workspace overlay.
    • S3-with-CAS-class manifest/blob storage.
    • Native Node 24 Zstandard for the activation path.
    • 250 ms p99 local hydrate-plus-boot budget, with provider first-token latency measured separately.

    The local baseline measured a 619.96 MiB checkout, with 487.70 MiB in node_modules and 70.83 MiB in .git. The deterministic session corpus measured 0.12 MiB Zstandard at p50 and 6.85 MiB at p99; the projected portable workspace plus state was 20.22 MiB at p50 and 26.96 MiB at p99. The record labels these as a reproducible local baseline, not production telemetry.

  5. Astro-Han commented on Aug 2, 2026

    @Astro-Han
    ContributorAuthor

    The spike's output, the measurement harness and decision record, landed in #1353. The PR only said Refs instead of Closes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions