Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions openwiki/.last-update.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"updatedAt": "2026-09-05T23:56:10.651Z",
"updatedAt": "2026-09-06T04:26:16.149Z",
"command": "update",
"gitHead": "da92936486b4c180b97579d54d44ae8019497533",
"gitHead": "a83da20c54b49c88829f4052419359f4724dd6ea",
"model": "zai.glm-5",
"status": "complete",
"language": "en"
Expand Down
2 changes: 1 addition & 1 deletion openwiki/agent-platform/index.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# Files

- [Agent Platform & Skills System](overview.md) - Extensible agent skill system with 36 domain-specific capabilities, Google Workspace integration, Cedar governance, and MCP tool exposure for K-12 AI assistants.
- [Agent Platform & Skills System](overview.md) - Extensible agent skill system with 39 domain-specific capabilities including media processing (HTML-to-PDF, ffmpeg, transcription), Google Workspace integration, Cedar governance, and MCP tool exposure for K-12 AI assistants.
18 changes: 17 additions & 1 deletion openwiki/agent-platform/overview.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
type: Platform Overview
title: Agent Platform & Skills System
description: Extensible agent skill system with 36 domain-specific capabilities, Google Workspace integration, Cedar governance, and MCP tool exposure for K-12 AI assistants.
description: Extensible agent skill system with 39 domain-specific capabilities including media processing (HTML-to-PDF, ffmpeg, transcription), Google Workspace integration, Cedar governance, and MCP tool exposure for K-12 AI assistants.
tags: [agents, skills, mcp, workspace, governance]
---

Expand Down Expand Up @@ -42,6 +42,9 @@ infra/agent-image/skills/{skill-name}/
- `psd-learning-page` — Multimodal UDL learning page generation
- `psd-hyperframes` — HTML/CSS/JS to MP4 video rendering
- `psd-html-artifact` — HTML artifacts published to Atrium with WCAG 2.2 AA audit, delivered as internal reader pages (not S3)
- `psd-print-pdf` — HTML to printable PDF with headless Chromium (8.5×11, letter, A4, landscape), honouring `@page` CSS, flexbox, and web fonts; routes through agent-media Lambda
- `psd-media` — ffprobe inspection + ffmpeg transcode via named presets (`social-mp4`, `web-mp4`, `audio-mp3`); routes through agent-media Lambda
- `psd-transcribe` — Speech-to-text using Amazon Transcribe over audio/video in owner's private workspace; routes through agent-media Lambda
- `psd-pdf-to-markdown` — PDF to Markdown conversion; scanned/image-only PDFs rendered to page images via `--rasterize-pages`
- `psd-image-gen` — Image generation
- `psd-sop-creator` — PSD Standard Operating Procedure document creation
Expand Down Expand Up @@ -80,6 +83,19 @@ Skills run in the agent container defined by `/infra/agent-image/Dockerfile`. Th
3. Executes skill logic with requested capabilities
4. Audits all credential reads and tool invocations

### Media Relay Transport

**Source**: `/infra/agent-image/skills/_shared/media-relay.js`, `/infra/agent-image/mantle_proxy.py`

The `psd-print-pdf`, `psd-media`, and `psd-transcribe` skills route through a shared transport that:

- Uploads workspace objects to `.media-scratch/` via the workspace broker (added to checkpoint exclusions in workspace-policy.json)
- Invokes the agent-media Lambda through the root-owned loopback relay
- Validates workspace-relative paths against traversal, backslashes, and control characters
- Removes scratch objects on all exit paths (important for transcription: the transport copy is someone's voice)

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Do not claim scratch cleanup covers failures

When psd-media or psd-transcribe fails after uploading an input, their catch blocks call fail(), which invokes process.exit(1) before the surrounding finally can run (media.js:166-170, transcribe.js:126-131). The scratch object therefore remains as a current S3 object, and the workspace bucket has no current-version expiration rule for .media-scratch/. Correct the underlying cleanup flow and regenerate this passage, or stop promising removal on all exit paths—especially because this guarantee is presented as protecting voice recordings.

AGENTS.md reference: AGENTS.md:L418-L418

Useful? React with 👍 / 👎.


The relay injects `workspacePrefix` from the web-verified invocation context — the caller never states who it is, preventing cross-owner access. Publishing stays separate through `psd-publish-file` and its sensitivity gate.

### Bundled Skill Manifest

Agent image builds include a bundled skill catalog (`/infra/lib/bundled-skill-manifest.ts`) that enforces catalog approval for skill loads. The manifest:
Expand Down
19 changes: 19 additions & 0 deletions openwiki/infrastructure/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,25 @@ For multi-turn agent architecture, see **[agent-platform/overview.md](../agent-p
|--------|---------|
| `agent-mint/` | DWD token broker (isolated security) |
| `hyperframes-render/` | HTML to video rendering |
| `agent-media/` | HTML-to-PDF, ffmpeg transcode/probe, and Amazon Transcribe |

### Agent Media Function

**Source**: `/infra/lib/constructs/compute/agent-media-function.ts`, `/infra/agent-media/`

A container-image Lambda providing three capabilities the agent kept having to refuse (issue #1738):

| Operation | Purpose |
|-----------|---------|
| `html-to-pdf` | Headless Chromium print-to-PDF, honouring `@page` CSS |
| `media` | ffprobe inspection + ffmpeg transcode via named presets |
| `transcribe` | Amazon Transcribe over audio in owner's private workspace |

**Why separate from hyperframes-render**: IAM isolation. That role may write only to `public-images/`; this one reads/writes owners' private workspace prefixes and carries an explicit DENY on `public-images/`. A scanned IEP or staff recording must never become a public-by-link object.

**Security model**: The function never accepts an identity from its caller. The relay injects `workspacePrefix` after the web-verified invocation context; the caller supplies only workspace-relative paths, validated against traversal, backslashes, and control characters. Publishing stays a separate act through `psd-publish-file`.

**Configuration**: x86_64 container (Chromium + FFmpeg cannot live in agent image), 4096 MB memory, 900s timeout, 6144 MB ephemeral storage, reserved concurrency 5. Amazon Transcribe scoped to `agent-media-*` job name prefix so this role cannot disturb other account jobs.

### Workspace Contract Validation

Expand Down
Loading