JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 202
  • Score
    100M100P100Q90752F
  • License https://github.com/ncounterspecialist/twick/blob/main/LICENSE.md

Workflow builders and appliers for Twick AI and project assembly.

Package Exports

  • @twick/workflow
  • @twick/workflow/dist/index.js
  • @twick/workflow/dist/index.mjs

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@twick/workflow) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

@twick/workflow

Workflow builders and appliers that bridge normalized AI outputs with Twick timeline/project data.

Purpose

  • Keep provider and model contracts in @twick/ai-models
  • Keep schema, serialization, and core editor behavior in @twick/timeline
  • Use @twick/workflow as the integration layer that:
    • builds ProjectJSON from normalized results
    • applies patches to project data
    • applies patches through TimelineEditor

Core API

import {
  buildCaptionProject,
  applyCaptionsToProject,
  buildProjectFromTemplateSpec,
} from "@twick/workflow";

const project = buildCaptionProject({
  videoUrl: "https://cdn.example.com/video.mp4",
  durationSec: 12,
  captions: [
    { t: "Hello world", s: 0, e: 1400 },
    { t: "This is Twick", s: 1500, e: 2900 },
  ],
});

const updated = applyCaptionsToProject(project, {
  captions: [{ t: "New caption", s: 3000, e: 4200 }],
  insertionStartSec: 3,
  insertionEndSec: 5,
});

const templated = buildProjectFromTemplateSpec({
  width: 720,
  height: 1280,
  tracks: [],
});

Notes

  • Legacy flows can continue to work through compatibility wrappers.
  • New AI integrations should prefer @twick/ai-models + @twick/workflow.