Study Time Statistics

by miss
5
4
3
2
1
Score: 51/100

Description

Private, local-first study analytics for Obsidian notes and PDFs · 本地隐私优先的学习时间统计

Reviews

No reviews yet.

Stats

2
stars
1,236
downloads
0
forks
55
days
2
days
3
days
7
total PRs
0
open PRs
0
closed PRs
7
merged PRs
1
total issues
0
open issues
1
closed issues
55
commits

Latest Version

4 days ago

Changelog

Study Time Statistics 2.2.0

中文

  • 新增“数据健康”页面,检查重复会话、异常时长和失效的笔记引用。
  • 安全修复前自动创建本地备份;仅修复可以明确判断的问题。
  • 笔记重命名后,阅读记录、会话和进度记录会自动迁移到新路径。
  • 自动保留最近 20 份备份,避免备份目录无限增长。
  • 仪表盘整理为“学习总览、统计分析、阅读记录、更多”四个入口,新功能放入对应子页。
  • 新页面跟随界面语言显示,不再把中英文同时挤在一行。
  • 图表默认统一跟随 Obsidian 主题色,也可在设置中选择自定义颜色;只有热力图用同色深浅表达强弱,柱状图仅以高度或长度表达数值。
  • 空白轨道不再伪装成满格数据,热力图采用自适应分档并显示“少—多”图例。
  • 修正趋势柱图比例、跨午夜会话、24 小时与星期分布、月底日期导航及阅读覆盖率汇总口径。
  • 自动计时改为一次原子写入,历史总计改为单次载入后在内存聚合,减少长期使用后的卡顿与并发覆盖风险。
  • 目标进度与每日记录使用同一口径并随数据更新;恢复备份前先保存当前状态,损坏的最新备份会自动跳过。
  • 趋势图只绘制与数值等高的单色实心柱,不再显示占满高度的按钮底色;柱高会直接对齐左侧时间刻度。
  • 发布流程使用中英文版本说明,并增加依赖审计和标签来源检查。

English

  • Adds a Data Health page for duplicate sessions, invalid durations, and references to missing notes.
  • Creates a local backup before safe repairs and only fixes deterministic issues.
  • Migrates reading records, sessions, and progress entries when a note is renamed.
  • Retains the 20 newest backups to prevent unbounded backup growth.
  • Organizes the dashboard into four clear sections: Overview, Analytics, Records, and More.
  • New pages now follow the interface language instead of showing Chinese and English together.
  • Charts use one consistent color that follows Obsidian's accent by default, with an optional custom color. Only heatmaps use intensity shades; bars communicate values solely through height or length.
  • Empty tracks stay visibly empty, while heatmap levels adapt to the active-day distribution and include a Less–More legend.
  • Fixes trend-bar scaling, cross-midnight sessions, hourly and weekday allocation, end-of-month navigation, and coverage aggregation.
  • Makes timer updates atomic and aggregates history from one in-memory snapshot to reduce long-term lag and lost-update risks.
  • Keeps goal progress aligned with daily records and live data changes; backup restore now preserves the current state first and skips an invalid newest backup.
  • Makes data-health repairs recalculate affected totals, and clearly separates safe automatic repairs from missing-note reminders.
  • Draws trend values as single solid columns with no full-height button background, so every column aligns directly with the time scale.
  • Publishes the maintained bilingual notes and adds dependency and tag-origin checks to the release workflow.

README file from

Github

Study Time Statistics

English (this page) · 中文完整版 · 中文摘要

This repository is documented in both English and Chinese. The English documentation appears first, followed by a Chinese summary on the same page.

Study Time Statistics is a privacy-first Obsidian plugin that measures how you study across notes and PDFs. It combines unobtrusive per-note metrics with an Anki-inspired analytics dashboard—without adding anything to your Markdown files.

Actual Study Time Statistics analytics overview with private note details excluded

Actual Obsidian interface, captured on 2026-10-02 from a 3.0.0 development build. At capture time, the public release was 2.2.0, so some controls may differ. This is a direct crop of aggregate statistics—not a UI mockup. No note titles, paths, folders, or contents are shown.

Highlights

  • Automatically track active reading time for Markdown notes and PDFs.
  • Count opens and completed reading sessions per note.
  • Show an inline statistics strip at the top of every note. It belongs to the view, scrolls away with the note, and never changes the source file.
  • Display opens, total time, average time per visit, longest session, active days, current streak, and last read time.
  • Explore day, week, month, year, and all-time statistics.
  • Review a 365-day heatmap, 30-day time and session trends, hourly and weekday patterns, session-length distribution, folder summaries, and recent sessions.
  • Review every recorded session, add a missed session, or correct and delete inaccurate entries without editing plugin data by hand.
  • Create timestamped local backups and restore the latest backup from the dashboard or Command Palette.
  • Optionally record self-reported reading coverage for each visit. Coverage describes how much content you reached—not how much you understood, remembered, or mastered.
  • Explore per-note and folder coverage, a 365-day coverage heatmap, hourly patterns, estimated covered characters, and character-based reading pace.
  • Set private daily and weekly study targets, follow a 28-day goal trend, and review ambiguous long sessions without automatic deletion.
  • Start from a Study Overview that combines goals, week-over-week change, session quality, high-investment hours, and a conservative revisit queue.
  • Track optional start/end position and manual or estimated characters read, then compare unique reach, repeated reading, equivalent passes, and time per 1,000 characters.
  • Classify new sessions from local interaction signals as interactive, quiet study, needs review, or unclassified. Ambiguous sessions are never silently discarded.
  • Rank notes by most opens, longest total reading time, longest average visit, longest single session, and most active days.
  • Pause tracking when Obsidian is not focused by enabling Strict mode.
  • Keep all statistics inside the local vault—no account, telemetry, advertising, or cloud upload.

