fakecard

approvedunreviewed

by godfatherlg

Spaced-repetition flashcards built from your notes, stored in their own folder - your notes stay untouched.

★ 1 stars↓ 269 downloadsUpdated 10d agoMIT

fakecard

在 Obsidian 里从笔记生成间隔重复卡片,卡片独立存放在 vault 的 fakecard/ 文件夹,不修改你的笔记。

Spaced-repetition flashcards for Obsidian, built from your notes and stored as plain JSON in their own folder. Notes are never modified.

English

fakecard turns your notes into spaced-repetition flashcards inside Obsidian. Cards live as plain JSON in a fakecard/ folder in your vault; your notes are only ever read, never edited.

Features:

  • Three ways to create cards: rules over a note, a manual editing panel, or JSON from any external tool
  • Q&A, cloze (Anki {{c1::...}} syntax) and image-occlusion cards
  • FSRS scheduling (ts-fsrs) with four grades
  • Daily queue: due cards first, with separate caps for new cards and reviews
  • Multi-group cloze and image cards, every group scheduled on its own
  • Child cards: a card you keep failing offers to build a simpler stand-in from its own text (Hard adds 1 point, Again adds the configured score); the parent is paused only once the child exists and comes back when every child graduates
  • Exam plans: several countdowns at once, each with ticked decks and a share, plus a live "cards per day" estimate before you build
  • Statistics: today, rating distribution, true retention, maturity, heatmap, due forecast, hard cards
  • Anki import (.apkg): basic, cloze and image-occlusion notes plus their media
  • Optional audio recordings: several clips per card, time-stamped files, renaming changes only the label, players on the review card (off by default)
  • Optional learning steps: Anki-style minute-level steps for new cards and lapses, while FSRS still picks the graduating interval (off by default)
  • Read-only towards your notes: any card can jump back to the exact spot it came from

Install:

  1. Community plugins: Settings -> Community plugins -> Browse -> search fakecard, or open its community directory page
  2. Manual: download main.js, manifest.json and styles.css from Releases into <vault>/.obsidian/plugins/fakecard/, then enable the plugin

