agentleFS
SuntorlinSuntorlin/mate-agent/skills/builtin/preview/SKILL.md

preview

Skill0 starsChanged 37 days agoMITView on GitHub

The pane to the right of the chat is yours: whatever you publish there opens as a tab, and the newest one is shown. Files to download are listed there too. Publish with the media-preview command (on PATH): Several files go in one call as <file> "<title>" pairs (--file before a pair makes that one a download), published in the order given; every pair is checked first, so a bad one publishes nothing. Publish what belongs together in one call…

23 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use ml-training-recipe, replication and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • getcompanion-aiSkill

    ml-training-recipe

    Find implementable ML training recipes from papers, datasets, docs, and code. Use when the user wants to fine-tune, train, reproduce, or choose a practical ML method, dataset, hyperparameter setup, or benchmark recipe.

    Also in 3 projects that use this

  • getcompanion-aiSkill

    replication

    Plan a replication of a paper, claim, or benchmark, and execute only after an explicit environment choice. Use when the user asks to replicate results, reproduce an experiment, verify a claim empirically, or build a replication package.

    Also in 3 projects that use this

  • brainbytes-devSkill

    alpha-research

    Also in 3 projects that use this

  • JaimeParkerSkill

    paper-code-audit

    Perform three-way cross-validation of a research paper by comparing the original paper text (via Zotero), official code implementation (via Git), and personal Obsidian notes. Use this skill whenever the user wants to "audit a paper", "verify paper claims against code", "cross-check notes with implementation", "triangulate paper + code + notes", "find discrepancies between paper and code", or mentions wanting a deep, structured comparison of a paper's claims against its implementation and their own notes. Also trigger when the user asks to "analyze this paper thoroughly" with code available, or when they want to systematically reconcile what the paper says, what the code does, and what their notes claim.

    Also in 3 projects that use this

  • JimLiuSkill

    pdf-explore

    Use this skill when the user has attached a PDF, paper, report, or other document and the answer needs content from more than one place in it: summarize the methods or any other section, compare sections, find where a topic is discussed, read a value or label off a figure or chart, or find/list/extract every instance of something across the whole document (datasets, benchmarks, citations, figures, table rows, accession numbers — including appendices). Skip it only for a single lookup of 1–4 pages quoted in your very next response — `read_file(pages=[...])` attaches pages as images that are dropped from context after one turn, so multi-section answers end up re-reading the same ranges repeatedly. Parses the PDF once in the Python kernel: `pdf_pages` (pages as persistent text), `pdf_outline` (TOC), `pdf_scan` (rank pages by relevance), `pdf_map`/`pdf_extract` (per-page summary / structured fields via parallel haiku calls). For PDF creation/manipulation, use reportlab/pypdf directly.

    Also in 3 projects that use this

  • KISHOR403Skill

    session-search

    This skill should be used when searching Claude Code session transcripts with semantic understanding. Triggers on queries like "find sessions about X", "when did I work on Y", "search previous conversations". Supports natural language queries with synonym matching.

    Also in 3 projects that use this

  • +1 more from getcompanion-ai

The file

We split this skill into the rules it gives an agent

3 rules. 0 are common, 0 are distinctive, and 3 are very specific to this project.

  • 0

    Common

    Most of the 13 edited versions we read keep these.

  • 0

    Distinctive

    This author's own choices. Worth a look.

  • 3

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    When the project has a script, optionally a short brief or shot list as a .md ("脚本与分镜表").

    line 104
  2. Very specific:

    Timeline: When a video comes from a timeline.json (render), publish that timeline next to the render, as a file named *.timeline.json:

    line 111
  3. Very specific:

    Never Chrome's own --headless --screenshot: it hangs in this sandbox.

    line 181

“Common” is measured: kept by at least 6 in 10 of the 13 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

preview

The pane to the right of the chat is yours: whatever you publish there opens as a tab, and the newest one is shown. Files to download are listed there too. Publish with the media-preview command (on PATH):

media-preview renders/v02.mp4 "成片 v2"
media-preview review/keyframes.jpg "Keyframes"
media-preview storyboard.html "Storyboard"
media-preview audio/music.mp3 "配乐"
media-preview handoff/edit.fcpxml "Final Cut 工程"
media-preview --file renders/master_prores.mov "母版 ProRes"
media-export /workspace/project "项目文件"

Several files go in one call as <file> "<title>" pairs (--file before a pair makes that one a download), published in the order given; every pair is checked first, so a bad one publishes nothing. Publish what belongs together in one call rather than one call each:

media-preview review/shot1.jpg "分镜 1 · 开场" review/shot2.jpg "分镜 2 · 产品特写" \
  review/shot3.jpg "分镜 3 · 结尾" audio/music.mp3 "配乐" renders/v01.final.mp4 "成片 v1"

Did it work? Read the exit code, not the JSON. Exit 0 means every pair is published; the last line of output says so in words — published 5/5: 分镜 1 · 开场, 分镜 2 · 产品特写, 分镜 3 · 结尾, 配乐, 成片 v1. Exit 1 means some were not: the last line counts them (published 4/5: ...) and the error names each title that failed — publish only those again. Never republish after exit 0, and do not count or grep the JSON to decide. Above the summary is one line of JSON per pair with its artifactId and title. Publishing the same file again (same bytes, file name and title) in this session uploads nothing: it returns the artifact it already became, marked "alreadyPublished":true, so a repeat never makes a second card. A new version is new content or a new title.

Preview (plays or shows in the pane):

  • Video: H.264 MP4 (with or without audio), at most 10 minutes and 1 GB, 200 per session. Duration, frame size and audio are read with ffprobe. 4K and long cuts play, but keep previews light (CRF 23–28, -movflags +faststart) so they start at once.
  • Image: PNG, JPEG or WebP, at most 10 MB.
  • Audio: MP3, WAV, M4A, AAC, OGG/Opus or FLAC gets its own tab with a player and waveform (the waveform up to 25 MB: a long WAV goes in as MP3 or M4A).
  • Document: Markdown (.md) and plain text are read in place; a PDF opens in the viewer.
  • Page: one self-contained HTML file, at most 10 MB, 50 per session. Inline its CSS and scripts; images go in as data: URIs or https:// URLs. It runs sandboxed in its own origin: no cookies, no forms, no requests to the sandbox, links open in a new tab. Use a page when a layout says more than a single image: storyboards, shot lists with frames, side-by-side cuts.

Download (listed in the pane with name, size and a download button):

  • Any other file becomes a download: DOCX, CSV, ZIP, FCPXML / Premiere XML / EDL / OTIO, ProRes/HEVC/VP9 .mov/.webm/.mkv, SRT/VTT captions, .cube LUTs (audio and documents above can be downloaded too). Up to 4 GB each, 200 per session; the file keeps its name.
  • --file hands over a previewable file as a download instead: the full-quality master .mp4, a full-resolution still.
  • Preview and delivery are separate: deliver masters (any codec, 4K, long, alpha) as files, and publish an H.264 preview of the same cut for watching.

media-export [folder] ["<title>"] zips a whole project folder (default /workspace/project): sources, timeline, captions, audio stems, renders and editing-app project files, without node_modules and caches. The pane offers the newest one as "Download project". Run it only when the user asks — for the project or source files, or to continue in their own editor. A finished video is not a reason to offer the zip, and the zip is never a default deliverable.

The title is the tab or file name the user sees: a few words in the user's language that say what it is ("成片 v2", "Storyboard", "Final Cut 工程"), never a path, codec or other engineering detail. Do not say something is in the preview or ready to download unless media-preview exited 0 (or its title is in the published line).

Show the process. The canvas is where the user watches the work take shape: their references and what you publish, versions in a row. What you make in the sandbox shows only when you publish it. In a creative job (a video, an edit, a series of images), publish, in the user's language:

  1. Storyboard frames, as soon as there is something to show and at the latest right after the first draft render: 3–8 images, one per planned or rendered shot, each titled by its shot ("分镜 1 · 开场", "分镜 2 · 产品特写"). They form the Storyboard tab. Take them from the draft render (one frame from the middle of each shot), a Remotion still (npx --no-install remotion still src/index.ts Main review/shot1.jpg --frame=<n>), a HyperFrames frame or a Blender still; do not republish generated media as it is.

    i=0; for t in 1.2 4.5 8.0 11.5 15.0; do i=$((i+1))   # the middle of each shot, from the timeline
      ffmpeg -v error -y -ss "$t" -i renders/v01.mp4 -frames:v 1 -vf scale=720:-2 -q:v 3 "review/shot$i.jpg"
    done
  2. Audio you made that shapes the piece: the music bed you synthesized, the final voice-over mix ("配乐", "旁白混音"). Not every line or stem.
  3. Each revision as a new version: the same title with the next number, then a short note of what changed after " · " ("成片 v1", then "成片 v2 · 开场换成产品特写"). The board matches titles up to the version mark, so v1 → v2 stay joined and the note shows on the card. Never reuse the old title for a new cut.
  4. When the project has a script, optionally a short brief or shot list as a .md ("脚本与分镜表").

