Skip to content

[Fleet Execution] Implement Tier 1 Foundational SDK Scripts #241

@jules-fleet

Description

@jules-fleet

Goal Reference

This issue was generated from .fleet/goals/sdk-examples.md. The worker agent should read this file for full context including verification commands, constraints, and structural guidance.

Objective

Implement foundational script examples (Tier 1) for the Stitch SDK that require no agent intelligence. These deterministic scripts must demonstrate basic design generation, browsing and exporting, batch generation, and creating a screenshot gallery.

Code-Level Diagnosis

Code path: packages/sdk/examples/
Mechanism: The examples directory contains a flat list of simple .ts files, missing the structured directory-based, scenario-driven scripts prioritized in the Tier 1 specification.
Root cause: Foundational, practical scenario-driven script examples have not been scaffolded and implemented per the architectural guidelines.

Current Implementation

// Current flat structure lacking scenario-driven modular directories like basic-design/

Proposed Implementation

Files to modify: Create the required directories and files for basic-design, browse-and-export, batch-generation, and screenshot-gallery. Each directory must include an index.ts demonstrating specific deterministic SDK calls and a README.md. Update the main README.md to link these examples.

Integration (Before -> After)

+ // New examples will be implemented in their respective directories and linked in the SDK README

Test Scenarios

  1. Basic Design Generation: Script executes successfully, creating a project and returning expected HTML and image URLs.
  2. Batch Generation: Script correctly parses input and generates multiple designs in parallel using Promise.allSettled.

Target Files

  • packages/sdk/examples/basic-design/index.ts
  • packages/sdk/examples/basic-design/README.md
  • packages/sdk/examples/browse-and-export/index.ts
  • packages/sdk/examples/browse-and-export/README.md
  • packages/sdk/examples/batch-generation/index.ts
  • packages/sdk/examples/batch-generation/README.md
  • packages/sdk/examples/screenshot-gallery/index.ts
  • packages/sdk/examples/screenshot-gallery/README.md
  • packages/sdk/README.md

Boundary Rules

Restrict your modifications exclusively to the files listed in the Target Files section. Ensure your source changes are entirely backward-compatible if unowned tests outside your boundary fail. Retain all existing file names and locations outside your explicitly declared target list.


Fleet Context

Metadata

Metadata

Assignees

No one assigned

    Labels

    fleetFleet-managed issue

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions