Habits
A habit is a practice you want to sustain over time. Unlike a task (which is completed and disappears) or an event (which has a specific date), a habit is logged day by day and what matters is consistency, the streak, and the trend.
You tell the agent "I want to create a habit to read 30 minutes every day" and it's created with the frequency and duration you define.
Create a habit
The Administration and productivity agent has the create_habit tool. Define:
- Title — what you want to do ("Meditate", "Run", "Learn English")
- Emoji — visual icon for the dashboard
- Activity type — classification (exercise, meditation, reading, language, etc.) — affects color and aggregated stats
- Frequency — three modes:
- Daily: every day
- Weekly: once a week
- Custom: you choose the specific days (Monday, Wednesday, Friday for example, using
recurrence_days=[1, 3, 5])
- Expected duration (optional) — minutes per session. Useful if you want to record not just whether you did the activity, but how much time you put into it
You can also create and configure habits from the Habits tab in the UI.
Log completion
The agent has log_habit to mark a habit as completed on a specific day. From the UI you have two paths:
- Quick — tap the card checkbox on the dashboard and it's logged for today
- Detailed — open the log dialog and add duration (with hours/minutes selector) and optional notes. Useful if you want to know not just whether you meditated, but for how long
You can also log past days by tapping the corresponding cell on the contribution grid.
The contribution grid
The habit detail screen shows a GitHub-style grid where each cell is a day:
- Full green — you completed that day
- Faint green — you completed partially (if you logged less duration than expected)
- Empty — you didn't complete
You can change the scale between week, month, quarter and year to see the trend at different resolutions.
Streaks and stats
The read_habit_stats tool (and the detail UI) shows:
- Current streak — how many consecutive days you've completed
- Best streak — historical record
- Completion rate — percentage of days completed in the last 90 days
- Total completions — every time you've completed the habit
read_habit_calendar returns a text representation of the 12-week grid — useful when you ask the chat "how's my meditation habit?".
Pause and archive
If you need to pause a habit temporarily — vacation, illness, whatever — edit_habit puts it in paused state. Stats aren't deleted and the accumulated streak isn't broken. When you reactivate it (status=active), it resumes where it was without breaking the history.
The archived state takes it out of the dashboard without deleting it, in case you want to review the history later.
delete_habit is soft-delete: it marks a deleted_at but keeps the row in case you need to recover it.
Tools summary
| Tool | What for |
|---|---|
read_habits | Lists active/paused/archived habits with their current streak. |
create_habit | Creates a new habit with frequency + type + expected duration. |
edit_habit | Rename, change frequency or state (preserves streaks when pausing). |
delete_habit | Soft-delete. |
log_habit | Marks completion for a day (requires a valid habit_id). |
read_habit_stats | Current + best streak + completion rate. |
read_habit_calendar | 12-week contribution grid in text. |