ferrum-interfaces 0.8.4

Core trait contracts for the Ferrum LLM inference engine
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
pub(super) const fn sequence_slot_active(epoch: u64) -> u64 {
    (epoch << 2) | 1
}

pub(super) const fn sequence_slot_poisoned_drained(epoch: u64) -> u64 {
    (epoch << 2) | 2
}

pub(super) const fn sequence_slot_poisoned_undrained(epoch: u64) -> u64 {
    (epoch << 2) | 3
}

pub(super) const fn sequence_slot_is_poisoned(state: u64) -> bool {
    matches!(state & 3, 2 | 3)
}