developmentseed / developmentseed/cng-sandbox

source.coop: example stories using example datasets

Open
#200 0 comments 0 reactions 0 assignees View on GitHub
enhancement feat
Dominant language
TypeScript
Stars
3
Forks
0
Avg merge
2h 21m
Merged PRs (30d)
3

Description

Part of the source.coop integration roadmap. Depends on #197 (shared example datasets).

## Why

Once example datasets exist and are visible across all workspaces, example **stories** built on top of them become the highest-leverage first-impression surface. A new visitor lands on the homepage, sees both example datasets and example stories, and can explore a real Dev Seed-built narrative without uploading anything.

## What

### Schema
- Add \`is_example: bool\` (default \`false\`) to the \`stories\` table, mirroring #197's change to datasets.
- Example stories have no \`workspace_id\` and are visible in every workspace.

### API
- \`GET /api/stories\` returns workspace-scoped stories plus all \`is_example=true\` stories.
- \`PATCH\` and \`DELETE\` return 403 for \`is_example=true\` stories — system-owned, not user-editable.
- New endpoint: \`POST /api/stories/{id}/clone\` — makes an editable copy of an example story in the current workspace. The clone has \`is_example=false\` and the current \`workspace_id\`.

### Story content
- Author 2-3 example stories using the example datasets available (GHRSST, GEBCO, Land & Carbon Lab, and whatever #199 adds).
- Stories should showcase different chapter types: at least one uses scrollytelling, one uses prose, one uses map.
- At least one example story should be multi-dataset (uses the full capability of the story editor).

### Seeding
- Example stories seed alongside example datasets in the ingestion startup task. Same idempotency rule: if the story row already exists (keyed by a stable ID), skip.

### UX
- Homepage gets a second row below the source.coop gallery: "Example stories". Click-through goes to the story reader.
- Story reader shows a "Use this as a template" button for example stories. Clicking calls \`/clone\` and navigates to the cloned editable story.
- Library page's story section groups example stories separately from workspace stories.

## Acceptance

- [ ] Every workspace sees the same set of example stories
- [ ] Example stories cannot be edited or deleted from any workspace
- [ ] Cloning an example story produces an editable copy in the current workspace
- [ ] At least 2 example stories exist and load correctly in the reader
- [ ] Homepage shows both example datasets and example stories

## Notes

- The story content itself is the meaningful deliverable — the code changes are small. Budget most of this issue's time on authoring high-quality narratives, not infrastructure.
- Consider Dev Seed's strongest narrative themes: climate observability, forest monitoring, ocean/SST trends. Pick stories that showcase Dev Seed's domain as much as the sandbox's capability.

Contributor guide

Open the contributing guide

Research direction

Start with dependency #197 and the ingestion startup task, then trace the story API endpoints, homepage, story reader, and library story section named in the issue. Done means seeded example stories are visible across workspaces, protected from edits, clonable into the current workspace, and displayed with the required reader and homepage UX.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
api, content, database, full-stack
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.