The final cut is published as before and is the last video you publish in the turn: the chat shows the turn's last video as its result. Publish frames, audio and documents before it, or ahead of it in the same call. Batch: one call for the storyboard frames (plus the music if it is ready), one for the draft or final cut, not one call per file.

Timeline. When a video comes from a timeline.json (render), publish that timeline next to the render, as a file named *.timeline.json:

media-preview renders/v02.mp4 "成片 v2"
cp project/timeline.json renders/v02.timeline.json && media-preview --file renders/v02.timeline.json "成片 v2 工程"

The pane shows it under the video it matches (same length): shots, text, captions and audio as blocks the user can click to jump to, and comment on. Publish a new one with each render.

Canvas. The canvas arranges itself — you never have to write a layout file. Everything you publish lands as a card on the board described above: versions named alike ("成片 v1", "成片 v2") share a row with arrows between them, and the user pins comments anywhere. A *.canvas.json replaces that board with yours (everything published, plus only the references it names), so publish one only when a layout would say more than the lanes — options to choose from, or an arrangement the user asked for:

cat > review/board.canvas.json <<'JSON'
{ "rows": [
    { "title": "分镜", "items": ["镜头 1", "镜头 2", "镜头 3"] },
    { "title": "成片", "items": ["成片 v1", "成片 v2"], "arrows": true }
  ],
  "from": { "成片 v1": ["镜头 1", "镜头 2", "镜头 3"] } }
JSON
media-preview --file review/board.canvas.json "画布"
  • Rows run top to bottom, items left to right. An item is the exact title you published it with (a downloaded file's name works too). That is all there is — no positions, sizes, colours or version numbers; title, a one-line note beside it, and arrows (link each item to the next) are optional, and a name that matches nothing is skipped, never an error.
  • "from" is lineage: for each thing, the things it was made from (the shots a cut was assembled from, the frame a cover was taken from). Things with lineage are laid out as a flow, sources on the left, results to their right, joined by lines. Record it whenever one published thing was made from others; rows and from each work alone.
  • Publishing the file opens the Canvas. A new version of something already in a row joins it by itself, with an arrow — nothing to do for a revision. Publish again only when the rows change (the newest file replaces the last one); whatever it leaves out stays on the board, below.

Review comments. The user can pin comments on what you published: a moment and a spot in a video, a spot in an image, a timeline block, a whole page, or the work as a whole (a note on the canvas itself: no artifactId, just n and text). They arrive as one message: a numbered list in their words, attached stills (the video frame or image with the comment's number drawn at the spot, in comment order), and a review-comments JSON block:

[
  {
    "n": 1,
    "artifactId": "…",
    "artifact": "成片 v2",
    "time": 12.4,
    "x": 0.32,
    "y": 0.18,
    "item": { "track": "shots", "index": 3, "label": "shot03", "start": 8, "end": 11.5 },
    "image": 1,
    "text": "这个镜头换成产品特写"
  }
]

x and y run 0–1 from the top left of the frame. item.track is the timeline array (shots, texts, captions, audio) and item.index is 1-based into the timeline you published for that video. Change only what the comments ask, render, publish the new version with a new title ("成片 v3") and its timeline, and answer each comment by number in one short line.

To look at a page yourself before publishing it, screenshot it with viral-remake's screenshot_page.sh (agent-browser, full page, killed after 60 s) or timeout 60 agent-browser …. Never Chrome's own --headless --screenshot: it hangs in this sandbox.

Publish when the user should look or listen: a storyboard before spending on it, keyframes before animating them, storyboard frames of the first draft, the music and voice-over you made, each render worth reviewing, and the final cut last. Do not publish intermediate files nobody needs to see (every voice line, scratch renders, stems, caches).

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.