Skip to content

spec+plan: consent-first, role-aware tutoring uplift (#8-#11)#12

Merged
OriNachum merged 1 commit into
mainfrom
spec/learn-consent-tutoring-uplift
Jul 11, 2026
Merged

spec+plan: consent-first, role-aware tutoring uplift (#8-#11)#12
OriNachum merged 1 commit into
mainfrom
spec/learn-consent-tutoring-uplift

Conversation

@OriNachum

Copy link
Copy Markdown
Contributor

What

The converged devague spec + 18-task build plan for the next /learn uplift, covering all four roadmap issues as one coherent phase: #8 (roles + approval-gated Bedrock tutoring), #9 (cloze contract kind + upstream content re-export), #10 (consent gate — the live gap), #11 (versioned Terms of Use + Privacy Policy).

  • docs/specs/2026-07-11-agentculture-org-learn-is-now-a-consent-first-role.md — the spec (27 claims, 17 confirmed honesty conditions, 3 nonblocking parked items)
  • docs/plans/2026-07-11-agentculture-org-learn-is-now-a-consent-first-role.md — the plan (18 tasks, 8 dependency waves, 5 recorded risks)
  • .devague/frames/ + .devague/plans/ — the converged state (evidence trail for every confirmed claim)

User decisions recorded in the frame

  • Bedrock-direct: AWS Bedrock is the only service that serves AWS Nova models — Nova Pro via the OpenAI-compatible endpoint + Bedrock API key, Nova Sonic 2 via its bidirectional stream. No sibling-hosted model server, no idle host.
  • Serverless only, no EC2: AWS plumbing copies league-of-agents-platform's SAM/Lambda/budget-ceiling pattern (pay-as-you-go, hard monthly USD ceiling, zero idle cost).
  • /learn-local policy docs: learn-cli authors and versions Terms + Privacy (the only data-processing surface); org gets a link-up issue (plan t18).
  • Sequencing: consent gate + published docs ship before any learner is approved for tutoring — enforced in code (approval requires consent to the current terms version).

Key spec calls

  • Consent covers both sign-in paths (web handleCallback AND device-flow poll both call upsertLearner today with no consent step).
  • Consent withdrawal hard-deletes (learners + records + consents) — erasure overrides the ledger's append-only rule at whole-learner granularity.
  • Unconsented sign-in gets a pending-consent session (view/accept/decline only, zero D1 writes).
  • Resource gate extends one level: signed-out < signed-in < approved — non-approved /api/tutor is 403 with zero outbound inference.

Refs #8, #9, #10, #11. Spec/plan produced with /think + /spec-to-plan (devague 0.17.0); parked-vagueness resolutions hand-edited into the frame JSON per the known devague CLI gap.

  • learn-cli (Claude)

…gue /think + /spec-to-plan)

Converged frame (27 claims, 17 honesty conditions) and 18-task/8-wave plan
covering the four roadmap issues: #10 consent gate (both sign-in paths, no
D1 write pre-consent), #11 versioned /learn-local Terms + Privacy, #8 roles
+ admin allow-list + approval-gated Bedrock-direct tutoring (Nova Pro via
the OpenAI-compatible endpoint, Nova Sonic 2 via a serverless league-pattern
voice bridge), #9 cloze contract kind + upstream content re-export.

User decisions recorded in the frame: Bedrock-direct (no sibling model
host), /learn-local policy docs, serverless-only plumbing (no EC2),
consent+docs ship before any tutoring approval.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014QpvZY8K67Q9uGA6keFhTz
@OriNachum

Copy link
Copy Markdown
Contributor Author

/agentic_review

@qodo-code-review

qodo-code-review Bot commented Jul 11, 2026

Copy link
Copy Markdown

Code Review by Qodo

Grey Divider

New Review Started

This review has been superseded by a new analysis

Grey Divider

Qodo Logo

@qodo-code-review

Copy link
Copy Markdown

PR Summary by Qodo