Real, anonymized snapshot

The captured development build shows 87 notes read, 200 opens, and 3h 45m of recorded reading time as of 2026-10-02. These are the owner's real, point-in-time aggregate values, shared with permission—not sample data, a benchmark, or a live counter. The screenshot excludes note-level rankings and all private titles, paths, folders, and contents.

Actual 30-day reading-time and reading-session charts from the same Obsidian capture

The two 30-day charts are another direct crop of the same interface capture. We show aggregate views here to keep private note details out of public screenshots.

Open the dashboard

Select the bar-chart icon in the left ribbon, or open the Command Palette and run Open Study Time Statistics. The current dashboard has four main areas: Study overview, Analytics, Records, and More. Rankings and filtered analysis live under Analytics; sessions, reading coverage, and goals live under Records; reports, data management, and feedback live under More. Reading Coverage is off by default and can be enabled from its page or the plugin settings.

Installation

Community Plugins

Study Time Statistics is available in the Obsidian Community Plugins directory. Open Settings → Community plugins → Browse, search for Study Time Statistics, and select Install.

View Study Time Statistics in the Obsidian plugin directory

Manual installation

  1. Download main.js, manifest.json, and styles.css from the latest GitHub release.
  2. Create <vault>/.obsidian/plugins/study-time-statistics/.
  3. Copy the three files into that directory.
  4. Restart Obsidian, then enable Study Time Statistics under Settings → Community plugins.

Privacy and storage

All data stays under .obsidian/plugins/study-time-statistics/ in your own vault. The plugin stores note paths and local study metrics needed for its charts. When Reading Coverage is enabled, it also stores self-reported percentages, note character-count snapshots, related active durations, and local interaction counts and timestamps. It never stores note contents. Timestamped backups are saved to Study Time Statistics Backups/ in the vault and therefore contain the same private note paths and metrics. It does not send data over the network. The public screenshots contain a permissioned, point-in-time snapshot of real aggregate values, but no note title, path, folder, or content field is visible.

Syncing between devices

The plugin does not implement or require a separate cloud service. If your whole vault—including its .obsidian configuration folder—is synchronized by Obsidian Sync, iCloud Drive, Nutstore, or another file-sync provider, the plugin data can travel with that vault according to the provider's settings. Enable configuration-folder syncing on every device and avoid editing the same data concurrently while a provider is still resolving conflicts. Backups in Study Time Statistics Backups/ may also be synchronized because they are normal vault files.

Feedback and support

The dashboard includes a Feedback page that opens the appropriate GitHub form for bugs, inaccurate statistics, feature requests, or discussions. The plugin never submits study data automatically; nothing is sent until the user explicitly submits a GitHub form.

Before posting screenshots or logs, replace private note titles and paths with anonymous examples.

Development

npm install
npm test
npm run build

The production build generates main.js. A GitHub release must include main.js, manifest.json, and styles.css, with a tag matching the version in manifest.json exactly.

Compatibility

  • Obsidian 1.13.0 or later
  • Desktop and mobile manifests are supported; background-focus behavior depends on the operating system

Credits and license

Study Time Statistics is an independent plugin inspired by Anki's statistical presentation. It is not affiliated with or endorsed by Anki.

The codebase is derived from AstraDev's open-source Obsidian time tracker, used under the Apache License 2.0. Original copyright notices and license terms are preserved. See LICENSE and NOTICE.


中文摘要

Study Time Statistics(学习时间统计)是一款本地隐私优先的 Obsidian 插件,用来统计 Markdown 笔记和 PDF 的有效阅读时间、打开次数、平均每次阅读、最长单次阅读、活跃天数和连续学习天数。每篇笔记顶部的统计条属于界面层,会随正文滚动消失,不会写入或修改 Markdown 原文。

仪表盘提供日、周、月、年和全部时间范围,并包含 365 天热力图、近 30 天趋势、时段与星期分布、会话时长分布、文件夹汇总、最近会话,以及按打开次数、累计阅读、平均阅读、最长单次和活跃天数排列的榜单。1.3.0 新增学习目标与会话复核;2.0.0 新增学习总览;2.1.0 新增阅读起止位置、手填/估算阅读字符、重复阅读量、等效通读遍数和每千字用时。覆盖度与位置都不代表吸收、理解、记忆或掌握程度。

上方图片是 2026-10-02 从实际 Obsidian 界面直接裁切的截图,显示当时 87 篇已读笔记、200 次打开、累计 3 小时 45 分钟。截图来自当时尚未公开发布的 3.0.0 开发版;截取时公开最新版为 2.2.0,部分控件可能不同。公开图片仅展示汇总数据,没有笔记标题、路径、文件夹或正文。

所有学习数据仅保存在本地库中,插件不上传数据、不收集遥测、无广告,也不需要云端账户。若整库同步包含 .obsidian 配置文件夹,数据可随 Obsidian Sync、iCloud、坚果云等现有方案同步,无需插件另建同步服务。完整中文说明见 README_zh.md。