@telepat/rilo 0.1.6 → 0.1.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.de.md ADDED
@@ -0,0 +1,101 @@
1
+ <p align="center"><img src="./assets/avatar/rilo-logo.webp" width="128" alt="Rilo"></p>
2
+ <h1 align="center">Rilo</h1>
3
+ <p align="center"><em>Verwandle eine Geschichte in ein fertiges Video — KI-generiertes Skript, Voiceover, Keyframes und Komposition, alles mit einem Befehl.</em></p>
4
+
5
+ <p align="center">
6
+ <a href="https://docs.telepat.io/rilo">📖 Docs</a>
7
+ · <a href="./README.md">🇺🇸 English</a>
8
+ · <a href="./README.zh-CN.md">🇨🇳 简体中文</a>
9
+ · <a href="./README.de.md">🇩🇪 Deutsch</a>
10
+ </p>
11
+
12
+ <p align="center">
13
+ <a href="https://github.com/telepat-io/rilo/actions/workflows/ci.yml"><img src="https://github.com/telepat-io/rilo/actions/workflows/ci.yml/badge.svg?branch=main" alt="Build"></a>
14
+ <a href="https://codecov.io/gh/telepat-io/rilo"><img src="https://codecov.io/gh/telepat-io/rilo/graph/badge.svg" alt="Codecov"></a>
15
+ <a href="https://www.npmjs.com/package/@telepat/rilo"><img src="https://img.shields.io/npm/v/@telepat/rilo" alt="npm"></a>
16
+ <a href="https://github.com/telepat-io/rilo/blob/main/LICENSE"><img src="https://img.shields.io/badge/license-MIT-yellow.svg" alt="License"></a>
17
+ </p>
18
+
19
+ Rilo verwandelt eine Geschichte in ein fertiges Video — KI-generiertes Skript, Voiceover, Keyframes und Komposition, alles mit einem Befehl.
20
+
21
+ Schreiben Sie Ihre Geschichte in einfachem Text. Rilo übernimmt den Rest: Skripterstellung, Erzählung, visuelle Keyframes, Videosegmente und die finale Komposition – mit optionaler Untertitel-Synchronisation und Einbrennung.
22
+
23
+ Entwickelt für Kreative und Teams, die reproduzierbare, hochwertige Videos in großem Umfang ohne manuellen Schnitt benötigen.
24
+
25
+ ## Features
26
+
27
+ - **Vollständige Pipeline, ein Befehl** — Story → Skript → Voiceover → Keyframes → Segmente → finales Video. `rilo --project demo --story-file ./story.txt`
28
+ - **Checkpoint-gestützte Durchläufe** — Jede Stufe speichert Artefakte. Setzen Sie beliebige Stufen fort oder generieren Sie sie selektiv neu. `rilo --project demo --force`
29
+ - **Ihre Modelle, Ihre Kontrolle** — Wählen Sie T2I- und I2V-Modelle. Überschreiben Sie modellspezifische Optionen. Wechseln Sie Modelle jederzeit.
30
+ - **Code-gesteuerte Pipeline** — Deterministische Orchestrierung, Checkpointing und Artefaktverwaltung. Tokens werden für die Generierung ausgegeben, nicht für Infrastruktur.
31
+ - **Untertitel-Synchronisation & Einbrennung** — Untertitel automatisch an Voiceover-Timing ausrichten. Ins finale Video einbrennen.
32
+ - **Vorschau-Dashboard** — Web-UI für Projektverwaltung, Neugenerierung und Asset-Vorschau. `rilo preview`
33
+ - **HTTP-API & Webhooks** — Bearer-Token-Authentifizierung, OpenAPI-3.1-Spezifikation, Webhook-Abonnements. Firebase oder lokal.
34
+ - **Plattformübergreifend** — macOS, Linux, Windows. Node.js 22+ und ffmpeg.
35
+
36
+ ## Quick Start
37
+
38
+ Voraussetzungen: Node.js 22+, ffmpeg im PATH und ein Replicate API-Token.
39
+
40
+ ```bash
41
+ npm install -g @telepat/rilo
42
+ rilo settings
43
+ rilo --project demo --story-file ./story.txt
44
+ ```
45
+
46
+ Erwartetes Ergebnis:
47
+
48
+ - Ein Projektordner wird unter `projects/demo/` erstellt.
49
+ - Die vollständige Pipeline durchläuft Skript, Voiceover, Keyframes, Segmente und Komposition.
50
+ - Das finale Video wird unter `projects/demo/final.mp4` abgelegt.
51
+ - Dashboard-Vorschau verfügbar via `rilo preview`.
52
+
53
+ ## Requirements
54
+
55
+ - Node.js 22+
56
+ - ffmpeg im PATH
57
+ - Replicate API-Token
58
+ - macOS, Linux oder Windows
59
+
60
+ ## How It Works
61
+
62
+ Rilo durchläuft eine gestufte Pipeline: Skripterstellung, Voiceover-Synthese, Shot-Prompt-Generierung, Keyframe-Rendering, Segmentgenerierung und finale Videokomposition. Jede Stufe schreibt Checkpoint-Artefakte, sodass Sie selektiv fortsetzen oder neugenerieren können.
63
+
64
+ Die Konfiguration fasst CLI-Flags, Umgebungsvariablen und `~/.rilo/config.json` mit Schema-Defaults zusammen. Das Vorschau-Dashboard (`rilo preview`) startet eine lokale API, einen Worker und ein Vite-React-Frontend für Monitoring und Bearbeitung.
65
+
66
+ ## Using With AI Agents
67
+
68
+ Rilo bietet mehrere Schnittstellen für agentische und automatisierte Workflows:
69
+
70
+ - **CLI-Automatisierung** — Die gesamte Generierung wird durch CLI-Flags und Umgebungsvariablen gesteuert. Nach der initialen Einrichtung sind keine interaktiven Prompts erforderlich.
71
+ - **HTTP-API** — `rilo preview` startet eine Express-API mit vollständigem Job- und Projekt-CRUD, Asset-Serving und Webhook-Endpunkten. Bearer-Token-Authentifizierung via `Authorization: Bearer <API_BEARER_TOKEN>`.
72
+ - **OpenAPI-Spezifikation** — Automatisch generierte OpenAPI-3.1-Spezifikation für schema-gesteuerte Agent-Integration.
73
+ - **Webhooks** — Abonnieren Sie Job-Lifecycle-Events für externe Orchestrierung.
74
+ - **Firebase Functions** — Stellen Sie `src/api/firebaseFunction.js` für serverloses API-Hosting bereit.
75
+ - **Agent-Dokumentation** — [API Reference](https://docs.telepat.io/rilo/reference/api-reference) behandelt Endpunkte, Authentifizierung und Webhooks.
76
+
77
+ ## Security And Trust
78
+
79
+ - API-Tokens und Replicate-Zugangsdaten werden, wenn verfügbar, im OS-Keystore gespeichert (macOS Keychain, Windows Credential Manager, Linux Secret Service).
80
+ - Fallback auf eine AES-256-verschlüsselte Datei unter `~/.rilo/.secrets`, falls kein nativer Keystore verfügbar ist.
81
+ - Umgebungsvariablen (`TELEPAT_REPLICATE_TOKEN`, `RILO_API_BEARER_TOKEN`) haben höchste Priorität und überschreiben gespeicherte Werte.
82
+ - Der Preview-Modus `--expose` sollte nur in vertrauenswürdigen Netzwerken oder isolierten Umgebungen verwendet werden.
83
+
84
+ ## Documentation And Support
85
+
86
+ - [Documentation site](https://docs.telepat.io/rilo)
87
+ - [Quickstart](https://docs.telepat.io/rilo/getting-started/quickstart)
88
+ - [CLI Reference](https://docs.telepat.io/rilo/reference/cli-reference)
89
+ - [Configuration Guide](https://docs.telepat.io/rilo/guides/configuration)
90
+ - [API Reference](https://docs.telepat.io/rilo/reference/api-reference)
91
+ - [Troubleshooting](https://docs.telepat.io/rilo/guides/troubleshooting)
92
+ - [Repository](https://github.com/telepat-io/rilo)
93
+ - [npm package](https://www.npmjs.com/package/@telepat/rilo)
94
+
95
+ ## Contributing
96
+
97
+ Beiträge sind willkommen. Siehe [Development](https://docs.telepat.io/rilo/contributing/development) für lokale Einrichtung, Build-Befehle und Test-Workflows.
98
+
99
+ ## License
100
+
101
+ MIT. Siehe [LICENSE](./LICENSE).
package/README.md CHANGED
@@ -1,224 +1,101 @@
1
- # Rilo
2
-
3
- [![CI](https://github.com/telepat-io/rilo/actions/workflows/ci.yml/badge.svg)](https://github.com/telepat-io/rilo/actions/workflows/ci.yml)
4
- [![Coverage](https://codecov.io/gh/telepat-io/rilo/graph/badge.svg)](https://codecov.io/gh/telepat-io/rilo)
5
- [![npm version](https://img.shields.io/npm/v/%40telepat%2Frilo)](https://www.npmjs.com/package/@telepat/rilo)
6
- [![npm downloads](https://img.shields.io/npm/dm/%40telepat%2Frilo)](https://www.npmjs.com/package/@telepat/rilo)
7
- [![Docs](https://img.shields.io/badge/docs-live-22c55e)](https://docs.telepat.io/rilo/)
8
- [![License](https://img.shields.io/github/license/telepat-io/rilo)](./LICENSE)
9
-
10
- Story-first vertical video generation.
11
-
12
- Rilo turns one story into a complete short-form video pipeline:
13
- - script generation
14
- - voiceover generation
15
- - keyframe generation
16
- - video segment generation
17
- - final composition
18
- - optional subtitle alignment and burn-in
19
-
20
- ## Why Rilo
21
-
22
- - Built for vertical video workflows
23
- - Checkpointed runs with resume support
24
- - Targeted regeneration for faster iteration
25
- - Model selection and per-model option overrides
26
- - Local and Firebase output backends
27
- - API, worker, and frontend flow for production usage
1
+ <p align="center"><img src="./assets/avatar/rilo-logo.webp" width="128" alt="Rilo"></p>
2
+ <h1 align="center">Rilo</h1>
3
+ <p align="center"><em>Turn a story into a finished video — AI-generated script, voiceover, keyframes, and composition, all in one command.</em></p>
28
4
 
29
- ## Quick Start
30
-
31
- Requirements:
32
- - Node.js 22+
33
- - ffmpeg in PATH
34
- - Replicate API token
35
-
36
- Install from npm and configure settings:
37
-
38
- ```bash
39
- npm install -g @telepat/rilo
40
- rilo settings
41
- rilo --project demo --story-file ./story.txt
42
- ```
43
-
44
- If you prefer environment variables instead of the interactive settings menu:
45
-
46
- ```bash
47
- export RILO_REPLICATE_API_TOKEN=your-token
48
- export RILO_API_BEARER_TOKEN=your-api-bearer-token
49
- ```
50
-
51
- ## Contributor Workflow
52
-
53
- For development in this repository:
54
-
55
- ```bash
56
- npm install
57
- cp .env.example .env
58
- npm run dev:all
59
- ```
60
-
61
- ## Settings
62
-
63
- Configure rilo interactively without editing files:
64
-
65
- ```bash
66
- rilo settings
67
- ```
5
+ <p align="center">
6
+ <a href="https://docs.telepat.io/rilo">📖 Docs</a>
7
+ · <a href="./README.md">🇺🇸 English</a>
8
+ · <a href="./README.zh-CN.md">🇨🇳 简体中文</a>
9
+ · <a href="./README.de.md">🇩🇪 Deutsch</a>
10
+ </p>
68
11
 
69
- If you're working from a checked-out repository instead of an installed package:
12
+ <p align="center">
13
+ <a href="https://github.com/telepat-io/rilo/actions/workflows/ci.yml"><img src="https://github.com/telepat-io/rilo/actions/workflows/ci.yml/badge.svg?branch=main" alt="Build"></a>
14
+ <a href="https://codecov.io/gh/telepat-io/rilo"><img src="https://codecov.io/gh/telepat-io/rilo/graph/badge.svg" alt="Codecov"></a>
15
+ <a href="https://www.npmjs.com/package/@telepat/rilo"><img src="https://img.shields.io/npm/v/@telepat/rilo" alt="npm"></a>
16
+ <a href="https://github.com/telepat-io/rilo/blob/main/LICENSE"><img src="https://img.shields.io/badge/license-MIT-yellow.svg" alt="License"></a>
17
+ </p>
70
18
 
71
- ```bash
72
- npm run dev -- settings
73
- npm run dev -- --project demo --story-file ./story.txt
74
- ```
19
+ Rilo turns a story into a finished video — AI-generated script, voiceover, keyframes, and composition, all in one command.
75
20
 
76
- This opens a menu where you can edit all non-sensitive settings and manage API tokens securely. Navigate with arrow keys, select with Enter, and use "Done" or "Cancel" to exit. You can also press Ctrl+C at any time to quit.
21
+ Write your story in plain text. Rilo handles the rest: script generation, narration, visual keyframes, video segments, and final composition with optional subtitle alignment and burn-in.
77
22
 
78
- **What gets stored where:**
23
+ Built for creators and teams who need reproducible, high-quality video at scale without manual editing.
79
24
 
80
- | Setting type | Storage |
81
- |---|---|
82
- | Replicate API Token, API Bearer Token | OS keystore (macOS Keychain, Windows Credential Manager, Linux Secret Service) — or an AES-256 encrypted file at `~/.rilo/.secrets` if no native keystore is available |
83
- | All other settings (timeouts, limits, binary paths, etc.) | `~/.rilo/config.json` |
25
+ ## Features
84
26
 
85
- **Precedence** (highestlowest): environment variable > `~/.rilo/config.json` > schema default.
86
- If an env var is set, the settings command shows it as read-only and any stored value is ignored while the env var is present.
27
+ - **Full pipeline, one command** Story script voiceover keyframes → segments → final video. `rilo --project demo --story-file ./story.txt`
28
+ - **Checkpointed runs** Every stage saves artifacts. Resume or regenerate any stage selectively. `rilo --project demo --force`
29
+ - **Your models, your control** — Choose T2I and I2V models. Override per-model options. Switch models anytime.
30
+ - **Code-driven pipeline** — Deterministic orchestration, checkpointing, and artifact management. Tokens spent on generation, not infrastructure.
31
+ - **Subtitle alignment & burn-in** — Auto-align subtitles to voiceover timing. Burn them into the final video.
32
+ - **Preview dashboard** — Web UI for project management, regeneration, and asset preview. `rilo preview`
33
+ - **HTTP API & webhooks** — Bearer-token auth, OpenAPI 3.1 spec, webhook subscriptions. Firebase or local.
34
+ - **Cross-platform** — macOS, Linux, Windows. Node.js 22+ and ffmpeg.
87
35
 
88
- **Hidden from settings UI** (env-only): Firebase credentials, webhook settings, output backend, API port, custom output/projects directories.
36
+ ## Quick Start
89
37
 
90
- ## Install from npm
38
+ Requirements: Node.js 22+, ffmpeg in PATH, and a Replicate API token.
91
39
 
92
40
  ```bash
93
41
  npm install -g @telepat/rilo
94
- rilo --help
95
- ```
96
-
97
- If you prefer not to install globally:
98
-
99
- ```bash
100
- npx @telepat/rilo --help
101
- ```
102
-
103
- ## CLI Quick Reference
104
-
105
- ### Launch dashboard preview
106
-
107
- ```bash
108
- rilo preview
109
- ```
110
-
111
- Starts local API + worker + dashboard on `127.0.0.1:3000` and opens the browser.
112
-
113
- For container/tunnel scenarios (unsafe unauthenticated access):
114
-
115
- ```bash
116
- rilo preview --expose --unsafe-no-auth --host 0.0.0.0 --port 3000
117
- ```
118
-
119
- Use exposed mode only on trusted networks or isolated environments.
120
-
121
- ### Generate a video from a story
122
-
123
- ```bash
124
- rilo --project <name> --story-file <path>
125
- ```
126
-
127
- Examples:
128
- ```bash
129
- # First run: create project and start generation
130
- rilo --project wedding-case --story-file ./story.txt
131
-
132
- # On subsequent runs: reuse story
133
- rilo --project wedding-case
134
-
135
- # Force restart from earlier stages (after config change)
136
- rilo --project wedding-case --force
137
- ```
138
-
139
- ### Configure settings
140
-
141
- ```bash
142
42
  rilo settings
43
+ rilo --project demo --story-file ./story.txt
143
44
  ```
144
45
 
145
- Opens an interactive menu to set API tokens, timeouts, and binary paths.
146
-
147
- ### Open the Rilo home folder
148
-
149
- ```bash
150
- rilo home
151
- ```
152
-
153
- Opens `~/.rilo`, the default location for saved settings, projects, and generated output.
154
-
155
- ### Help and version
46
+ Expected outcome:
156
47
 
157
- ```bash
158
- rilo --help # Show usage
159
- rilo --version # Show version
160
- ```
161
-
162
- ### Invocation methods
48
+ - A project folder is created under `projects/demo/`.
49
+ - The full pipeline runs through script, voiceover, keyframes, segments, and composition.
50
+ - Final video is written to `projects/demo/final.mp4`.
51
+ - Dashboard preview available via `rilo preview`.
163
52
 
164
- | Method | Command |
165
- |--------|---------|
166
- | **Global install** | `rilo --project <name> --story-file <path>` |
167
- | **No install (npx)** | `npx @telepat/rilo --project <name> --story-file <path>` |
168
- | **Contributor dev** | `npm run dev -- --project <name> --story-file <path>` |
53
+ ## Requirements
169
54
 
170
- ### Key flags
55
+ - Node.js 22+
56
+ - ffmpeg in PATH
57
+ - Replicate API token
58
+ - macOS, Linux, or Windows
171
59
 
172
- | Flag | Type | Notes |
173
- |------|------|-------|
174
- | `--project` | `<name>` | **Required.** Project identifier; creates `projects/<name>/` |
175
- | `--story-file` | `<path>` | Path to story text file (required on first run) |
176
- | `--force` | flag | Restart from earlier stages; used after config changes |
60
+ ## How It Works
177
61
 
178
- ### Common tasks
62
+ Rilo runs a staged pipeline: script generation, voiceover synthesis, shot prompt generation, keyframe rendering, segment generation, and final video composition. Each stage writes checkpointed artifacts so you can resume or regenerate selectively.
179
63
 
180
- **Update project config and regenerate:**
181
- ```bash
182
- # Edit projects/wedding-case/config.json (aspect ratio, models, etc.)
183
- rilo --project wedding-case --force
184
- ```
64
+ Configuration merges CLI flags, environment variables, and `~/.rilo/config.json` with schema defaults. The preview dashboard (`rilo preview`) starts a local API, worker, and Vite React frontend for monitoring and editing.
185
65
 
186
- **Change app settings (tokens, timeouts, binary paths):**
187
- ```bash
188
- rilo settings
189
- # Arrow keys to navigate, Enter to edit, "Done" to save
190
- ```
66
+ ## Using With AI Agents
191
67
 
192
- **Open the default app folder for projects/output:**
193
- ```bash
194
- rilo home
195
- # Opens ~/.rilo in your system file manager
196
- ```
68
+ Rilo provides multiple surfaces for agentic and automated workflows:
197
69
 
198
- **Check where generated files are stored:**
199
- ```bash
200
- ls projects/wedding-case/
201
- # Outputs: config.json, story.md, final.mp4, artifacts.json, run-state.json, assets/, logs/
202
- ```
70
+ - **CLI automation** All generation is driven by CLI flags and environment variables. No interactive prompts are required after initial setup.
71
+ - **HTTP API** — `rilo preview` starts an Express API with full job and project CRUD, asset serving, and webhook endpoints. Bearer-token auth via `Authorization: Bearer <API_BEARER_TOKEN>`.
72
+ - **OpenAPI spec** — Auto-generated OpenAPI 3.1 spec for schema-driven agent integration.
73
+ - **Webhooks** Subscribe to job lifecycle events for external orchestration.
74
+ - **Firebase Functions** — Deploy `src/api/firebaseFunction.js` for serverless API hosting.
75
+ - **Agent docs** — [API Reference](https://docs.telepat.io/rilo/reference/api-reference) covers endpoints, auth, and webhooks.
203
76
 
204
- ---
77
+ ## Security And Trust
205
78
 
206
- ## CLI Documentation
79
+ - API tokens and Replicate credentials are stored in the OS keystore (macOS Keychain, Windows Credential Manager, Linux Secret Service) when available.
80
+ - Falls back to an AES-256 encrypted file at `~/.rilo/.secrets` if no native keystore is available.
81
+ - Environment variables (`TELEPAT_REPLICATE_TOKEN`, `RILO_API_BEARER_TOKEN`) take highest precedence and override stored values.
82
+ - Preview `--expose` mode should only be used on trusted networks or isolated environments.
207
83
 
208
- For comprehensive CLI documentation, see:
209
- - **[Quickstart](/docs.telepat.io/rilo/getting-started/quickstart)** — Step-by-step guide to your first generation
210
- - **[CLI Reference](/docs.telepat.io/rilo/reference/cli-reference)** — All commands, flags, and invocation methods
211
- - **[Complete Config Schema](/docs.telepat.io/rilo/reference/config-schema)** — Every config key with types and defaults
212
- - **[Configuration Guide](/docs.telepat.io/rilo/guides/configuration)** — Project and app settings with examples
213
- - **[Troubleshooting](/docs.telepat.io/rilo/guides/troubleshooting)** — Common errors and solutions
214
- - **[Environment Variables](/docs.telepat.io/rilo/reference/environment-variables)** — Setting precedence and env var reference
84
+ ## Documentation And Support
215
85
 
216
- ## Full Documentation
86
+ - [Documentation site](https://docs.telepat.io/rilo)
87
+ - [Quickstart](https://docs.telepat.io/rilo/getting-started/quickstart)
88
+ - [CLI Reference](https://docs.telepat.io/rilo/reference/cli-reference)
89
+ - [Configuration Guide](https://docs.telepat.io/rilo/guides/configuration)
90
+ - [API Reference](https://docs.telepat.io/rilo/reference/api-reference)
91
+ - [Troubleshooting](https://docs.telepat.io/rilo/guides/troubleshooting)
92
+ - [Repository](https://github.com/telepat-io/rilo)
93
+ - [npm package](https://www.npmjs.com/package/@telepat/rilo)
217
94
 
218
- Guides, API reference, architecture notes, and advanced configuration:
95
+ ## Contributing
219
96
 
220
- https://docs.telepat.io/rilo/
97
+ Contributions are welcome. See [Development](https://docs.telepat.io/rilo/contributing/development) for local setup, build commands, and test workflows.
221
98
 
222
99
  ## License
223
100
 
224
- MIT
101
+ MIT. See [LICENSE](./LICENSE).
@@ -0,0 +1,101 @@
1
+ <p align="center"><img src="./assets/avatar/rilo-logo.webp" width="128" alt="Rilo"></p>
2
+ <h1 align="center">Rilo</h1>
3
+ <p align="center"><em>将故事转化为成品视频——AI 生成脚本、配音、关键帧和合成,一条命令完成。</em></p>
4
+
5
+ <p align="center">
6
+ <a href="https://docs.telepat.io/rilo">📖 文档</a>
7
+ · <a href="./README.md">🇺🇸 English</a>
8
+ · <a href="./README.zh-CN.md">🇨🇳 简体中文</a>
9
+ · <a href="./README.de.md">🇩🇪 Deutsch</a>
10
+ </p>
11
+
12
+ <p align="center">
13
+ <a href="https://github.com/telepat-io/rilo/actions/workflows/ci.yml"><img src="https://github.com/telepat-io/rilo/actions/workflows/ci.yml/badge.svg?branch=main" alt="Build"></a>
14
+ <a href="https://codecov.io/gh/telepat-io/rilo"><img src="https://codecov.io/gh/telepat-io/rilo/graph/badge.svg" alt="Codecov"></a>
15
+ <a href="https://www.npmjs.com/package/@telepat/rilo"><img src="https://img.shields.io/npm/v/@telepat/rilo" alt="npm"></a>
16
+ <a href="https://github.com/telepat-io/rilo/blob/main/LICENSE"><img src="https://img.shields.io/badge/license-MIT-yellow.svg" alt="License"></a>
17
+ </p>
18
+
19
+ Rilo 将故事转化为成品视频——AI 生成脚本、配音、关键帧和合成,一条命令完成。
20
+
21
+ 用纯文本写下您的故事。Rilo 处理剩下的部分:脚本生成、旁白配音、视觉关键帧、视频片段和最终合成——以及可选的字幕对齐与烧录。
22
+
23
+ 专为需要大规模、可复现、高质量视频生产而无需手动编辑的创作者和团队打造。
24
+
25
+ ## 功能特性
26
+
27
+ - **完整流水线,一条命令** — 故事 → 脚本 → 配音 → 关键帧 → 片段 → 最终视频。`rilo --project demo --story-file ./story.txt`
28
+ - **检查点运行** — 每个阶段保存产物。可恢复或选择性重新生成任何阶段。`rilo --project demo --force`
29
+ - **您的模型,您做主** — 选择 T2I 和 I2V 模型。覆盖每个模型的选项。随时切换。
30
+ - **代码驱动的工作流** — 确定性编排、检查点和产物管理。Token 用于生成,而非基础设施。
31
+ - **字幕对齐与烧录** — 自动将字幕对齐到配音时间轴。烧录到最终视频中。
32
+ - **预览控制台** — Web 界面用于项目管理、重新生成和资产预览。`rilo preview`
33
+ - **HTTP API 与 Webhook** — Bearer 令牌认证、OpenAPI 3.1 规范、Webhook 订阅。支持 Firebase 或本地。
34
+ - **跨平台** — macOS、Linux、Windows。需要 Node.js 22+ 和 ffmpeg。
35
+
36
+ ## 快速开始
37
+
38
+ 环境要求:Node.js 22+、PATH 中有 ffmpeg、Replicate API token。
39
+
40
+ ```bash
41
+ npm install -g @telepat/rilo
42
+ rilo settings
43
+ rilo --project demo --story-file ./story.txt
44
+ ```
45
+
46
+ 预期结果:
47
+
48
+ - 在 `projects/demo/` 下创建项目文件夹。
49
+ - 完整流水线依次运行脚本、配音、关键帧、片段和合成。
50
+ - 最终视频写入 `projects/demo/final.mp4`。
51
+ - 可通过 `rilo preview` 打开仪表板预览。
52
+
53
+ ## 环境要求
54
+
55
+ - Node.js 22+
56
+ - PATH 中有 ffmpeg
57
+ - Replicate API token
58
+ - macOS、Linux 或 Windows
59
+
60
+ ## 工作原理
61
+
62
+ Rilo 运行分阶段流水线:脚本生成、语音合成、镜头提示生成、关键帧渲染、片段生成和最终视频合成。每个阶段都会写入检查点产物,因此你可以恢复或有选择地重新生成。
63
+
64
+ 配置会合并 CLI 标志、环境变量和 `~/.rilo/config.json`,并以模式默认值兜底。预览仪表板(`rilo preview`)启动本地 API、worker 和 Vite React 前端,用于监控和编辑。
65
+
66
+ ## 与 AI Agent 一起使用
67
+
68
+ Rilo 为智能体和自动化工作流提供多种接口:
69
+
70
+ - **CLI 自动化** — 所有生成均由 CLI 标志和环境变量驱动。初始设置后无需交互式提示。
71
+ - **HTTP API** — `rilo preview` 启动 Express API,提供完整的 job 和 project CRUD、资源服务和 webhook 端点。通过 `Authorization: Bearer <API_BEARER_TOKEN>` 进行 Bearer token 认证。
72
+ - **OpenAPI 规范** — 自动生成 OpenAPI 3.1 规范,支持基于模式的智能体集成。
73
+ - **Webhook** — 订阅 job 生命周期事件,用于外部编排。
74
+ - **Firebase Functions** — 部署 `src/api/firebaseFunction.js` 实现无服务器 API 托管。
75
+ - **Agent 文档** — [API 参考](https://docs.telepat.io/rilo/reference/api-reference) 涵盖端点、认证和 webhook。
76
+
77
+ ## 安全与信任
78
+
79
+ - API token 和 Replicate 凭证在 OS 密钥库可用时保存(macOS Keychain、Windows Credential Manager、Linux Secret Service)。
80
+ - 如果无原生密钥库可用,则回退到 `~/.rilo/.secrets` 的 AES-256 加密文件。
81
+ - 环境变量(`TELEPAT_REPLICATE_TOKEN`、`RILO_API_BEARER_TOKEN`)优先级最高,会覆盖已存储的值。
82
+ - Preview `--expose` 模式应仅在可信网络或隔离环境中使用。
83
+
84
+ ## 文档与支持
85
+
86
+ - [文档站点](https://docs.telepat.io/rilo)
87
+ - [快速上手](https://docs.telepat.io/rilo/getting-started/quickstart)
88
+ - [CLI 参考](https://docs.telepat.io/rilo/reference/cli-reference)
89
+ - [配置指南](https://docs.telepat.io/rilo/guides/configuration)
90
+ - [API 参考](https://docs.telepat.io/rilo/reference/api-reference)
91
+ - [故障排查](https://docs.telepat.io/rilo/guides/troubleshooting)
92
+ - [仓库](https://github.com/telepat-io/rilo)
93
+ - [npm 包](https://www.npmjs.com/package/@telepat/rilo)
94
+
95
+ ## 贡献
96
+
97
+ 欢迎贡献。请参阅[开发指南](https://docs.telepat.io/rilo/contributing/development)了解本地环境搭建、构建命令和测试工作流。
98
+
99
+ ## 许可证
100
+
101
+ MIT。详见 [LICENSE](./LICENSE)。
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@telepat/rilo",
3
- "version": "0.1.6",
3
+ "version": "0.1.8",
4
4
  "license": "MIT",
5
5
  "bin": {
6
6
  "rilo": "src/cli/index.js"
@@ -31,7 +31,7 @@
31
31
  "frontend:lint": "npm --prefix frontend run lint",
32
32
  "frontend:build": "npm --prefix frontend run build",
33
33
  "frontend:preview": "npm --prefix frontend run preview",
34
- "prepack": "npm run frontend:build",
34
+ "prepack": "node -e \"const fs=require('node:fs'); if(!fs.existsSync('frontend/dist/index.html')) { console.error('Missing frontend build output at frontend/dist/index.html. Run npm run build before publish.'); process.exit(1); }\"",
35
35
  "docs:start": "npm --prefix docs-site run start",
36
36
  "docs:build": "npm --prefix docs-site run build",
37
37
  "docs:serve": "npm --prefix docs-site run serve",
@@ -53,6 +53,7 @@
53
53
  "express": "^4.21.2",
54
54
  "firebase-admin": "^13.4.0",
55
55
  "firebase-functions": "^6.4.0",
56
+ "@telepat/limn": "^0.1.7",
56
57
  "replicate": "^1.0.1",
57
58
  "uuid": "^11.1.0"
58
59
  },
@@ -21,7 +21,7 @@ const runtimeOptions = {
21
21
  invoker: 'public',
22
22
  secrets: [
23
23
  'SECRET_API_BEARER_TOKEN',
24
- 'SECRET_REPLICATE_API_TOKEN',
24
+ 'TELEPAT_REPLICATE_TOKEN',
25
25
  'SECRET_OUTPUT_BACKEND',
26
26
  'SECRET_FIREBASE_PROJECT_ID',
27
27
  'SECRET_FIREBASE_STORAGE_BUCKET'
package/src/cli/index.js CHANGED
@@ -47,7 +47,7 @@ async function main() {
47
47
 
48
48
  if (process.argv.includes('--help')) {
49
49
  const helpText = `
50
- Rilo — Story-first vertical video generation
50
+ Rilo — Turn a story into a finished video
51
51
 
52
52
  USAGE
53
53
  rilo --project <name> [--story-file <path>] [--force]
@@ -138,7 +138,7 @@ SETTINGS
138
138
  npm install -g @telepat/rilo
139
139
 
140
140
  Or with environment variables:
141
- export RILO_REPLICATE_API_TOKEN=r8_xxxxx
141
+ export TELEPAT_REPLICATE_TOKEN=r8_xxxxx
142
142
  export RILO_MAX_RETRIES=5
143
143
  export PREDICTION_MAX_WAIT_MS=900000
144
144
  rilo --project my-project --story-file ./story.txt
package/src/config/env.js CHANGED
@@ -41,9 +41,11 @@ export function parseAllowedHosts(value, fallback = 'replicate.delivery,replicat
41
41
 
42
42
  export const env = {
43
43
  replicateApiToken: parseEnvString(
44
- process.env.SECRET_REPLICATE_API_TOKEN
45
- || process.env.RILO_REPLICATE_API_TOKEN
46
- || process.env.REPLICATE_API_TOKEN,
44
+ process.env.TELEPAT_REPLICATE_TOKEN,
45
+ ''
46
+ ),
47
+ openRouterApiKey: parseEnvString(
48
+ process.env.TELEPAT_OPENROUTER_KEY,
47
49
  ''
48
50
  ),
49
51
  apiBearerToken: parseEnvString(
@@ -147,7 +149,7 @@ export async function applyStoredSettings() {
147
149
 
148
150
  export function assertRequiredEnv() {
149
151
  if (!env.replicateApiToken) {
150
- throw new Error('Missing REPLICATE_API_TOKEN in environment');
152
+ throw new Error('Missing TELEPAT_REPLICATE_TOKEN in environment');
151
153
  }
152
154
  }
153
155