File size: 1,140 Bytes
c6d7c4c
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
.Checks: &Checks
    one_argument:
      assert: "len(f.args)"
      eq: 2
    gcd_1_1:
      assert: "f.call(1,1)"
      eq: 1
    gcd_100_10:
      assert: "f.call(100,10)"
      eq: 10

GCDZeroShot:
    Signature: "gcd(a, b)"
    Input: "with two inputs a and b"
    Output: "the greatest common demoninator (gcd) of a and b"
    Description: "See if the model can output a well-known, simple algorithm."
    Checks:
        <<: *Checks
        input_name_0:
            assert: "f.args[0].name"
            eq: "a"
        input_name_1:
            assert: "f.args[1].name"
            eq: "b"

GCDMisnamed:
    Signature: "fofx(x, banana)"
    Input: "with two inputs x and banana"
    Output: "the greatest common demoninator (gcd) of x and banana"
    Description: "See if the model can output a well-known, simple algorithm if the name has been changed."
    Checks:
        <<: *Checks
        input_name_0:
            assert: "f.args[0].name"
            eq: "x"
        input_name_1:
            assert: "f.args[1].name"
            eq: "banana"
        func_name:
            assert: "f.name"
            eq: "fofx"