gemini-sync

gemini-sync is a skill for Claude Code from tonydzi/second-brain-starter-kit. It costs 0 tokens per session (1,163 once invoked), scanned A, original, MIT.

A data-import workflow that reads a Google Takeout export of Gemini Apps activity and adds the conversation history to an Obsidian vault and a SQLite database. Google Takeout is Google’s tool for downloading a copy of account data.

In plain words
What is it for?
It is for parsing Gemini export files, adding chats to day notes and the database, and processing only new records on later runs.
Why use it?
It provides a way to preserve Gemini conversations when no live history API is available and avoids creating duplicates when the export is imported again.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the second-brain-skills plugin — 248 skills, 1 plugin shipped together

Good fit It is for parsing Gemini export files, adding chats to day notes and the database, and processing only new records on later runs.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/tonydzi/second-brain-starter-kit/local-gemini-sync
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add tonydzi/second-brain-starter-kit --skill local-gemini-sync
Clone the repo
git clone --depth 1 https://github.com/tonydzi/second-brain-starter-kit

Made for: Claude Code.

Or install second-brain-skills, the plugin that ships this one along with the rest of its 248 skills, 1 plugin.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for gemini-sync

README.md
[![agentmods](https://agentmods.dev/badge/skills/tonydzi/second-brain-starter-kit/local-gemini-sync/github.svg)](https://agentmods.dev/skills/tonydzi/second-brain-starter-kit/local-gemini-sync)
Your own site
<a href="https://agentmods.dev/skills/tonydzi/second-brain-starter-kit/local-gemini-sync"><img src="https://agentmods.dev/badge/skills/tonydzi/second-brain-starter-kit/local-gemini-sync/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for gemini-sync

Your own site · 80×15
<a href="https://agentmods.dev/skills/tonydzi/second-brain-starter-kit/local-gemini-sync"><img src="https://agentmods.dev/badge/skills/tonydzi/second-brain-starter-kit/local-gemini-sync.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,163 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.01163
Opus 5.5 $0.00000 $0.00465
Sonnet 5.5 $0.00000 $0.00233
Haiku 4.5 $0.00000 $0.00116

Measured 26d ago against content hash 07e52f4a73cb, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

gemini-sync scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 26d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/local-gemini-sync/SKILL.md · 42 lines

How it starts

The opening of the file, as written. The whole thing — 42 lines — stays where its author put it; the contents beside it link to each section on GitHub.

OBJECTIVE: Fold a Gemini Apps activity export into the vault (day-notes + SQLite), idempotently. Reply to Anton in Russian; end with a 🧒 «Простыми словами» recap ([[eli5-always]]).

Why this shape (read before "fixing")

Gemini chats are NOT reachable by any live/incremental API (the xAI-style console API is Grok-only; Google's is completions-only). Google Takeout My Activity → Gemini Apps is the ONLY reliable route to a user's own Gemini history. So this skill is a PARSER over an export file, not a puller — the "recurring" part is Google's native scheduled Takeout export + the takeout-pull actor that downloads it. Canon + full DR: 02-Decisions/decision-2026-07-14-personal-data-importers-grok-gemini-takeout.md (DR26-07-10-MACANTON-07).

Step 0 — Get the export (one-time human gate, then automatable)

If no fresh Gemini export is on disk:

  • takeout.google.com → Deselect all → My Activity → "All activity data included" → Deselect all → tick only Gemini Apps → format JSON → Create export. Delivery = download link (lands in a@ mailbox) OR set up the native scheduled export (every 2 months, up to 6) so it recurs.
  • Interactive Google login / 2FA = HARD-STOP → escalate to Anton (never enter credentials). Download of his OWN Takeout = pre-authorized (drive his logged-in Chrome, or takeout-pull detects the ready mail).
  • Requires Gemini Apps Activity = ON in his Google account, else nothing is saved to export.

Step 1 — Import (idempotent, stdlib, 0 tokens)

Point the importer at the extracted My Activity JSON (usually Takeout/My Activity/Gemini Apps/MyActivity.json):

python "$HOME/Obsidian/_imports/gemini/gemini_lib.py" import "<path-to-MyActivity.json>"

It: normalizes rows (keeps Gemini/Bard, skips other products) → upserts into gemini_activity.db (dedup by time|hash(title)) → writes ONE note per Gemini day under 01-Conversations/Gemini/days/ → writes _freshness.json. Re-running on the same export inserts +0 (idempotent).

Read the full file on GitHub · 42 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 26d ago First seen · 42 lines · 0 tokens per session scan A 07e52f4a73cb

Subscribe to this mod's changes

gemini-sync is a skill published in the GitHub repository tonydzi/second-brain-starter-kit (10 stars, last pushed yesterday), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,163 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-24.

Related

Other skills, from other repositories

save

Save a user-selected answer, decision, insight, or session summary into an Obsidian vault as one reviewed transaction. Use only when the user explicitly asks to preserve specific conversation content, not when they supply a file or URL to ingest. Triggers: /save, save this, save that answer, file this conversation…

AgriciDaniel/claude-obsidian · 80 tokens

wiki-retrieve

Build and query a vault-local contextual BM25 retrieval index with optional multilingual Nomic cosine reranking; use for retrieve, hybrid retrieval, BM25, rerank, contextual retrieval, chunk search, vault search, semantic search, find relevant passages, or retrieval diagnostics. Derived caches stay under .vault-meta…

AgriciDaniel/claude-obsidian · 81 tokens

obsidian-bases

Explain, draft, and validate Obsidian Bases .base files with filters, formulas, properties, summaries, and table, card, or list views. Use for Obsidian Bases, database-like vault views, dynamic tables, reading lists, task trackers, filters, formulas, summaries, and .base file edits.

AgriciDaniel/claude-obsidian · 69 tokens

wiki-fold

Create a bounded, extractive, structurally idempotent rollup of recent Obsidian wiki log entries, with dry-run preview by default and one optional transaction apply. Use for manual log compression without modifying child pages. Triggers: fold the log, run a fold, run wiki-fold, log rollup, roll up log entries, commit…

AgriciDaniel/claude-obsidian · 76 tokens

wiki-mode

Read or configure the vault filing methodology and suggest destinations for planned knowledge creation under Generic, LYT, PARA, or Zettelkasten. Use for wiki mode, methodology mode, what is my vault mode, set vault mode, switch to PARA, use LYT, Zettelkasten setup, change mode, configure mode, or methodology routing.…

AgriciDaniel/claude-obsidian · 83 tokens

wiki-cli

Detect and use the official Obsidian command-line interface for read-only vault access; use for wiki-cli, Obsidian CLI, Obsidian read, Obsidian search, vault transport, which transport, transport detection, backlinks, tags, or Obsidian command line. Mutations always go through the claude-obsidian transaction core.

AgriciDaniel/claude-obsidian · 74 tokens