obsidian-cost-tuning
Optimize Obsidian resource usage, sync storage, Publish hosting, and third-party plugin API costs. Use when managing vault size, reducing Sync bandwidth, controlling Publish costs, or optimizing external API consumption from community plugins. Trigger with phrases like "obsidian costs", "obsidian sync storage", "optimize obsidian", "reduce obsidian costs", "obsidian publish costs".
What this skill does
# Obsidian Cost Tuning
## Overview
Optimize costs across Obsidian's paid services and third-party plugin API usage. Covers Obsidian Sync storage management ($4-$10/mo), Publish hosting optimization ($8/mo per site), vault size reduction strategies, plugin API cost control with caching and quotas, and self-hosted alternatives for zero-cost sync.
## Prerequisites
- Understanding of your Obsidian subscription tier
- Terminal access to the vault directory
- Knowledge of which community plugins make external API calls
## Cost Structure
| Service | Price | Storage | Cost Driver |
|---------|-------|---------|-------------|
| Obsidian (core) | Free | N/A | None |
| Catalyst (early access) | $25 one-time | N/A | One-time |
| Sync (Standard) | $4/mo | 1 GB | Vault size, attachment count |
| Sync (Plus) | $8/mo | 10 GB | Large vaults with media |
| Publish | $8/mo per site | N/A | Published page count, bandwidth |
| Plugin API costs | Varies | N/A | Per-call pricing (AI, translation, etc.) |
## Instructions
### Step 1: Audit Vault Size and Storage Usage
```bash
set -euo pipefail
VAULT_PATH="${1:-$HOME/MyVault}"
echo "=== Vault Storage Audit ==="
echo "Total vault size: $(du -sh "$VAULT_PATH" 2>/dev/null | cut -f1)"
echo ".obsidian size: $(du -sh "$VAULT_PATH/.obsidian" 2>/dev/null | cut -f1)"
echo ""
# File counts by type
echo "=== Files by Type ==="
command find "$VAULT_PATH" -type f -not -path '*/.obsidian/*' -not -path '*/.trash/*' \
| sed 's/.*\.//' | sort | uniq -c | sort -rn | head -15
echo ""
echo "=== Top 20 Largest Files ==="
command find "$VAULT_PATH" -type f -not -path '*/.obsidian/*' \
-exec du -h {} + 2>/dev/null | sort -rh | head -20
echo ""
echo "=== Plugin Cache Sizes ==="
for dir in "$VAULT_PATH/.obsidian/plugins"/*/; do
[ -f "$dir/data.json" ] || continue
size=$(du -h "$dir/data.json" 2>/dev/null | cut -f1)
echo " $(basename "$dir")/data.json: $size"
done
```
### Step 2: Reduce Sync Storage — Exclusion Patterns
Obsidian Sync respects `.obsidian/sync-exclude.json` for excluding paths:
```json
{
"patterns": [
"*.pdf",
"*.mp4",
"*.mov",
"*.zip",
"*.tar.gz",
"attachments/archives/**",
"node_modules/**",
".git/**"
]
}
```
For manual file-level control:
```bash
# Find files over 5MB that consume sync bandwidth
command find "$VAULT_PATH" -type f -size +5M -not -path '*/.obsidian/*' \
-exec du -h {} + | sort -rh
# Count sync-heavy file types
echo "PDF count: $(command find "$VAULT_PATH" -name '*.pdf' | wc -l)"
echo "Image count: $(command find "$VAULT_PATH" \( -name '*.png' -o -name '*.jpg' -o -name '*.jpeg' \) | wc -l)"
echo "Total attachments: $(du -sh "$VAULT_PATH/attachments" 2>/dev/null | cut -f1)"
```
Strategies to stay under the 1 GB Sync Standard tier:
- Move PDFs to a local folder outside the vault, link with ` URIs
- Compress images before adding: `pngquant --quality=65-80 *.png` or ImageOptim
- Use external image hosting (Cloudinary free tier: 25 credits/mo, ~25K transforms)
- Exclude `.obsidian/plugins/*/data.json` — plugin caches regenerate on launch
### Step 3: Optimize Plugin API Costs
Plugins that call external APIs (AI assistants, translation, image generation) can incur per-call costs. Implement caching in your plugin:
```typescript
// src/services/api-cache.ts
import { Plugin } from 'obsidian';
interface CacheEntry<T> {
result: T;
timestamp: number;
}
export class APICache<T> {
private cache = new Map<string, CacheEntry<T>>();
private ttlMs: number;
constructor(ttlMinutes: number = 60) {
this.ttlMs = ttlMinutes * 60 * 1000;
}
get(key: string): T | null {
const entry = this.cache.get(key);
if (!entry) return null;
if (Date.now() - entry.timestamp > this.ttlMs) {
this.cache.delete(key);
return null;
}
return entry.result;
}
set(key: string, result: T) {
this.cache.set(key, { result, timestamp: Date.now() });
// Prevent unbounded growth
if (this.cache.size > 1000) {
const oldest = this.cache.keys().next().value;
if (oldest) this.cache.delete(oldest);
}
}
/** Wrap an API call with cache-first logic */
async getOrFetch(key: string, fetchFn: () => Promise<T>): Promise<T> {
const cached = this.get(key);
if (cached !== null) return cached;
const result = await fetchFn();
this.set(key, result);
return result;
}
clear() { this.cache.clear(); }
get size() { return this.cache.size; }
}
// Usage in plugin
const aiCache = new APICache<string>(24 * 60); // 24-hour TTL
async function getSummary(noteContent: string): Promise<string> {
const hash = simpleHash(noteContent);
return aiCache.getOrFetch(hash, async () => {
// Only calls API if not cached
const response = await requestUrl({ url: 'https://api.openai.com/...', ... });
return response.json.choices[0].message.content;
});
}
```
### Step 4: Rate Limiting for External Calls
```typescript
// Prevent runaway API costs with a quota counter
class APIQuota {
private calls = 0;
private resetTime = 0;
private maxCallsPerHour: number;
constructor(maxPerHour: number) {
this.maxCallsPerHour = maxPerHour;
}
canCall(): boolean {
const now = Date.now();
if (now - this.resetTime > 3600000) {
this.calls = 0;
this.resetTime = now;
}
return this.calls < this.maxCallsPerHour;
}
recordCall() { this.calls++; }
remaining(): number {
return Math.max(0, this.maxCallsPerHour - this.calls);
}
}
// Usage
const quota = new APIQuota(100); // max 100 API calls per hour
async function callExternalAPI() {
if (!quota.canCall()) {
new Notice('API quota exceeded. Try again later.');
return;
}
quota.recordCall();
// ... make API call
}
```
### Step 5: Optimize Obsidian Publish Costs
Publish at $8/mo per site. Minimize what you publish to reduce bandwidth:
```yaml
# In each note's frontmatter, control what gets published
---
publish: true # Include this note on Publish site
permalink: custom-url # Custom URL path
---
```
Cost reduction strategies:
- Use `publish: true` frontmatter selectively instead of publishing entire folders
- Compress images before embedding (target < 200KB per image)
- Use lazy-loading for heavy media: `!alt` with external hosting
- Monitor page count — each additional page adds build time and bandwidth
- Use Obsidian's built-in image compression in Publish settings
### Step 6: Self-Hosted Sync Alternatives (Free)
```yaml
# Decision matrix for $0/month sync
obsidian_git:
cost: Free
setup: Install Obsidian Git plugin, configure repo
pros: Full version history, unlimited storage, branch per device
cons: Manual setup, no conflict resolution UI, requires Git knowledge
best_for: Developers, technical users
syncthing:
cost: Free
setup: Install on each device, share vault folder
pros: Real-time sync, no cloud dependency, encrypted
cons: Devices must be online simultaneously (or have relay), no web access
best_for: Privacy-focused users, LAN-only setups
icloud_drive:
cost: Free (with Apple devices)
setup: Move vault to ~/Library/Mobile Documents/iCloud~md~obsidian/Documents/
pros: Zero config on Apple ecosystem, transparent to Obsidian
cons: .obsidian/ conflicts common, slow on large vaults, Apple-only
best_for: Apple-only users with small vaults
remotely_save:
cost: Free (with existing S3/WebDAV)
setup: Install Remotely Save plugin, configure backend
pros: Works with S3, Dropbox, OneDrive, WebDAV
cons: Plugin manages sync (no native integration), manual conflict handling
best_for: Users with existing cloud storage
```
### Step 7: Ongoing Cost Monitoring Script
```bash
#!/bin/bash
# vault-cost-report.sh <vault-path>
VAULT="${1:-$HOME/MyVault}"
echo "=== Monthly Cost Estimate ==="
# Vault size
SIZE_MB=$(du -sm "$VAULT" 2>/dev/null | cut -f1)
echo "Vault size: ${SIZE_MB} MB"
if [ "$SIZE_MB" -lt 1024 ]; then
echo "Sync tier needed: Standard ($4/mo) — under 1 GB"
Related in Backend & APIs
jfrog
IncludedInteract with the JFrog Platform via the JFrog CLI and REST/GraphQL APIs. Use this skill when the user wants to manage Artifactory repositories, upload or download artifacts, manage builds, configure permissions, manage users and groups, work with access tokens, configure JFrog CLI servers, search artifacts, manage properties, set up replication, manage JFrog Projects, run security audits or scans, look up CVE details, query exposures scan results from JFrog Advanced Security, manage release bundles and lifecycle operations, aggregate or export platform data, or perform any JFrog Platform administration task. Also use when the user mentions jf, jfrog, artifactory, xray, distribution, evidence, apptrust, onemodel, graphql, workers, mission control, curation, advanced security, exposures, or any JFrog product name.
cupynumeric-migration-readiness
IncludedPre-migration readiness assessor for porting NumPy to cuPyNumeric. Use BEFORE substantial porting work begins when the user asks whether code will scale on GPU, whether they should migrate to cuPyNumeric, which NumPy patterns transfer cleanly, what must be refactored before porting, or mentions pre-port assessment, scaling analysis, or refactor planning. Inspect the user's source code, look up NumPy usage, cross-reference the cuPyNumeric API support manifest, and distinguish distributed-scaling-friendly patterns from blockers such as unsupported APIs, scalar synchronization, host round-trips, Python/object-heavy control flow, shape/data-dependent branching, and in-place mutation hazards. Produce a verdict of READY, LIGHT REFACTOR, SIGNIFICANT REFACTOR, or NOT RECOMMENDED, with concrete refactor pointers.
alibabacloud-data-agent-skill
IncludedInvoke Alibaba Cloud Apsara Data Agent for Analytics via CLI to perform natural language-driven data analysis on enterprise databases. Data Agent for Analytics is an intelligent data analysis agent developed by Alibaba Cloud Database team for enterprise users. It automatically completes requirement analysis, data understanding, analysis insights, and report generation based on natural language descriptions. This tool supports: discovering data resources (instances/databases/tables) managed in DMS, initiating query or deep analysis sessions, real-time progress tracking, and retrieving analysis conclusions and generated reports. Use this Skill when users need to query databases, analyze data trends, generate data reports, ask questions in natural language, or mention "Data Agent", "data analysis", "database query", "SQL analysis", "data insights".
token-optimizer
IncludedReduce OpenClaw token usage and API costs through smart model routing, heartbeat optimization, budget tracking, and native 2026.2.15 features (session pruning, bootstrap size limits, cache TTL alignment). Use when token costs are high, API rate limits are being hit, or hosting multiple agents at scale. The 4 executable scripts (context_optimizer, model_router, heartbeat_optimizer, token_tracker) are local-only — no network requests, no subprocess calls, no system modifications. Reference files (PROVIDERS.md, config-patches.json) document optional multi-provider strategies that require external API keys and network access if you choose to use them. See SECURITY.md for full breakdown.
resend-cli
IncludedUse this skill when the task is specifically about operating Resend from an AI agent, terminal session, or CI job via the official resend CLI: installing/authenticating the CLI, sending/listing/updating/cancelling emails, batch sends, domains and DNS, webhooks and local listeners, inbound receiving, contacts, topics, segments, broadcasts, templates, API keys, profiles, or debugging Resend CLI/API failures. Trigger on mentions of Resend CLI, `resend`, `resend doctor`, `resend emails send`, `resend domains`, `resend webhooks listen`, `resend emails receiving`, or agent-friendly terminal automation.
alibabacloud-odps-maxframe-coding
IncludedUse this skill for MaxFrame SDK development and documentation navigation on Alibaba Cloud MaxCompute (ODPS). Helps answer MaxFrame API, concept, official example, and supported pandas API questions; create data processing programs; read/write MaxCompute tables; debug jobs (remote or local); and build custom DPE runtime images. Trigger when users mention MaxFrame, MaxCompute with MaxFrame, ODPS table processing, DPE runtime, MaxFrame docs/examples, DataFrame/Tensor operations, or GPU runtime setup. Works for both English and Chinese queries about Alibaba Cloud data processing with MaxFrame.