conflag 0.1.1

A simple and powreful configuration language, extending JSON with declarative and functional language features.
Documentation
{
    a: {
        b: 1,
        c: {cx: 2, cy: 3},
        d: {dx: 4, dy: 5, do: {doa: "blah"}},
    },
    patch: &{c: &{cy: 6, cz: 7}, d: &{do: {dob: "haha"}}},
    a_: a + patch,
    eval: [
        a_.b,
        a_.c.cx,
        a_.c.cy,
        a_.c.cz,
        a_.d.dx,
        a_.d.dy,
        a_.d.do,
    ],

    base_experiment: {
        model: {
            parameters: {
                layers: 6,
            },
            training: {
                epochs: 10,
            }
        },
        data: {
            paths: {
                train: "train.parquet",
                test: "test.parquet",
            }
        }
    },

    base_config: {
        experiments: [
            base_experiment,
            base_experiment + {model: &{parameters: &{layers: 4}}},
        ],
    },

    downsampled: (path) => path + ".downsampled",

    configs: {
        eval: base_config,
        dev: base_config + {
            experiments: &&{
                model: &{training: &{epochs: 1}},
                data: &{paths: &&downsampled},
            },
        }
    },

    // Is this a comment?
    dsp: &&downsampled,
}