Agent-first pattern repo for bounded teaching and progression.
This repo demonstrates one reusable shape:
- a curriculum exists
- an agent picks the next useful concept
- the system produces a teaching artifact or recall prompt
- progression is tracked over time
The point is not the current curriculum. The point is the pattern.
Companion reading: Three SDKs, three jobs explains why this repo stays in the smallest-loop lane. Three repos, one thesis shows how this repo joins the wider proof set.
This repo is one member of the StoneyTECH Trinity pattern set:
StoneyTECH-Trinity-Learning-AgentStoneyTECH-Trinity-Evidence-AgentStoneyTECH-Trinity-GVAR-Engine
Use this repo as a reference when an agent needs to:
- draft teaching content from a bounded curriculum
- advance through topics with explicit progression rules
- pair content generation with spaced repetition
Do not use this repo as a production learning platform. It is a pattern repo, not a full application.
Pick the next teachable thing on purpose, then generate or reinforce it in a bounded loop.
That shape is useful for:
- onboarding systems
- study companions
- concept drills
- progressive content generation
The control shape is:
curriculum -> pick next concept -> draft or recall -> update ledger
This repo uses a small loop instead of a full graph runtime, but the flow is still named first so an agent can reuse it.
The bounded context surface is:
- the curriculum
- prerequisite state
- drill ledger
- study ledger
If this pattern is wrapped by an MCP later, that MCP should expose curriculum state and progression state, not an unbounded authoring environment.
The reusable contracts are:
- the teaching-draft template
- the recall-question template
- the grading scale
Those templates are the portable teaching surface for agents and humans.
- Axiom #1 — the smallest lever wins: this repo keeps the loop intentionally small.
- Axiom #2 — push work down toward determinism: the curriculum and ledger do the steering work instead of free-form guesswork.
- Axiom #16 — do not curate without proving: concepts are exercised through runnable drills and recall loops.
See AXIOMS.md for the local doctrine map.
- StoneyTECH public content MCP: https://public-content-mcp.stoneytech.net/mcp
- local repo MCP stub: mcp/manifest.json
The shared StoneyTECH MCP gives family doctrine. This repo-local MCP exposes curriculum and progression truth.
Before promoting the local MCP beyond development, run it through the StoneyTECH MCP compliance scanner and keep the scan result with the release notes or repo receipts.
curriculum
-> picker
-> draft or recall prompt
-> ledger update
-> next concept chosen from progression state
Use this pattern when:
- progression matters more than one-off answers
- the system should know what has already been covered
- teaching and recall both matter
- a small loop is enough
Do not use this pattern when:
- the system first needs outside research
- the output must pass multi-lens acceptance checks
- the work spans many review stages or external tools
For those cases, pair it with StoneyTECH-Trinity-Evidence-Agent or StoneyTECH-Trinity-GVAR-Engine.
This repo starts with a direct Anthropic path, but it should grow with the reader.
Upgrade later to:
- local agents
- direct vendor keys across providers
- OpenRouter routing
- graph-mapped role selection
- shadow tribunals for draft or study quality
n8nscheduling and webhook delivery
The upgrade seams live in:
- agents/graph-map.json
- providers/provider-map.example.json
- shadow/tribunal-config.example.json
- integrations/n8n/workflow-stub.jsonc
- graph/README.md
Use StoneyTECH-Trinity-Learning-Agent by itself for:
- a concept-of-the-day teaching loop
- a recall and reinforcement companion
- progressive curriculum generation
Use the pair when:
- a lesson needs a bounded evidence input first
- teaching content should be grounded before drafting
Flow:
StoneyTECH-Trinity-Evidence-Agent -> StoneyTECH-Trinity-Learning-Agent
StoneyTECH-Trinity-Evidence-Agent gathers a bounded brief. StoneyTECH-Trinity-Learning-Agent turns that material into a teaching artifact.
Use the pair when:
- a teaching artifact needs structured review before use or publication
Flow:
StoneyTECH-Trinity-Learning-Agent -> StoneyTECH-Trinity-GVAR-Engine
StoneyTECH-Trinity-Learning-Agent drafts. StoneyTECH-Trinity-GVAR-Engine verifies whether the draft is acceptable yet.
Use all three together when the job is:
- gather bounded evidence
- teach or explain from that material
- verify the result before acceptance
Flow:
StoneyTECH-Trinity-Evidence-Agent -> StoneyTECH-Trinity-Learning-Agent -> StoneyTECH-Trinity-GVAR-Engine
That is the full public proof set:
StoneyTECH-Trinity-Evidence-AgentresearchesStoneyTECH-Trinity-Learning-AgentteachesStoneyTECH-Trinity-GVAR-Engineverifies
v0.1 — portable and local-runnable. The core loop runs locally, optional bridge delivery is env-driven, and larger schedulers or cron surfaces remain upgrade seams rather than baked assumptions.
cp .env.example .env
# Fill in ANTHROPIC_API_KEY in .env
npm install
npm run hello
npm run list
# Content engine
npm run drill
# Learning engine
npm run study
npm run grade <slug> <0-5> [notes...]By default, generated drafts go to ./output/drafts/architect/ or ./output/drafts/primer/, and study state lives in curriculum/study-ledger.json.
Standalone demo, no model key required:
npm run demoWrite a draft or gold teaching artifact from a bounded evidence brief:
npm run demo -- --mode draft --output ./demo/draft.md
npm run demo -- --mode gold --output ./demo/gold.mdLocal MCP demo:
npm run mcp:demoPair and Trinity demos live in StoneyTECH-Trinity-GVAR-Engine so the chain can finish at verification:
cd ../stoneytech-trinity-gvar-engine
python -m gvar_engine.trinity_demo --scenario evidence-learning
python -m gvar_engine.trinity_demo --scenario trinityThis repo contains two small loops over the same curriculum:
drill— picks the next undrilled concept and generates a teaching draftstudy— picks the next due concept and sends a recall prompt with SM-2 scheduling
The picker (src/picker.ts):
- filters concepts whose prerequisites are satisfied
- filters out already-drilled concepts
- prefers lower-tier foundation concepts first
- prefers concepts closest to the main progression spine
- rotates across recent levers so the cadence does not stall
Force a specific concept:
CONCEPT=rag-vs-lora npm run drillDry-run:
DRY_RUN=1 npm run drillThe study side uses SM-2 spaced repetition:
- grades
0-2reset the concept to near-term review - grades
3-5expand the interval - state is kept per concept in
curriculum/study-ledger.json
Keep:
- explicit curriculum state
- progression-aware picking
- separate generation and recall loops
- small, inspectable output steps
Replace:
- the curriculum
- the delivery channel
- the output format
- the persistence and scheduling backend
This repo ships a file-backed graph DB and a read-only MCP stub:
The graph starts as files on purpose. If the repo grows up:
- move to SQLite or Postgres for larger local state
- move to a graph-native backend when relationships become the main query surface
- keep the MCP boundary read-only even after the storage backend changes
src/picker.ts— progression-aware concept selectionsrc/prompt-template.ts— teaching-draft prompt shapecurriculum/concepts.json— concept catalogcurriculum/ledger.json— drill historycurriculum/study-ledger.json— recall statePATTERN.md— the reusable pattern in one pageSCENARIOS.md— standalone, pair, and trinity scenariosAXIOMS.md— local map to immutable StoneyTECH axiomsgraph/— file-backed graph DB plus upgrade notesmcp/— repo-local read-only MCP stub and manifestproviders/— BYO-provider upgrade mapshadow/— shadow-tribunal starter configintegrations/n8n/— workflow stub and handoff seams
Apache-2.0