Skip to content

Durasi: 10 menit | Block: 4


⏰ Cron = Scheduled Tasks

Manual: Kamu buka Hermes → ketik prompt → dapat hasil
Cron:   Hermes jalan sendiri jam 8 pagi → hasil sudah menunggu

Ini "passive income" style automation. Set once, benefit terus.


🛠️ Setup Cron di Hermes

Config

yaml
# hermes.config.yaml
cron:
  enabled: true
  timezone: "Asia/Jakarta"
  jobs:
    - name: "daily-brief"
      schedule: "0 8 * * *"    # Setiap hari jam 8 pagi
      task: "Baca data kemarin dari context/daily-data.md, buat morning brief"
      output: "output/daily-brief.md"
      notify: "slack:#daily-updates"

    - name: "weekly-report"
      schedule: "0 9 * * 1"    # Setiap Senin jam 9
      task: "Compile weekly summary dari output/daily-brief-*.md"
      output: "output/weekly-report.md"
      notify: "email:owner@business.com"

    - name: "competitor-check"
      schedule: "0 10 * * 5"   # Setiap Jumat jam 10
      task: "Research competitor updates, bandingkan dengan data kita"
      output: "output/competitor-check.md"

📋 Cron Expression Cheat Sheet

┌───────────── menit (0-59)
│ ┌───────────── jam (0-23)
│ │ ┌───────────── tanggal (1-31)
│ │ │ ┌───────────── bulan (1-12)
│ │ │ │ ┌───────────── hari (0-6, 0=Minggu)
│ │ │ │ │
* * * * *

Contoh:
0 8 * * *       → Setiap hari jam 8:00
0 9 * * 1       → Setiap Senin jam 9:00
0 9 1 * *       → Setiap tanggal 1 jam 9:00
*/30 * * * *    → Setiap 30 menit
0 8,12,18 * * * → Jam 8, 12, 18 setiap hari

🏗️ Common Cron Patterns

Daily Brief

Schedule: 0 8 * * *
Task: "Baca data kemarin, buat ringkasan:
      - Total order
      - Revenue
      - Top products
      - Issues yang perlu attention"
Output: Formatted brief
Notify: WhatsApp/Slack

Competitor Monitor

Schedule: 0 10 * * 5 (Jumat)
Task: "Cek website competitor:
      1. Ada produk baru?
      2. Ada perubahan harga?
      3. Ada promo?
      Bandingkan dengan data kemarin."
Output: Change report
Notify: Email

Content Calendar Reminder

Schedule: 0 7 * * * (Setiap hari)
Task: "Cek content calendar untuk hari ini.
      Kalau ada konten scheduled, generate draft caption."
Output: Draft content
Notify: Slack

Inventory Alert

Schedule: 0 9 * * 1-5 (Senin-Jumat)
Task: "Baca inventory data. Flag produk yang 
      stoknya < 10 unit."
Output: Alert list
Notify: WhatsApp owner

⚠️ Cron Best Practices

  1. Start dengan 1 cron — jangan banyak sekaligus
  2. Set timezone — default UTC bisa bikin jalan di tengah malam
  3. Monitor output — cek hasil cron secara berkala
  4. Error handling — kalau cron fail, harus ada notifikasi
  5. Cost awareness — cron = API calls rutin, hitung biaya
  6. Keep task specific — task yang terlalu broad = hasil yang kurang berguna

💰 Cost Estimation per Cron

CronFrequencyModelEst. Cost/Bulan
Daily brief30x/bulanGPT-4o-mini~$0.50 (Rp 8K)
Weekly report4x/bulanGPT-4o~$0.20 (Rp 3K)
Competitor check4x/bulanGPT-4o~$0.80 (Rp 13K)
Inventory alert22x/bulanGPT-4o-mini~$0.15 (Rp 2K)
Total~$1.65 (Rp 26K)

Sangat affordable dibanding hiring orang untuk task yang sama.

Bootcamp AI Automation — akala.id