CLI Reference — escribano-query
Agent-native work memory interface. JSON to stdout, logs to stderr, exit 0 on success.
Quickstart
escribano-query # today's activity escribano-query recent --since 2h # last 2 hours escribano-query search "swift actor" # full-text search escribano-query entities --since 24h # tools, languages, apps escribano-query status # health + license info
Command index
Command | What it does |
|---|---|
Activity from today (default) | |
Activity from yesterday | |
Activity from this week | |
Most recent day with activity | |
Activity in a rolling window ( | |
Activity between two dates | |
Full-text search across observations | |
Aggregated tools, languages, apps, etc. | |
Structured summary for support drafts | |
Health check, DB stats, license info | |
Activate a license key | |
Remove license, revert to free tier |
Time-based queries
Four shortcuts that return a moment timeline for a fixed window:
escribano-query today
escribano-query yesterday --json
escribano-query this-week --compact
escribano-query last-active-day # falls back to today if emptyCommand | Window |
|---|---|
| Today (default if no command given) |
| Yesterday |
| Current ISO week |
| Most recent day with observations |
Shared flags: --json, --compact, --full, --limit N
recent — moment timeline by duration
escribano-query recent --since 2h
escribano-query recent --since 30m --images
escribano-query recent --since 1d --compact --jsonFlag | Required | Description |
|---|---|---|
| ✓ |
|
| Include | |
| Toggle | |
| Cap results | |
| Force JSON output |
Returns observations bucketed by the given window with entity summaries.
range — custom time range
escribano-query range --from 2026-04-01 --to 2026-04-07
escribano-query range --from 2026-04-20T10:00:00Z --to 2026-04-20T18:00:00Z --jsonFlag | Required | Description |
|---|---|---|
| ✓ | Start date — |
| ✓ | End date — |
| Toggle | |
| Cap results | |
| Force JSON output |
search — full-text (FTS5, BM25 ranked)
escribano-query search "debugging" --since 4h
escribano-query search "swift actor" --collapse
escribano-query search "coolify" --limit 10Required: keyword string
Flag | Description |
|---|---|
| Time window |
| Explicit date range |
| Return only the most recent match |
| Deduplicate by description |
| Omit |
| Include |
| Cap results — default |
Search syntax
swift actor→ OR — matchesswiftoractor
"swift actor"→ exact phrase
swift AND actor→ both terms required
entities — aggregated data
escribano-query entities --since 24h
escribano-query entities --since 2h --kind programming_languageFlag | Description |
|---|---|
| Time window — default |
| Filter by kind |
| Cap results — default |
Entity kinds: software_tool · programming_language · framework · file_path · url · git_branch · error_message · app · company · website · person · location · event
No license check — works on any tier.
support-context — support summary
escribano-query support-context --jsonStructured context summary for support drafts and agent handoffs. Aggregated signals only — no raw observations.
status — health and license
escribano-query status --jsonReturns DB stats, operational health, and license info. No license check.
activate / deactivate — license
escribano-query activate ESC-BETA-XXXX
escribano-query activate ESC-PRO-XXXX
escribano-query deactivateactivate requires internet. deactivate reverts to the free tier (7-day history limit).
Global flags
Flag | Applies to | Description |
|---|---|---|
|
| Time window — |
|
| Explicit date range |
| most | Omit |
| most | Include |
|
| Deduplicate results by description |
|
| Include |
|
| Filter by entity kind |
| most | Cap result count |
| all | Force JSON output (default when piped) |
| all | Show help |
| all | Show version |
Output schema
Every JSON response uses this envelope:
{
"ok": true,
"api_version": 2,
"data": { ... },
"meta": {
"current_date": "2026-04-20",
"current_datetime": "2026-04-20T11:00:00+02:00",
"timezone": "Europe/Berlin"
}
}Anchor "today" to
meta.current_date— don't rely on the agent's system clock.
Errors use the same envelope with ok: false:
{
"ok": false,
"error": {
"code": "LICENSE_ERROR",
"message": "Search requires a Pro license for history older than 7 days."
}
}Code | Meaning |
|---|---|
| Database file missing |
| Database busy (WAL contention) |
| Schema version mismatch |
| Bad date format or inverted range |
| License invalid, expired, or network failure |
| Catch-all |
License tiers
Capability | Free | Pro |
|---|---|---|
History window | 7 days | Unlimited |
| ✗ | ✓ |
| ✓ | ✓ |
Activation | — |
|
State transitions:
stateDiagram-v2
[*] --> Free
Free --> Pro: activate ESC-PRO-XXXX
Free --> Beta: activate ESC-BETA-XXXX
Pro --> Free: deactivate
Beta --> Free: deactivateRun escribano-query status at any time to check your current tier.