Skip to content
Cette page a été générée et traduite avec l'aide de l'IA. Si vous remarquez des inexactitudes, n'hésitez pas à contribuer. Modifier sur GitHub

Built-in Tasks

PRX inclut several built-in cron tasks that handle routine maintenance. These tasks run automatiquement lorsque le cron system est active.

Task Reference

TaskDefaut ScheduleDescription
heartbeatEvery 30sSystem health check
memory-hygieneDaily at 3:00Compact and prune memory entries
log-rotationDaily at 0:00Rotate and compress old log files
cache-cleanupHourlyRemove expired cache entries
metrics-exportEvery 5mExport metrics pour configurerd backends
signature-updateEvery 6hUpdate threat signatures (if PRX-SD integration enabled)

Configuration

Each built-in task peut etre individually enabled/disabled and rescheduled:

toml
[cron.builtin.memory_hygiene]
enabled = true
schedule = "0 3 * * *"

[cron.builtin.log_rotation]
enabled = true
schedule = "0 0 * * *"
max_log_age_days = 30

[cron.builtin.cache_cleanup]
enabled = true
schedule = "0 * * * *"

Custom Tasks

En plus de built-in tasks, you can define custom agent tasks that execute a prompt sur un schedule:

toml
[[cron.tasks]]
name = "weekly-cleanup"
schedule = "0 2 * * 0"  # Sundays at 2:00 AM
action = "agent"
prompt = "Review and archive old conversation logs"
timeout_secs = 300

Voir aussi Pages

Released under the Apache-2.0 License.