{"id":29127804,"url":"https://github.com/cylind/scribe2srt","last_synced_at":"2026-03-03T09:32:51.471Z","repository":{"id":298487635,"uuid":"1000030349","full_name":"cylind/scribe2srt","owner":"cylind","description":"一款基于 PySide6 和 ElevenLabs API 的桌面应用，能将音视频或JSON转录稿智能地转换为高质量SRT字幕。特别为中、日、韩、英等语言优化了排版规则。","archived":false,"fork":false,"pushed_at":"2025-07-08T10:15:59.000Z","size":1975,"stargazers_count":32,"open_issues_count":0,"forks_count":2,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-07-08T11:31:27.433Z","etag":null,"topics":["cjk","desktop-app","elevenlabs-api","pyside6","python","qt","speech-to-text","srt","subtitles","transcription"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cylind.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-06-11T06:54:53.000Z","updated_at":"2025-07-08T10:16:02.000Z","dependencies_parsed_at":"2025-06-11T11:37:00.187Z","dependency_job_id":"9f8da1cc-9d4a-40e2-8a3a-f8399a29b386","html_url":"https://github.com/cylind/scribe2srt","commit_stats":null,"previous_names":["cylind/scribe2srt"],"tags_count":11,"template":false,"template_full_name":null,"purl":"pkg:github/cylind/scribe2srt","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cylind%2Fscribe2srt","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cylind%2Fscribe2srt/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cylind%2Fscribe2srt/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cylind%2Fscribe2srt/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cylind","download_url":"https://codeload.github.com/cylind/scribe2srt/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cylind%2Fscribe2srt/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30039885,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-03T06:58:30.252Z","status":"ssl_error","status_checked_at":"2026-03-03T06:58:15.329Z","response_time":61,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cjk","desktop-app","elevenlabs-api","pyside6","python","qt","speech-to-text","srt","subtitles","transcription"],"created_at":"2025-06-30T01:01:56.335Z","updated_at":"2026-03-03T09:32:51.425Z","avatar_url":"https://github.com/cylind.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Scribe2SRT v0.3.3\n\n一个基于 ElevenLabs Speech-to-Text API 的音视频转字幕工具，支持多语言转录和专业字幕制作标准。\n\n## 🚀 主要特性\n\n### 全新的两阶段字幕分割算法\n- **句子预分割**：基于标点符号优先级的语义分割\n- **智能合并**：基于CPS、CPL、显示时间等规则的优化合并\n- **语义完整性**：避免破坏句子结构，提升可读性\n\n### 显著的质量改善\n\n| 指标 | v0.2.x | v0.3.x | 改善幅度 |\n|------|--------|--------|----------|\n| 标点问题率 | 7.72% | 2.81% | **+4.91%** ✅ |\n| 时长过短率 | 5.30% | 0.64% | **+4.66%** ✅ |\n| CPS过高率 | 10.13% | 7.02% | **+3.11%** ✅ |\n| 整体合规率 | 75.41% | 79.11% | **+3.71%** ✅ |\n| 标点结尾率 | - | 97.7% | **显著提升** ✅ |\n\n## 功能特点\n\n- 🎯 **高质量转录**：基于 ElevenLabs 先进的语音识别技术\n- 🌍 **多语言支持**：支持中文、英文、日文等多种语言\n- 📝 **专业字幕标准**：遵循 Netflix 等行业标准的字幕制作规范\n- ⚡ **智能分割**：基于标点符号优先级的语义分割算法\n- 🔄 **智能重试机制**：失败时自动保留临时文件，重试时快速恢复\n- 🎨 **用户友好界面**：简洁直观的图形用户界面，统一的视觉设计\n- 📊 **实时进度反馈**：清晰的进度显示和状态提示\n- 🛠️ **质量分析**：内置字幕质量检测和优化建议\n\n## 安装要求\n\n### 必需依赖\n- Python 3.8+\n- PySide6 (Qt界面库)\n- requests (网络请求)\n- requests-toolbelt (文件上传)\n\n### 可选依赖\n- FFmpeg (推荐安装，用于视频文件处理)\n\n## 快速开始\n\n1. **克隆项目**\n   ```bash\n   git clone https://github.com/your-username/scribe2srt.git\n   cd scribe2srt\n   ```\n\n2. **安装依赖**\n   ```bash\n   pip install -r requirements.txt\n   ```\n\n3. **运行程序**\n   ```bash\n   python app.py\n   ```\n\n## 使用方法\n\n1. **选择文件**：拖拽或点击选择音视频文件\n2. **设置选项**：选择源语言和其他处理选项\n3. **开始转录**：点击\"生成字幕\"按钮\n4. **获取结果**：程序会自动生成 SRT 字幕文件\n\n## 支持的文件格式\n\n### 音频格式\n- MP3, WAV, FLAC, M4A, AAC, OGG\n\n### 视频格式\n- MP4, MOV, MKV, AVI, FLV, WEBM\n\n### 转录数据\n- JSON (ElevenLabs 格式)\n\n## 字幕质量标准\n\n本工具遵循以下专业字幕制作标准：\n\n- **时长控制**：最短 0.83 秒，最长 7.0 秒\n- **字符密度**：CJK 语言每秒最多 15 字符，拉丁语言每秒最多 15 字符\n- **行长限制**：CJK 语言每行最多 25 字符，拉丁语言每行最多 42 字符\n- **语义完整性**：优先保持句子完整，基于标点符号优先级分割\n\n## 高级功能\n\n### 字幕设置\n- 自定义时长和间隔参数\n- 调整字符密度限制\n- 设置每行字符数限制\n\n### 并发处理\n- 支持大文件分段并发处理\n- 可配置并发数和重试策略\n- API 速率限制控制\n\n### 智能重试机制\n- 失败时自动保留临时文件\n- 重试时避免重复音频提取\n- 完整的状态恢复和进度显示\n- 智能错误处理和异常恢复\n\n### 质量分析\n- 自动检测字幕质量问题\n- 提供详细的合规性报告\n- 生成改进建议\n\n## 项目结构\n\n```\nscribe2srt/\n├── app.py                    # 主应用入口\n├── requirements.txt          # 依赖文件\n├── README.md                # 项目文档\n├── settings.json            # 配置文件\n├── core/                    # 核心功能模块\n│   ├── __init__.py         # 包初始化\n│   ├── config.py           # 配置管理\n│   ├── srt_processor.py    # 字幕处理器\n│   ├── sentence_splitter.py # 句子分割器\n│   ├── intelligent_merger.py # 智能合并器\n│   ├── ffmpeg_utils.py     # FFmpeg工具\n│   ├── async_chunk_processor.py # 异步处理\n│   └── worker.py           # 工作线程\n├── ui/                     # 用户界面模块\n│   ├── __init__.py         # 包初始化\n│   ├── main_window.py      # 主窗口\n│   ├── settings_dialog.py  # 设置对话框\n│   ├── async_settings_dialog.py # 异步设置对话框\n│   ├── widgets.py          # 自定义组件\n│   └── segmented_progress_bar.py # 进度条\n├── api/                    # API客户端模块\n│   ├── __init__.py         # 包初始化\n│   └── client.py           # API客户端\n├── tests/                  # 测试模块\n│   ├── __init__.py         # 包初始化\n│   ├── test_subtitle_rules.py\n│   └── optimize_based_on_analysis.py\n├── sample/                 # 示例文件\n└── docs/                   # 文档\n    └── 字幕制作的通用原则.md\n```\n\n## 技术特点\n\n### 新一代字幕分割算法\n- **两阶段处理**：句子预分割 + 智能合并\n- **标点符号优先**：基于语言学规律的分割策略\n- **语义完整性**：避免破坏句子结构\n- **多语言优化**：针对 CJK 和拉丁语言的差异化处理\n\n### 质量保证\n- **实时质量检测**：处理过程中自动检测质量问题\n- **合规性验证**：确保符合行业标准\n- **智能优化**：自动调整参数以提高质量\n\n## 核心改进\n\n### 算法优化\n- **移除长停顿检测**：用基于标点符号的语义分割替代时间间隔检测\n- **智能合并策略**：基于CPS、CPL、显示时间等多规则约束\n- **语义完整性**：显著减少句子中断，提升可读性\n- **模块化架构**：重新组织代码结构，提高可维护性\n\n### 技术创新\n- **标点符号优先级**：高优先级（。！？）、中优先级（；：）、低优先级（，、）\n- **动态CPS调整**：根据文本长度智能调整字符密度限制\n- **智能收益计算**：指导合并决策的收益评估算法\n- **智能重试机制**：失败时保留状态，重试时快速恢复\n- **实时进度反馈**：统一的进度显示和状态管理\n\n## 许可证\n\n本项目采用 MIT 许可证。详见 [LICENSE](LICENSE) 文件。\n\n## 贡献\n\n欢迎提交 Issue 和 Pull Request！\n\n## 更新日志\n\n### v0.3.3 (最新)\n- 🔄 重试机制全面优化：修复临时文件管理，重试时不再重复提取音频\n- 📊 进度显示全面改进：修复重试进度显示，优化信息展示层次\n- 🎨 界面优化：简化进度条颜色方案，统一视觉风格\n- 🛠️ 错误处理增强：修复多个稳定性问题，提升程序健壮性\n\n### v0.3.1\n- 🚀 全新的两阶段字幕分割算法\n- 📊 显著提升标点符号分割准确率（从 7.72% 降至 2.81%）\n- 🏗️ 重构代码架构，模块化设计\n- 📈 整体合规率从 75.41% 提升至 79.11%\n\n### v0.2.x\n- 基础转录功能\n- 简单的字幕分割算法\n- 基本的用户界面\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcylind%2Fscribe2srt","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcylind%2Fscribe2srt","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcylind%2Fscribe2srt/lists"}