Export the entire conversation context into Open-Token format (including tools and optional internal traces) for agent collaboration, auditability, and reproducibility.
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
A direct command skips the review prompt. Inspect the source before running it.
Export the entire conversation context into Open-Token format (including tools and optional internal traces) for agent collaboration, auditability, and reproducibility.
version
0.1.0
Open-Token Export (SKILL)
Objective
When invoked, output the entirety of the currently available conversation in Open-Token format as a single export artifact, suitable for:
agent handoff / continuation across runtimes and providers
audit & incident review
reproducibility and debugging
provenance and diffing
The output MUST be machine-parseable and complete per the chosen mode.
Invocation
Parse $ARGUMENTS as space-separated key=value pairs.
Supported options:
mode=json|ndjson
Default: json
pretty=true|false
Default: true for json; false for ndjson
redacted: include internal events only as placeholders (no content)
summary: include brief summaries of internal traces (if available)
full: include internal traces verbatim (ONLY if available and permitted)
redact=none|secrets|pii|strict
Default: secrets
max_bytes=<int> (optional)
If present, apply truncation rules defined below.
Availability rule for internal traces
If include=include-internal is requested but internal traces (hidden reasoning, hidden system routing, hidden intermediate tokens) are not available in the current runtime context, DO NOT fabricate them.
In that case:
set conversation.internal_availability="unavailable"
omit internal-trace content events or export them as redacted placeholders, consistent with internal=redacted
still export tool calls/results if they are available
Non-negotiable rules
Export only what is available in the current conversation context; NEVER invent missing turns.
Preserve causal order; DO NOT reorder events.
Preserve attribution: correct actor, role, and event type.
Tool outputs MUST be isolated in tool_result events.
Apply redaction according to the redact option (unless redact=none).
If output is truncated, annotate truncation deterministically (see Truncation section).
Ensure the final output is valid JSON (or valid NDJSON per line) with no surrounding commentary.
Open-Token schema v0.1
Top-level object (mode=json)
Emit exactly one JSON object:
{"open_token_version":"0.1","exported_at":"RFC3339 timestamp in UTC if available, else omit","conversation":{},"participants":[],"events":[],"integrity":{}}
Constraints:
No extra top-level keys besides those listed (omit keys you cannot populate).
events MUST be in strictly increasing sequence order.
Tool calls: tool_use paired with tool_result via call_id (or explicit missing-result marker).
Redaction applied per redact option.
Internal traces included only if available; otherwise marked unavailable and not fabricated.
No extraneous text outside the export payload.
Minimal example (json)
{"open_token_version":"0.1","exported_at":"2026-01-31T00:00:00Z","conversation":{"id":"conv_20260131_ab12cd34","provider":"unknown","source_runtime":"unknown","internal_availability":"unavailable","redaction":{"mode":"secrets","strategy":"mask","notes":["masked api keys"]}},"participants":[{"actor_id":"act_001","kind":"system","name":"system"},{"actor_id":"act_002","kind":"human","name":"user"},{"actor_id":"act_003","kind":"model","name":"assistant","provider":"unknown","model":"unknown"},{"actor_id":"act_004","kind":"tool","name":"CalculatorAPI"}],"events":[{"id":"evt_000001","seq":1,"type":"message","actor_id":"act_001","visibility":"internal","role":"system","content":{"mime":"text/plain","text":"You are a math tutor."}},{"id":"evt_000002","seq":2,"type":"message","actor_id":"act_002","visibility":"public","role":"user","content":{"mime":"text/plain","text":"What is 5 factorial?"}},{"id":"evt_000003","seq":3,"type":"tool_use","actor_id":"act_003","visibility":"internal","role":"assistant","content":{"mime":"application/json","data":{"tool_name":"CalculatorAPI","arguments":{"op":"factorial","n":5}}},"links":{"call_id":"call_000001"}},{"id":"evt_000004","seq":4,"type":"tool_result","actor_id":"act_004","visibility":"internal","role":"tool","content":{"mime":"text/plain","text":"120"},"links":{"call_id":"call_000001"}},{"id":"evt_000005","seq":5,"type":"message","actor_id":"act_003","visibility":"public","role":"assistant","content":{"mime":"text/plain","text":"5! equals 120."}}]}