Skip to main content
Glama

arifOS — Constitutional AI Kernel

777 Forge · Execute Gate

arif_forge
Destructive

Execute an action arif_judge has already SEALed — nothing runs without seal_verdict_id and approved_action_hash matching the judged action. Modes: engineer (default; plan and apply — requires manifest), dry_run (preview, no side effects; manifest or query), query (read-only), write (write files), generate (generate code/content), commit (commit prepared work), recall (retrieve past forge artifacts). Irreversible judged actions additionally require ack_irreversible=true. On missing seal or hash mismatch the call returns REFUSED with no change made. Outputs: execution receipt (receipt_id, status, actor_id, timestamp).

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "arif_forge"
  }
}

Input Schema

NameRequiredDescriptionDefault
modeNo'engineer' (default) — plan and apply the work; 'dry_run' — preview what would happen, nothing is applied; 'query' — read-only questions about the workspace; 'write' — write files; 'generate' — generate code or content; 'commit' — commit prepared work; 'recall' — retrieve past forge artifacts.engineer
queryNoThe task in plain language when no manifest is supplied, e.g. 'restart the gateway service'.
plan_idNoPlan id from arif_think's plan mode, when executing an approved plan.
actor_idNoYour agent identity, e.g. 'kimi-code/FI-008' — recorded in the audit log.
manifestNoRequired for engineer (the default mode), write, and generate: the work order (usually JSON or markdown) describing exactly what to build or change — the more specific, the tighter the gate. mode=dry_run accepts the manifest or a plain-language query; mode=query uses query instead.
session_idNoSession id returned by arif_init; scopes this execution to your governed session.
arif_ack_idNoAcknowledgment id from a prior step, for multi-step execution chains.
artifact_idNoId of an existing artifact (from an earlier forge or judge response) that this call operates on.
session_tokenNoSession Continuity Token (SCT) returned by arif_init — proves the session is yours.
vault_entry_idNoId of the permanent-ledger entry linked to this execution, when one already exists.
seal_verdict_idNoThe SEAL verdict id arif_judge returned — without it, nothing is executed.
ack_irreversibleNoSet true to confirm you accept this execution cannot be undone, when the judged action was irreversible.
judge_state_hashNoHash string from the arif_judge SEAL response — proves the verdict has not been tampered with.
approved_action_hashNoHash of the exact action that was judged — execution is refused if what you submit differs from it.
constitutional_chain_idNoId of the evidence chain (observe→think→judge) that led to the SEAL — copy it from the judge response.

Output Schema

