1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
// CONTRACT: flash-attention-v1.yaml
// HASH: sha256:a3b4c5d6e7f89012
// Generated by: pv probar --binding
// DO NOT EDIT — regenerate with `pv probar --binding`
use proptest::prelude::*;
proptest! {
/// Obligation: Numerically equivalent to standard attention (equivalence)
/// Formal: |FlashAttn(Q,K,V) - softmax(QK^T/√d)V| < ε
#[test]
#[ignore = "Flash attention not implemented"]
fn prop_standard_attention_equivalence(
_x in proptest::collection::vec(-10.0f32..10.0, 1..32usize)
) {
// Blocked: flash attention not implemented in aprender
}
/// Obligation: Memory O(N) not O(N²) (resource bound)
/// Formal: peak memory ∝ N (sequence length), not N²
#[test]
#[ignore = "Flash attention not implemented"]
fn prop_linear_memory(
_x in proptest::collection::vec(-10.0f32..10.0, 1..32usize)
) {
// Blocked: flash attention not implemented
}
/// Obligation: Causal mask correctness (invariant)
/// Formal: output[i] depends only on input[0..=i]
#[test]
#[ignore = "Flash attention not implemented"]
fn prop_causal_mask(
_x in proptest::collection::vec(-10.0f32..10.0, 1..32usize)
) {
// Blocked: flash attention not implemented
}
/// Obligation: SIMD matches scalar within ULP (equivalence)
#[test]
#[ignore = "Flash attention not implemented"]
fn prop_simd_equivalence(
_x in proptest::collection::vec(-10.0f32..10.0, 1..32usize)
) {
// Blocked: flash attention not implemented
}
}