Didn’t find much free time until this weekend. I’m not sure how closely this follows your proposal, but I wanted to convert an existing motion over into a full JSON implementation to discuss.
I used this motion as the base, as it’s pretty simple. Which in turn was translated to:
{
"id": "1",
"name": "Liquidity",
"chapters": [
{
"id": "1",
"name": "FLOT",
"section": [
{
"id": "1",
"name": "Joining FLOT",
"items": [
{
"id": "1",
"content": "@mhps shall be one of the members of the First Liquidity Operations Team (FLOT)."
},
{
"id": "2",
"content": " @mhps will coordinate with other members of FLOT, and members of FSRT if necessary, to defend the peg."
},
{
"id": "3",
"content": "@mhps promises to be a part of FLOT for at least one year and to abide by all shareholder motions governing the use of funds."
}
]
},
{
"id": "2",
"name": "Limitations",
"items": [
{
"id": "1",
"content": "@mhps will be able to respond to any proposal for signing within 24 hours for 280 days a year, and be available on a best effort basis for the rest of the days. "
},
{
"id": "2",
"content ": "@mhps is able to carry out a maximum one signing a week, with its required investigation, discussion and deliberation, and no more than three a month."
},
{
"id": "3",
"content": "FLOT must be informed of exceptions."
},
{
"id": "4",
"content": "Being able to sign a request within 24 hours requires tools whithout which the response time cannot be held in case access to the internet is limited."
}
]
},
{
"id": "3",
"name": "Compensation",
"items": [
{
"id": "1",
"content": "Compensation for @mhps will occur in 90-day cycles, for a total of 4 cycles."
},
{
"id": "2",
"content": "By the end of each cycle, a total of amount of 435 NBT shall be paid to @mhps, conditional on satisfactory performance, which shall be measured in terms of his presence, effort and contribution."
},
{
"id": "2",
"content": "@mhps reserves the right to withdraw from his service if he does not receive the full amount of compensation by the end of any cycle or by personal discretion."
}
]
},
{
"id": "4",
"name": "Operation start",
"items": [
{
"id": "1",
"content": "The service of @mhps and the compensation cycles will commence from the passage of this motion."
}
]
}
]
}
]
}
You can manipulate it pretty easily from here: http://www.jsoneditoronline.org/?id=4f6422b4a6dacd6cfce853940bb73f3d
There was a number of formatting changes I had to make. If i’m understanding the point of this makes it easier to automate presentation and finding specific components of a motion, so those formatting changed were needed. Though the original motion hash can’t be computed from the text when any changes occur. It may be worthwhile including a B64 encoding of the original text for validating the motion hash from this source. Which (with removing the chapter for brevity) would look like:
{
"id": "1",
"name": "Liquidity",
"chapters": [],
"B64": "PG1vdGlvbmhhc2g+PHA+PGNvZGU+PSMjPSMjPSMjPSMjPSMjPSMjIE1vdGlvbiBoYXNoIHN0YXJ0cyB3aXRoIHRoaXMgbGluZSAjIz0jIz0jIz0jIz0jIz0jIz08L2NvZGU+PC9wPjxwPjxtb3Rpb250ZXh0PjxwPkBtaHBzIHNoYWxsIGJlIG9uZSBvZiB0aGUgbWVtYmVycyBvZiB0aGUgRmlyc3QgTGlxdWlkaXR5IE9wZXJhdGlvbnMgVGVhbSAoRkxPVCkuIEBtaHBzIHdpbGwgY29vcmRpbmF0ZSB3aXRoIG90aGVyIG1lbWJlcnMgb2YgRkxPVCwgYW5kIG1lbWJlcnMgb2YgRlNSVCBpZiBuZWNlc3NhcnksIHRvIGRlZmVuZCB0aGUgcGVnLiBAbWhwcyBwcm9taXNlcyB0byBiZSBhIHBhcnQgb2YgRkxPVCBmb3IgYXQgbGVhc3Qgb25lIHllYXIgYW5kIHRvIGFiaWRlIGJ5IGFsbCBzaGFyZWhvbGRlciBtb3Rpb25zIGdvdmVybmluZyB0aGUgdXNlIG9mIGZ1bmRzLiBAbWhwczwvcD48cD53aWxsIGJlIGFibGUgdG8gcmVzcG9uZCB0byBhbnkgcHJvcG9zYWwgZm9yIHNpZ25pbmcgd2l0aGluIDI0IGhvdXJzIGZvciAyODAgZGF5cyBhIHllYXIsIGFuZCBiZSBhdmFpbGFibGUgb24gYSBiZXN0IGVmZm9ydCBiYXNpcyBmb3IgdGhlIHJlc3Qgb2YgdGhlIGRheXMuIEBtaHBzIGlzIGFibGUgdG8gY2Fycnkgb3V0IGEgbWF4aW11bSBvbmUgc2lnbmluZyBhIHdlZWssIHdpdGggaXRzIHJlcXVpcmVkIGludmVzdGlnYXRpb24sIGRpc2N1c3Npb24gYW5kIGRlbGliZXJhdGlvbiwgYW5kIG5vIG1vcmUgdGhhbiB0a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jPSMjPSMjPSMjPSMjPSMjIE1vdGlvbiBoYXNoIGVuZHMgd2l0aCB0aGlzIGxpbmUgIyM9IyM9IyM9IyM9IyM9IyM9PC9jb2RlPjwvcD48L21vdGlvbmhhc2g+"
}
That way the original text used and voted on can be reproduced, since it cannot be reproduced from the codex format.
Is this in the direction you envisioned?