Quick start:

  1. Put a * marker in a heading (## Ginkgo biloba *); the heading is the question and the text below it is the answer. Run Generate Q&A cards from the whole note.
  2. Highlight text inside a list block; every ==highlight== becomes a cloze deletion. Run Generate cloze cards from the whole note.
  3. The ribbon icon opens Statistics, which links to Browse and Review the way the True Recall dashboard does; grade with Again / Hard / Good / Easy (space bar shows the answer).

The settings tab follows the Obsidian language and switches between English and Chinese automatically.

Browse & filter (Browse and edit cards): search box, quick filters, table and preview. Terms are separated by spaces and every one of them has to match; - excludes a term; wrap a value in " when it contains a space. The ⌄ button in the box inserts a term for you.

TermMeaning
deck:x / tag:x / type:qadeck (contains) / tag (exact) / type qa cloze image map
is:new is:learning is:review is:relearning is:dueFSRS state
is:child is:buried is:paused is:graduated is:orphanchild / buried until tomorrow / suspended / graduated / source note gone
added:7 rated:7created / reviewed within N days (rated:1 = today)
prop:due<7 prop:ivl>=21 prop:difficulty>=7 prop:reps>5 prop:lapses>0due days / interval / FSRS difficulty / reviews / lapses
front:x back:xone field only
-tag:xexclusion
plain wordsfull text (front, back, tags, source path)

Examples:

deck:方剂 tag:麻黄 is:due      in the 方剂 deck, tagged 麻黄, due today
tag:针灸 -is:paused            tagged 针灸 and not suspended
type:cloze front:桂枝 back:芍药
prop:due<7 prop:ivl>=21        due within a week, interval already 21+ days
added:7 rated:1                added this week, reviewed today

Data and privacy: cards are stored in fakecard/cards/, review logs in fakecard/reviews/, backups in fakecard/backup/. Everything is local and the plugin makes no network requests. The system clipboard is read only when you run one of the import commands that takes cards from it, and the plugin never writes to it.

Audio recordings and learning steps (optional)

Both are off by default; turn them on in Settings -> fakecard.

  • Audio recordings: open an existing card's edit panel and press Record. Every clip is saved with a time-stamped file name under fakecard/media/; its label starts as that time and can be renamed without touching the file. A card keeps as many clips as you record. Review shows a player strip above the card and never plays by itself; after the answer is revealed, a compact Record button sits at the right of the timing hint row.
  • Learning steps: set step lists such as 1m 10m for new cards and 10m after a lapse. Again sends a card back to the first step, Good moves it one step on, Hard repeats the current step, Easy graduates immediately; after the last step FSRS picks the interval. Turning this off restores FSRS's own short-term schedule, and cards that already carry a learning step from this feature are left to FSRS as well.

The rest of this document is in Chinese.


功能

  • 三种制卡方式:规则批量生成、手动编辑面板、外部 AI / 工具导入
  • 问答、挖空、图片蒙板 三种卡片类型
  • FSRS 调度(ts-fsrs),四档评分
  • 每日队列:到期优先 + 新卡/复习双上限
  • 多组卡片:一张挖空/图片卡按组拆分,每组独立调度
  • 子卡:卡住了就拆成更简单的替身,全部毕业父卡自动恢复
  • 考试计划:可建多个倒计时,勾选牌组 + 比例,生成前先看到每天多少张
  • 统计:今日、评分分布、真实保持率、成熟度、热力图、到期预测、难卡
  • Anki 导入(.apkg):Basic / Cloze / 图片蒙板 + 媒体文件
  • 可选录音:一张卡可挂多段录音,文件按时间戳命名,改名只改显示名,复习卡片上方显示播放条(默认关闭)
  • 可选学习步骤:新卡与遗忘后的卡按 Anki 式分钟级步骤走,最后一步之后的间隔仍由 FSRS 决定(默认关闭)
  • 读而不写:卡片可跳回原笔记位置(按内容实时定位),阅读模式显示来源徽标

录音与学习步骤(可选)

两项都默认关闭,在「设置 → fakecard」里开启。

  • 录音:打开已有卡片的编辑面板,点「录音」。每段录音按时间戳命名保存在 fakecard/media/;默认显示名也是这个时间,可以改名,但不会改文件名。一张卡可以保留多段录音。复习时卡片上方会显示播放条,不会自动播放;翻到答案后,提示行右侧也有一个紧凑的「录音」按钮,或使用命令 Record the answer (start/stop) 开始/停止。
  • 学习步骤:为新卡设置如 1m 10m、为遗忘后的卡设置 10m 的步骤表。Again 回到第一步,Good 前进一步,Hard 重复当前步,Easy 直接毕业;最后一步之后的间隔由 FSRS 决定。关闭后恢复 FSRS 自带的短期调度;已经带有本功能学习步骤的卡也交回 FSRS。

安装

社区插件

设置 → 第三方插件 → 浏览 → 搜索 fakecard,或直接打开社区目录页。

列表里暂时搜不到时重启一次 Obsidian:客户端会缓存插件清单,新上架的条目需要重新拉取后才会出现。

手动安装

  1. 从 Releases 下载 main.js、manifest.json、styles.css
  2. 放到 <vault>/.obsidian/plugins/fakecard/
  3. 重启 Obsidian,在第三方插件里启用

快速开始

1. 用标记批量生成

问答卡:标题里带标记(默认 *,可在设置改)就是一张卡,标题是问题,标题下面是答案。

## 小青龙汤 *

组成:麻黄、桂枝、芍药、细辛、干姜、炙甘草、半夏、五味子

挖空卡:一个列表块一张卡,==高亮== 变成挖空(整块默认一组)。

- 解表剂:==麻黄==、桂枝
- 主治:==外感风寒==

然后:

  • 命令 Generate Q&A cards from the whole note
  • 命令 Generate cloze cards from the whole note
  • 或右键文件 → fakecard: generate Q&A / cloze cards
  • 或选中几行后 Generate cards from the selected lines

会先弹出预览,勾选后才写入卡片库。

2. 手动面板

命令 New card (manual) → 选类型:

类型面板
Q&A问题 / 答案两个框(随内容自适应高度)
ClozeAnki 格式 {{c1::挖空}}、{{c1::挖空::注释}},New group 造 c2/c3,选中文字 Wrap
图片蒙板画矩形/椭圆,分组,缩放平移,键盘微调

3. 外部 AI

插件不内置任何模型。任何工具按下面的格式输出,就能把卡片推进来:

obsidian://fakecard?data=<URL 编码的 JSON>

或命令 Import cards from clipboard (JSON)。

[
  { "type": "qa", "front": "问题", "back": "答案" },
  { "type": "cloze", "clozeText": "{{c1::挖空}} 其余文字" }
]

可选字段:sourcePath(关联笔记)、sourceText(定位片段)。==高亮== 也会自动转成挖空。

入口与导航

左侧 ribbon 图标打开统计界面,页面顶部一行 Statistics / Browse / Review 在三个界面之间切换(已有同名标签会直接跳过去,不会开一堆标签)。命令面板里也可以单独打开任意一个:Open statistics / Browse and edit cards / Start reviewing。

复习

命令 Start reviewing 或统计页顶部的 Review → 主区域打开复习界面。

  • 问答卡:问题 → Show answer → 答案
  • 挖空/图片卡:原地揭示,没有单独的答案块
  • 四档评分:Again / Hard / Good / Easy
  • 空格键显示答案
  • 工具栏:牌组筛选、进度、考试倒计时、+ Child、↗ Source、✎ Edit
  • 建议时长:卡片超过建议时间后才显示「已用 / 建议」,提前显示反而变成计时压力;切到别的窗口的时间不计入
  • 建议用时怎么算:作答 = (基础 + 字数 ÷ 40 × 每段秒数) × 作答系数,记忆一遍 = (基础 + 字数 ÷ 40 × 每段秒数) × 记忆系数,记忆首遍 = (基础 + 首遍额外 + 字数 ÷ 40 × 每段秒数) × 记忆系数,记忆 = 记忆一遍 × (遍数 − 1) + 记忆首遍。首遍已经算一遍,所以后面只再加「遍数 − 1」遍;记忆时间的每一遍都用记忆系数,作答系数只用于问题面的作答时间。作答系数默认 −20%(越难给得越少,防纠结),记忆系数默认 +20%(越难给得越多);字数不含链接、** / == 等标记。没有上限:长答案记三遍就是二十几分钟,照实显示
  • 两个胶囊都放在顶部「全部牌组」那一行:问题面是 作答 0:28 / 4:47,从卡片出现到揭示,只用「一遍」的作答预算,提醒别在一个词上耗太久,不计分
  • 揭示后同一个位置换成 记忆 0:05 / 17:22:从答案出现起重新计时(不接着用作答的时间),量的是记忆答案的用时;只有它超时才按步长记 Hard——每多 0.5 倍(可调)记 0.5 分(可调),1.5 倍记 0.5、2 倍记 1。只有 Again / Hard 才折算超时分:Good / Easy 即使超时也清零,避免分心时靠超时拖出分数
  • 两个胶囊右侧都有 ↻ 和眼睛按钮:↻ 重新计时;眼睛关闭计时(不测也不记分),关闭后会一直保持,换卡也不恢复;同一位置留一个小时钟按钮,点它重新打开并从当前时刻重新计时
  • 防中庸提示(设置里默认关,只对间隔 ≥ 1 天的成熟卡):很快时给「太容易(简单)」「没思路(重来)」;很慢时给「卡思路(重来)」「记混卡(困难)」;正常速度也常驻一个「记混卡(困难)」,用来标记答案记混、按错误答案回答的情况。提示只是一行,不点就不变;点「记混卡」按困难记分并在日志里打 mixed 标记,直接进下一张
  • 中断处理(三个开关,默认关):① 恢复顺序——到期卡里两成以上「还能想起的概率低于 50%」时,先做还记得的,最弱的每天最多掺 20%;② 超期封顶——超期超过自身稳定度 5 倍的卡,成功后新间隔不超过上次的 1.5 倍、最多 60 天;③ 自适应每日量——昨天成功率低于 70% 今天少放 20%,高于 90% 多放 10%
  • 建子卡:Hard 记 1 分、Again 按设置记分(默认 2),累计到阈值(默认 4)时评分栏上方出现「Card keeps failing - build a child card」,可选 Q&A 或挖空子卡,内容从父卡预填;子卡真的保存后父卡才挂起,取消面板不会留下挂着的父卡

浏览与筛选

命令 Browse and edit cards → 主区域标签:搜索框 + 快捷筛选 + 表格 + 右侧预览。

搜索语法:空格分隔多个条件,全部满足才命中(AND);- 取反;值里有空格时用 " 包起来。搜索框左侧的 ⌄ 按钮可以直接插入条件,不用背。

语法含义
deck:方剂 / tag:麻黄 / type:qa牌组(包含即可)/ 标签(完全相同)/ 类型 qa cloze image map
is:new is:learning is:review is:relearningFSRS 状态
is:due已到期
is:child is:buried is:paused is:graduated子卡 / 埋藏到明天 / 挂起父卡 / 已毕业
is:orphan来源笔记已删除
added:77 天内创建
rated:77 天内复习过(rated:1 = 今天)
prop:due<7 prop:ivl>=21 prop:difficulty>=7到期天数 / 间隔 / FSRS 难度(1–10)
prop:reps>5 prop:lapses>0复习次数 / 遗忘次数
front:x back:x只在问题 / 答案里找
-tag:x排除
普通词全文(问题、答案、标签、来源路径)

组合示例:

  • deck:方剂 tag:麻黄 is:due —— 方剂牌组里、带麻黄标签、今天到期
  • tag:针灸 -is:paused —— 有针灸标签且没有被挂起
  • type:cloze front:桂枝 back:芍药 —— 挖空卡,问题含桂枝、答案含芍药
  • prop:due<7 prop:ivl>=21 —— 一周内到期、间隔已≥21 天
  • added:7 rated:1 —— 一周内新建、今天复习过

支持批量勾选 → 移动牌组 / 暂停 / 删除。

面板里点挖空可以直接写注释:挖空卡写成 {{c1::答案::注释}},导图同理;注释会显示在挖空上,和 Anki 的 cloze hint 一致。留空即删除注释,输入框旁还有「删除挖空」。

预览里的 Bury 把这张卡埋藏到今天结束,不改 FSRS 排期;Export all cards (CSV) 额外导出一份表格,方便放进 Excel 或其他 SRS。

图片蒙板

  • Alt + 点击编辑器里的图片 → 打开挖空面板(可在设置关闭)
  • 右键图片 → Obsidian 原生菜单保持不变
  • 命令 Make occlusion card from the image at the cursor(光标放在 ![[图片]] 行)
  • 命令 New image occlusion card (from clipboard)(先复制截图)

编辑面板:矩形/椭圆、多挖空组、缩放(+/-/Ctrl+滚轮)、平移、方向键微调、Ctrl+Z 撤销。保存时每组一张卡。

考试计划

设置 → 考试计划 里可以同时建多个计划(一科一个),每个计划有自己的名称、剩余天数、牌组和比例:

  • 还有多久考试填天数(默认 30,填 0 表示今天考),不用填日期;数字每天自动递减,考完当天该计划自动消失
  • 牌组是勾选,一个都不勾 = 全部牌组
  • 比例滑块下方实时显示这个计划会产生的负荷:≈ 每天 N 张,共 D 天,以及「选中的 X 张里有 Y 张排在考试之后」(超过每日上限会变红提示)
  • 点计划上的 生成 按钮,或命令 Build an exam plan(有多个计划时会让你选一个)
  • 只统计该计划牌组里未挂起、未毕业的卡,按难度从高到低排序后取比例部分
  • 到期日在考试之后的卡,会被均匀铺到考前每一天,不超过每日复习上限
  • 生成前自动备份到 fakecard/backup/exam-plan-<id>-<时间>.json
  • 考试当天过后计划自动移除,卡片回到正常 FSRS 调度,数据全部保留

数据与隐私

  • 卡片:fakecard/cards/<id>.json(纯 JSON,可手改)
  • 牌组:fakecard/decks.json
  • 复习记录:fakecard/reviews/YYYY-MM-DD.json
  • 备份/导出:fakecard/backup/、fakecard/export/
  • 导入的图片:fakecard/images/

全部本地,没有任何网络请求。插件不写你的笔记文件;阅读模式里的 📇 是渲染时插入的 DOM,不落盘。

命令

命令作用
Generate cards from the whole note整篇按规则生成
Generate from the selected lines只处理选中行
New Q&A card from selection用选中内容新建问答卡
New cloze card from selection用选中内容新建填空卡
New card (manual)手动面板
Start reviewing复习
Record the answer (start/stop)复习答案面录音开关
Edit this card编辑当前复习卡
Browse and edit cards浏览/筛选/编辑
Open statistics统计
Import cards from Anki (.apkg)Anki 导入
Import cards from clipboard (JSON)外部 JSON 导入
Export all cards (JSON)导出
Clean up orphan cards清理来源已删的卡
Remove graduated child cards清理已毕业子卡
Build an exam plan生成考试计划(多个计划时选择)
Make occlusion card from the image at the cursor光标处图片制卡

第三方

依赖许可用途
ts-fsrsMITFSRS 调度
fflateMIT.apkg zip 解压
fzstdMIT.apkg zstd 解压
sql.jsMIT读取 Anki 的 SQLite

开发

npm install
npm run dev     # 监听构建
npm run build   # 类型检查 + 生产构建

把 main.js、manifest.json、styles.css 复制到 <vault>/.obsidian/plugins/fakecard/。

License

MIT

For plugin developers

Search results and similarity scores are powered by semantic analysis of your plugin's README. If your plugin isn't appearing for searches you'd expect, try updating your README to clearly describe your plugin's purpose, features, and use cases.