ai-agent 0.13.4

Idiomatic agent sdk inspired by the claude code source leak
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
// Source: /data/home/swei/claudecode/openclaudecode/src/keybindings/resolver.ts
//! Keybinding resolver

use std::collections::HashMap;

pub fn resolve_keybinding(
    context: &str,
    action: &str,
    bindings: &HashMap<String, HashMap<String, String>>,
) -> Option<String> {
    bindings
        .get(context)
        .and_then(|ctx| ctx.get(action).cloned())
}