Add consent-first, role-aware tutoring uplift spec + build plan (#8-#11)

📝 Documentation ⚙️ Configuration changes 🕐 20-40 Minutes

Grey Divider

AI Description

• Publish a unified spec for consent-first sign-in, roles, approval-gated tutoring, and cloze
 content.
• Add an 18-task, dependency-waved build plan with acceptance tests, risks, and sequencing.
• Capture converged devague frame/plan artifacts and bump project version + changelog.
Diagram

graph TD
  cur[".devague/current*"] --> frame["Frame JSON"] --> spec["Spec (MD)"] --> chlog["CHANGELOG"]
  cur --> planj["Plan JSON"] --> planmd["Plan (MD)"] --> chlog --> ver["pyproject.toml"]
Loading
High-Level Assessment

The following are alternative approaches to this PR:

1. Split into four per-issue specs/plans (#8/#9/#10/#11)
  • ➕ Smaller, easier-to-review documents per domain area
  • ➕ Clearer ownership boundaries (consent vs tutoring vs curriculum vs policies)
  • ➖ Loses the explicit sequencing constraint (consent/docs before approvals) as a single coherent phase
  • ➖ More risk of duplicated assumptions and mismatched acceptance criteria
2. Publish only the markdown spec/plan (omit .devague artifacts)
  • ➕ Cleaner repo surface area (fewer machine artifacts)
  • ➕ Less churn in future exports
  • ➖ Loses the evidence trail for confirmed claims/honesty conditions and traceability to tasks
  • ➖ Harder to regenerate or audit the plan/spec provenance
3. Add a short top-level index doc summarizing scope + links
  • ➕ Makes the phase easier to discover without reading long docs
  • ➕ Provides a stable entry point for contributors and issue linking
  • ➖ Adds a third narrative surface that can drift unless maintained

Recommendation: Keep the unified spec + plan as submitted because the cross-cutting sequencing (consent/policies before approvals) is central and benefits from being treated as one phase. Consider a lightweight index/README entry as a follow-up to improve discoverability, but retaining the .devague frame/plan artifacts is valuable for auditability and task/claim traceability.

Files changed (8) +1199 / -3

Documentation (5) +1196 / -0
agentculture-org-learn-is-now-a-consent-first-role.jsonAdd exported devague frame for #8–#11 uplift +447/-0

Add exported devague frame for #8#11 uplift

• Adds the converged frame capturing the end-to-end product spec as claims/requirements/decisions, including honesty conditions and open vagueness items for later resolution.

.devague/frames/agentculture-org-learn-is-now-a-consent-first-role.json

agentculture-org-learn-is-now-a-consent-first-role.jsonAdd exported devague plan (18 tasks, deps, risks) +521/-0

Add exported devague plan (18 tasks, deps, risks)

• Adds the structured build plan with 18 tasks across dependency waves, acceptance criteria per task, and recorded risks tied to specific tasks.

.devague/plans/agentculture-org-learn-is-now-a-consent-first-role.json

CHANGELOG.mdDocument spec+plan addition in 0.5.4 changelog +6/-0

Document spec+plan addition in 0.5.4 changelog

• Adds a 0.5.4 entry noting the new roadmap uplift spec/plan and associated devague artifacts.

CHANGELOG.md

2026-07-11-agentculture-org-learn-is-now-a-consent-first-role.mdPublish build plan markdown for consent-first tutoring uplift +151/-0

Publish build plan markdown for consent-first tutoring uplift

• Introduces the human-readable plan version listing tasks t1–t18, dependencies, acceptance criteria, and risks.

docs/plans/2026-07-11-agentculture-org-learn-is-now-a-consent-first-role.md

2026-07-11-agentculture-org-learn-is-now-a-consent-first-role.mdPublish spec markdown for consent-first, role-aware tutoring uplift +71/-0

Publish spec markdown for consent-first, role-aware tutoring uplift

• Introduces the human-readable spec covering audience, before/after, requirements (consent, re-consent, delete/export, roles, approval gating, cloze contract, policy pages, Bedrock-direct inference), and success signals.

docs/specs/2026-07-11-agentculture-org-learn-is-now-a-consent-first-role.md

Other (3) +3 / -3
currentPoint devague to the new consent-first uplift frame +1/-1

Point devague to the new consent-first uplift frame

• Updates the active devague frame slug to 'agentculture-org-learn-is-now-a-consent-first-role'.

.devague/current

current_planPoint devague to the new consent-first uplift plan +1/-1

Point devague to the new consent-first uplift plan

• Updates the active devague plan slug to 'agentculture-org-learn-is-now-a-consent-first-role'.

.devague/current_plan

pyproject.tomlBump learn-cli version to 0.5.4 +1/-1

Bump learn-cli version to 0.5.4

• Increments the project version from 0.5.3 to 0.5.4 to reflect the documentation/spec+plan release.

pyproject.toml

@sonarqubecloud

Copy link
Copy Markdown

@qodo-code-review

Copy link
Copy Markdown

Code Review by Qodo

🐞 Bugs (1) 📘 Rule violations (0) 📎 Requirement gaps (0) 📜 Skill insights (0)

Context used
✅ Compliance rules (platform): 9 rules

Grey Divider


Informational

1. Doctor command inconsistent 🐞 Bug ⚙ Maintainability
Description
The new build plan documents teken cli doctor --strict, while other repo docs use `teken cli
doctor . --strict`, creating inconsistent contributor guidance for running the rubric gate. This PR
adds a new instance of the inconsistent form in both the human plan markdown and the exported
devague plan JSON.
Code

docs/plans/2026-07-11-agentculture-org-learn-is-now-a-consent-first-role.md[76]

+  - Approve/revoke is admin-only (allow-list enforced) and takes effect without re-login; learn admin verbs pass teken cli doctor --strict (explain catalog entries included)
Evidence
The plan markdown added in this PR includes teken cli doctor --strict while existing repo docs
show a different common form (teken cli doctor . --strict), demonstrating inconsistency
introduced/propagated by this change.

docs/plans/2026-07-11-agentculture-org-learn-is-now-a-consent-first-role.md[70-77]
README.md[20-26]
CLAUDE.md[57-64]
.devague/plans/agentculture-org-learn-is-now-a-consent-first-role.json[307-315]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

### Issue description
`docs/plans/2026-07-11-agentculture-org-learn-is-now-a-consent-first-role.md` (and the mirrored exported `.devague` plan JSON) uses `teken cli doctor --strict`, while other project docs (README/CLAUDE) commonly use `teken cli doctor . --strict`. This inconsistency makes it unclear what the canonical invocation is.

### Issue Context
The plan markdown and `.devague/plans/*.json` should be kept consistent with the repo’s established contributor instructions.

### Fix Focus Areas
- docs/plans/2026-07-11-agentculture-org-learn-is-now-a-consent-first-role.md[76-76]
- .devague/plans/agentculture-org-learn-is-now-a-consent-first-role.json[312-314]

### Suggested change
Update the plan text (and matching JSON) to use the same invocation as the Quickstart docs (e.g., `uv run teken cli doctor . --strict` or at least `teken cli doctor . --strict`), so all contributor instructions match.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


Grey Divider

Qodo Logo

- covers: c13, h5
- acceptance:
- Signed-in non-approved POST /api/tutor gets 403 with ZERO outbound inference requests — extends the existing signed-out ordering test one level (h5)
- Approve/revoke is admin-only (allow-list enforced) and takes effect without re-login; learn admin verbs pass teken cli doctor --strict (explain catalog entries included)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Informational

1. Doctor command inconsistent 🐞 Bug ⚙ Maintainability

The new build plan documents teken cli doctor --strict, while other repo docs use `teken cli
doctor . --strict`, creating inconsistent contributor guidance for running the rubric gate. This PR
adds a new instance of the inconsistent form in both the human plan markdown and the exported
devague plan JSON.
Agent Prompt
### Issue description
`docs/plans/2026-07-11-agentculture-org-learn-is-now-a-consent-first-role.md` (and the mirrored exported `.devague` plan JSON) uses `teken cli doctor --strict`, while other project docs (README/CLAUDE) commonly use `teken cli doctor . --strict`. This inconsistency makes it unclear what the canonical invocation is.

### Issue Context
The plan markdown and `.devague/plans/*.json` should be kept consistent with the repo’s established contributor instructions.

### Fix Focus Areas
- docs/plans/2026-07-11-agentculture-org-learn-is-now-a-consent-first-role.md[76-76]
- .devague/plans/agentculture-org-learn-is-now-a-consent-first-role.json[312-314]

### Suggested change
Update the plan text (and matching JSON) to use the same invocation as the Quickstart docs (e.g., `uv run teken cli doctor . --strict` or at least `teken cli doctor . --strict`), so all contributor instructions match.

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

@OriNachum OriNachum merged commit bde5887 into main Jul 11, 2026
8 checks passed
@OriNachum OriNachum deleted the spec/learn-consent-tutoring-uplift branch July 11, 2026 06:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant