Commit Graph
3 Commits
Author SHA1 Message Date
wyucandClaude Fable 5 4f00cf7ad6 feat(materials): material library manifest and id-addressed generation images (#1153 part 2) (#1168)
* feat(materials): material library manifest and id-addressed generation images (#1153 part 2)

* fix(materials): library-owned references and failure-path parity (#1153 part 2)

* fix(generation): resolve-then-slice vision images and close allocation leaks (#1153 part 2)

* fix(generation): bound vision resolution and make library writes leak-safe (#1153 part 2)

Bound the resolve-with-refill phase with an aggregate 15s budget raced
against every probe plus a 3-consecutive-failure fuse — either stop strips
unresolved and unprobed ids from the mapping and proceeds (text-only at
worst), never failing the request. Restore the original interleaved text
ordering for non-vision runs with a mapping present. Guard the library's
failed-entry-write release with an ambiguous-commit re-read: release only
when the entry provably does not point at the new id, keep it when the
write actually landed, and prefer a recoverable leak over a dangling entry
when the re-read fails. Drop the unused package export.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

* chore(generation): bump @openmaic/generation to 0.3.1 (#1153 part 2)

The package's inputs changed (partitionImagesForVision, resolvedVisionImages
option, non-vision ordering fix); the merge-time gate requires a version bump.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-08-24 18:08:40 +08:00
Yizuki_Ame 95b5c2bf55 fix: persist agent configs in server-generated classrooms (#336)
* fix: persist agent configs in server-generated classrooms (#316)

Server-generated classrooms via /api/generate-classroom silently skip all discussion actions because agent configurations are never embedded in the persisted Stage object.

Changes:

- Add optional generatedAgentConfigs field to Stage interface

- Inject agent configs (with avatar/color/priority) into Stage during server-side generation

- Hydrate agents into IndexedDB/registry when loading from server storage on client

Closes #316

* fix: extract shared agent constants and fix avatar paths

- Extract AGENT_COLOR_PALETTE and AGENT_DEFAULT_AVATARS into
  lib/constants/agent-defaults.ts to eliminate duplication
- Fix invalid avatar paths (student.png -> assist.png, etc.)
  to match actual files in public/avatars/
- Remove duplicated inline constants from classroom-generation.ts
  and agent-profiles/route.ts

Addresses reviewer feedback on #336

---------
2026-04-02 16:23:16 +08:00
wyucandClaude Opus 4.6 0d20abfed9 Initial commit: OpenMAIC AI classroom platform
Next.js 16 App Router application with:
- AI-powered interactive classroom generation from PDF/text requirements
- Multi-agent discussion system (teacher, students, assistant roles)
- Provider abstraction for LLM, TTS, ASR, image, video, web search
- Local-first data architecture (IndexedDB/Dexie)
- i18n support (zh-CN/en-US)
- Structured logger, SSRF guard, lint/build passing (0 errors)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 16:41:07 +08:00