aboutsummaryrefslogtreecommitdiff
path: root/src/agent_detection_policy.rs
diff options
context:
space:
mode:
authorOgulcan Celik <ogulcancelik@gmail.com>2026-06-09 15:59:34 +0300
committerOgulcan Celik <ogulcancelik@gmail.com>2026-06-09 15:59:34 +0300
commitdf7880c54b8b5d337421cb4b1dd8daea27008801 (patch)
tree4d0cc6290ad71c413bac71cfaab4ef41ea017ecb /src/agent_detection_policy.rs
parenteeacb45b4b6ab4446c5bea1331f743fee5e5b9f8 (diff)
feat: update agent lifecycle integrations
Diffstat (limited to 'src/agent_detection_policy.rs')
-rw-r--r--src/agent_detection_policy.rs27
1 files changed, 16 insertions, 11 deletions
diff --git a/src/agent_detection_policy.rs b/src/agent_detection_policy.rs
index a0d7ba4c..7a2677a2 100644
--- a/src/agent_detection_policy.rs
+++ b/src/agent_detection_policy.rs
@@ -43,7 +43,7 @@ fn screen_blocked_or_idle_fallback(detection: AgentDetection) -> AgentDetection
pub(crate) fn full_lifecycle_detected_agent(agent: Agent) -> bool {
matches!(
agent,
- Agent::Pi | Agent::GithubCopilot | Agent::Kimi | Agent::Hermes | Agent::Qodercli
+ Agent::Pi | Agent::Hermes | Agent::OpenCode | Agent::Kilo
)
}
@@ -52,10 +52,9 @@ pub(crate) fn full_lifecycle_hook_authority(source: &str, agent_label: &str) ->
(source, agent_label),
("herdr:pi", "pi")
| ("herdr:omp", "omp")
- | ("herdr:kimi", "kimi")
- | ("herdr:copilot", "copilot")
| ("herdr:hermes", "hermes")
- | ("herdr:qodercli", "qodercli")
+ | ("herdr:opencode", "opencode")
+ | ("herdr:kilo", "kilo")
)
}
@@ -122,23 +121,29 @@ mod tests {
fn classifies_full_lifecycle_hook_sources() {
assert!(full_lifecycle_hook_authority("herdr:pi", "pi"));
assert!(full_lifecycle_hook_authority("herdr:omp", "omp"));
- assert!(full_lifecycle_hook_authority("herdr:kimi", "kimi"));
- assert!(full_lifecycle_hook_authority("herdr:copilot", "copilot"));
assert!(full_lifecycle_hook_authority("herdr:hermes", "hermes"));
- assert!(full_lifecycle_hook_authority("herdr:qodercli", "qodercli"));
+ assert!(full_lifecycle_hook_authority("herdr:opencode", "opencode"));
+ assert!(full_lifecycle_hook_authority("herdr:kilo", "kilo"));
+ assert!(!full_lifecycle_hook_authority("herdr:copilot", "copilot"));
assert!(!full_lifecycle_hook_authority("herdr:codex", "codex"));
assert!(!full_lifecycle_hook_authority("herdr:claude", "claude"));
- assert!(!full_lifecycle_hook_authority("herdr:opencode", "opencode"));
+ assert!(!full_lifecycle_hook_authority("herdr:cursor", "cursor"));
+ assert!(!full_lifecycle_hook_authority("herdr:kimi", "kimi"));
+ assert!(!full_lifecycle_hook_authority("herdr:droid", "droid"));
+ assert!(!full_lifecycle_hook_authority("herdr:qodercli", "qodercli"));
assert!(!full_lifecycle_hook_authority("custom", "pi"));
}
#[test]
fn classifies_full_lifecycle_detected_agents_without_omp_variant() {
assert!(full_lifecycle_detected_agent(Agent::Pi));
- assert!(full_lifecycle_detected_agent(Agent::Kimi));
- assert!(full_lifecycle_detected_agent(Agent::GithubCopilot));
assert!(full_lifecycle_detected_agent(Agent::Hermes));
- assert!(full_lifecycle_detected_agent(Agent::Qodercli));
+ assert!(full_lifecycle_detected_agent(Agent::OpenCode));
+ assert!(full_lifecycle_detected_agent(Agent::Kilo));
+ assert!(!full_lifecycle_detected_agent(Agent::GithubCopilot));
+ assert!(!full_lifecycle_detected_agent(Agent::Kimi));
+ assert!(!full_lifecycle_detected_agent(Agent::Droid));
+ assert!(!full_lifecycle_detected_agent(Agent::Qodercli));
assert!(!full_lifecycle_detected_agent(Agent::Codex));
assert!(!full_lifecycle_detected_agent(Agent::Claude));
}