funlesson
funlesson 的核心处理库:把一条课程视频链接(B 站等)转成结构化图文教案素材——转写、大纲、思维导图、PPT、架构图。被 funlesson-api 后端服务封装调用。
功能特性
- 视频下载:基于
yt-dlp,原生支持 B 站等多平台 - 语音转写:复用 funtalk 的 Whisper 封装
- 大纲结构化 / PPT 文案 / 架构图代码:统一通过
claude -p单任务调用完成内容理解, 不依赖额外 LLM API Key(详见doc/API.md) - 思维导图:输出 markmap 兼容的 markdown 文本,交给前端渲染成可交互导图
- PPT:用
python-pptx渲染成.pptx文件
快速开始
安装
包发布在公开 pypi.org:
pip install funlesson
从源码开发用可编辑模式:pip install -e .
环境要求
- 系统已安装
ffmpeg - 本机已安装并登录 Claude Code CLI(
claude命令可用) - 首次转写会下载 Whisper 模型权重,需要能访问模型源的网络环境
运行
from funlesson import process
note = process("https://www.bilibili.com/video/BVxxxxxxxx", workdir="./data/demo")
print(note.outline.title)
print(note.mindmap)
API 文档
见 doc/API.md。
变更日志
见 CHANGELOG.md。
许可证
MIT
Metadata
Release files for funlesson 0.1.12
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| funlesson-0.1.12-py3-none-any.whl | Python 3 | none | any | Details |
Release files / funlesson-0.1.12-py3-none-any.whl
| Download URL | funlesson-0.1.12-py3-none-any.whl |
|---|---|
| Size | 10.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3a2b7023a027c90b2af30f46a0b7e53123715a0a8a2e115b0bce510a3fc14b53
|
|
BLAKE2b-256 checksum How to use checksums |
3418907bee890e14a3517bbe1f6438cecf332c2ca158ffe0c5337f6d0e5bae32
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.17 {"installer":{"name":"uv","version":"0.11.17","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|