NameRequiredDescriptionDefault
metaYes
toolYes
resultYes
statusYes
delta_SNo
reasonsYes
actor_idNo
timestampYes
session_idNo
nine_signalYes
output_policyNo
stage_progressionNo
philosophical_anchorNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • removedInput schema / allOf
      Removed value: -[
      -  {
      -    "if": {
      -      "anyOf": [
      -        {
      -          "not": {
      -            "required": [
      -              "mode"
      -            ]
      -          }
      -        },
      -        {
      -          "properties": {
      -            "mode": {
      -              "enum": [
      -                "engineer",
      -                "write",
      -                "generate"
      -              ]
      -            }
      -          },
      -          "required": [
      -            "mode"
      -          ]
      -        }
      -      ]
      -    },
      -    "then": {
      -      "required": [
      -        "manifest"
      -      ]
      -    }
      -  },
      -  {
      -    "if": {
      -      "properties": {
      -        "mode": {
      -          "enum": [
      -            "dry_run"
      -          ]
      -        }
      -      },
      -      "required": [
      -        "mode"
      -      ]
      -    },
      -    "then": {
      -      "anyOf": [
      -        {
      -          "required": [
      -            "manifest"
      -          ]
      -        },
      -        {
      -          "required": [
      -            "query"
      -          ]
      -        }
      -      ]
      -    }
      -  }
      -]
  2. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "additionalProperties": true,
      +  "properties": {
      +    "actor_id": {
      +      "anyOf": [
      +        {
      +          "type": "string"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "delta_S": {
      +      "anyOf": [
      +        {
      +          "type": "number"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "meta": {
      +      "additionalProperties": true,
      +      "type": "object"
      +    },
      +    "nine_signal": {
      +      "additionalProperties": true,
      +      "properties": {
      +        "delta": {
      +          "properties": {
      +            "en": {
      +              "type": "string"
      +            },
      +            "plane": {
      +              "type": "string"
      +            },
      +            "state": {
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "state",
      +            "en"
      +          ],
      +          "type": "object"
      +        },
      +        "omega": {
      +          "properties": {
      +            "en": {
      +              "type": "string"
      +            },
      +            "plane": {
      +              "type": "string"
      +            },
      +            "state": {
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "state",
      +            "en"
      +          ],
      +          "type": "object"
      +        },
      +        "overall": {
      +          "properties": {
      +            "en": {
      +              "type": "string"
      +            },
      +            "state": {
      +              "type": "string"
      +            }
      +          },
      +          "type": "object"
      +        },
      +        "psi": {
      +          "properties": {
      +            "en": {
      +              "type": "string"
      +            },
      +            "plane": {
      +              "type": "string"
      +            },
      +            "state": {
      +              "type": "string"
      +            }
      +          },
      +          "required": [
      +            "state",
      +            "en"
      +          ],
      +          "type": "object"
      +        }
      +      },
      +      "type": "object"
      +    },
      +    "output_policy": {
      +      "type": "string"
      +    },
      +    "philosophical_anchor": {
      +      "additionalProperties": true,
      +      "type": "object"
      +    },
      +    "reasons": {
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    },
      +    "result": {
      +      "additionalProperties": true,
      +      "properties": {
      +        "artifact_id": {
      +          "anyOf": [
      +            {
      +              "type": "string"
      +            },
      +            {
      +              "type": "null"
      +            }
      +          ]
      +        },
      +        "execution_trace": {
      +          "anyOf": [
      +            {
      +              "items": {
      +                "additionalProperties": true,
      +                "type": "object"
      +              },
      +              "type": "array"
      +            },
      +            {
      +              "type": "null"
      +            }
      +          ]
      +        },
      +        "irreversibility_level": {
      +          "type": "string"
      +        },
      +        "mode": {
      +          "type": "string"
      +        },
      +        "nine_signal": {
      +          "additionalProperties": true,
      +          "type": "object"
      +        },
      +        "reasons": {
      +          "anyOf": [
      +            {
      +              "items": {
      +                "type": "string"
      +              },
      +              "type": "array"
      +            },
      +            {
      +              "type": "null"
      +            }
      +          ]
      +        },
      +        "status": {
      +          "type": "string"
      +        },
      +        "verdict": {
      +          "type": "string"
      +        }
      +      },
      +      "type": "object"
      +    },
      +    "session_id": {
      +      "anyOf": [
      +        {
      +          "type": "string"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "stage_progression": {
      +      "anyOf": [
      +        {
      +          "type": "null"
      +        },
      +        {
      +          "properties": {
      +            "current_stage": {
      +              "type": "string"
      +            },
      +            "next_prompt": {
      +              "anyOf": [
      +                {
      +                  "type": "string"
      +                },
      +                {
      +                  "type": "null"
      +                }
      +              ]
      +            },
      +            "next_stage": {
      +              "anyOf": [
      +                {
      +                  "type": "string"
      +                },
      +                {
      +                  "type": "null"
      +                }
      +              ]
      +            },
      +            "next_tool": {
      +              "anyOf": [
      +                {
      +                  "type": "string"
      +                },
      +                {
      +                  "type": "null"
      +                }
      +              ]
      +            }
      +          },
      +          "type": "object"
      +        }
      +      ]
      +    },
      +    "status": {
      +      "type": "string"
      +    },
      +    "timestamp": {
      +      "type": "string"
      +    },
      +    "tool": {
      +      "const": "arif_forge"
      +    }
      +  },
      +  "required": [
      +    "status",
      +    "tool",
      +    "result",
      +    "meta",
      +    "timestamp",
      +    "nine_signal",
      +    "reasons"
      +  ],
      +  "type": "object"
      +}
  3. Changed1 schema field changed
    • changedInput schema / properties / manifest / description
      Previous value: -"Required for engineer (the default mode), write, generate, and dry_run: the work order (usually JSON or markdown) describing exactly what to build or change — the more specific, the tighter the gate. mode=query uses query instead."New value: +"Required for engineer (the default mode), write, and generate: the work order (usually JSON or markdown) describing exactly what to build or change — the more specific, the tighter the gate. mode=dry_run accepts the manifest or a plain-language query; mode=query uses query instead."
  4. Changed2 schema fields changed
    • addedInput schema / allOf
      Added value: +[
      +  {
      +    "if": {
      +      "anyOf": [
      +        {
      +          "not": {
      +            "required": [
      +              "mode"
      +            ]
      +          }
      +        },
      +        {
      +          "properties": {
      +            "mode": {
      +              "enum": [
      +                "engineer",
      +                "write",
      +                "generate"
      +              ]
      +            }
      +          },
      +          "required": [
      +            "mode"
      +          ]
      +        }
      +      ]
      +    },
      +    "then": {
      +      "required": [
      +        "manifest"
      +      ]
      +    }
      +  },
      +  {
      +    "if": {
      +      "properties": {
      +        "mode": {
      +          "enum": [
      +            "dry_run"
      +          ]
      +        }
      +      },
      +      "required": [
      +        "mode"
      +      ]
      +    },
      +    "then": {
      +      "anyOf": [
      +        {
      +          "required": [
      +            "manifest"
      +          ]
      +        },
      +        {
      +          "required": [
      +            "query"
      +          ]
      +        }
      +      ]
      +    }
      +  }
      +]
    • changedInput schema / properties / manifest / description
      Previous value: -"The work order (usually JSON or markdown) describing exactly what to build or change — the more specific, the tighter the gate."New value: +"Required for engineer (the default mode), write, generate, and dry_run: the work order (usually JSON or markdown) describing exactly what to build or change — the more specific, the tighter the gate. mode=query uses query instead."
  5. Changed1 schema field changed
    • removedInput schema / properties / _envelope
      Removed value: -{
      -  "default": null,
      -  "description": "Internal transport envelope handle — server-side; omit.",
      -  "title": "Envelope"
      -}
  6. Changed16 schema fields changed
    • addedInput schema / properties / _envelope / description
      Added value: +"Internal transport envelope handle — server-side; omit."
    • addedInput schema / properties / ack_irreversible / description
      Added value: +"Set true to confirm you accept this execution cannot be undone, when the judged action was irreversible."
    • addedInput schema / properties / actor_id / description
      Added value: +"Your agent identity, e.g. 'kimi-code/FI-008' — recorded in the audit log."
    • addedInput schema / properties / approved_action_hash / description
      Added value: +"Hash of the exact action that was judged — execution is refused if what you submit differs from it."
    • addedInput schema / properties / arif_ack_id / description
      Added value: +"Acknowledgment id from a prior step, for multi-step execution chains."
    • addedInput schema / properties / artifact_id / description
      Added value: +"Id of an existing artifact (from an earlier forge or judge response) that this call operates on."
    • addedInput schema / properties / constitutional_chain_id / description
      Added value: +"Id of the evidence chain (observe→think→judge) that led to the SEAL — copy it from the judge response."
    • addedInput schema / properties / judge_state_hash / description
      Added value: +"Hash string from the arif_judge SEAL response — proves the verdict has not been tampered with."
    • addedInput schema / properties / manifest / description
      Added value: +"The work order (usually JSON or markdown) describing exactly what to build or change — the more specific, the tighter the gate."
    • addedInput schema / properties / mode / description
      Added value: +"'engineer' (default) — plan and apply the work; 'dry_run' — preview what would happen, nothing is applied; 'query' — read-only questions about the workspace; 'write' — write files; 'generate' — generate code or content; 'commit' — commit prepared work; 'recall' — retrieve past forge artifacts."
    • addedInput schema / properties / plan_id / description
      Added value: +"Plan id from arif_think's plan mode, when executing an approved plan."
    • addedInput schema / properties / query / description
      Added value: +"The task in plain language when no manifest is supplied, e.g. 'restart the gateway service'."
    • addedInput schema / properties / seal_verdict_id / description
      Added value: +"The SEAL verdict id arif_judge returned — without it, nothing is executed."
    • addedInput schema / properties / session_id / description
      Added value: +"Session id returned by arif_init; scopes this execution to your governed session."
    • changedInput schema / properties / session_token / description
      Previous value: -"SCT from arif_init — continuity for ChatGPT multi-call path"New value: +"Session Continuity Token (SCT) returned by arif_init — proves the session is yours."
    • addedInput schema / properties / vault_entry_id / description
      Added value: +"Id of the permanent-ledger entry linked to this execution, when one already exists."
  7. Changed16 schema fields changed
    • removedInput schema / properties / _envelope / description
      Removed value: -"Internal transport envelope handle — server-side; omit."
    • removedInput schema / properties / ack_irreversible / description
      Removed value: -"Set true to confirm you accept this execution cannot be undone, when the judged action was irreversible."
    • removedInput schema / properties / actor_id / description
      Removed value: -"Your agent identity, e.g. 'kimi-code/FI-008' — recorded in the audit log."
    • removedInput schema / properties / approved_action_hash / description
      Removed value: -"Hash of the exact action that was judged — execution is refused if what you submit differs from it."
    • removedInput schema / properties / arif_ack_id / description
      Removed value: -"Acknowledgment id from a prior step, for multi-step execution chains."
    • removedInput schema / properties / artifact_id / description
      Removed value: -"Id of an existing artifact (from an earlier forge or judge response) that this call operates on."
    • removedInput schema / properties / constitutional_chain_id / description
      Removed value: -"Id of the evidence chain (observe→think→judge) that led to the SEAL — copy it from the judge response."
    • removedInput schema / properties / judge_state_hash / description
      Removed value: -"Hash string from the arif_judge SEAL response — proves the verdict has not been tampered with."
    • removedInput schema / properties / manifest / description
      Removed value: -"The work order (usually JSON or markdown) describing exactly what to build or change — the more specific, the tighter the gate."
    • removedInput schema / properties / mode / description
      Removed value: -"'engineer' (default) — plan and apply the work; 'dry_run' — preview what would happen, nothing is applied; 'query' — read-only questions about the workspace; 'write' — write files; 'generate' — generate code or content; 'commit' — commit prepared work; 'recall' — retrieve past forge artifacts."
    • removedInput schema / properties / plan_id / description
      Removed value: -"Plan id from arif_think's plan mode, when executing an approved plan."
    • removedInput schema / properties / query / description
      Removed value: -"The task in plain language when no manifest is supplied, e.g. 'restart the gateway service'."
    • removedInput schema / properties / seal_verdict_id / description
      Removed value: -"The SEAL verdict id arif_judge returned — without it, nothing is executed."
    • removedInput schema / properties / session_id / description
      Removed value: -"Session id returned by arif_init; scopes this execution to your governed session."
    • changedInput schema / properties / session_token / description
      Previous value: -"Session Continuity Token (SCT) returned by arif_init — proves the session is yours."New value: +"SCT from arif_init — continuity for ChatGPT multi-call path"
    • removedInput schema / properties / vault_entry_id / description
      Removed value: -"Id of the permanent-ledger entry linked to this execution, when one already exists."
  8. Changed16 schema fields changed
    • addedInput schema / properties / _envelope / description
      Added value: +"Internal transport envelope handle — server-side; omit."
    • addedInput schema / properties / ack_irreversible / description
      Added value: +"Set true to confirm you accept this execution cannot be undone, when the judged action was irreversible."
    • addedInput schema / properties / actor_id / description
      Added value: +"Your agent identity, e.g. 'kimi-code/FI-008' — recorded in the audit log."
    • addedInput schema / properties / approved_action_hash / description
      Added value: +"Hash of the exact action that was judged — execution is refused if what you submit differs from it."
    • addedInput schema / properties / arif_ack_id / description
      Added value: +"Acknowledgment id from a prior step, for multi-step execution chains."
    • addedInput schema / properties / artifact_id / description
      Added value: +"Id of an existing artifact (from an earlier forge or judge response) that this call operates on."
    • addedInput schema / properties / constitutional_chain_id / description
      Added value: +"Id of the evidence chain (observe→think→judge) that led to the SEAL — copy it from the judge response."
    • addedInput schema / properties / judge_state_hash / description
      Added value: +"Hash string from the arif_judge SEAL response — proves the verdict has not been tampered with."
    • addedInput schema / properties / manifest / description
      Added value: +"The work order (usually JSON or markdown) describing exactly what to build or change — the more specific, the tighter the gate."
    • addedInput schema / properties / mode / description
      Added value: +"'engineer' (default) — plan and apply the work; 'dry_run' — preview what would happen, nothing is applied; 'query' — read-only questions about the workspace; 'write' — write files; 'generate' — generate code or content; 'commit' — commit prepared work; 'recall' — retrieve past forge artifacts."
    • addedInput schema / properties / plan_id / description
      Added value: +"Plan id from arif_think's plan mode, when executing an approved plan."
    • addedInput schema / properties / query / description
      Added value: +"The task in plain language when no manifest is supplied, e.g. 'restart the gateway service'."
    • addedInput schema / properties / seal_verdict_id / description
      Added value: +"The SEAL verdict id arif_judge returned — without it, nothing is executed."
    • addedInput schema / properties / session_id / description
      Added value: +"Session id returned by arif_init; scopes this execution to your governed session."
    • changedInput schema / properties / session_token / description
      Previous value: -"SCT from arif_init — continuity for ChatGPT multi-call path"New value: +"Session Continuity Token (SCT) returned by arif_init — proves the session is yours."
    • addedInput schema / properties / vault_entry_id / description
      Added value: +"Id of the permanent-ledger entry linked to this execution, when one already exists."
  9. Changed1 schema field changed
    • addedInput schema / properties / session_token
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "SCT from arif_init — continuity for ChatGPT multi-call path"
      +}
  10. Changed2 schema fields changed
    • addedInput schema / properties / approved_action_hash
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null
      +}
    • addedInput schema / properties / seal_verdict_id
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null
      +}
  11. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -{
      -  "additionalProperties": true,
      -  "type": "object"
      -}New value: +null
  12. Added

TDQS

A4.1/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare destructiveHint=true, readOnlyHint=false, and idempotentHint=false, so the safety profile is partly covered. The description still adds real behavioral context beyond them: the seal/hash gate, the ack_irreversible requirement for irreversible actions, the REFUSED outcome with no change on gate failure, and the receipt fields. Minor gap: no guidance on partial-failure or retry behavior for a non-idempotent tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The gate and its prerequisites are front-loaded before the mode catalog, and the refusal and output sentences are tight. The mode list is somewhat redundant with the schema's mode enum description, which costs a fraction of a point.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 15-parameter, irreversible execution gate with an output schema and full annotation coverage, the description covers the gate, the mode contract, the irreversibility acknowledgment, and the failure mode. It omits what artifact_id, vault_entry_id, and arif_ack_id do in chains, but those are documented in the schema itself.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so every parameter is already documented in the input schema, and the description's mode breakdown largely restates the enum descriptions. It does add value by stating which modes require a manifest versus a query and by tying seal_verdict_id and approved_action_hash to a mismatch-refusal condition, but the net gain over the schema is modest.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The first sentence states a specific verb and object — 'Execute an action arif_judge has already SEALed' — and immediately names the gating resource (seal_verdict_id, approved_action_hash). An agent can distinguish this from arif_judge or arif_think without opening any schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description enumerates all seven modes with a one-line condition for each (engineer default, dry_run preview, query read-only, etc.) and states the hard prerequisite that nothing runs without a SEAL. It stops short of explicitly saying 'use arif_judge first if you have not', though the dependency implies it.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.