Dataset Viewer
Auto-converted to Parquet Duplicate
corpus_id
stringlengths
15
52
feature
stringlengths
9
34
source
stringlengths
2
304
references
listlengths
0
5
stability
stringclasses
3 values
tags
listlengths
1
9
schema_version
stringclasses
1 value
git_ref
stringclasses
1 value
read
stringlengths
5
430
expand
stringlengths
5
333
eval
stringclasses
114 values
error
stringclasses
6 values
invalid
stringclasses
21 values
class-layout-init-repr-eq-001
layout/define-class
define-class Vector2 []: define __init__ [self x y]: (set-attr self x x) (set-attr self y y) define __repr__ [self]: (#str "Vector2(" self.x ", " self.y ")") define __eq__ [self other]: (and (instance? other Vector2) (== self.x other.x) (== self.y other.y))
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-define-class.md", "reference/specials/compile-class.md", "reference/specials/compile-set-attr.md", "reference/specials/compile-attr.md" ]
evolving
[ "class", "define-class", "layout", "dunder", "method" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/define-class Vector2 () (compile/begin (define __init__ [self x y] (set-attr self x x) (set-attr self y y)) (define __repr__ [self] (#str "Vector2(" (compile/attr self x) ", " (compile/attr self y) ")")) (define __eq__ [self other] (and (instance? other Vector2) (== (compile/attr self x) (compile/attr other x)...
null
null
null
null
class-layout-hash-bool-001
layout/define-class
define-class Token []: define __init__ [self text kind]: (set-attr self text text) (set-attr self kind kind) define __hash__ [self]: (hash [self.kind self.text]) define __bool__ [self]: (truth self.text)
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-define-class.md", "reference/specials/compile-class.md", "reference/specials/compile-set-attr.md" ]
evolving
[ "class", "define-class", "layout", "dunder", "protocol", "define-type" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/define-class Token () (compile/begin (define __init__ [self text kind] (set-attr self text text) (set-attr self kind kind)) (define __hash__ [self] (hash [(compile/attr self kind) (compile/attr self text)])) (define __bool__ [self] (truth (compile/attr self text))))))
null
null
null
null
class-layout-len-iter-contains-001
layout/define-class
define-class Bag []: define __init__ [self items]: (set-attr self items items) define __len__ [self]: (len self.items) define __iter__ [self]: (iter self.items) define __contains__ [self item]: (in? item self.items)
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-define-class.md", "reference/specials/compile-class.md", "reference/specials/compile-attr.md" ]
evolving
[ "class", "define-class", "layout", "dunder", "collection", "define-type" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/define-class Bag () (compile/begin (define __init__ [self items] (set-attr self items items)) (define __len__ [self] (len (compile/attr self items))) (define __iter__ [self] (iter (compile/attr self items))) (define __contains__ [self item] (in? item (compile/attr self items))))))
null
null
null
null
class-layout-getitem-setitem-001
layout/define-class
define-class Row []: define __init__ [self cells]: (set-attr self cells cells) define __getitem__ [self index]: (item self.cells index) define __setitem__ [self index value]: (set-item self.cells index value)
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-define-class.md", "reference/specials/compile-class.md" ]
evolving
[ "class", "define-class", "layout", "dunder", "indexing", "define-type" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/define-class Row () (compile/begin (define __init__ [self cells] (set-attr self cells cells)) (define __getitem__ [self index] (item (compile/attr self cells) index)) (define __setitem__ [self index value] (set-item (compile/attr self cells) index value)))))
null
null
null
null
class-layout-callable-001
layout/define-class
define-class Multiplier []: define __init__ [self factor]: (set-attr self factor factor) define __call__ [self value]: (* self.factor value)
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-define-class.md", "reference/specials/compile-call.md", "reference/specials/compile-class.md" ]
evolving
[ "class", "define-class", "layout", "dunder", "callable", "define-type" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/define-class Multiplier () (compile/begin (define __init__ [self factor] (set-attr self factor factor)) (define __call__ [self value] (* (compile/attr self factor) value)))))
null
null
null
null
class-layout-context-manager-001
layout/define-class
define-class ManagedFlag []: define __init__ [self]: (set-attr self active False) define __enter__ [self]: (set-attr self active True) self define __exit__ [self exc_type exc value]: (set-attr self active False) False
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-define-class.md", "reference/specials/compile-class.md", "reference/specials/compile-set-attr.md" ]
evolving
[ "class", "define-class", "layout", "dunder", "context-manager", "cleanup", "define-type" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/define-class ManagedFlag () (compile/begin (define __init__ [self] (set-attr self active False)) (define __enter__ [self] (set-attr self active True) self) (define __exit__ [self exc_type exc value] (set-attr self active False) False))))
null
null
null
null
class-layout-ordering-001
layout/define-class
define-class Version []: define __init__ [self major minor]: (set-attr self major major) (set-attr self minor minor) define __lt__ [self other]: (< [self.major self.minor] [other.major other.minor]) define __le__ [self other]: (<= [self.major self.minor] [other.major other.minor])
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-define-class.md", "reference/specials/compile-class.md" ]
evolving
[ "class", "define-class", "layout", "dunder", "comparison", "define-type" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/define-class Version () (compile/begin (define __init__ [self major minor] (set-attr self major major) (set-attr self minor minor)) (define __lt__ [self other] (< [(compile/attr self major) (compile/attr self minor)] [(compile/attr other major) (compile/attr other minor)])) (define __le__ [self other] (<= [(co...
null
null
null
null
class-layout-string-conversion-001
layout/define-class
define-class Label []: define __init__ [self text]: (set-attr self text text) define __str__ [self]: self.text define __repr__ [self]: (#str "Label(" (repr self.text) ")")
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-define-class.md", "reference/specials/compile-class.md", "reference/specials/compile-attr.md" ]
evolving
[ "class", "define-class", "layout", "dunder", "string", "define-type" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/define-class Label () (compile/begin (define __init__ [self text] (set-attr self text text)) (define __str__ [self] (compile/attr self text)) (define __repr__ [self] (#str "Label(" (repr (compile/attr self text)) ")")))))
null
null
null
null
class-layout-dataclass-decorator-001
layout/decorate
import-from dataclasses dataclass @dataclass define-class Point3 []: define x :: float 0.0 define y :: float 0.0 define z :: float 0.0 define __iter__ [self]: (iter [self.x self.y self.z])
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-decorate.md", "reference/macros/compile-define-class.md" ]
evolving
[ "class", "define-class", "layout", "decorator", "dataclass", "decorate" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/begin (import-from dataclasses dataclass) (compile/decorate (dataclass) (compile/define-class Point3 () (compile/begin (define x :: float 0.0) (define y :: float 0.0) (define z :: float 0.0) (define __iter__ [self] (iter ((compile/attr self x) (compile/attr self y) (compile/attr self z)))))))))
null
null
null
null
class-layout-dataclass-options-001
layout/decorate
import-from dataclasses dataclass @(dataclass frozen: True order: True) define-class Span []: define start :: int 0 define stop :: int 0 define __len__ [self]: (- self.stop self.start)
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-decorate.md", "reference/macros/compile-define-class.md" ]
evolving
[ "class", "define-class", "layout", "decorator", "dataclass", "decorate" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/begin (import-from dataclasses dataclass) (compile/decorate ((dataclass frozen: True order: True)) (compile/define-class Span () (compile/begin (define start :: int 0) (define stop :: int 0) (define __len__ [self] (- (compile/attr self stop) (compile/attr self start))))))))
null
null
null
null
class-layout-staticmethod-001
layout/decorate
define-class Slug []: @staticmethod define normalize [text]: (.replace (.lower text) " " "-") @staticmethod define valid? [text]: (truth text)
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-decorate.md", "reference/macros/compile-define-class.md" ]
evolving
[ "class", "define-class", "layout", "decorator", "staticmethod", "decorate" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/define-class Slug () (compile/begin (compile/decorate (staticmethod) (define normalize [text] (.replace (.lower text) " " "-"))) (compile/decorate (staticmethod) (define valid? [text] (truth text))))))
null
null
null
null
class-layout-classmethod-001
layout/decorate
define-class Color []: define __init__ [self red green blue]: (set-attr self red red) (set-attr self green green) (set-attr self blue blue) @classmethod define from_hex [cls text]: (cls (parse-int (slice text 1 3) 16) (parse-int (slice text 3 5) 16) (parse-int (slice text 5 7) 16))
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-decorate.md", "reference/macros/compile-define-class.md", "reference/specials/compile-call.md" ]
evolving
[ "class", "define-class", "layout", "decorator", "classmethod", "decorate" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/define-class Color () (compile/begin (define __init__ [self red green blue] (set-attr self red red) (set-attr self green green) (set-attr self blue blue)) (compile/decorate (classmethod) (define from_hex [cls text] (cls (parse-int (slice text 1 3) 16) (parse-int (slice text 3 5) 16) (parse-int (slice text 5 7)...
null
null
null
null
class-layout-property-decorator-001
layout/decorate
define-class Rectangle []: define __init__ [self width height]: (set-attr self width width) (set-attr self height height) @property define area [self]: (* self.width self.height)
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-decorate.md", "reference/macros/compile-define-class.md" ]
evolving
[ "class", "define-class", "layout", "decorator", "property", "decorate" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/define-class Rectangle () (compile/begin (define __init__ [self width height] (set-attr self width width) (set-attr self height height)) (compile/decorate (property) (define area [self] (* (compile/attr self width) (compile/attr self height)))))))
null
null
null
null
class-layout-multiple-method-decorators-001
layout/decorate
define-class Parser []: @classmethod @trace-factory define build [cls grammar]: (cls grammar) @staticmethod @memoize define tokenize [source]: (split source)
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-decorate.md", "reference/macros/compile-define-class.md" ]
evolving
[ "class", "define-class", "layout", "decorator", "classmethod", "staticmethod", "decorate" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/define-class Parser () (compile/begin (compile/decorate (classmethod trace-factory) (define build [cls grammar] (cls grammar))) (compile/decorate (staticmethod memoize) (define tokenize [source] (split source))))))
null
null
null
null
class-layout-inheritance-super-001
layout/define-class
define-class BaseRecord []: define __init__ [self id]: (set-attr self id id) define-class AuditRecord (BaseRecord): define __init__ [self id actor]: (.__init__ (super) id) (set-attr self actor actor) define __repr__ [self]: (#str "AuditRecord(" self.id ", " self.actor ")")
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-super.md", "reference/macros/compile-define-class.md", "reference/specials/compile-class.md" ]
evolving
[ "class", "define-class", "layout", "inheritance", "dunder", "super", "define-type" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/begin (compile/define-class BaseRecord () (compile/begin (define __init__ [self id] (set-attr self id id)))) (compile/define-class AuditRecord (BaseRecord) (compile/begin (define __init__ [self id actor] (.__init__ (super) id) (set-attr self actor actor)) (define __repr__ [self] (#str "AuditRecord(" (compile/a...
null
null
null
null
class-layout-match-args-001
layout/define-class
define-class Event []: define __match_args__ ["kind" "payload"] define __init__ [self kind payload]: (set-attr self kind kind) (set-attr self payload payload) define __repr__ [self]: (#str "Event(" (repr self.kind) ", " (repr self.payload) ")")
[ "reference/layouts/layout-define-class.md", "reference/macros/compile-define-class.md", "reference/specials/compile-class.md" ]
evolving
[ "class", "define-class", "layout", "dunder", "pattern-matching", "define-type" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/define-class Event () (compile/begin (define __match_args__ ("kind" "payload")) (define __init__ [self kind payload] (set-attr self kind kind) (set-attr self payload payload)) (define __repr__ [self] (#str "Event(" (repr (compile/attr self kind)) ", " (repr (compile/attr self payload)) ")"))))
null
null
null
null
class-define-dataclass-field-001
macro/compile/define-dataclass
(begin (define-dataclass Point [] (define x :: int 0) (define y :: int 0)) (define p (Point 3 5)) p.x)
[ "reference/macros/compile-define-dataclass.md", "reference/macros/compile-define-class.md" ]
evolving
[ "class", "define-dataclass", "dataclass", "define-type" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
3
null
null
class-define-dataclass-predicate-true-001
macro/compile/define-dataclass
(begin (define-dataclass Point [] (define x :: int 0) (define y :: int 0)) (Point? (Point 1 2)))
[ "reference/macros/compile-define-dataclass.md" ]
evolving
[ "class", "define-dataclass", "dataclass", "predicate", "define-type" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
true
null
null
class-define-dataclass-predicate-false-001
macro/compile/define-dataclass
(begin (define-dataclass Point [] (define x :: int 0) (define y :: int 0)) (Point? 42))
[ "reference/macros/compile-define-dataclass.md" ]
evolving
[ "class", "define-dataclass", "dataclass", "predicate", "define-type" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
false
null
null
class-property-getter-eval-001
special/compile/decorate
(begin (define-class Rectangle [] (define __init__ [self w h] (set-attr self w w) (set-attr self h h)) (compile/decorate (property) (define area [self] (* self.w self.h)))) (define r (Rectangle 3 4)) r.area)
[ "reference/macros/compile-decorate.md", "reference/macros/compile-define-class.md" ]
evolving
[ "class", "property", "decorator", "define-class", "decorate" ]
https://koskari.dev/corpus/schema.json
652598c
(begin (define-class Rectangle [] (define __init__ [self w h] (set-attr self w w) (set-attr self h h)) (compile/decorate (property) (define area [self] (* (compile/attr self w) (compile/attr self h))))) (define r (Rectangle 3 4)) (compile/attr r area))
(begin (define-class Rectangle [] (define __init__ [self w h] (set-attr self w w) (set-attr self h h)) (compile/decorate (property) (define area [self] (* (compile/attr self w) (compile/attr self h))))) (define r (Rectangle 3 4)) (compile/attr r area))
12
null
null
class-property-setter-roundtrip-001
special/compile/decorate
(begin (define-class Celsius [] (define __init__ [self t] (set-attr self _t t)) (compile/decorate (property) (define temp [self] self._t)) (compile/decorate ((compile/attr temp setter)) (define temp [self value] (set-attr self _t value)))) (define c (Celsius 20)) (set! c.temp 30) c.temp)
[ "reference/macros/compile-decorate.md", "reference/macros/compile-define-class.md" ]
evolving
[ "class", "property", "decorator", "setter", "define-class", "decorate" ]
https://koskari.dev/corpus/schema.json
652598c
(begin (define-class Celsius [] (define __init__ [self t] (set-attr self _t t)) (compile/decorate (property) (define temp [self] (compile/attr self _t))) (compile/decorate ((compile/attr temp setter)) (define temp [self value] (set-attr self _t value)))) (define c (Celsius 20)) (set! (compile/attr c temp) 30) (compile/...
(begin (define-class Celsius [] (define __init__ [self t] (set-attr self _t t)) (compile/decorate (property) (define temp [self] (compile/attr self _t))) (compile/decorate ((compile/attr temp setter)) (define temp [self value] (set-attr self _t value)))) (define c (Celsius 20)) (set! (compile/attr c temp) 30) (compile/...
30
null
null
conditional-layout-if-mixed-inline-else-001
layout/if
if (< n 1) a else: b
[ "reference/layouts/layout-if.md", "reference/concepts/layout-and-s-expressions.md" ]
evolving
[ "conditional", "if", "surface:line", "surface:block", "invalid", "surprising" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/begin (if (< n 1) a) (else b))
null
null
null
surprising layout: line-mode if completes as (if (< n 1) a); else: is not an if peer — reads as (else (compile/begin b)), a call to unbound else, not conditional fallthrough; no LayoutError, runtime error if else is undefined
conditional-layout-if-mixed-inline-elif-001
layout/if
if (< n 1) a elif (== n 1): b
[ "reference/layouts/layout-if.md", "reference/concepts/layout-and-s-expressions.md" ]
evolving
[ "conditional", "if", "elif", "surface:line", "surface:block", "invalid", "surprising", "branch", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/begin (if (< n 1) a) (elif (== n 1) b))
null
null
null
surprising layout: line-mode if completes first; elif: is not an if peer — reads as (elif (== n 1) (compile/begin b)), a call to unbound elif; no LayoutError, runtime error if elif is undefined
conditional-layout-if-no-condition-001
layout/if
if: 1
[ "reference/layouts/layout-if.md" ]
evolving
[ "conditional", "if", "surface:block", "invalid", "branch", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
LayoutError
null
conditional-layout-if-multiple-conditions-001
layout/if
if x y: 1
[ "reference/layouts/layout-if.md" ]
evolving
[ "conditional", "if", "surface:block", "invalid", "branch", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
LayoutError
null
conditional-layout-if-elif-after-else-001
layout/if
if False: 1 else: 2 elif True: 3
[ "reference/layouts/layout-if.md" ]
evolving
[ "conditional", "if", "elif", "surface:block", "invalid", "branch", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
LayoutError
null
conditional-layout-if-elif-no-condition-001
layout/if
if False: 1 elif: 2
[ "reference/layouts/layout-if.md" ]
evolving
[ "conditional", "if", "elif", "surface:block", "invalid", "branch", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
LayoutError
null
conditional-layout-if-elif-multiple-conditions-001
layout/if
if False: 1 elif x y: 2
[ "reference/layouts/layout-if.md" ]
evolving
[ "conditional", "if", "elif", "surface:block", "invalid", "branch", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
LayoutError
null
conditional-layout-if-multiple-else-001
layout/if
if False: 1 else: 2 else: 3
[ "reference/layouts/layout-if.md" ]
evolving
[ "conditional", "if", "surface:block", "invalid", "branch", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
LayoutError
null
conditional-layout-if-else-with-args-001
layout/if
if False: 1 else x: 2
[ "reference/layouts/layout-if.md" ]
evolving
[ "conditional", "if", "surface:block", "invalid", "branch", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
LayoutError
null
conditional-layout-if-invalid-peer-001
layout/if
if False: 1 then: 2
[ "reference/layouts/layout-if.md", "reference/concepts/layout-and-s-expressions.md" ]
evolving
[ "conditional", "if", "surface:block", "invalid", "surprising", "branch", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/begin (compile/cond (False 1)) (then 2))
null
null
null
surprising layout: then: is not an if peer (only elif and else are collected); reads as separate (then (compile/begin 2)) call to unbound then — not LayoutError invalid peer for if block
conditional-layout-switch-with-peers-001
layout/switch
switch x: case [1]: "one" else: "other"
[ "reference/layouts/layout-switch.md", "reference/concepts/layout-and-s-expressions.md" ]
evolving
[ "conditional", "switch", "surface:block", "invalid", "surprising", "branch", "multi-way", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/begin (compile/switch x ([1] "one")) (else "other"))
null
null
null
surprising layout: else: at switch indent is not a switch peer or inner clause; switch reads without else arm, then else: is separate (else (compile/begin "other")) call to unbound else; no LayoutError — put else: inside switch body
conditional-layout-switch-no-value-001
layout/switch
switch: case [1]: "one"
[ "reference/layouts/layout-switch.md" ]
evolving
[ "conditional", "switch", "surface:block", "invalid", "branch", "multi-way", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
LayoutError
null
conditional-layout-switch-multiple-values-001
layout/switch
switch x y: case [1]: "one"
[ "reference/layouts/layout-switch.md" ]
evolving
[ "conditional", "switch", "surface:block", "invalid", "branch", "multi-way", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
LayoutError
null
conditional-layout-switch-case-after-else-001
layout/switch
switch x: else: "other" case [1]: "one"
[ "reference/layouts/layout-switch.md" ]
evolving
[ "conditional", "switch", "surface:block", "invalid", "branch", "multi-way", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
LayoutError
null
conditional-layout-switch-multiple-else-001
layout/switch
switch x: else: "a" else: "b"
[ "reference/layouts/layout-switch.md" ]
evolving
[ "conditional", "switch", "surface:block", "invalid", "branch", "multi-way", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
LayoutError
null
conditional-layout-switch-invalid-body-001
layout/switch
switch x: (print "oops")
[ "reference/layouts/layout-switch.md" ]
evolving
[ "conditional", "switch", "surface:block", "invalid", "branch", "multi-way", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
LayoutError
null
conditionals-block-colon-in-sexpr-invalid-001
reader/layout
(unless (None? x): (handle x))
[ "reference/grammar.md", "reference/concepts/layout-and-s-expressions.md" ]
evolving
[ "conditionals", "reader", "layout", "colon", "invalid", "surprising", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
(unless (None? x) : (handle x))
null
null
null
agent mistake: the block-opening colon is layout-only and must be followed by a newline. Inside parentheses it is read as a bare symbol `:`, which here takes unless's then-slot and shoves (handle x) into the else position. In s-expr, drop the colon. Correct form: (unless (None? x) (handle x)). Use the colon only in lay...
conditional-cond-empty-001
special/compile/cond
(cond)
[ "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "cond", "control-flow" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
null
null
conditional-cond-single-true-001
special/compile/cond
(cond [True 100])
[ "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "cond", "branch", "multi-way" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
100
null
null
conditional-cond-else-only-001
special/compile/cond
(cond [else: 100])
[ "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "cond", "branch", "multi-way" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
100
null
null
conditional-cond-first-match-001
special/compile/cond
(cond [False 100] [True 101] [else: 102])
[ "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "cond", "branch", "multi-way" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
101
null
null
conditional-cond-else-fallthrough-001
special/compile/cond
(cond [False 100] [False 101] [else: 102])
[ "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "cond", "branch", "multi-way" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
102
null
null
conditional-cond-falsy-clause-001
special/compile/cond
(call add (cond [False 100] [nil 101] [else: 102]) 100)
[ "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "cond", "branch", "multi-way" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
202
null
null
conditional-cond-nested-001
special/compile/cond
(cond [False 100] [False 101] [else: (cond [False 102] [else: 103])])
[ "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "cond", "branch", "multi-way" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
103
null
null
conditional-switch-no-clauses-001
special/compile/switch
(switch 5)
[ "reference/specials/compile-switch.md" ]
evolving
[ "conditional", "switch", "branch", "multi-way" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
null
null
conditional-switch-else-only-001
special/compile/switch
(switch 5 [else: 100])
[ "reference/specials/compile-switch.md" ]
evolving
[ "conditional", "switch", "branch", "multi-way" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
100
null
null
conditional-switch-first-match-001
special/compile/switch
(switch 5 [[1] "one"] [[2] "two"] [[5] "five"] [else: "meh"])
[ "reference/specials/compile-switch.md" ]
evolving
[ "conditional", "switch", "branch", "multi-way" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
"five"
null
null
conditional-switch-else-fallthrough-001
special/compile/switch
(switch 5 [[1] "one"] [[2] "two"] [else: "meh"])
[ "reference/specials/compile-switch.md" ]
evolving
[ "conditional", "switch", "branch", "multi-way" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
"meh"
null
null
conditional-switch-no-match-001
special/compile/switch
(switch 5 [[1] "one"] [[2] "two"])
[ "reference/specials/compile-switch.md" ]
evolving
[ "conditional", "switch", "branch", "multi-way" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
null
null
conditional-and-no-args-001
special/compile/and
(and)
[ "reference/specials/compile-and.md" ]
evolving
[ "conditional", "and", "control-flow", "short-circuit" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
true
null
null
conditional-and-single-truthy-001
special/compile/and
(and 42)
[ "reference/specials/compile-and.md" ]
evolving
[ "conditional", "and", "short-circuit" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
42
null
null
conditional-and-single-falsy-001
special/compile/and
(and None)
[ "reference/specials/compile-and.md" ]
evolving
[ "conditional", "and", "short-circuit" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
null
null
conditional-and-all-truthy-001
special/compile/and
(and 1 2 3)
[ "reference/specials/compile-and.md" ]
evolving
[ "conditional", "and", "short-circuit" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
3
null
null
conditional-and-short-circuit-001
special/compile/and
(and 1 None 3)
[ "reference/specials/compile-and.md" ]
evolving
[ "conditional", "and", "short-circuit" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
null
null
conditional-and-first-falsy-001
special/compile/and
(and False 99)
[ "reference/specials/compile-and.md" ]
evolving
[ "conditional", "and", "short-circuit" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
false
null
null
conditional-or-no-args-001
special/compile/or
(or)
[ "reference/specials/compile-or.md" ]
evolving
[ "conditional", "or", "control-flow", "short-circuit" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
false
null
null
conditional-or-first-truthy-001
special/compile/or
(or None 99 0)
[ "reference/specials/compile-or.md" ]
evolving
[ "conditional", "or", "short-circuit" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
99
null
null
conditional-or-single-falsy-001
special/compile/or
(or None)
[ "reference/specials/compile-or.md" ]
evolving
[ "conditional", "or", "short-circuit" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
null
null
conditional-or-all-falsy-001
special/compile/or
(or None False 0)
[ "reference/specials/compile-or.md" ]
evolving
[ "conditional", "or", "short-circuit" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
0
null
null
conditional-or-first-truthy-value-001
special/compile/or
(or False 42)
[ "reference/specials/compile-or.md" ]
evolving
[ "conditional", "or", "short-circuit" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
42
null
null
conditional-when-true-001
macro/compile/when
(when True 42)
[ "reference/macros/compile-when.md" ]
evolving
[ "conditional", "macro", "when", "surface:sexpr", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(when True 42)
null
42
null
null
conditional-when-false-001
macro/compile/when
(when False 42)
[ "reference/macros/compile-when.md" ]
evolving
[ "conditional", "macro", "when", "surface:sexpr", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(when False 42)
null
null
null
null
conditional-unless-false-001
macro/compile/unless
(unless False 42)
[ "reference/macros/compile-unless.md" ]
evolving
[ "conditional", "macro", "unless", "surface:sexpr", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(unless False 42)
null
42
null
null
conditional-unless-true-001
macro/compile/unless
(unless True 42)
[ "reference/macros/compile-unless.md" ]
evolving
[ "conditional", "macro", "unless", "surface:sexpr", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(unless True 42)
null
null
null
null
conditional-q-ternary-true-001
macro/compile/?
(? True 1 2)
[ "reference/macros/compile-q.md" ]
evolving
[ "conditional", "macro", "?", "predicate" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
1
null
null
conditional-q-ternary-false-001
macro/compile/?
(? False 1 2)
[ "reference/macros/compile-q.md" ]
evolving
[ "conditional", "macro", "?", "predicate" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
2
null
null
conditional-q-binary-false-001
macro/compile/?
(? False 1)
[ "reference/macros/compile-q.md" ]
evolving
[ "conditional", "macro", "?", "predicate" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
false
null
null
conditional-q-unary-truth-001
macro/compile/?
(? 42)
[ "reference/macros/compile-q.md", "reference/specials/object-operators/index.md" ]
evolving
[ "conditional", "macro", "?", "predicate" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
true
null
null
conditional-bool-truthy-001
macro/compile/bool
(bool 42)
[ "reference/macros/compile-bool.md" ]
evolving
[ "conditional", "macro", "bool" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
true
null
null
conditional-bool-falsy-001
macro/compile/bool
(bool None)
[ "reference/macros/compile-bool.md" ]
evolving
[ "conditional", "macro", "bool" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
false
null
null
conditional-layout-if-only-true-001
layout/if
if True: 1
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/layouts/layout-if.md", "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "if", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/cond (True 1))
null
1
null
null
conditional-layout-if-only-false-001
layout/if
if False: 1
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/layouts/layout-if.md", "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "if", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/cond (False 1))
null
null
null
null
conditional-layout-if-else-true-001
layout/if
if True: 1 else: 2
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/layouts/layout-if.md", "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "if", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/cond (True 1) (else: 2))
null
1
null
null
conditional-layout-if-else-false-001
layout/if
if False: 1 else: 2
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/layouts/layout-if.md", "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "if", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/cond (False 1) (else: 2))
null
2
null
null
conditional-layout-if-elif-first-001
layout/if
if False: 1 elif True: 2
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/layouts/layout-if.md", "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "if", "elif", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/cond (False 1) (True 2))
null
2
null
null
conditional-layout-if-elif-fallthrough-001
layout/if
if False: 1 elif False: 2
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/layouts/layout-if.md", "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "if", "elif", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/cond (False 1) (False 2))
null
null
null
null
conditional-layout-if-elif-first-branch-001
layout/if
if True: 1 elif False: 2
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/layouts/layout-if.md", "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "if", "elif", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/cond (True 1) (False 2))
null
1
null
null
conditional-layout-if-elif-else-first-001
layout/if
if True: 1 elif False: 2 else: 3
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/layouts/layout-if.md", "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "if", "elif", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/cond (True 1) (False 2) (else: 3))
null
1
null
null
conditional-layout-if-elif-else-elif-001
layout/if
if False: 1 elif True: 2 else: 3
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/layouts/layout-if.md", "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "if", "elif", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/cond (False 1) (True 2) (else: 3))
null
2
null
null
conditional-layout-if-elif-else-else-001
layout/if
if False: 1 elif False: 2 else: 3
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/layouts/layout-if.md", "reference/specials/compile-cond.md" ]
evolving
[ "conditional", "if", "elif", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(compile/cond (False 1) (False 2) (else: 3))
null
3
null
null
conditional-layout-when-true-001
macro/compile/when
when True: 42
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/macros/compile-when.md" ]
evolving
[ "conditional", "macro", "when", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(when True 42)
null
42
null
null
conditional-layout-when-false-001
macro/compile/when
when False: 42
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/macros/compile-when.md" ]
evolving
[ "conditional", "macro", "when", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(when False 42)
null
null
null
null
conditional-layout-unless-false-001
macro/compile/unless
unless False: 42
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/macros/compile-unless.md" ]
evolving
[ "conditional", "macro", "unless", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(unless False 42)
null
42
null
null
conditional-layout-unless-true-001
macro/compile/unless
unless True: 42
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/macros/compile-unless.md" ]
evolving
[ "conditional", "macro", "unless", "surface:block", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(unless True 42)
null
null
null
null
conditional-line-if-true-001
macro/compile/if
if True 1 2
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/macros/compile-if.md" ]
evolving
[ "conditional", "macro", "if", "surface:line", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(if True 1 2)
null
1
null
null
conditional-line-if-false-001
macro/compile/if
if False 1 2
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/macros/compile-if.md" ]
evolving
[ "conditional", "macro", "if", "surface:line", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(if False 1 2)
null
2
null
null
conditional-line-when-true-001
macro/compile/when
when True 42
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/macros/compile-when.md" ]
evolving
[ "conditional", "macro", "when", "surface:line", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(when True 42)
null
42
null
null
conditional-line-when-false-001
macro/compile/when
when False 42
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/macros/compile-when.md" ]
evolving
[ "conditional", "macro", "when", "surface:line", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(when False 42)
null
null
null
null
conditional-line-unless-false-001
macro/compile/unless
unless False 42
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/macros/compile-unless.md" ]
evolving
[ "conditional", "macro", "unless", "surface:line", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(unless False 42)
null
42
null
null
conditional-line-unless-true-001
macro/compile/unless
unless True 42
[ "reference/concepts/layout-and-s-expressions.md", "reference/reader-layout.md", "reference/macros/compile-unless.md" ]
evolving
[ "conditional", "macro", "unless", "surface:line", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(unless True 42)
null
null
null
null
conditional-sexpr-if-true-001
macro/compile/if
(if True 1 2)
[ "reference/concepts/layout-and-s-expressions.md", "reference/macros/compile-if.md" ]
evolving
[ "conditional", "macro", "if", "surface:sexpr", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(if True 1 2)
null
1
null
null
conditional-sexpr-if-false-001
macro/compile/if
(if False 1 2)
[ "reference/concepts/layout-and-s-expressions.md", "reference/macros/compile-if.md" ]
evolving
[ "conditional", "macro", "if", "surface:sexpr", "branch" ]
https://koskari.dev/corpus/schema.json
652598c
(if False 1 2)
null
2
null
null
conditional-while-false-001
special/compile/while
(while False 42)
[ "reference/specials/compile-while.md" ]
evolving
[ "conditional", "while", "loop" ]
https://koskari.dev/corpus/schema.json
652598c
(while False 42)
(while False 42)
null
null
null
conditional-while-break-002
special/compile/while
(while True (break 99))
[ "reference/specials/compile-while.md" ]
evolving
[ "conditional", "while", "early-exit", "loop" ]
https://koskari.dev/corpus/schema.json
652598c
(while True (break 99))
(while True (break 99))
99
null
null
conditional-while-else-003
special/compile/while
(while (> z 0) (setq z (- z 1)) (else: "done"))
[ "reference/specials/compile-while.md" ]
evolving
[ "conditional", "while", "loop" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
"done"
null
null
conditional-bool-zero-003
macro/compile/bool
(bool 0)
[ "reference/macros/compile-bool.md" ]
evolving
[ "conditional", "macro", "bool" ]
https://koskari.dev/corpus/schema.json
652598c
(bool 0)
(compile/truth 0)
false
null
null
function-gensym-thunk-gap-error-001
special/compile/gensym-thunk
(gensym-thunk (+ %2 1))
[ "reference/specials/compile-gensym-partial.md" ]
evolving
[ "function", "gensym-thunk", "error", "invalid" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
SpecialError: placeholders must be contiguous
null
function-gensym-thunk-nested-001
special/compile/gensym-thunk
(((gensym-thunk (gensym-thunk (+ %1 1))) 7))
[ "reference/specials/compile-gensym-partial.md" ]
evolving
[ "function", "gensym-thunk", "invalid", "metaprogramming", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
null
null
null
null
nested gensym-thunk body forms are siblings, not call targets; outer (gensym-thunk (gensym-thunk (+ %1 1))) is zero-arg — passing 7 in the same expression is a TypeError (too many positional arguments). Build (gensym-thunk (gensym-thunk (+ %1 1))), call outer with no args, then call inner with 7 in separate steps
function-let-flat-binding-invalid-001
special/compile/let
(let [x 1] x)
[ "reference/specials/compile-let.md" ]
evolving
[ "function", "let", "invalid", "local-binding", "pitfall" ]
https://koskari.dev/corpus/schema.json
652598c
(let (x 1) x)
null
null
SyntaxMatchError: no matching syntax rule
null
End of preview. Expand in Data Studio

Koskari language corpus

Verified Koskari language examples exported from the Koskari conformance corpus. Each row traces to a corpus record with machine-checked expectations at one or more language phases (read, expand, eval, error, invalid).

Source repository: github.com/obriencj/koskari

Configurations

corpus (default)

Every corpus record. One row per record regardless of which verify stages are present. Missing stages are null.

Column Description
corpus_id Unique corpus record identifier
feature Feature path (e.g. special/compile/cond, layout/if)
source Koskari source text
read Expected reader output from verify.read
expand Expected macro expansion from verify.expand
eval Expected eval result from verify.eval
error Expected pipeline error from verify.error
invalid Prose explanation from verify.invalid
references Links to user documentation pages under docs/
stability Record stability label (stable, evolving, experimental)
tags Maintainer tags (not copied from training-only metadata)
schema_version Corpus schema identifier at export time
git_ref Short git commit at export time

docs

User documentation pages (Markdown) from the source repository's docs/reference/ and docs/start/ trees. One row per page. The path column matches the strings in the corpus config's references column verbatim, so a record's references resolve directly to their documentation content.

Column Description
path Docs-relative page path (e.g. reference/specials/compile-define.md)
title Page title (first Markdown heading)
summary First paragraph, plain text
content Full raw Markdown of the page
section Parent directory (e.g. reference/specials)
kind Always doc
schema_version Corpus schema identifier at export time
git_ref Short git commit at export time

Whole-file cells: each page is one content cell. The Hugging Face Dataset Viewer caps cell size in API responses, so a very large page would be truncated. Pages are small today (a few KiB); chunk-by-heading is a deferred mitigation should pages grow. See tools/corpus/views/docs.py.

programs

Example Koskari programs (whole .ki files and their READMEs) from the source repository's examples/ tree, excluding build artifacts. These give composition-level context — full programs rather than single-construct snippets.

These rows are illustrative and NOT verified. Unlike the corpus config, they carry no machine-checked read/expand/eval expectations; they are working example source, not conformance assertions.

Column Description
path Repo-relative file path (e.g. examples/life/koslife/life.ki)
title File stem, or README heading
summary Module docstring or leading comment, plain text
content Full raw source of the file
section Top-level example group (e.g. examples/life)
kind Always example
schema_version Corpus schema identifier at export time
git_ref Short git commit at export time

Verify stages

Each corpus record asserts behaviour at language boundaries:

  • read — reader and layout output
  • expand — macro expansion on the outer form
  • eval — runtime result (including @-marked complex encodings in source)
  • error — expected pipeline failure
  • invalid — documented illegal source (may coexist with read expectations)

Only stages present in the source corpus record appear as non-null columns in the corpus config.

Provenance

Every row includes corpus_id, schema_version, and git_ref so downstream consumers can join back to the authoritative YAML record and the export revision.

License

GNU General Public License v3. See the Koskari repository for full terms.

Downloads last month
166