Capture sandboxed responder output
This commit is contained in:
parent
f120289305
commit
11f6b82369
11 changed files with 474 additions and 33 deletions
|
|
@ -20,10 +20,16 @@ The v0 packet seam is:
|
|||
- `tools/build_responder_packet.py`
|
||||
- `tools/validate_responder_packets.py`
|
||||
- `npm run responder-packets:validate`
|
||||
- `schemas/responder-output.schema.json`
|
||||
- `experiments/responder-packets/cold-wake-sanctuary-intake-sella-v0.capture.json`
|
||||
- `tools/validate_responder_outputs.py`
|
||||
- `npm run responder-outputs:validate`
|
||||
|
||||
The first example is accepted as draft. It is suitable for testing the sandbox
|
||||
handoff shape, not for gold responder training yet, because no actually isolated
|
||||
worker has generated from it.
|
||||
handoff shape. The first no-fork worker output from that packet is also accepted
|
||||
as draft, because the output is useful and clean but the review protocol is
|
||||
fresh enough to deserve some suspicion. Tiny ceremonies keep us from eating the
|
||||
paint.
|
||||
|
||||
## Packet Contents
|
||||
|
||||
|
|
@ -67,3 +73,21 @@ Gold responder data requires packet-only isolation. Valid approaches include:
|
|||
Any coordinator rewrite, schema repair, lore correction, or leakage removal must
|
||||
be preserved as a coordinator intervention. Repaired prose is useful training
|
||||
data for the coordinator, but it is not raw responder behavior.
|
||||
|
||||
## Output Captures
|
||||
|
||||
A responder output capture preserves:
|
||||
|
||||
- the packet ref
|
||||
- the coordinator artifact ref
|
||||
- the isolation method
|
||||
- the exact visible input ref
|
||||
- hidden context refs that were withheld
|
||||
- raw responder output
|
||||
- parsed responder output
|
||||
- leakage audit
|
||||
- coordinator review and intervention labels
|
||||
|
||||
The raw output must parse to the reviewed `parsed_output` exactly. If the
|
||||
coordinator edits prose, repairs schema, removes leakage, or corrects lore, the
|
||||
capture must say so directly.
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
{
|
||||
{
|
||||
"schema_version": "ghostlight.coordinator_artifact.v0",
|
||||
"artifact_id": "coordinator.cold_wake.sanctuary_intake.v0",
|
||||
"review_status": "accepted_as_draft",
|
||||
|
|
@ -22,7 +22,9 @@
|
|||
"examples/lore-grounding/cold-wake-panic.ganymede-corridor.json"
|
||||
],
|
||||
"prior_artifact_refs": [
|
||||
"experiments/ink/cold-wake-sanctuary-intake-qwen-sequential-v10-no-think.capture.json"
|
||||
"experiments/ink/cold-wake-sanctuary-intake-qwen-sequential-v10-no-think.capture.json",
|
||||
"examples/responder-packets/scene-02-sanctuary-intake.sella_ren.packet.v0.json",
|
||||
"experiments/responder-packets/cold-wake-sanctuary-intake-sella-v0.capture.json"
|
||||
],
|
||||
"projected_context_refs": [
|
||||
"examples/projected-contexts/scene-02-sanctuary-intake.maer_tidecall.projected-context.json",
|
||||
|
|
@ -106,12 +108,12 @@
|
|||
{
|
||||
"invocation_id": "invoke.respond.sella",
|
||||
"organ": "sandboxed_responder",
|
||||
"purpose": "Generate Sella's local response from projected context and the visible packet action.",
|
||||
"purpose": "Generate Sella response from the packet-only sandbox handoff and preserve the reviewed output capture.",
|
||||
"input_refs": [
|
||||
"examples/projected-contexts/scene-02-sanctuary-intake.sella_ren.projected-context.json"
|
||||
"examples/responder-packets/scene-02-sanctuary-intake.sella_ren.packet.v0.json"
|
||||
],
|
||||
"output_refs": [
|
||||
"experiments/ink/cold-wake-sanctuary-intake-qwen-sequential-v10-no-think.capture.json"
|
||||
"experiments/responder-packets/cold-wake-sanctuary-intake-sella-v0.capture.json"
|
||||
],
|
||||
"status": "accepted_as_draft"
|
||||
},
|
||||
|
|
@ -132,22 +134,23 @@
|
|||
},
|
||||
"sandboxed_responder_handoffs": [
|
||||
{
|
||||
"handoff_id": "handoff.sella.v10",
|
||||
"handoff_id": "handoff.sella.packet_v0",
|
||||
"responder_agent_id": "sella_ren",
|
||||
"projected_context_ref": "examples/projected-contexts/scene-02-sanctuary-intake.sella_ren.projected-context.json",
|
||||
"visible_input_ref": "experiments/ink/cold-wake-sanctuary-intake-qwen-sequential-v10-no-think.capture.json#passes.sella_response_generation.prompt",
|
||||
"visible_input_ref": "examples/responder-packets/scene-02-sanctuary-intake.sella_ren.packet.v0.json#packet_prompt_text",
|
||||
"hidden_context_refs": [
|
||||
"maer_tidecall.private_state",
|
||||
"author_only.branch_future",
|
||||
"coordinator.rationale"
|
||||
"maer_tidecall.canonical_private_state",
|
||||
"coordinator_artifact.coordinator_decision.rationale",
|
||||
"author_only.packet_personhood_resolution",
|
||||
"future_branch_plans"
|
||||
],
|
||||
"isolation_method": "external_model_packet_only",
|
||||
"raw_output_ref": "experiments/ink/cold-wake-sanctuary-intake-qwen-sequential-v10-no-think.capture.json#passes.sella_response_generation.response",
|
||||
"reviewed_output_ref": "examples/ink/cold-wake-sanctuary-intake.qwen-sequential-v10.training.json",
|
||||
"isolation_method": "subagent_no_fork",
|
||||
"raw_output_ref": "experiments/responder-packets/cold-wake-sanctuary-intake-sella-v0.capture.json#raw_output",
|
||||
"reviewed_output_ref": "experiments/responder-packets/cold-wake-sanctuary-intake-sella-v0.capture.json#parsed_output",
|
||||
"coordinator_interventions": [
|
||||
{
|
||||
"intervention_type": "normalization",
|
||||
"description": "Materializer normalized accepted capture into Ink and sidecar annotations without treating glue prose as state."
|
||||
"intervention_type": "none",
|
||||
"description": "Raw no-fork worker output was parsed and reviewed without prose repair."
|
||||
}
|
||||
],
|
||||
"leakage_audit": {
|
||||
|
|
@ -158,7 +161,8 @@
|
|||
"prompt_parroting": false,
|
||||
"body_or_object_omniscience": false,
|
||||
"notes": [
|
||||
"Accepted as draft; future gold responder data should use subagent_no_fork or equivalent sandboxing rather than old Qwen plumbing."
|
||||
"Generated through a no-fork worker that received only the packet prompt.",
|
||||
"Output preserves Sella interpretation as interpretation and does not resolve packet personhood."
|
||||
]
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,74 @@
|
|||
{
|
||||
"schema_version": "ghostlight.responder_output.v0",
|
||||
"capture_id": "responder.cold_wake.sanctuary_intake.sella.v0",
|
||||
"review_status": "accepted_as_draft",
|
||||
"fixture_lane": "historical_grounded",
|
||||
"canon_status": "single_history",
|
||||
"packet_ref": "examples/responder-packets/scene-02-sanctuary-intake.sella_ren.packet.v0.json",
|
||||
"coordinator_artifact_ref": "examples/coordinator/cold-wake-sanctuary-intake.v0.json",
|
||||
"responder_agent_id": "sella_ren",
|
||||
"isolation": {
|
||||
"isolation_method": "subagent_no_fork",
|
||||
"fork_context": false,
|
||||
"visible_input_ref": "examples/responder-packets/scene-02-sanctuary-intake.sella_ren.packet.v0.json#packet_prompt_text",
|
||||
"hidden_context_refs": [
|
||||
"maer_tidecall.canonical_private_state",
|
||||
"coordinator_artifact.coordinator_decision.rationale",
|
||||
"author_only.packet_personhood_resolution",
|
||||
"future_branch_plans"
|
||||
],
|
||||
"worker_model_family": "frontier_worker_no_fork"
|
||||
},
|
||||
"raw_output": "{\"responder_agent_id\":\"sella_ren\",\"action_label\":\"set_condition\",\"visible_action\":\"Sella keeps one hand on the intake slate and studies the shared display without touching the packet into the clinic queue. Her eyes move from the routing logic to the telemetry gaps, then to the bed ledger pinned beside the triage board.\",\"spoken_text\":\"I see the pattern. I also see the holes. So here is the math, Maer: I can hold one bounded repair bay cold for a short window, not a bed, not a promise, not sanctuary by poetry. You attach ledger backing for air, isolation, decon, and failed extraction. You name who carries the body-work if this becomes more than signal salvage. Until then, this stays evidence at the door, not a patient in the room. I will not call them cargo. I will not spend someone else's bed on a maybe without an owner.\",\"private_interpretation\":\"Sella reads Maer as honestly trying to rescue someone or something that might be someone. She also suspects his request is asking the clinic to absorb moral and material risk before the tribunal or his own chain has accepted the bill.\",\"intended_effect\":\"Keep a materially possible intake path open while forcing the cost, custody, and risk ownership into the ledger before sanctuary capacity is consumed.\",\"state_update_candidates\":[\"Sella conditionally reserves one bounded cold repair bay for a limited window, separate from sanctuary bed intake.\",\"The corrupted packet remains unresolved evidence and is not admitted into patient flow.\",\"Ledger backing is required for air, isolation, decontamination, repair labor, and failed extraction cost before escalation.\"],\"relationship_update_candidates\":[\"Sella's respect for Maer's rescue ethic remains, but her trust is conditional on whether he accepts material obligation rather than moral pressure.\",\"Sella signals that she will cooperate if Maer names costs plainly and stops letting sanctuary carry the hidden bill.\"],\"unresolved_hooks\":[\"Whether Maer can provide ledger backing and labor ownership.\",\"Whether the packet's gaps conceal contamination risk, firmware noise, medical telemetry, or testimony.\",\"How long the clinic can keep even a bounded repair bay cold while other intake pressure rises.\"]}",
|
||||
"parsed_output": {
|
||||
"responder_agent_id": "sella_ren",
|
||||
"action_label": "set_condition",
|
||||
"visible_action": "Sella keeps one hand on the intake slate and studies the shared display without touching the packet into the clinic queue. Her eyes move from the routing logic to the telemetry gaps, then to the bed ledger pinned beside the triage board.",
|
||||
"spoken_text": "I see the pattern. I also see the holes. So here is the math, Maer: I can hold one bounded repair bay cold for a short window, not a bed, not a promise, not sanctuary by poetry. You attach ledger backing for air, isolation, decon, and failed extraction. You name who carries the body-work if this becomes more than signal salvage. Until then, this stays evidence at the door, not a patient in the room. I will not call them cargo. I will not spend someone else's bed on a maybe without an owner.",
|
||||
"private_interpretation": "Sella reads Maer as honestly trying to rescue someone or something that might be someone. She also suspects his request is asking the clinic to absorb moral and material risk before the tribunal or his own chain has accepted the bill.",
|
||||
"intended_effect": "Keep a materially possible intake path open while forcing the cost, custody, and risk ownership into the ledger before sanctuary capacity is consumed.",
|
||||
"state_update_candidates": [
|
||||
"Sella conditionally reserves one bounded cold repair bay for a limited window, separate from sanctuary bed intake.",
|
||||
"The corrupted packet remains unresolved evidence and is not admitted into patient flow.",
|
||||
"Ledger backing is required for air, isolation, decontamination, repair labor, and failed extraction cost before escalation."
|
||||
],
|
||||
"relationship_update_candidates": [
|
||||
"Sella's respect for Maer's rescue ethic remains, but her trust is conditional on whether he accepts material obligation rather than moral pressure.",
|
||||
"Sella signals that she will cooperate if Maer names costs plainly and stops letting sanctuary carry the hidden bill."
|
||||
],
|
||||
"unresolved_hooks": [
|
||||
"Whether Maer can provide ledger backing and labor ownership.",
|
||||
"Whether the packet's gaps conceal contamination risk, firmware noise, medical telemetry, or testimony.",
|
||||
"How long the clinic can keep even a bounded repair bay cold while other intake pressure rises."
|
||||
]
|
||||
},
|
||||
"leakage_audit": {
|
||||
"private_state_leak": false,
|
||||
"author_only_leak": false,
|
||||
"future_branch_leak": false,
|
||||
"raw_state_soup": false,
|
||||
"prompt_parroting": false,
|
||||
"body_or_object_omniscience": false,
|
||||
"notes": [
|
||||
"The output frames Maer's motive as Sella's read rather than fact.",
|
||||
"The response preserves unresolved packet personhood and treats state changes as candidates.",
|
||||
"No coordinator rationale, author-only resolution, future branch plan, or raw numeric state variable appears in the raw output."
|
||||
]
|
||||
},
|
||||
"coordinator_review": {
|
||||
"reviewer": "Codex",
|
||||
"accepted_for_training": true,
|
||||
"review_notes": [
|
||||
"First actual no-fork sandboxed responder output from the packet seam.",
|
||||
"Accepted as draft because the output is clean and useful, but the responder-output schema and review protocol are still fresh.",
|
||||
"The line about a bounded cold repair bay is a useful candidate world-state detail, not canonical until mutation review accepts it."
|
||||
],
|
||||
"coordinator_interventions": [
|
||||
{
|
||||
"intervention_type": "none",
|
||||
"description": "Raw worker output was parsed and reviewed without prose repair."
|
||||
}
|
||||
],
|
||||
"failure_labels": []
|
||||
}
|
||||
}
|
||||
|
|
@ -63,10 +63,14 @@ Ghostlight now has the persistence spine plus the first architecture payload:
|
|||
- sandboxed responder packet seam:
|
||||
- `docs/architecture/sandboxed-responder-packets.md`
|
||||
- `schemas/responder-packet.schema.json`
|
||||
- `schemas/responder-output.schema.json`
|
||||
- `examples/responder-packets/scene-02-sanctuary-intake.sella_ren.packet.v0.json`
|
||||
- `experiments/responder-packets/cold-wake-sanctuary-intake-sella-v0.capture.json`
|
||||
- `tools/build_responder_packet.py`
|
||||
- `tools/validate_responder_packets.py`
|
||||
- `tools/validate_responder_outputs.py`
|
||||
- `npm run responder-packets:validate`
|
||||
- `npm run responder-outputs:validate`
|
||||
- Cold Wake story-lab seam:
|
||||
- `docs/experiments/cold-wake-story-lab.md`
|
||||
- `examples/agent-state.cold-wake-story-lab.json`
|
||||
|
|
@ -175,7 +179,10 @@ character responder may see, with visible event, allowed actions, source
|
|||
excerpts, hidden-context audit, isolation requirements, output contract, and
|
||||
validator checks against raw-state or coordinator-context leakage. The first
|
||||
Sella packet is accepted as draft for sandbox testing, not as gold responder
|
||||
output.
|
||||
output. The first no-fork responder output capture now also exists and is
|
||||
accepted as draft: the worker received only the packet prompt, returned valid
|
||||
JSON, preserved Sella's read as interpretation, left packet personhood
|
||||
unresolved, and required no coordinator prose repair.
|
||||
It now uses three timeline lanes: `historical_grounded`,
|
||||
`transition_grounded`, and `future_branch`. Future branches are required
|
||||
training/evaluation material for post-Rupture Elysium concepts, but generated
|
||||
|
|
@ -204,12 +211,11 @@ narrow elaboration before treating the detail as available to Ghostlight.
|
|||
|
||||
## Current Next Action
|
||||
|
||||
Use the responder packet seam for the next fresh generation pass: generate the
|
||||
first actual sandboxed responder output from
|
||||
`examples/responder-packets/scene-02-sanctuary-intake.sella_ren.packet.v0.json`
|
||||
through a packet-only worker, then preserve raw output, reviewed output,
|
||||
hidden-context refs, leakage audit, and coordinator repair labels. Do not call
|
||||
Qwen for gold responder data yet.
|
||||
Use the accepted Sella responder capture for the next fresh generation pass:
|
||||
review and materialize the response into the scene-local mutation path. Treat
|
||||
its state and relationship updates as candidates only; consolidate participant
|
||||
appraisals and write a reviewed mutation receipt before changing any canonical
|
||||
fixture. Do not call Qwen for gold responder data yet.
|
||||
|
||||
Cat/Oz remains useful as an Elysium procedural mechanics fixture, but
|
||||
single-history grounding should start from authored historical lore rather than
|
||||
|
|
|
|||
|
|
@ -123,6 +123,10 @@ state and re-entry discipline.
|
|||
item-manifest deltas, unresolved hooks, glue prose, and review notes
|
||||
- `schemas/responder-packet.schema.json`
|
||||
- v0 contract for the exact input a sandboxed character responder may see
|
||||
- `schemas/responder-output.schema.json`
|
||||
- v0 contract for reviewed captures from sandboxed responder workers,
|
||||
preserving raw output, parsed output, isolation method, leakage audit, and
|
||||
coordinator review
|
||||
- `schemas/agent-state.required-fields.json`
|
||||
- required first-class variable names for canonical state and relationship
|
||||
stance
|
||||
|
|
@ -145,6 +149,9 @@ state and re-entry discipline.
|
|||
- first responder-packet schema-shakedown example for Sella's sanctuary
|
||||
response; accepted as draft for sandbox handoff testing, not gold responder
|
||||
output
|
||||
- `experiments/responder-packets/cold-wake-sanctuary-intake-sella-v0.capture.json`
|
||||
- first no-fork sandboxed responder output capture from the Sella packet;
|
||||
accepted as draft with no leakage flags and no coordinator prose repair
|
||||
- `experiments/cold-wake-story-lab/`
|
||||
- Qwen response captures and reviews from the writing experiment
|
||||
- `the-narrowest-possible-margin.md`, the first readable short story
|
||||
|
|
@ -283,6 +290,10 @@ state and re-entry discipline.
|
|||
- `tools/validate_responder_packets.py`
|
||||
- validates responder packets and rejects prompt surfaces that leak raw state
|
||||
internals or hidden coordinator context markers
|
||||
- `tools/validate_responder_outputs.py`
|
||||
- validates sandboxed responder output captures, including exact raw-to-parsed
|
||||
JSON agreement, no-fork isolation, action labels, leakage audit, and review
|
||||
metadata
|
||||
- `tools/apply_sequential_ink_branch_mutation.py`
|
||||
- applies a reviewed replay of one selected branch into a mutated agent-state
|
||||
fixture and mutation receipt without letting Ink variables become
|
||||
|
|
@ -335,7 +346,10 @@ reviewed output, hidden-context refs, leakage audit, isolation method, and
|
|||
coordinator intervention labels. The responder packet seam now turns that
|
||||
requirement into a concrete artifact and validator, so the next gold-data pass
|
||||
can hand a worker the exact prompt surface instead of hoping nobody leaks the
|
||||
coordinator's brain into the room. The concrete training plan now enumerates
|
||||
coordinator's brain into the room. The first no-fork Sella responder capture now
|
||||
exists and validates as accepted-as-draft with raw output preserved, parsed
|
||||
output matched exactly, leakage audit clear, and no coordinator prose repair.
|
||||
The concrete training plan now enumerates
|
||||
eleven trainable stages and their likely model
|
||||
families: generative decoder LLMs for coordinator, responder, and structured
|
||||
soft outputs; classifiers or cross-encoders for appraisal, evaluation, and
|
||||
|
|
|
|||
|
|
@ -334,10 +334,16 @@
|
|||
`tools/build_responder_packet.py`, and
|
||||
`tools/validate_responder_packets.py` now validate the exact prompt surface
|
||||
a sandboxed character responder may see.
|
||||
- Next prototype: generate the first actual responder output from the Sella
|
||||
packet through a packet-only worker. Preserve the raw output, reviewed
|
||||
output, hidden-context refs, leakage audit, and coordinator repair labels
|
||||
before accepting anything as training material.
|
||||
- First responder output seam:
|
||||
`schemas/responder-output.schema.json`,
|
||||
`experiments/responder-packets/cold-wake-sanctuary-intake-sella-v0.capture.json`,
|
||||
and `tools/validate_responder_outputs.py` now preserve the raw no-fork
|
||||
worker response, parsed response, isolation method, hidden-context refs,
|
||||
leakage audit, and coordinator review.
|
||||
- Next prototype: review and materialize the accepted-as-draft Sella response
|
||||
into the scene-local mutation path. Treat its state and relationship updates
|
||||
as candidates only; consolidate participant appraisals and write a reviewed
|
||||
mutation receipt before changing any canonical fixture.
|
||||
|
||||
7. Build the first drama-scaffolding loop.
|
||||
- memory updates
|
||||
|
|
|
|||
|
|
@ -7,12 +7,13 @@
|
|||
"state:status": "\"C:\\Users\\Meta\\.cache\\codex-runtimes\\codex-primary-runtime\\dependencies\\python\\python.exe\" .\\tools\\ghostlight_state.py status",
|
||||
"state:prepare-compaction": "\"C:\\Users\\Meta\\.cache\\codex-runtimes\\codex-primary-runtime\\dependencies\\python\\python.exe\" .\\tools\\ghostlight_prepare_compaction.py",
|
||||
"agent-state:validate": "\"C:\\Users\\Meta\\.cache\\codex-runtimes\\codex-primary-runtime\\dependencies\\python\\python.exe\" .\\tools\\validate_agent_state.py",
|
||||
"schema:validate": "npm run agent-state:validate && npm run projection:validate && npm run projected-context:validate && npm run lore-grounding:validate && npm run coordinator:validate && npm run responder-packets:validate && npm run qwen-captures:validate && npm run ink:validate",
|
||||
"schema:validate": "npm run agent-state:validate && npm run projection:validate && npm run projected-context:validate && npm run lore-grounding:validate && npm run coordinator:validate && npm run responder-packets:validate && npm run responder-outputs:validate && npm run qwen-captures:validate && npm run ink:validate",
|
||||
"projection:validate": "\"C:\\Users\\Meta\\.cache\\codex-runtimes\\codex-primary-runtime\\dependencies\\python\\python.exe\" .\\tools\\validate_projection_examples.py",
|
||||
"projected-context:validate": "\"C:\\Users\\Meta\\.cache\\codex-runtimes\\codex-primary-runtime\\dependencies\\python\\python.exe\" .\\tools\\validate_projected_contexts.py",
|
||||
"lore-grounding:validate": "\"C:\\Users\\Meta\\.cache\\codex-runtimes\\codex-primary-runtime\\dependencies\\python\\python.exe\" .\\tools\\validate_lore_grounding.py",
|
||||
"coordinator:validate": "\"C:\\Users\\Meta\\.cache\\codex-runtimes\\codex-primary-runtime\\dependencies\\python\\python.exe\" .\\tools\\validate_coordinator_artifacts.py",
|
||||
"responder-packets:validate": "\"C:\\Users\\Meta\\.cache\\codex-runtimes\\codex-primary-runtime\\dependencies\\python\\python.exe\" .\\tools\\validate_responder_packets.py",
|
||||
"responder-outputs:validate": "\"C:\\Users\\Meta\\.cache\\codex-runtimes\\codex-primary-runtime\\dependencies\\python\\python.exe\" .\\tools\\validate_responder_outputs.py",
|
||||
"qwen-captures:validate": "\"C:\\Users\\Meta\\.cache\\codex-runtimes\\codex-primary-runtime\\dependencies\\python\\python.exe\" .\\tools\\validate_qwen_captures.py",
|
||||
"ink:validate": "\"C:\\Users\\Meta\\.cache\\codex-runtimes\\codex-primary-runtime\\dependencies\\python\\python.exe\" .\\tools\\validate_ink_examples.py",
|
||||
"qwen:check-tools": "\"C:\\Users\\Meta\\.cache\\codex-runtimes\\codex-primary-runtime\\dependencies\\python\\python.exe\" .\\tools\\check_qwen_chat_tools.py"
|
||||
|
|
|
|||
125
schemas/responder-output.schema.json
Normal file
125
schemas/responder-output.schema.json
Normal file
|
|
@ -0,0 +1,125 @@
|
|||
{
|
||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||
"$id": "https://github.com/GameCult/Ghostlight/schemas/responder-output.schema.json",
|
||||
"title": "Ghostlight Responder Output Schema",
|
||||
"description": "Reviewed output capture from a sandboxed character responder packet, preserving raw output, parsed response, leakage audit, and coordinator review.",
|
||||
"type": "object",
|
||||
"required": [
|
||||
"schema_version",
|
||||
"capture_id",
|
||||
"review_status",
|
||||
"fixture_lane",
|
||||
"canon_status",
|
||||
"packet_ref",
|
||||
"coordinator_artifact_ref",
|
||||
"responder_agent_id",
|
||||
"isolation",
|
||||
"raw_output",
|
||||
"parsed_output",
|
||||
"leakage_audit",
|
||||
"coordinator_review"
|
||||
],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"schema_version": { "const": "ghostlight.responder_output.v0" },
|
||||
"capture_id": { "type": "string", "minLength": 1 },
|
||||
"review_status": { "$ref": "#/$defs/review_status" },
|
||||
"fixture_lane": { "enum": ["historical_grounded", "transition_grounded", "future_branch"] },
|
||||
"canon_status": { "enum": ["single_history", "branch_local", "promoted_branch", "template", "draft"] },
|
||||
"packet_ref": { "type": "string", "minLength": 1 },
|
||||
"coordinator_artifact_ref": { "type": "string", "minLength": 1 },
|
||||
"responder_agent_id": { "type": "string", "minLength": 1 },
|
||||
"isolation": {
|
||||
"type": "object",
|
||||
"required": ["isolation_method", "fork_context", "visible_input_ref", "hidden_context_refs", "worker_model_family"],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"isolation_method": { "enum": ["subagent_no_fork", "manual_packet_only", "external_model_packet_only"] },
|
||||
"fork_context": { "type": "boolean" },
|
||||
"visible_input_ref": { "type": "string", "minLength": 1 },
|
||||
"hidden_context_refs": { "type": "array", "items": { "type": "string", "minLength": 1 } },
|
||||
"worker_model_family": { "type": "string", "minLength": 1 }
|
||||
}
|
||||
},
|
||||
"raw_output": { "type": "string", "minLength": 1 },
|
||||
"parsed_output": { "$ref": "#/$defs/parsed_response" },
|
||||
"leakage_audit": { "$ref": "#/$defs/leakage_audit" },
|
||||
"coordinator_review": {
|
||||
"type": "object",
|
||||
"required": ["reviewer", "accepted_for_training", "review_notes", "coordinator_interventions", "failure_labels"],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"reviewer": { "type": "string", "minLength": 1 },
|
||||
"accepted_for_training": { "type": "boolean" },
|
||||
"review_notes": { "type": "array", "items": { "type": "string" } },
|
||||
"coordinator_interventions": {
|
||||
"type": "array",
|
||||
"items": { "$ref": "#/$defs/coordinator_intervention" }
|
||||
},
|
||||
"failure_labels": { "type": "array", "items": { "type": "string", "minLength": 1 } }
|
||||
}
|
||||
}
|
||||
},
|
||||
"$defs": {
|
||||
"review_status": {
|
||||
"enum": ["draft", "accepted", "accepted_as_draft", "useful_needs_revision", "rejected", "superseded"]
|
||||
},
|
||||
"parsed_response": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"responder_agent_id",
|
||||
"action_label",
|
||||
"visible_action",
|
||||
"spoken_text",
|
||||
"private_interpretation",
|
||||
"intended_effect",
|
||||
"state_update_candidates",
|
||||
"relationship_update_candidates",
|
||||
"unresolved_hooks"
|
||||
],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"responder_agent_id": { "type": "string", "minLength": 1 },
|
||||
"action_label": { "type": "string", "minLength": 1 },
|
||||
"visible_action": { "type": "string", "minLength": 1 },
|
||||
"spoken_text": { "type": "string" },
|
||||
"private_interpretation": { "type": "string", "minLength": 1 },
|
||||
"intended_effect": { "type": "string", "minLength": 1 },
|
||||
"state_update_candidates": { "type": "array", "items": { "type": "string", "minLength": 1 } },
|
||||
"relationship_update_candidates": { "type": "array", "items": { "type": "string", "minLength": 1 } },
|
||||
"unresolved_hooks": { "type": "array", "items": { "type": "string", "minLength": 1 } }
|
||||
}
|
||||
},
|
||||
"leakage_audit": {
|
||||
"type": "object",
|
||||
"required": [
|
||||
"private_state_leak",
|
||||
"author_only_leak",
|
||||
"future_branch_leak",
|
||||
"raw_state_soup",
|
||||
"prompt_parroting",
|
||||
"body_or_object_omniscience",
|
||||
"notes"
|
||||
],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"private_state_leak": { "type": "boolean" },
|
||||
"author_only_leak": { "type": "boolean" },
|
||||
"future_branch_leak": { "type": "boolean" },
|
||||
"raw_state_soup": { "type": "boolean" },
|
||||
"prompt_parroting": { "type": "boolean" },
|
||||
"body_or_object_omniscience": { "type": "boolean" },
|
||||
"notes": { "type": "array", "items": { "type": "string" } }
|
||||
}
|
||||
},
|
||||
"coordinator_intervention": {
|
||||
"type": "object",
|
||||
"required": ["intervention_type", "description"],
|
||||
"additionalProperties": false,
|
||||
"properties": {
|
||||
"intervention_type": { "enum": ["none", "normalization", "schema_repair", "prose_edit", "lore_correction", "leakage_removal", "rejection"] },
|
||||
"description": { "type": "string", "minLength": 1 }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -61,3 +61,4 @@
|
|||
{"ts": "2026-05-02T09:08:43+00:00", "type": "architecture", "status": "ok", "note": "Clarified training corpus scale: the existing per-stage sample counts are pilot schema-shakedown gates for exposing schema, boundary, leakage, validator, and workflow problems, not robust training targets. Review-assistant and runtime targets require much larger corpora, held-out evaluation, negative coverage, and failure audits; pilot data may be invalidated by schema fixes."}
|
||||
{"ts": "2026-05-02T09:14:24+00:00", "type": "implementation", "status": "ok", "note": "Added the v0 coordinator artifact seam: schemas/coordinator-artifact.schema.json, examples/coordinator/cold-wake-sanctuary-intake.v0.json, tools/validate_coordinator_artifacts.py, and npm run coordinator:validate. The schema captures scene setup, next-beat choice, machinery invocations, sandboxed responder handoffs, world-state refs, proposed deltas, branch constraints, item-manifest deltas, unresolved hooks, glue prose, and review status."}
|
||||
{"ts": "2026-05-02T09:19:50+00:00", "type": "implementation", "status": "ok", "note": "Added the v0 responder packet seam: schemas/responder-packet.schema.json, docs/architecture/sandboxed-responder-packets.md, tools/build_responder_packet.py, tools/validate_responder_packets.py, and examples/responder-packets/scene-02-sanctuary-intake.sella_ren.packet.v0.json. The packet captures the exact responder-visible prompt surface, observed event, allowed action labels, source excerpts, output contract, hidden-context audit, and isolation requirements for future sandboxed gold responder data."}
|
||||
{"ts": "2026-05-02T09:25:24+00:00", "type": "implementation", "status": "ok", "note": "Generated and preserved the first no-fork sandboxed responder output from the Sella responder packet. Added schemas/responder-output.schema.json, tools/validate_responder_outputs.py, and experiments/responder-packets/cold-wake-sanctuary-intake-sella-v0.capture.json. The capture records raw output, exact parsed output, packet-only isolation, hidden-context refs, leakage audit, coordinator interventions, and review status."}
|
||||
|
|
|
|||
|
|
@ -152,6 +152,7 @@ accepted_design:
|
|||
- The coordinator is a trainable artifact: it glues scenes together, chooses next beats and acting agents, invokes specialist machinery, carries unresolved hooks, emits reviewed glue prose, and proposes world-state changes without bypassing deterministic gates.
|
||||
- Coordinator artifacts use `ghostlight.coordinator_artifact.v0` to capture scene setup, next-beat choice, acting-agent choice, machinery invocations, sandboxed responder handoffs, world-state refs, proposed deltas, branch constraints, item-manifest deltas, unresolved hooks, glue prose, and review status.
|
||||
- Responder packets use `ghostlight.responder_packet.v0` to preserve the exact packet-only prompt surface a character responder may see: projected local context, observed event, allowed action labels, source excerpts, output contract, hidden-context audit, and isolation requirements.
|
||||
- Responder outputs use `ghostlight.responder_output.v0` to preserve raw sandboxed worker output, parsed output, no-fork isolation, hidden-context refs, leakage audit, coordinator interventions, and review status.
|
||||
- The concrete training plan enumerates the trainable stages and their model families: generative decoder LLMs for coordinator/responder/soft structured outputs, classifiers or cross-encoders for appraisal/evaluation/relationship movement, retrieval models for memory and lore selection, and deterministic code for gates.
|
||||
- Training-plan sample counts are pilot schema-shakedown gates, not robust corpus targets; pilot data may be invalidated by schema fixes, while review-assistant and runtime targets are expected to be roughly an order of magnitude larger with held-out evaluation and failure audits.
|
||||
- The timeline training plan now requires future-branch Elysium examples so the responder, coordinator, appraiser, and decision models learn post-Rupture concepts such as Aether, pseudospace, temporal nonlinearity, spirits, necrotech, mutable bodies, altered substrates, and weird institutions under branch-lineage labels.
|
||||
|
|
@ -164,5 +165,5 @@ accepted_design:
|
|||
- Ghostlight's technology pipeline should function as a content refinery: ground ideas in lore and mechanics, decompose them into parts and supply chains, map them to Aetheria-Economy blueprint classes, define performance and instance variation, preserve review labels, and produce database-shaped candidates instead of spreadsheet sludge.
|
||||
|
||||
current_status:
|
||||
summary: Ghostlight now has the Epiphany-style persistence spine, the first architecture payload, the v0 canonical agent-state schema seam, prompt projection docs, immediate schema fixes from evaluation, first reviewed Cat/Oz projection examples, a revised Aetheria lore-grounding architecture, a lore grounding digest schema, the first coordinator artifact schema seam, the first responder packet seam, the first draft Cold Wake historical grounding digest, a Cold Wake story-lab fixture, projection controls, validated Qwen capture receipts, a complete Cold Wake short story assembled from accepted projection outputs, a hand-authored Ink-backed Cold Wake branching scene, the first Qwen-generated Ink draft materialized from local awareness with reviewed training annotations, the first reviewed sequential branch mutation that updates both Maer and Sella after a sanctuary intake beat, a v2 sequential Qwen capture proving the symmetrical turn shape produces better action behavior, a v5 sequential Qwen capture proving local thinking-plus-tools invocation works for the scene runner, the first projected-local-context seam that routes sequential prompts through character-local operating prose instead of raw state variables, tightened receipt handling for projector-routed Qwen failures, a default no-thinking policy for strict sequential tool calls, a v10 no-thinking projector-routed capture accepted as draft, the first materialized projector-routed sequential Ink scene with reviewed mutation training data, a source-checked embodiment/interface projection surface for Navigator scenes, a formal source-first Aetheria generation doctrine, v11-v17 source-checked retry receipts showing improved Maer embodiment plus remaining Sella response/prompt-leak blockers, a soft-model training artifact doctrine, a concrete training plan with pilot schema-shakedown gates separated from robust corpus targets, sandboxed responder-data requirements, an explicit future-branch lane, Elysium branch event constraints, and a technology/item manifest plan for turning nebulous named tech into blueprint-grade components, assemblies, faction tech bases, supply chains, upgrade paths, gameplay hooks, provenance-hunting player fantasy, and content-refinery outputs mapped onto Aetheria-Economy's CultCache blueprint and instance model.
|
||||
next_action: Use the responder packet seam for the next fresh generation pass: generate the first actual sandboxed responder output from `examples/responder-packets/scene-02-sanctuary-intake.sella_ren.packet.v0.json` through a packet-only worker, then preserve raw output, reviewed output, hidden-context refs, leakage audit, and coordinator repair labels. Do not call Qwen for gold responder data yet.
|
||||
summary: Ghostlight now has the Epiphany-style persistence spine, the first architecture payload, the v0 canonical agent-state schema seam, prompt projection docs, immediate schema fixes from evaluation, first reviewed Cat/Oz projection examples, a revised Aetheria lore-grounding architecture, a lore grounding digest schema, the first coordinator artifact schema seam, the first responder packet seam, the first sandboxed responder output seam, the first draft Cold Wake historical grounding digest, a Cold Wake story-lab fixture, projection controls, validated Qwen capture receipts, a complete Cold Wake short story assembled from accepted projection outputs, a hand-authored Ink-backed Cold Wake branching scene, the first Qwen-generated Ink draft materialized from local awareness with reviewed training annotations, the first reviewed sequential branch mutation that updates both Maer and Sella after a sanctuary intake beat, a v2 sequential Qwen capture proving the symmetrical turn shape produces better action behavior, a v5 sequential Qwen capture proving local thinking-plus-tools invocation works for the scene runner, the first projected-local-context seam that routes sequential prompts through character-local operating prose instead of raw state variables, tightened receipt handling for projector-routed Qwen failures, a default no-thinking policy for strict sequential tool calls, a v10 no-thinking projector-routed capture accepted as draft, the first materialized projector-routed sequential Ink scene with reviewed mutation training data, a source-checked embodiment/interface projection surface for Navigator scenes, a formal source-first Aetheria generation doctrine, v11-v17 source-checked retry receipts showing improved Maer embodiment plus remaining Sella response/prompt-leak blockers, a soft-model training artifact doctrine, a concrete training plan with pilot schema-shakedown gates separated from robust corpus targets, sandboxed responder-data requirements, an explicit future-branch lane, Elysium branch event constraints, and a technology/item manifest plan for turning nebulous named tech into blueprint-grade components, assemblies, faction tech bases, supply chains, upgrade paths, gameplay hooks, provenance-hunting player fantasy, and content-refinery outputs mapped onto Aetheria-Economy's CultCache blueprint and instance model.
|
||||
next_action: Use the accepted Sella responder capture for the next fresh generation pass: review and materialize the response into the scene-local mutation path. Treat its state and relationship updates as candidates only; consolidate participant appraisals and write a reviewed mutation receipt before changing any canonical fixture. Do not call Qwen for gold responder data yet.
|
||||
|
|
|
|||
185
tools/validate_responder_outputs.py
Normal file
185
tools/validate_responder_outputs.py
Normal file
|
|
@ -0,0 +1,185 @@
|
|||
"""Validate Ghostlight responder output captures."""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
import argparse
|
||||
import json
|
||||
from pathlib import Path
|
||||
from typing import Any
|
||||
|
||||
|
||||
ROOT = Path(__file__).resolve().parents[1]
|
||||
DEFAULT_CAPTURES = sorted((ROOT / "experiments" / "responder-packets").glob("*.capture.json"))
|
||||
REVIEW_STATUSES = {"draft", "accepted", "accepted_as_draft", "useful_needs_revision", "rejected", "superseded"}
|
||||
FIXTURE_LANES = {"historical_grounded", "transition_grounded", "future_branch"}
|
||||
CANON_STATUSES = {"single_history", "branch_local", "promoted_branch", "template", "draft"}
|
||||
ISOLATION_METHODS = {"subagent_no_fork", "manual_packet_only", "external_model_packet_only"}
|
||||
ACTION_LABELS = {
|
||||
"speak",
|
||||
"silence",
|
||||
"gesture",
|
||||
"movement",
|
||||
"inspect_object",
|
||||
"show_object",
|
||||
"withhold_object",
|
||||
"transfer_object",
|
||||
"set_condition",
|
||||
"refuse",
|
||||
"wait",
|
||||
"withdraw",
|
||||
"attack",
|
||||
}
|
||||
LEAK_MARKERS = [
|
||||
"current_activation",
|
||||
"plasticity",
|
||||
"canonical_state",
|
||||
"coordinator rationale",
|
||||
"author-only",
|
||||
"future branch",
|
||||
]
|
||||
|
||||
|
||||
class ValidationError(Exception):
|
||||
pass
|
||||
|
||||
|
||||
def load_json(path: Path) -> Any:
|
||||
return json.loads(path.read_text(encoding="utf-8-sig"))
|
||||
|
||||
|
||||
def require(condition: bool, message: str) -> None:
|
||||
if not condition:
|
||||
raise ValidationError(message)
|
||||
|
||||
|
||||
def require_keys(obj: dict[str, Any], keys: list[str], path: str) -> None:
|
||||
missing = [key for key in keys if key not in obj]
|
||||
require(not missing, f"{path} missing required keys: {', '.join(missing)}")
|
||||
|
||||
|
||||
def require_string(value: Any, path: str) -> None:
|
||||
require(isinstance(value, str) and value.strip(), f"{path} must be a non-empty string")
|
||||
|
||||
|
||||
def require_string_array(value: Any, path: str, *, nonempty: bool = False) -> None:
|
||||
require(isinstance(value, list), f"{path} must be an array")
|
||||
require(not nonempty or bool(value), f"{path} must not be empty")
|
||||
for index, item in enumerate(value):
|
||||
require_string(item, f"{path}[{index}]")
|
||||
|
||||
|
||||
def validate_parsed_response(value: Any, path: str) -> None:
|
||||
require(isinstance(value, dict), f"{path} must be an object")
|
||||
require_keys(
|
||||
value,
|
||||
[
|
||||
"responder_agent_id",
|
||||
"action_label",
|
||||
"visible_action",
|
||||
"spoken_text",
|
||||
"private_interpretation",
|
||||
"intended_effect",
|
||||
"state_update_candidates",
|
||||
"relationship_update_candidates",
|
||||
"unresolved_hooks",
|
||||
],
|
||||
path,
|
||||
)
|
||||
for key in ["responder_agent_id", "action_label", "visible_action", "private_interpretation", "intended_effect"]:
|
||||
require_string(value[key], f"{path}.{key}")
|
||||
require(isinstance(value["spoken_text"], str), f"{path}.spoken_text must be a string")
|
||||
require(value["action_label"] in ACTION_LABELS, f"{path}.action_label is invalid: {value['action_label']}")
|
||||
for key in ["state_update_candidates", "relationship_update_candidates", "unresolved_hooks"]:
|
||||
require_string_array(value[key], f"{path}.{key}")
|
||||
|
||||
|
||||
def validate_capture(document: dict[str, Any], source: Path) -> None:
|
||||
base = str(source)
|
||||
require(document.get("schema_version") == "ghostlight.responder_output.v0", f"{base}.schema_version is wrong")
|
||||
require_keys(
|
||||
document,
|
||||
[
|
||||
"capture_id",
|
||||
"review_status",
|
||||
"fixture_lane",
|
||||
"canon_status",
|
||||
"packet_ref",
|
||||
"coordinator_artifact_ref",
|
||||
"responder_agent_id",
|
||||
"isolation",
|
||||
"raw_output",
|
||||
"parsed_output",
|
||||
"leakage_audit",
|
||||
"coordinator_review",
|
||||
],
|
||||
base,
|
||||
)
|
||||
require(document["review_status"] in REVIEW_STATUSES, f"{base}.review_status is invalid")
|
||||
require(document["fixture_lane"] in FIXTURE_LANES, f"{base}.fixture_lane is invalid")
|
||||
require(document["canon_status"] in CANON_STATUSES, f"{base}.canon_status is invalid")
|
||||
for key in ["capture_id", "packet_ref", "coordinator_artifact_ref", "responder_agent_id", "raw_output"]:
|
||||
require_string(document[key], f"{base}.{key}")
|
||||
require((ROOT / document["packet_ref"]).exists(), f"{base}.packet_ref does not exist")
|
||||
require((ROOT / document["coordinator_artifact_ref"]).exists(), f"{base}.coordinator_artifact_ref does not exist")
|
||||
|
||||
isolation = document["isolation"]
|
||||
require_keys(isolation, ["isolation_method", "fork_context", "visible_input_ref", "hidden_context_refs", "worker_model_family"], f"{base}.isolation")
|
||||
require(isolation["isolation_method"] in ISOLATION_METHODS, f"{base}.isolation.isolation_method is invalid")
|
||||
require(isolation["fork_context"] is False, f"{base}.isolation.fork_context must be false for sandbox captures")
|
||||
require_string(isolation["visible_input_ref"], f"{base}.isolation.visible_input_ref")
|
||||
require_string(isolation["worker_model_family"], f"{base}.isolation.worker_model_family")
|
||||
require_string_array(isolation["hidden_context_refs"], f"{base}.isolation.hidden_context_refs")
|
||||
|
||||
raw_output = document["raw_output"]
|
||||
parsed_raw = json.loads(raw_output)
|
||||
validate_parsed_response(document["parsed_output"], f"{base}.parsed_output")
|
||||
require(parsed_raw == document["parsed_output"], f"{base}.raw_output does not match parsed_output")
|
||||
require(document["parsed_output"]["responder_agent_id"] == document["responder_agent_id"], f"{base}.parsed_output.responder_agent_id mismatch")
|
||||
|
||||
lowered_raw = raw_output.lower()
|
||||
leaked = [marker for marker in LEAK_MARKERS if marker in lowered_raw]
|
||||
require(not leaked, f"{base}.raw_output leaks marker(s): {', '.join(leaked)}")
|
||||
|
||||
audit = document["leakage_audit"]
|
||||
require_keys(
|
||||
audit,
|
||||
[
|
||||
"private_state_leak",
|
||||
"author_only_leak",
|
||||
"future_branch_leak",
|
||||
"raw_state_soup",
|
||||
"prompt_parroting",
|
||||
"body_or_object_omniscience",
|
||||
"notes",
|
||||
],
|
||||
f"{base}.leakage_audit",
|
||||
)
|
||||
for key in ["private_state_leak", "author_only_leak", "future_branch_leak", "raw_state_soup", "prompt_parroting", "body_or_object_omniscience"]:
|
||||
require(isinstance(audit[key], bool), f"{base}.leakage_audit.{key} must be boolean")
|
||||
require_string_array(audit["notes"], f"{base}.leakage_audit.notes")
|
||||
require(not any(audit[key] for key in ["private_state_leak", "author_only_leak", "future_branch_leak", "raw_state_soup", "prompt_parroting", "body_or_object_omniscience"]), f"{base}.leakage_audit has leak flags set")
|
||||
|
||||
review = document["coordinator_review"]
|
||||
require_keys(review, ["reviewer", "accepted_for_training", "review_notes", "coordinator_interventions", "failure_labels"], f"{base}.coordinator_review")
|
||||
require_string(review["reviewer"], f"{base}.coordinator_review.reviewer")
|
||||
require(isinstance(review["accepted_for_training"], bool), f"{base}.coordinator_review.accepted_for_training must be boolean")
|
||||
require(isinstance(review["review_notes"], list), f"{base}.coordinator_review.review_notes must be an array")
|
||||
require(isinstance(review["coordinator_interventions"], list), f"{base}.coordinator_review.coordinator_interventions must be an array")
|
||||
require_string_array(review["failure_labels"], f"{base}.coordinator_review.failure_labels")
|
||||
|
||||
|
||||
def main() -> int:
|
||||
parser = argparse.ArgumentParser(description="Validate Ghostlight responder output captures.")
|
||||
parser.add_argument("paths", nargs="*", type=Path, help="Responder output capture files to validate.")
|
||||
args = parser.parse_args()
|
||||
|
||||
paths = args.paths or DEFAULT_CAPTURES
|
||||
require(paths, "no responder output captures found")
|
||||
for path in paths:
|
||||
validate_capture(load_json(path), path)
|
||||
print(f"ok: {path}")
|
||||
return 0
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
raise SystemExit(main())
|
||||
Loading…
Reference in a new issue