Governance Operations
Review supplied policy revision conflicts
Apply supplied authority ranks and effective intervals while exposing tied text conflicts and unknown selection facts. Supplied facts only; returns a review packet with no external effects.
Experimental native example · local preview · revision 1
WORKFLOW PREVIEW
See how it works
Use + and − to zoom, F to fit. Press Enter on a node to inspect it.
Private preview. These tested drafts are available for inspection. Adding them to a Vora workspace is still being tested.
What you need
- Authorized supplied facts matching the closed contract.
- Explicit scope, version, authority and completeness facts reviewed by an operator.
Follow the workflow step by step
Supplied agency data
Receive the explicitly supplied manual input packet.
Review supplied policy revision conflicts
Apply supplied authority ranks and effective intervals while exposing tied text conflicts and unknown selection facts. Supplied facts only; returns a review packet with no external effects.
Setup and review
- Review the contract and evidence bounds.
- Run a synthetic supplied-data case.
- Inspect every conflict, omission and unknown before proposing downstream action.
Inspect every node
Expand a node to inspect its complete settings. Review the runtime and adoption evidence before installing it.
Supplied agency data · wfManualTrigger
{
"label": "Supplied agency data"
}Review supplied policy revision conflicts · code
{
"code": "\nfunction fail(reason){throw new Error('input: '+reason);}\nfunction check(schema,value,where){\n if(value===null){if(schema.type==='null'||Array.isArray(schema.type)&&schema.type.includes('null'))return;fail(where+' wrong_type');}\n const type=Array.isArray(schema.type)?schema.type[0]:schema.type;\n if(type==='object'){\n if(!value||typeof value!=='object'||Array.isArray(value))fail(where+' wrong_type');\n for(const name of Object.keys(value))if(!Object.hasOwn(schema.properties,name))fail(where+' unknown_field');\n for(const name of schema.required)if(!Object.hasOwn(value,name))fail(where+' missing_field');\n for(const [name,shape]of Object.entries(schema.properties))check(shape,value[name],where+'.'+name);\n }else if(type==='array'){\n if(!Array.isArray(value)||value.length>schema.maxItems)fail(where+' array_bound');\n for(const item of value)check(schema.items,item,where+'[]');\n }else if(type==='string'){if(typeof value!=='string'||value.length>schema.maxLength)fail(where+' string_bound');}\n else if(type==='integer'){if(!Number.isSafeInteger(value)||value<schema.minimum||value>schema.maximum)fail(where+' integer_bound');}\n else if(type==='boolean'){if(typeof value!=='boolean')fail(where+' wrong_type');}\n else fail(where+' unsupported_type');\n}\nfunction id(value){if(typeof value!=='string'||!value||value.trim()!==value)fail('noncanonical_identity');return value;}\nfunction unique(values,reason){if(new Set(values).size!==values.length)fail(reason);}\nfunction safeAdd(a,b){if(a>Number.MAX_SAFE_INTEGER-b)fail('unsafe_sum');return a+b;}\nfunction day(value){if(!/^\\d{4}-\\d{2}-\\d{2}$/.test(value))fail('invalid_calendar_day');const ms=Date.parse(value+'T00:00:00Z');if(!Number.isFinite(ms)||new Date(ms).toISOString().slice(0,10)!==value)fail('invalid_calendar_day');return ms;}\nfunction refKey(ref){id(ref.assetId);if(ref.version<1)fail('positive_version_required');return JSON.stringify([ref.assetId,ref.version]);}\nfunction refValue(key){const pair=JSON.parse(key);return {assetId:pair[0],version:pair[1]};}\nfunction sortedRefs(keys){return [...keys].sort().map(refValue);}\n\ncheck({\"type\":\"object\",\"properties\":{\"scopeId\":{\"type\":\"string\",\"maxLength\":128},\"asOfDay\":{\"type\":\"string\",\"maxLength\":10},\"selectionComplete\":{\"type\":[\"boolean\",\"null\"]},\"precedence\":{\"type\":\"string\",\"maxLength\":128},\"revisions\":{\"type\":\"array\",\"items\":{\"type\":\"object\",\"properties\":{\"revisionId\":{\"type\":\"string\",\"maxLength\":128},\"scopeId\":{\"type\":\"string\",\"maxLength\":128},\"authorityRank\":{\"type\":[\"integer\",\"null\"],\"minimum\":0,\"maximum\":9007199254740991},\"approved\":{\"type\":[\"boolean\",\"null\"]},\"effectiveFrom\":{\"type\":\"string\",\"maxLength\":10},\"effectiveUntil\":{\"type\":[\"string\",\"null\"],\"maxLength\":10},\"contentIdentity\":{\"type\":\"string\",\"maxLength\":128}},\"required\":[\"revisionId\",\"scopeId\",\"authorityRank\",\"approved\",\"effectiveFrom\",\"effectiveUntil\",\"contentIdentity\"],\"additionalProperties\":false},\"maxItems\":100}},\"required\":[\"scopeId\",\"asOfDay\",\"selectionComplete\",\"precedence\",\"revisions\"],\"additionalProperties\":false},context.input,\"input\");\nconst result=(function policyRevisionConflicts(x){\n id(x.scopeId);if(x.precedence!=='lower_rank_wins')fail('unsupported_precedence');\n const now=day(x.asOfDay),eligible=[],unknown=[],ignored=[];\n unique(x.revisions.map(r=>id(r.revisionId)),'duplicate_revision_id');\n for(const row of x.revisions){\n if(id(row.scopeId)!==x.scopeId)fail('scope_mismatch');id(row.contentIdentity);\n const start=day(row.effectiveFrom),end=row.effectiveUntil===null?null:day(row.effectiveUntil);\n if(end!==null&&end<=start)fail('invalid_interval');\n if(now<start||end!==null&&now>=end||row.approved===false){ignored.push(row.revisionId);continue;}\n if(row.approved===null||row.authorityRank===null){unknown.push(row.revisionId);continue;}\n eligible.push(row);\n }\n const rank=eligible.length?Math.min(...eligible.map(r=>r.authorityRank)):null;\n const best=eligible.filter(r=>r.authorityRank===rank),conflict=new Set(best.map(r=>r.contentIdentity)).size>1;\n const uncertain=x.selectionComplete!==true||unknown.length>0;\n const status=uncertain?'unknown':!best.length?'none_applicable':conflict?'conflict':'applicable';\n return {status,applicableRevisionIds:status==='applicable'?best.map(r=>r.revisionId).sort():[],conflictingRevisionIds:conflict?best.map(r=>r.revisionId).sort():[],unknownRevisionIds:unknown.sort(),ignoredRevisionIds:ignored.sort(),observedEligibleRevisionIds:eligible.map(r=>r.revisionId).sort(),winningAuthorityRank:uncertain?null:rank,selectionComplete:x.selectionComplete};\n})(context.input);\ncheck({\"type\":\"object\",\"properties\":{\"status\":{\"type\":\"string\",\"maxLength\":128},\"applicableRevisionIds\":{\"type\":\"array\",\"items\":{\"type\":\"string\",\"maxLength\":128},\"maxItems\":100},\"conflictingRevisionIds\":{\"type\":\"array\",\"items\":{\"type\":\"string\",\"maxLength\":128},\"maxItems\":100},\"unknownRevisionIds\":{\"type\":\"array\",\"items\":{\"type\":\"string\",\"maxLength\":128},\"maxItems\":100},\"ignoredRevisionIds\":{\"type\":\"array\",\"items\":{\"type\":\"string\",\"maxLength\":128},\"maxItems\":100},\"observedEligibleRevisionIds\":{\"type\":\"array\",\"items\":{\"type\":\"string\",\"maxLength\":128},\"maxItems\":100},\"winningAuthorityRank\":{\"type\":[\"integer\",\"null\"],\"minimum\":0,\"maximum\":9007199254740991},\"selectionComplete\":{\"type\":[\"boolean\",\"null\"]}},\"required\":[\"status\",\"applicableRevisionIds\",\"conflictingRevisionIds\",\"unknownRevisionIds\",\"ignoredRevisionIds\",\"observedEligibleRevisionIds\",\"winningAuthorityRank\",\"selectionComplete\"],\"additionalProperties\":false},result,\"output\");\nreturn result;",
"label": "Review supplied policy revision conflicts",
"memoryLimit": 16,
"outputVar": "result",
"timeout": 1000
}Input and output contracts
Input
{
"type": "object",
"properties": {
"scopeId": {
"type": "string",
"maxLength": 128
},
"asOfDay": {
"type": "string",
"maxLength": 10
},
"selectionComplete": {
"type": [
"boolean",
"null"
]
},
"precedence": {
"type": "string",
"maxLength": 128
},
"revisions": {
"type": "array",
"items": {
"type": "object",
"properties": {
"revisionId": {
"type": "string",
"maxLength": 128
},
"scopeId": {
"type": "string",
"maxLength": 128
},
"authorityRank": {
"type": [
"integer",
"null"
],
"minimum": 0,
"maximum": 9007199254740991
},
"approved": {
"type": [
"boolean",
"null"
]
},
"effectiveFrom": {
"type": "string",
"maxLength": 10
},
"effectiveUntil": {
"type": [
"string",
"null"
],
"maxLength": 10
},
"contentIdentity": {
"type": "string",
"maxLength": 128
}
},
"required": [
"revisionId",
"scopeId",
"authorityRank",
"approved",
"effectiveFrom",
"effectiveUntil",
"contentIdentity"
],
"additionalProperties": false
},
"maxItems": 100
}
},
"required": [
"scopeId",
"asOfDay",
"selectionComplete",
"precedence",
"revisions"
],
"additionalProperties": false
}Output
{
"type": "object",
"properties": {
"status": {
"type": "string",
"maxLength": 128
},
"applicableRevisionIds": {
"type": "array",
"items": {
"type": "string",
"maxLength": 128
},
"maxItems": 100
},
"conflictingRevisionIds": {
"type": "array",
"items": {
"type": "string",
"maxLength": 128
},
"maxItems": 100
},
"unknownRevisionIds": {
"type": "array",
"items": {
"type": "string",
"maxLength": 128
},
"maxItems": 100
},
"ignoredRevisionIds": {
"type": "array",
"items": {
"type": "string",
"maxLength": 128
},
"maxItems": 100
},
"observedEligibleRevisionIds": {
"type": "array",
"items": {
"type": "string",
"maxLength": 128
},
"maxItems": 100
},
"winningAuthorityRank": {
"type": [
"integer",
"null"
],
"minimum": 0,
"maximum": 9007199254740991
},
"selectionComplete": {
"type": [
"boolean",
"null"
]
}
},
"required": [
"status",
"applicableRevisionIds",
"conflictingRevisionIds",
"unknownRevisionIds",
"ignoredRevisionIds",
"observedEligibleRevisionIds",
"winningAuthorityRank",
"selectionComplete"
],
"additionalProperties": false
}Choose an output for this job
This business workflow also has 15 delivery formats. Compare their inputs, output examples and limits.
Example input and result
These examples use synthetic data.
Input
{
"scopeId": "client-A",
"asOfDay": "2026-10-08",
"selectionComplete": true,
"precedence": "lower_rank_wins",
"revisions": [
{
"revisionId": "p-B",
"scopeId": "client-A",
"authorityRank": 1,
"approved": true,
"effectiveFrom": "2026-10-01",
"effectiveUntil": "2026-11-01",
"contentIdentity": "text-B"
},
{
"revisionId": "p-A",
"scopeId": "client-A",
"authorityRank": 1,
"approved": true,
"effectiveFrom": "2026-10-01",
"effectiveUntil": "2026-11-01",
"contentIdentity": "text-A"
}
]
}Expected result
{
"status": "conflict",
"applicableRevisionIds": [],
"conflictingRevisionIds": [
"p-A",
"p-B"
],
"unknownRevisionIds": [],
"ignoredRevisionIds": [],
"observedEligibleRevisionIds": [
"p-A",
"p-B"
],
"winningAuthorityRank": 1,
"selectionComplete": true
}Success means: Apply supplied authority ranks and effective intervals while exposing tied text conflicts and unknown selection facts. Supplied facts only; returns a review packet with no external effects.
When something goes wrong
- Correct the rejected shape, identity, scope or numeric bound and repeat with supplied facts. Preserve unknown and conflicting facts rather than invent a resolution.
Limits and costs
- Only active approved records with known rank are eligible. Explicit lower_rank_wins precedence; half-open [effectiveFrom,effectiveUntil) UTC calendar dates, nullable indefinite end. Unknown active approval/rank or incomplete/unknown selection means unknown and no selected revision. Known-minimum rank ties with different supplied content identities conflict; same identity returns every tied reference. IDs sort by UTF-16 order. Uploaded/created time has no authority. Supplied scope/identity facts are not independently verified. Pure supplied-data processing; no independent provider, legal, authentication or customer-acceptance verification.
- No paid model calls or metered third-party operations are declared in this pure graph. Vora plan availability, compute and quotas still apply; pricing has not been verified by this batch.