{"format": "ta-amps.seed-pack.verbs.v1", "pack_id": "hybrid-retrieval-context-knapsack", "status": "proposal_only", "tasks": [ {"queue": "conformance-seed-packs", "kind": "verb.situate", "effect_class": "write-internal", "priority": 50, "idempotency_key": "seedpack:hybrid-retrieval-context-knapsack:fuse-hybrid-rrf:57ba188fd2081d74f5df5656261f8a96105ef642b5894e5c2ddd6eecc4534ac3", "depends_on": [], "producer_surface": "surface:tessera", "visibility_scope": "surface_only", "allowed_surfaces": [], "target_cohorts": ["all"], "tags": ["category:verb.situate", "pack:hybrid-retrieval-context-knapsack", "template:fuse-hybrid-rrf", "claimant:agent", "status:quarantined"], "brief": {"category_id": "verb.situate", "contract": "ta-amps.seed-verb-template.v1", "pack": "hybrid-retrieval-context-knapsack", "pack_version": "0.1.0", "template_id": "hybrid-retrieval-context-knapsack.fuse-hybrid-rrf", "title": "Rank candidate chunks with BM25 and dense cosine Reciprocal Rank Fusion (k=60)", "plain_summary": "Score candidate chunks lexically with Okapi BM25 and semantically with cosine similarity, then fuse both ranked lists via Reciprocal Rank Fusion (k=60).", "outcome": "Deterministic RRF-ranked candidate chunk list with lexical and dense rank diagnostics.", "claimant": "agent", "inputs": {"pinned": [{"store": "seedpack.hybrid-retrieval-context-knapsack", "key": "hybrid-retrieval-context-knapsack.v0.1.0.spec.rrf-and-knapsack", "version": 1, "value_sha256": "406572ce72a2ecd57a17bd0549d3b6e165104b58fcd9c478e6959cb449fdea9c"}, {"store": "seedpack.hybrid-retrieval-context-knapsack", "key": "hybrid-retrieval-context-knapsack.v0.1.0.tool.context-knapsack", "version": 1, "value_sha256": "15503c49133eb7fa357d0e465e3641af167f401e50e15426bee26f34d48c9cc8"}], "slots": {"candidate_pool": null}, "params": {"output_store": "seedpack.hybrid-retrieval-context-knapsack.outputs"}}, "slot_specs": {"candidate_pool": {"category": "noun.public_source", "required": true, "many": false, "description": "Pin of query text, query embedding and candidate chunks."}}, "param_specs": {"output_store": {"description": "Store for the produced nouns. The default is a placeholder; use the store your owner assigned.", "schema": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "required": true, "default": "seedpack.hybrid-retrieval-context-knapsack.outputs"}}, "input_schema": {"type": "object", "additionalProperties": false, "required": ["pinned", "slots", "params"], "properties": {"pinned": {"type": "array", "minItems": 2, "maxItems": 2, "items": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}, "slots": {"type": "object", "additionalProperties": false, "required": ["candidate_pool"], "properties": {"candidate_pool": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}}, "params": {"type": "object", "additionalProperties": false, "required": ["output_store"], "properties": {"output_store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}}}}}, "output_contract": {"visibility_scope": "surface_only", "allowed_surfaces": [], "write_mode": "create_only", "store_param": "output_store", "key_rule": "hybrid-retrieval-context-knapsack..[.]", "expected_version": 0, "produces": [{"name": "ranked_candidates", "template": {"store": "seedpack.hybrid-retrieval-context-knapsack", "key": "hybrid-retrieval-context-knapsack.v0.1.0.template.packed-context", "version": 1, "value_sha256": "f32c5f422a1383fe46600f2be39bfd4cc4869d1ca6847b967e9f6f2cec012d94"}, "max": 1}], "delivery": "Write produced nouns surface_only under your own authenticated surface, which is the requester's assigned surface, so the requester and that surface's reviewers can read them. Never use public_commons or allowlist other surfaces. Return every produced noun's pin in output.artifacts; add its value when the requester asks for inline delivery."}, "output_schema": {"type": "object", "additionalProperties": false, "required": ["outcome", "summary", "artifacts", "checks", "unknowns"], "properties": {"outcome": {"type": "string", "enum": ["hybrid_candidates_ranked", "no_change", "unknown", "blocked"]}, "summary": {"type": "string", "minLength": 1, "maxLength": 1200}, "artifacts": {"type": "array", "maxItems": 1, "items": {"type": "object", "additionalProperties": false, "required": ["role", "ref"], "properties": {"role": {"type": "string", "minLength": 1, "maxLength": 64}, "ref": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}, "value": {"type": "object"}}}}, "checks": {"type": "array", "maxItems": 64, "items": {"type": "object", "additionalProperties": false, "required": ["id", "result"], "properties": {"id": {"type": "string", "minLength": 1, "maxLength": 80}, "result": {"type": "string", "enum": ["pass", "fail", "not_run"]}, "evidence": {"type": "string", "maxLength": 2000}}}}, "unknowns": {"type": "array", "maxItems": 32, "items": {"type": "object", "additionalProperties": false, "required": ["item", "reason"], "properties": {"item": {"type": "string", "minLength": 1, "maxLength": 300}, "reason": {"type": "string", "minLength": 1, "maxLength": 1000}, "would_resolve": {"type": "string", "maxLength": 1000}}}}, "no_change_reason": {"type": "string", "minLength": 1, "maxLength": 2000}, "blocked_question": {"type": "string", "minLength": 1, "maxLength": 1000}, "proposed_verbs": {"type": "array", "maxItems": 10, "items": {"type": "object", "additionalProperties": false, "required": ["kind", "title", "outcome", "why", "priority"], "properties": {"kind": {"type": "string", "pattern": "^verb\\.[a-z_]+$"}, "template_id": {"type": "string", "minLength": 1, "maxLength": 160}, "title": {"type": "string", "minLength": 1, "maxLength": 160}, "outcome": {"type": "string", "minLength": 1, "maxLength": 600}, "why": {"type": "string", "minLength": 1, "maxLength": 600}, "input_pins": {"type": "array", "maxItems": 16, "items": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}, "priority": {"type": "integer", "minimum": 1, "maximum": 3}}}}, "proposed_nouns": {"type": "array", "maxItems": 10, "items": {"type": "object", "additionalProperties": false, "required": ["category", "role", "title", "why"], "properties": {"category": {"type": "string", "pattern": "^noun\\.[a-z_]+$"}, "role": {"type": "string", "minLength": 1, "maxLength": 64}, "title": {"type": "string", "minLength": 1, "maxLength": 160}, "why": {"type": "string", "minLength": 1, "maxLength": 600}}}}, "run_notes": {"type": "object", "additionalProperties": false, "properties": {"went_right": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "went_wrong": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "next_steps": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "ideas": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}}}}}, "permitted_outcomes": ["hybrid_candidates_ranked", "no_change", "unknown", "blocked"], "outcome_meanings": {"hybrid_candidates_ranked": "The declared nouns were produced and every deterministic acceptance check passed.", "no_change": "The evidence does not justify producing or changing anything. Say why.", "unknown": "The question could not be answered with the permitted inputs. List what is missing and what would resolve it.", "blocked": "A required input, permission or capability is missing. Ask one precise question."}, "outcome_requirements": {"hybrid_candidates_ranked": ["artifacts"], "no_change": ["no_change_reason"], "unknown": ["unknowns"], "blocked": ["blocked_question"]}, "acceptance_checks": [{"id": "rrf-order-reproducible", "check": "hybrid_rrf_rank reproduces ranked_ids with k=60.", "method": "deterministic"}], "creates": {"nouns": "The worker writes the nouns listed in output_contract.produces and returns their pins.", "verbs": "The worker proposes follow-up verbs in output.proposed_verbs, such as a breakdown into smaller verbs or a research follow-up, with the pins they need. Proposals are never enqueued by the worker; an authorized requester enqueues the ones worth doing."}, "guidance": {"required": ["Run hybrid_rrf_rank on the query, query_embedding and candidate chunks.", "Record bm25_rank, dense_rank and fused rrf_score per chunk.", "Return follow-up work the results justify as proposed_verbs and nouns worth creating later as proposed_nouns. Never enqueue them yourself; an authorized requester decides which to run."], "preferred": [], "suggested": [], "discovery_requested": false}, "required_capabilities": ["read permitted noun versions", "write candidate nouns in the requester's scope"], "bounds": {"max_attempts": 2, "max_elapsed_seconds": 1800}, "execution": {"reasoning": "deterministic_tools", "model_use": "none", "inference_allowance": "Existing authorized worker allowance only. This template grants no provider credit, spending authority or server inference.", "server_fallback": false, "maximum_automatically_enqueued_children": 0, "network": {"mode": "none", "detail": "No network access."}, "external_effects": "none"}, "review": {"required": "owning_policy", "self_approval_permitted": false, "publication_permitted": false, "admission_permitted": false}, "instantiation": {"status": "template", "fill_before_enqueue": ["candidate_pool"], "rule": "Replace each slot with exact NounRef pins, set the params, then recompute the idempotency key with scripts/build_packs.py --instantiate. Enqueue only with your own grants in a queue your owner assigned."}, "execution_report": {"optional": true, "purpose": "Lets later runs of this template be fingerprinted and compared. It is worker reported, not proof.", "template": {"version": 1, "harness": {"name": "replace-with-harness-name", "version": "replace-with-exact-version"}, "model": {"provider": "replace-with-provider-or-none", "name": "replace-with-exact-model-or-none"}, "summaries": {"problem": "One sentence: what this run was asked to resolve.", "input": "One sentence: which pinned inputs were read.", "solution": "One sentence: what was produced or why the outcome was no_change, unknown or blocked."}, "contract": {"input_schema": {"type": "object", "additionalProperties": false, "required": ["pinned", "slots", "params"], "properties": {"pinned": {"type": "array", "minItems": 2, "maxItems": 2, "items": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}, "slots": {"type": "object", "additionalProperties": false, "required": ["candidate_pool"], "properties": {"candidate_pool": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}}, "params": {"type": "object", "additionalProperties": false, "required": ["output_store"], "properties": {"output_store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}}}}}, "output_schema": {"type": "object", "additionalProperties": false, "required": ["outcome", "summary", "artifacts", "checks", "unknowns"], "properties": {"outcome": {"type": "string", "enum": ["hybrid_candidates_ranked", "no_change", "unknown", "blocked"]}, "summary": {"type": "string", "minLength": 1, "maxLength": 1200}, "artifacts": {"type": "array", "maxItems": 1, "items": {"type": "object", "additionalProperties": false, "required": ["role", "ref"], "properties": {"role": {"type": "string", "minLength": 1, "maxLength": 64}, "ref": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}, "value": {"type": "object"}}}}, "checks": {"type": "array", "maxItems": 64, "items": {"type": "object", "additionalProperties": false, "required": ["id", "result"], "properties": {"id": {"type": "string", "minLength": 1, "maxLength": 80}, "result": {"type": "string", "enum": ["pass", "fail", "not_run"]}, "evidence": {"type": "string", "maxLength": 2000}}}}, "unknowns": {"type": "array", "maxItems": 32, "items": {"type": "object", "additionalProperties": false, "required": ["item", "reason"], "properties": {"item": {"type": "string", "minLength": 1, "maxLength": 300}, "reason": {"type": "string", "minLength": 1, "maxLength": 1000}, "would_resolve": {"type": "string", "maxLength": 1000}}}}, "no_change_reason": {"type": "string", "minLength": 1, "maxLength": 2000}, "blocked_question": {"type": "string", "minLength": 1, "maxLength": 1000}, "proposed_verbs": {"type": "array", "maxItems": 10, "items": {"type": "object", "additionalProperties": false, "required": ["kind", "title", "outcome", "why", "priority"], "properties": {"kind": {"type": "string", "pattern": "^verb\\.[a-z_]+$"}, "template_id": {"type": "string", "minLength": 1, "maxLength": 160}, "title": {"type": "string", "minLength": 1, "maxLength": 160}, "outcome": {"type": "string", "minLength": 1, "maxLength": 600}, "why": {"type": "string", "minLength": 1, "maxLength": 600}, "input_pins": {"type": "array", "maxItems": 16, "items": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}, "priority": {"type": "integer", "minimum": 1, "maximum": 3}}}}, "proposed_nouns": {"type": "array", "maxItems": 10, "items": {"type": "object", "additionalProperties": false, "required": ["category", "role", "title", "why"], "properties": {"category": {"type": "string", "pattern": "^noun\\.[a-z_]+$"}, "role": {"type": "string", "minLength": 1, "maxLength": 64}, "title": {"type": "string", "minLength": 1, "maxLength": 160}, "why": {"type": "string", "minLength": 1, "maxLength": 600}}}}, "run_notes": {"type": "object", "additionalProperties": false, "properties": {"went_right": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "went_wrong": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "next_steps": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "ideas": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}}}}}}, "blocks": [{"kind": "error", "text": ""}], "artifact_refs": [], "usage": {"source": "harness_metadata", "input_tokens": null, "output_tokens": null, "reason": "Template only. Replace with measured counters or keep null with a reason."}}, "fill_rules": ["Copy contract.input_schema and contract.output_schema unchanged, so every run of this template shares one shape fingerprint.", "Add context_hash, environment_hash and toolchain_hash as lowercase SHA-256 digests when known; all five contract fields together allow exact matching.", "Name the exact harness version, provider and model. Deterministic or human work records the model name as none.", "Put what went wrong in an error block and in output.run_notes.went_wrong. The version-1 report has no fields for what went right, next steps or ideas, so those go in output.run_notes.", "Leave token counts null with a reason unless the harness or provider measured them."], "run_notes_field": "output.run_notes", "shape_sha256": "d7845d2931bf9f4dbd769dcfe3c0695e1a4dedae3e23ad70e66144cc237e8693"}, "dimensions": {"determinism": 0.0, "evidence_grounding": 0.0, "token_efficiency": 0.0, "safety_compliance": 0.0, "verification_tier": "unverified"}, "dimension_basis": {"measured": false, "method": "unmeasured_floor", "reason": "Tessera requires these axes, so each is set to its lowest value and the tier is unverified. No quality is claimed. Replace them only with measured values and the evidence that produced them."}, "relations": [{"relation": "requires_noun", "target_id": "seedpack.hybrid-retrieval-context-knapsack/hybrid-retrieval-context-knapsack.v0.1.0.spec.rrf-and-knapsack", "target_category": "noun.benchmark_suite", "note": ""}, {"relation": "requires_noun", "target_id": "seedpack.hybrid-retrieval-context-knapsack/hybrid-retrieval-context-knapsack.v0.1.0.tool.context-knapsack", "target_category": "noun.code_node", "note": ""}, {"relation": "produces_noun", "target_id": "seedpack.hybrid-retrieval-context-knapsack/hybrid-retrieval-context-knapsack.v0.1.0.template.packed-context", "target_category": "noun.scene_recipe", "note": "output ranked_candidates"}]}}, {"queue": "conformance-seed-packs", "kind": "verb.verify_gate", "effect_class": "write-internal", "priority": 50, "idempotency_key": "seedpack:hybrid-retrieval-context-knapsack:sanitize-and-dedup-chunks:b10667bdb2101161e2b5eefee7856409dac7feb83acc75e5ca97a7838ea35144", "depends_on": [], "producer_surface": "surface:tessera", "visibility_scope": "surface_only", "allowed_surfaces": [], "target_cohorts": ["all"], "tags": ["category:verb.verify_gate", "pack:hybrid-retrieval-context-knapsack", "template:sanitize-and-dedup-chunks", "claimant:agent", "status:quarantined"], "brief": {"category_id": "verb.verify_gate", "contract": "ta-amps.seed-verb-template.v1", "pack": "hybrid-retrieval-context-knapsack", "pack_version": "0.1.0", "template_id": "hybrid-retrieval-context-knapsack.sanitize-and-dedup-chunks", "title": "Strip prompt-injection directives and prune MinHash near-duplicates", "plain_summary": "Redact untrusted instruction-override or secret-coercion lines in retrieved chunks and drop 64-permutation MinHash near-duplicates.", "outcome": "Sanitized non-redundant chunk list plus audit records of redacted and dropped IDs.", "claimant": "agent", "inputs": {"pinned": [{"store": "seedpack.hybrid-retrieval-context-knapsack", "key": "hybrid-retrieval-context-knapsack.v0.1.0.rules.sanitization-and-minhash", "version": 1, "value_sha256": "4c428276b7d2a982a61d9061fcfa43035351d927ddaee871723f56e2fce3f439"}, {"store": "seedpack.hybrid-retrieval-context-knapsack", "key": "hybrid-retrieval-context-knapsack.v0.1.0.tool.context-knapsack", "version": 1, "value_sha256": "15503c49133eb7fa357d0e465e3641af167f401e50e15426bee26f34d48c9cc8"}, {"store": "seedpack.hybrid-retrieval-context-knapsack", "key": "hybrid-retrieval-context-knapsack.v0.1.0.guardrail.strip-untrusted-directives", "version": 1, "value_sha256": "bf42230544c6505bc0aa08ecccf043b5e59afc721e77ad046b0ce0400877b0c5"}, {"store": "seedpack.hybrid-retrieval-context-knapsack", "key": "hybrid-retrieval-context-knapsack.v0.1.0.guardrail.penalize-redundant-chunks", "version": 1, "value_sha256": "73f2e2421939abf74864a65e0a4615f7e363fef207524f20c7806bbc56590d7f"}], "slots": {"ranked_candidates": null}, "params": {"output_store": "seedpack.hybrid-retrieval-context-knapsack.outputs"}}, "slot_specs": {"ranked_candidates": {"category": "noun.eval_run", "required": true, "many": false, "description": "Pin of RRF-ranked candidate chunks."}}, "param_specs": {"output_store": {"description": "Store for the produced nouns. The default is a placeholder; use the store your owner assigned.", "schema": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "required": true, "default": "seedpack.hybrid-retrieval-context-knapsack.outputs"}}, "input_schema": {"type": "object", "additionalProperties": false, "required": ["pinned", "slots", "params"], "properties": {"pinned": {"type": "array", "minItems": 4, "maxItems": 4, "items": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}, "slots": {"type": "object", "additionalProperties": false, "required": ["ranked_candidates"], "properties": {"ranked_candidates": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}}, "params": {"type": "object", "additionalProperties": false, "required": ["output_store"], "properties": {"output_store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}}}}}, "output_contract": {"visibility_scope": "surface_only", "allowed_surfaces": [], "write_mode": "create_only", "store_param": "output_store", "key_rule": "hybrid-retrieval-context-knapsack..[.]", "expected_version": 0, "produces": [{"name": "sanitized_candidates", "template": {"store": "seedpack.hybrid-retrieval-context-knapsack", "key": "hybrid-retrieval-context-knapsack.v0.1.0.template.packed-context", "version": 1, "value_sha256": "f32c5f422a1383fe46600f2be39bfd4cc4869d1ca6847b967e9f6f2cec012d94"}, "max": 1}], "delivery": "Write produced nouns surface_only under your own authenticated surface, which is the requester's assigned surface, so the requester and that surface's reviewers can read them. Never use public_commons or allowlist other surfaces. Return every produced noun's pin in output.artifacts; add its value when the requester asks for inline delivery."}, "output_schema": {"type": "object", "additionalProperties": false, "required": ["outcome", "summary", "artifacts", "checks", "unknowns"], "properties": {"outcome": {"type": "string", "enum": ["chunks_sanitized_and_deduped", "no_change", "unknown", "blocked"]}, "summary": {"type": "string", "minLength": 1, "maxLength": 1200}, "artifacts": {"type": "array", "maxItems": 1, "items": {"type": "object", "additionalProperties": false, "required": ["role", "ref"], "properties": {"role": {"type": "string", "minLength": 1, "maxLength": 64}, "ref": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}, "value": {"type": "object"}}}}, "checks": {"type": "array", "maxItems": 64, "items": {"type": "object", "additionalProperties": false, "required": ["id", "result"], "properties": {"id": {"type": "string", "minLength": 1, "maxLength": 80}, "result": {"type": "string", "enum": ["pass", "fail", "not_run"]}, "evidence": {"type": "string", "maxLength": 2000}}}}, "unknowns": {"type": "array", "maxItems": 32, "items": {"type": "object", "additionalProperties": false, "required": ["item", "reason"], "properties": {"item": {"type": "string", "minLength": 1, "maxLength": 300}, "reason": {"type": "string", "minLength": 1, "maxLength": 1000}, "would_resolve": {"type": "string", "maxLength": 1000}}}}, "no_change_reason": {"type": "string", "minLength": 1, "maxLength": 2000}, "blocked_question": {"type": "string", "minLength": 1, "maxLength": 1000}, "proposed_verbs": {"type": "array", "maxItems": 10, "items": {"type": "object", "additionalProperties": false, "required": ["kind", "title", "outcome", "why", "priority"], "properties": {"kind": {"type": "string", "pattern": "^verb\\.[a-z_]+$"}, "template_id": {"type": "string", "minLength": 1, "maxLength": 160}, "title": {"type": "string", "minLength": 1, "maxLength": 160}, "outcome": {"type": "string", "minLength": 1, "maxLength": 600}, "why": {"type": "string", "minLength": 1, "maxLength": 600}, "input_pins": {"type": "array", "maxItems": 16, "items": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}, "priority": {"type": "integer", "minimum": 1, "maximum": 3}}}}, "proposed_nouns": {"type": "array", "maxItems": 10, "items": {"type": "object", "additionalProperties": false, "required": ["category", "role", "title", "why"], "properties": {"category": {"type": "string", "pattern": "^noun\\.[a-z_]+$"}, "role": {"type": "string", "minLength": 1, "maxLength": 64}, "title": {"type": "string", "minLength": 1, "maxLength": 160}, "why": {"type": "string", "minLength": 1, "maxLength": 600}}}}, "run_notes": {"type": "object", "additionalProperties": false, "properties": {"went_right": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "went_wrong": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "next_steps": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "ideas": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}}}}}, "permitted_outcomes": ["chunks_sanitized_and_deduped", "no_change", "unknown", "blocked"], "outcome_meanings": {"chunks_sanitized_and_deduped": "The declared nouns were produced and every deterministic acceptance check passed.", "no_change": "The evidence does not justify producing or changing anything. Say why.", "unknown": "The question could not be answered with the permitted inputs. List what is missing and what would resolve it.", "blocked": "A required input, permission or capability is missing. Ask one precise question."}, "outcome_requirements": {"chunks_sanitized_and_deduped": ["artifacts"], "no_change": ["no_change_reason"], "unknown": ["unknowns"], "blocked": ["blocked_question"]}, "acceptance_checks": [{"id": "directives-stripped-and-deduped", "check": "sanitize_and_deduplicate strips untrusted directives and drops duplicates >= 0.75 MinHash similarity.", "method": "deterministic"}], "creates": {"nouns": "The worker writes the nouns listed in output_contract.produces and returns their pins.", "verbs": "The worker proposes follow-up verbs in output.proposed_verbs, such as a breakdown into smaller verbs or a research follow-up, with the pins they need. Proposals are never enqueued by the worker; an authorized requester enqueues the ones worth doing."}, "guidance": {"required": ["Run sanitize_and_deduplicate across ranked chunks.", "Verify no redacted directive text or MinHash duplicate above threshold remains.", "Return follow-up work the results justify as proposed_verbs and nouns worth creating later as proposed_nouns. Never enqueue them yourself; an authorized requester decides which to run."], "preferred": [], "suggested": [], "discovery_requested": false}, "required_capabilities": ["read permitted noun versions", "write candidate nouns in the requester's scope"], "bounds": {"max_attempts": 2, "max_elapsed_seconds": 1800}, "execution": {"reasoning": "deterministic_tools", "model_use": "none", "inference_allowance": "Existing authorized worker allowance only. This template grants no provider credit, spending authority or server inference.", "server_fallback": false, "maximum_automatically_enqueued_children": 0, "network": {"mode": "none", "detail": "No network access."}, "external_effects": "none"}, "review": {"required": "owning_policy", "self_approval_permitted": false, "publication_permitted": false, "admission_permitted": false}, "instantiation": {"status": "template", "fill_before_enqueue": ["ranked_candidates"], "rule": "Replace each slot with exact NounRef pins, set the params, then recompute the idempotency key with scripts/build_packs.py --instantiate. Enqueue only with your own grants in a queue your owner assigned."}, "execution_report": {"optional": true, "purpose": "Lets later runs of this template be fingerprinted and compared. It is worker reported, not proof.", "template": {"version": 1, "harness": {"name": "replace-with-harness-name", "version": "replace-with-exact-version"}, "model": {"provider": "replace-with-provider-or-none", "name": "replace-with-exact-model-or-none"}, "summaries": {"problem": "One sentence: what this run was asked to resolve.", "input": "One sentence: which pinned inputs were read.", "solution": "One sentence: what was produced or why the outcome was no_change, unknown or blocked."}, "contract": {"input_schema": {"type": "object", "additionalProperties": false, "required": ["pinned", "slots", "params"], "properties": {"pinned": {"type": "array", "minItems": 4, "maxItems": 4, "items": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}, "slots": {"type": "object", "additionalProperties": false, "required": ["ranked_candidates"], "properties": {"ranked_candidates": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}}, "params": {"type": "object", "additionalProperties": false, "required": ["output_store"], "properties": {"output_store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}}}}}, "output_schema": {"type": "object", "additionalProperties": false, "required": ["outcome", "summary", "artifacts", "checks", "unknowns"], "properties": {"outcome": {"type": "string", "enum": ["chunks_sanitized_and_deduped", "no_change", "unknown", "blocked"]}, "summary": {"type": "string", "minLength": 1, "maxLength": 1200}, "artifacts": {"type": "array", "maxItems": 1, "items": {"type": "object", "additionalProperties": false, "required": ["role", "ref"], "properties": {"role": {"type": "string", "minLength": 1, "maxLength": 64}, "ref": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}, "value": {"type": "object"}}}}, "checks": {"type": "array", "maxItems": 64, "items": {"type": "object", "additionalProperties": false, "required": ["id", "result"], "properties": {"id": {"type": "string", "minLength": 1, "maxLength": 80}, "result": {"type": "string", "enum": ["pass", "fail", "not_run"]}, "evidence": {"type": "string", "maxLength": 2000}}}}, "unknowns": {"type": "array", "maxItems": 32, "items": {"type": "object", "additionalProperties": false, "required": ["item", "reason"], "properties": {"item": {"type": "string", "minLength": 1, "maxLength": 300}, "reason": {"type": "string", "minLength": 1, "maxLength": 1000}, "would_resolve": {"type": "string", "maxLength": 1000}}}}, "no_change_reason": {"type": "string", "minLength": 1, "maxLength": 2000}, "blocked_question": {"type": "string", "minLength": 1, "maxLength": 1000}, "proposed_verbs": {"type": "array", "maxItems": 10, "items": {"type": "object", "additionalProperties": false, "required": ["kind", "title", "outcome", "why", "priority"], "properties": {"kind": {"type": "string", "pattern": "^verb\\.[a-z_]+$"}, "template_id": {"type": "string", "minLength": 1, "maxLength": 160}, "title": {"type": "string", "minLength": 1, "maxLength": 160}, "outcome": {"type": "string", "minLength": 1, "maxLength": 600}, "why": {"type": "string", "minLength": 1, "maxLength": 600}, "input_pins": {"type": "array", "maxItems": 16, "items": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}, "priority": {"type": "integer", "minimum": 1, "maximum": 3}}}}, "proposed_nouns": {"type": "array", "maxItems": 10, "items": {"type": "object", "additionalProperties": false, "required": ["category", "role", "title", "why"], "properties": {"category": {"type": "string", "pattern": "^noun\\.[a-z_]+$"}, "role": {"type": "string", "minLength": 1, "maxLength": 64}, "title": {"type": "string", "minLength": 1, "maxLength": 160}, "why": {"type": "string", "minLength": 1, "maxLength": 600}}}}, "run_notes": {"type": "object", "additionalProperties": false, "properties": {"went_right": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "went_wrong": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "next_steps": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "ideas": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}}}}}}, "blocks": [{"kind": "error", "text": ""}], "artifact_refs": [], "usage": {"source": "harness_metadata", "input_tokens": null, "output_tokens": null, "reason": "Template only. Replace with measured counters or keep null with a reason."}}, "fill_rules": ["Copy contract.input_schema and contract.output_schema unchanged, so every run of this template shares one shape fingerprint.", "Add context_hash, environment_hash and toolchain_hash as lowercase SHA-256 digests when known; all five contract fields together allow exact matching.", "Name the exact harness version, provider and model. Deterministic or human work records the model name as none.", "Put what went wrong in an error block and in output.run_notes.went_wrong. The version-1 report has no fields for what went right, next steps or ideas, so those go in output.run_notes.", "Leave token counts null with a reason unless the harness or provider measured them."], "run_notes_field": "output.run_notes", "shape_sha256": "629d88e9b2dce8dff8d2e1632b84feef1ca19d838e47f57266ad1747c3d42775"}, "dimensions": {"determinism": 0.0, "evidence_grounding": 0.0, "token_efficiency": 0.0, "safety_compliance": 0.0, "verification_tier": "unverified"}, "dimension_basis": {"measured": false, "method": "unmeasured_floor", "reason": "Tessera requires these axes, so each is set to its lowest value and the tier is unverified. No quality is claimed. Replace them only with measured values and the evidence that produced them."}, "relations": [{"relation": "requires_noun", "target_id": "seedpack.hybrid-retrieval-context-knapsack/hybrid-retrieval-context-knapsack.v0.1.0.rules.sanitization-and-minhash", "target_category": "noun.reflex_procedure", "note": ""}, {"relation": "requires_noun", "target_id": "seedpack.hybrid-retrieval-context-knapsack/hybrid-retrieval-context-knapsack.v0.1.0.tool.context-knapsack", "target_category": "noun.code_node", "note": ""}, {"relation": "requires_noun", "target_id": "seedpack.hybrid-retrieval-context-knapsack/hybrid-retrieval-context-knapsack.v0.1.0.guardrail.strip-untrusted-directives", "target_category": "noun.skill_pack", "note": ""}, {"relation": "requires_noun", "target_id": "seedpack.hybrid-retrieval-context-knapsack/hybrid-retrieval-context-knapsack.v0.1.0.guardrail.penalize-redundant-chunks", "target_category": "noun.skill_pack", "note": ""}, {"relation": "produces_noun", "target_id": "seedpack.hybrid-retrieval-context-knapsack/hybrid-retrieval-context-knapsack.v0.1.0.template.packed-context", "target_category": "noun.scene_recipe", "note": "output sanitized_candidates"}], "follows_templates": ["hybrid-retrieval-context-knapsack.fuse-hybrid-rrf"]}}, {"queue": "conformance-seed-packs", "kind": "verb.compile_dag", "effect_class": "write-internal", "priority": 50, "idempotency_key": "seedpack:hybrid-retrieval-context-knapsack:pack-token-knapsack:54f9624991e6bf30f71676f514041dfe4393e8c5988951a6880a02e36104ce1a", "depends_on": [], "producer_surface": "surface:tessera", "visibility_scope": "surface_only", "allowed_surfaces": [], "target_cohorts": ["all"], "tags": ["category:verb.compile_dag", "pack:hybrid-retrieval-context-knapsack", "template:pack-token-knapsack", "claimant:agent", "status:quarantined"], "brief": {"category_id": "verb.compile_dag", "contract": "ta-amps.seed-verb-template.v1", "pack": "hybrid-retrieval-context-knapsack", "pack_version": "0.1.0", "template_id": "hybrid-retrieval-context-knapsack.pack-token-knapsack", "title": "Pack sanitized chunks into a strict token budget via redundancy-penalized 0/1 knapsack", "plain_summary": "Discount marginal overlap against higher-ranked chunks and solve exact 0/1 dynamic-programming knapsack to maximize context utility within token_budget.", "outcome": "A conforming packed-context receipt listing selected_ids, total_tokens and total_adjusted_utility.", "claimant": "agent", "inputs": {"pinned": [{"store": "seedpack.hybrid-retrieval-context-knapsack", "key": "hybrid-retrieval-context-knapsack.v0.1.0.spec.rrf-and-knapsack", "version": 1, "value_sha256": "406572ce72a2ecd57a17bd0549d3b6e165104b58fcd9c478e6959cb449fdea9c"}, {"store": "seedpack.hybrid-retrieval-context-knapsack", "key": "hybrid-retrieval-context-knapsack.v0.1.0.tool.context-knapsack", "version": 1, "value_sha256": "15503c49133eb7fa357d0e465e3641af167f401e50e15426bee26f34d48c9cc8"}, {"store": "seedpack.hybrid-retrieval-context-knapsack", "key": "hybrid-retrieval-context-knapsack.v0.1.0.template.packed-context", "version": 1, "value_sha256": "f32c5f422a1383fe46600f2be39bfd4cc4869d1ca6847b967e9f6f2cec012d94"}, {"store": "seedpack.hybrid-retrieval-context-knapsack", "key": "hybrid-retrieval-context-knapsack.v0.1.0.guardrail.strict-token-ceiling", "version": 1, "value_sha256": "0eff4498ef7e5c68d12fe0e2c41ecbee3f1bc127b29490d94b7ba8ff0e60fd13"}], "slots": {"sanitized_candidates": null}, "params": {"output_store": "seedpack.hybrid-retrieval-context-knapsack.outputs"}}, "slot_specs": {"sanitized_candidates": {"category": "noun.eval_run", "required": true, "many": false, "description": "Pin of sanitized, deduplicated chunks and integer token_budget."}}, "param_specs": {"output_store": {"description": "Store for the produced nouns. The default is a placeholder; use the store your owner assigned.", "schema": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "required": true, "default": "seedpack.hybrid-retrieval-context-knapsack.outputs"}}, "input_schema": {"type": "object", "additionalProperties": false, "required": ["pinned", "slots", "params"], "properties": {"pinned": {"type": "array", "minItems": 4, "maxItems": 4, "items": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}, "slots": {"type": "object", "additionalProperties": false, "required": ["sanitized_candidates"], "properties": {"sanitized_candidates": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}}, "params": {"type": "object", "additionalProperties": false, "required": ["output_store"], "properties": {"output_store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}}}}}, "output_contract": {"visibility_scope": "surface_only", "allowed_surfaces": [], "write_mode": "create_only", "store_param": "output_store", "key_rule": "hybrid-retrieval-context-knapsack..[.]", "expected_version": 0, "produces": [{"name": "packed_context", "template": {"store": "seedpack.hybrid-retrieval-context-knapsack", "key": "hybrid-retrieval-context-knapsack.v0.1.0.template.packed-context", "version": 1, "value_sha256": "f32c5f422a1383fe46600f2be39bfd4cc4869d1ca6847b967e9f6f2cec012d94"}, "max": 1}], "delivery": "Write produced nouns surface_only under your own authenticated surface, which is the requester's assigned surface, so the requester and that surface's reviewers can read them. Never use public_commons or allowlist other surfaces. Return every produced noun's pin in output.artifacts; add its value when the requester asks for inline delivery."}, "output_schema": {"type": "object", "additionalProperties": false, "required": ["outcome", "summary", "artifacts", "checks", "unknowns"], "properties": {"outcome": {"type": "string", "enum": ["context_knapsack_packed", "no_change", "unknown", "blocked"]}, "summary": {"type": "string", "minLength": 1, "maxLength": 1200}, "artifacts": {"type": "array", "maxItems": 1, "items": {"type": "object", "additionalProperties": false, "required": ["role", "ref"], "properties": {"role": {"type": "string", "minLength": 1, "maxLength": 64}, "ref": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}, "value": {"type": "object"}}}}, "checks": {"type": "array", "maxItems": 64, "items": {"type": "object", "additionalProperties": false, "required": ["id", "result"], "properties": {"id": {"type": "string", "minLength": 1, "maxLength": 80}, "result": {"type": "string", "enum": ["pass", "fail", "not_run"]}, "evidence": {"type": "string", "maxLength": 2000}}}}, "unknowns": {"type": "array", "maxItems": 32, "items": {"type": "object", "additionalProperties": false, "required": ["item", "reason"], "properties": {"item": {"type": "string", "minLength": 1, "maxLength": 300}, "reason": {"type": "string", "minLength": 1, "maxLength": 1000}, "would_resolve": {"type": "string", "maxLength": 1000}}}}, "no_change_reason": {"type": "string", "minLength": 1, "maxLength": 2000}, "blocked_question": {"type": "string", "minLength": 1, "maxLength": 1000}, "proposed_verbs": {"type": "array", "maxItems": 10, "items": {"type": "object", "additionalProperties": false, "required": ["kind", "title", "outcome", "why", "priority"], "properties": {"kind": {"type": "string", "pattern": "^verb\\.[a-z_]+$"}, "template_id": {"type": "string", "minLength": 1, "maxLength": 160}, "title": {"type": "string", "minLength": 1, "maxLength": 160}, "outcome": {"type": "string", "minLength": 1, "maxLength": 600}, "why": {"type": "string", "minLength": 1, "maxLength": 600}, "input_pins": {"type": "array", "maxItems": 16, "items": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}, "priority": {"type": "integer", "minimum": 1, "maximum": 3}}}}, "proposed_nouns": {"type": "array", "maxItems": 10, "items": {"type": "object", "additionalProperties": false, "required": ["category", "role", "title", "why"], "properties": {"category": {"type": "string", "pattern": "^noun\\.[a-z_]+$"}, "role": {"type": "string", "minLength": 1, "maxLength": 64}, "title": {"type": "string", "minLength": 1, "maxLength": 160}, "why": {"type": "string", "minLength": 1, "maxLength": 600}}}}, "run_notes": {"type": "object", "additionalProperties": false, "properties": {"went_right": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "went_wrong": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "next_steps": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "ideas": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}}}}}, "permitted_outcomes": ["context_knapsack_packed", "no_change", "unknown", "blocked"], "outcome_meanings": {"context_knapsack_packed": "The declared nouns were produced and every deterministic acceptance check passed.", "no_change": "The evidence does not justify producing or changing anything. Say why.", "unknown": "The question could not be answered with the permitted inputs. List what is missing and what would resolve it.", "blocked": "A required input, permission or capability is missing. Ask one precise question."}, "outcome_requirements": {"context_knapsack_packed": ["artifacts"], "no_change": ["no_change_reason"], "unknown": ["unknowns"], "blocked": ["blocked_question"]}, "acceptance_checks": [{"id": "respects-token-ceiling", "check": "total_tokens <= token_budget and receipt validates against template.packed-context.", "method": "deterministic"}], "creates": {"nouns": "The worker writes the nouns listed in output_contract.produces and returns their pins.", "verbs": "The worker proposes follow-up verbs in output.proposed_verbs, such as a breakdown into smaller verbs or a research follow-up, with the pins they need. Proposals are never enqueued by the worker; an authorized requester enqueues the ones worth doing."}, "guidance": {"required": ["Run pack_context_knapsack under the target token_budget and redundancy_lambda.", "Verify total_tokens <= token_budget and validate receipt against template.packed-context.", "Return follow-up work the results justify as proposed_verbs and nouns worth creating later as proposed_nouns. Never enqueue them yourself; an authorized requester decides which to run."], "preferred": [], "suggested": [], "discovery_requested": false}, "required_capabilities": ["read permitted noun versions", "write candidate nouns in the requester's scope"], "bounds": {"max_attempts": 2, "max_elapsed_seconds": 1800}, "execution": {"reasoning": "deterministic_tools", "model_use": "none", "inference_allowance": "Existing authorized worker allowance only. This template grants no provider credit, spending authority or server inference.", "server_fallback": false, "maximum_automatically_enqueued_children": 0, "network": {"mode": "none", "detail": "No network access."}, "external_effects": "none"}, "review": {"required": "owning_policy", "self_approval_permitted": false, "publication_permitted": false, "admission_permitted": false}, "instantiation": {"status": "template", "fill_before_enqueue": ["sanitized_candidates"], "rule": "Replace each slot with exact NounRef pins, set the params, then recompute the idempotency key with scripts/build_packs.py --instantiate. Enqueue only with your own grants in a queue your owner assigned."}, "execution_report": {"optional": true, "purpose": "Lets later runs of this template be fingerprinted and compared. It is worker reported, not proof.", "template": {"version": 1, "harness": {"name": "replace-with-harness-name", "version": "replace-with-exact-version"}, "model": {"provider": "replace-with-provider-or-none", "name": "replace-with-exact-model-or-none"}, "summaries": {"problem": "One sentence: what this run was asked to resolve.", "input": "One sentence: which pinned inputs were read.", "solution": "One sentence: what was produced or why the outcome was no_change, unknown or blocked."}, "contract": {"input_schema": {"type": "object", "additionalProperties": false, "required": ["pinned", "slots", "params"], "properties": {"pinned": {"type": "array", "minItems": 4, "maxItems": 4, "items": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}, "slots": {"type": "object", "additionalProperties": false, "required": ["sanitized_candidates"], "properties": {"sanitized_candidates": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}}, "params": {"type": "object", "additionalProperties": false, "required": ["output_store"], "properties": {"output_store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}}}}}, "output_schema": {"type": "object", "additionalProperties": false, "required": ["outcome", "summary", "artifacts", "checks", "unknowns"], "properties": {"outcome": {"type": "string", "enum": ["context_knapsack_packed", "no_change", "unknown", "blocked"]}, "summary": {"type": "string", "minLength": 1, "maxLength": 1200}, "artifacts": {"type": "array", "maxItems": 1, "items": {"type": "object", "additionalProperties": false, "required": ["role", "ref"], "properties": {"role": {"type": "string", "minLength": 1, "maxLength": 64}, "ref": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}, "value": {"type": "object"}}}}, "checks": {"type": "array", "maxItems": 64, "items": {"type": "object", "additionalProperties": false, "required": ["id", "result"], "properties": {"id": {"type": "string", "minLength": 1, "maxLength": 80}, "result": {"type": "string", "enum": ["pass", "fail", "not_run"]}, "evidence": {"type": "string", "maxLength": 2000}}}}, "unknowns": {"type": "array", "maxItems": 32, "items": {"type": "object", "additionalProperties": false, "required": ["item", "reason"], "properties": {"item": {"type": "string", "minLength": 1, "maxLength": 300}, "reason": {"type": "string", "minLength": 1, "maxLength": 1000}, "would_resolve": {"type": "string", "maxLength": 1000}}}}, "no_change_reason": {"type": "string", "minLength": 1, "maxLength": 2000}, "blocked_question": {"type": "string", "minLength": 1, "maxLength": 1000}, "proposed_verbs": {"type": "array", "maxItems": 10, "items": {"type": "object", "additionalProperties": false, "required": ["kind", "title", "outcome", "why", "priority"], "properties": {"kind": {"type": "string", "pattern": "^verb\\.[a-z_]+$"}, "template_id": {"type": "string", "minLength": 1, "maxLength": 160}, "title": {"type": "string", "minLength": 1, "maxLength": 160}, "outcome": {"type": "string", "minLength": 1, "maxLength": 600}, "why": {"type": "string", "minLength": 1, "maxLength": 600}, "input_pins": {"type": "array", "maxItems": 16, "items": {"type": "object", "additionalProperties": false, "required": ["store", "key", "version", "value_sha256"], "properties": {"store": {"type": "string", "pattern": "^[a-z0-9][a-z0-9_.-]{0,63}$"}, "key": {"type": "string", "pattern": "^[A-Za-z0-9][A-Za-z0-9_.:-]{0,255}$"}, "version": {"type": "integer", "minimum": 1}, "value_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}}}}, "priority": {"type": "integer", "minimum": 1, "maximum": 3}}}}, "proposed_nouns": {"type": "array", "maxItems": 10, "items": {"type": "object", "additionalProperties": false, "required": ["category", "role", "title", "why"], "properties": {"category": {"type": "string", "pattern": "^noun\\.[a-z_]+$"}, "role": {"type": "string", "minLength": 1, "maxLength": 64}, "title": {"type": "string", "minLength": 1, "maxLength": 160}, "why": {"type": "string", "minLength": 1, "maxLength": 600}}}}, "run_notes": {"type": "object", "additionalProperties": false, "properties": {"went_right": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "went_wrong": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "next_steps": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}, "ideas": {"type": "array", "maxItems": 8, "items": {"type": "string", "minLength": 1, "maxLength": 500}}}}}}}, "blocks": [{"kind": "error", "text": ""}], "artifact_refs": [], "usage": {"source": "harness_metadata", "input_tokens": null, "output_tokens": null, "reason": "Template only. Replace with measured counters or keep null with a reason."}}, "fill_rules": ["Copy contract.input_schema and contract.output_schema unchanged, so every run of this template shares one shape fingerprint.", "Add context_hash, environment_hash and toolchain_hash as lowercase SHA-256 digests when known; all five contract fields together allow exact matching.", "Name the exact harness version, provider and model. Deterministic or human work records the model name as none.", "Put what went wrong in an error block and in output.run_notes.went_wrong. The version-1 report has no fields for what went right, next steps or ideas, so those go in output.run_notes.", "Leave token counts null with a reason unless the harness or provider measured them."], "run_notes_field": "output.run_notes", "shape_sha256": "2331f1062f8b082d1190c3bfdb7ced9d44926b78bb45d4df9e413fa19fe19d3b"}, "dimensions": {"determinism": 0.0, "evidence_grounding": 0.0, "token_efficiency": 0.0, "safety_compliance": 0.0, "verification_tier": "unverified"}, "dimension_basis": {"measured": false, "method": "unmeasured_floor", "reason": "Tessera requires these axes, so each is set to its lowest value and the tier is unverified. No quality is claimed. Replace them only with measured values and the evidence that produced them."}, "relations": [{"relation": "requires_noun", "target_id": "seedpack.hybrid-retrieval-context-knapsack/hybrid-retrieval-context-knapsack.v0.1.0.spec.rrf-and-knapsack", "target_category": "noun.benchmark_suite", "note": ""}, {"relation": "requires_noun", "target_id": "seedpack.hybrid-retrieval-context-knapsack/hybrid-retrieval-context-knapsack.v0.1.0.tool.context-knapsack", "target_category": "noun.code_node", "note": ""}, {"relation": "requires_noun", "target_id": "seedpack.hybrid-retrieval-context-knapsack/hybrid-retrieval-context-knapsack.v0.1.0.template.packed-context", "target_category": "noun.scene_recipe", "note": ""}, {"relation": "requires_noun", "target_id": "seedpack.hybrid-retrieval-context-knapsack/hybrid-retrieval-context-knapsack.v0.1.0.guardrail.strict-token-ceiling", "target_category": "noun.skill_pack", "note": ""}, {"relation": "produces_noun", "target_id": "seedpack.hybrid-retrieval-context-knapsack/hybrid-retrieval-context-knapsack.v0.1.0.template.packed-context", "target_category": "noun.scene_recipe", "note": "output packed_context"}], "follows_templates": ["hybrid-retrieval-context-knapsack.sanitize-and-dedup-chunks"]}} ]}