Map Bubble article/space fields from authenticated session export

Record CSOC-WP-0001-T02 progress: live ES payloads show custom.article as
Research content with nomer/abstractor/content/logo; redacted field map only.
This commit is contained in:
tegwick 2026-08-13 10:40:08 +02:00
parent 7cc4d8b976
commit 440719b9eb
3 changed files with 159 additions and 3 deletions

View file

@ -5,7 +5,8 @@ CSOC-WP-0001-T02/T04 home for Bubble → rebuild mapping and rehearsal notes.
| Doc | Status |
|-----|--------|
| `bubble-auth-and-export.md` | **Safe read access for agents** (session file; no secrets in chat) |
| `schema-mapping-sketch-2026-08-12.md` | Provisional mapping (update after export; target ADR-0003/0004) |
| `field-map-from-session-2026-08-13.md` | **Field map from live session export** (article/space/user) |
| `schema-mapping-sketch-2026-08-12.md` | Provisional mapping (supersede with field map) |
| *(later)* field-level map | After authenticated dump |
| *(later)* rehearsal log | Import of one space to thin git tree (ADR-0004) |

View file

@ -0,0 +1,150 @@
# Field map from authenticated Bubble session (2026-08-13)
| Field | Value |
|-------|--------|
| Workplan | CSOC-WP-0001-T02 |
| Session | Playwright storage-state (local only; not in git) |
| Export | `~/.config/coulomb-social/auth/exports/20260813-083747/` (local) |
| Target SoR | ADR-0003 / ADR-0004 thin dir+git |
## Session validation
| Check | Result |
|-------|--------|
| Probe URL | `https://coulomb.social/vw_pages` (authenticated) |
| Page title | Research \| Coulomb |
| Network captures | 147 (elasticsearch mget/msearch dominant) |
| Public `/api/1.1/meta` types | still empty (schema not public) |
## Live data model (from ES payloads)
Primary content type in Research UI is **`custom.article`**, not `custom.page`
(page may still exist in static packages as a type; session payloads for
`vw_pages` / chunks list are **articles**).
### `custom.space`
| Bubble field | Observed | Rebuild (ADR-0003/0004) |
|--------------|----------|-------------------------|
| `Slug` | yes | space directory slug / frontmatter slug |
| `isprivate_boolean` | yes | access / visibility |
| `members_list_user` | yes | SpaceMembership |
| `crew_list_user` | yes | membership role variant (map later) |
| `addnewusersasmember_boolean` / `addnewusersasguest_boolean` | yes | invite defaults |
| `locale_option_location` | yes | later |
| `funds_number` | yes | later / out of stage-1 |
| `gitea_text` | rare | optional repo pointer |
| Created By / Date, Modified Date | yes | provenance in backmatter or git |
**UI card (SpaceLet):** name + short description (e.g. DeepNews / “Tracking progress”) — name field may be displayed from related article or a space title field not always present under the keys above; confirm on detail view next pass.
### `custom.article` (Research “PageLet” / “ExtendLet”)
| Bubble field | Observed | Rebuild |
|--------------|----------|---------|
| `nomer_text` | **title-like name** (always in sample) | frontmatter `title` |
| `abstractor_text` | short description | frontmatter `abstractor` |
| `content_text` | body text (often markdown-ish) | markdown **body** |
| `logo_image` | image | frontmatter `visual``assets/` |
| `space_custom_space` | parent space id | path under `spaces/<slug>/` |
| `chunks_list_custom_article` | list (often empty or nested articles) | **do not** store as chunk table; optional live includes / sections (ADR-0003) |
| `context_custom_article` | parent/context article | backmatter relation / include parent |
| `contents_list_custom_article` | list | later / relations |
| `access_option_visibility` | visibility | access policy later |
| `archived_boolean` | archive | archive lifecycle |
| `taskstate_option_chunktask` | task state on chunk-like items | later (work tracking) |
| `canonical_text` | canonical ref | later |
| `moders_list_user` | moderators | membership roles later |
| `_owner_user` / `_creator_user` | owner | Created By / Member link |
| Created/Modified | timestamps | git / backmatter |
**UI labels:** **PageLet** (page-like) vs **ExtendLet** (extension/journal under a parent) — both appear as `custom.article` with different presentation; map both to **pages** with optional `kind` or parent relation.
### `user`
| Bubble field | Rebuild |
|--------------|---------|
| `name_first_text`, `name_last_text`, `namenick_text` | Member display profile (not IdP password) |
| `avatar_image` | optional profile visual |
| `about_text` | later |
| `spaceselected_custom_space` | last-selected space (UI state) |
| `superadmin_boolean` | later / NK groups |
| `userroles_list_option_user_type` | later |
| authentication | **do not migrate passwords** — NetKingdom (ADR-0001) |
### Relations (stage-1 optional)
| Type | Role | Stage-1 |
|------|------|---------|
| `custom.rellike` | likes | later |
| `custom.relfollow` | follows article | later |
## UI surfaces confirmed live
| Route | Title | Notes |
|-------|-------|--------|
| `/vw_pages` | Research | Article list in current space; copy + favorite actions |
| `/vw_spaces` | Research | ~70 spaces listed for session user |
| `/vw_chunks` | Research | Same corpus, “chunks” framing (ExtendLet/PageLet) |
| `/vw_search` | Research | Space multi-select filter |
| `/vw_feed` | Explore | Social feed |
| `/vw_new` | Explore | Create/new stream (rich text sample content) |
| `/vw_invites` | Explore | Invite player by email |
| `/vw_likes` | Explore | Liked PageLets |
## Mapping recipe (export → thin git)
For each `custom.space`:
```text
spaces/<Slug>/
pages/
assets/
```
For each `custom.article` with `space_custom_space` → that space:
```text
spaces/<space-slug>/pages/<slug-from-nomer>.md
```
```markdown
---
id: bubble:<article_id>
title: "<nomer_text>"
abstractor: "<abstractor_text>"
visual: "assets/<logo_file>" # after download
bubble_type: article
bubble_kind: pagelet|extendlet|unknown
parent: bubble:<context_id> # if context_custom_article set
archived: false
---
<content_text>
```
**Members:** map `members_list_user` / `crew_list_user` to invitations or NK subjects after identity linking — **not** Bubble passwords.
**Chunks list:** if non-empty, either:
1. concatenate into body with headings (simple), or
2. emit child pages + live `mkt:include` (ADR-0003 preferred for reuse).
## What this export does *not* yet give
- Stable full field schema for every Bubble type (only keys observed in payloads).
- Binary download of all `logo_image` CDN files (next script step).
- Complete article dump for all spaces (session shows current space context heavily).
- Backend workflow definitions.
- Guaranteed coverage of `custom.page` / `custom.chunk` as separate types in ES (names appear in static packages; live Research uses **article**).
## Next actions
1. Extend exporter to walk **all spaces** the user can access and dump article JSON redacted/normalized into a private corpus.
2. Download visuals for sample space.
3. Emit one space as ADR-0004 tree (rehearsal dry-run for T04).
4. Keep raw export **only** under XDG auth dir.
## Privacy
This note intentionally omits user emails, full article bodies, and raw IDs beyond structure. Raw export stays local.

View file

@ -80,8 +80,13 @@ content layout decisions for lossless mapping of pages/artefacts.
`docs/migration/bubble-auth-and-export.md` + `scripts/export-bubble-session.sh`.
Operator captures Playwright session once (`capture-auth-state.sh`); agents use
`storage-state.json` under `~/.config/coulomb-social/auth/`. Map target is
**thin dir+git** (ADR-0003/0004), not Forgejo-only. Still need a live member
session for T02 corpus; full schema may still need editor if member APIs empty.
**thin dir+git** (ADR-0003/0004), not Forgejo-only.
2026-08-13: **Session export run** (probe `vw_pages`, 147 network captures).
Research content is primarily **`custom.article`** (nomer/abstractor/content/
logo + space link), not empty public meta. Field map (redacted):
`docs/migration/field-map-from-session-2026-08-13.md`. Remaining: multi-space
walk, visual download, emit sample tree, then T04 rehearsal.
## Feature cut decision (human gate)