Repository navigation
feat(elos): share a read-only learner snapshot with local agents (Hermes) - #22
Conversation
…mes) App side (Données → Agent local): - the learner picks a folder once (File System Access API, Chrome/Edge); ELOS writes elos-state.json there and keeps it fresh while open (every minute and when the tab is hidden, only if changed, never prompting); download fallback for other browsers; sharing can be stopped - minimal content: words and cards due, difficulties, upcoming exams, streak, scheduler replay summary. Never personal sentences, transcriptions, notes, answers or source passages (tested) MCP side: elos_today, elos_progress and elos_exam_plan read the file from ELOS_STATE_FILE, validate it strictly, flag snapshots older than 24 h and never write back or grant mastery. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
ⓘ Qodo reviews are paused because the subscription is no longer active. Ask your workspace admin to reactivate the subscription to resume reviews. Manage billing |
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configuration
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: a6a8fb8a64
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (value?.format !== SNAPSHOT_FORMAT || value.version !== SNAPSHOT_VERSION || typeof value.generatedAt !== "string" | ||
| || typeof value.today !== "string" || !value.dailyEnglish || !value.studio || !Array.isArray(value.exams)) { |
There was a problem hiding this comment.
Validate the complete snapshot structure
Reject malformed nested data here rather than accepting any truthy dailyEnglish and studio values. For example, a syntactically valid file with dailyEnglish: {} passes this check, after which elos_today dereferences dueWords.length and fails with an MCP tool error instead of returning the documented invalid-snapshot response. Validate the nested arrays, objects, scalar types, and date strings before casting to LearnerSnapshot.
AGENTS.md reference: AGENTS.md:L30-L31
Useful? React with 👍 / 👎.
| }, | ||
| studio: { | ||
| scheduler: input.studio.scheduler ?? "CURRENT_V1", | ||
| dueToday: (plan[0]?.due ?? []).slice(0, MAX_ITEMS).flatMap((id) => { |
There was a problem hiding this comment.
Preserve the total count when truncating due cards
When more than 30 cards are due—especially on a fresh Studio library, where every never-reviewed card is due today—this slice silently discards the remainder. elos_today then uses snapshot.studio.dueToday.length as the exact workload and tells the agent to review only 30 cards, so the generated study plan understates the learner's actual backlog. Keep the bounded item list, but include the untruncated total or a truncation marker.
Useful? React with 👍 / 👎.
Summary
elos-state.jsonand keeps it fresh while open (changes only, never prompting); download fallback; stop sharing anytime.elos_today,elos_progress,elos_exam_planreadELOS_STATE_FILE, strict validation, stale (>24 h) warning, read-only.Test plan
npm test642/642 (snapshot privacy + 8 MCP integration tests), typecheck,eslint ., build🤖 Generated with Claude Code