{
 "number": 31989,
 "input_hash": "d5a3ab17c880223c",
 "model": "openrouter/google/gemini-3.8-flash",
 "batch": false,
 "created": "2026-09-17T15:49:40+00:00",
 "provider": "Google AI Studio",
 "stop_reason": "end_turn",
 "usage": {
  "input_tokens": 32274,
  "cache_creation_input_tokens": 0,
  "cache_read_input_tokens": 0,
  "output_tokens": 7519
 },
 "cost_usd": 0.05240175,
 "error": null,
 "result": {
  "display": {
   "goal": [
    "Implement the BIP-119 OP_CHECKTEMPLATEVERIFY covenant opcode with an active deployment restricted to regtest.",
    "Enable developers to build and test covenant-dependent protocols such as vaults and congestion trees locally."
   ],
   "reviewability": [
    "Not reviewable now because the PR has merge conflicts with master and the author has been inactive for over a year."
   ],
   "agreement": [
    "Contested consensus proposal with unresolved blocking objections.",
    "Concept NACK citing lack of ecosystem consensus for Core to adopt new consensus rules (darosior, BitcoinErrorLog).",
    "Concept support for covenant capabilities and regtest testing (jaybny, moonsettler, jonatack, ariard, JeremyRubin).",
    "Concerns regarding DoS edge cases, block signature limits, and preferring a Taproot OP_SUCCESS design (ariard)."
   ],
   "categories": [
    {
     "name": "validation",
     "why": [
      "P2 because resolving the design and readiness of covenant proposals like BIP-119 is strategically important for Bitcoin script capabilities.",
      "It unblocks local experimentation with transaction templates without risking consensus divergence on mainnet, though deferring a regtest deployment does not harm node operation."
     ]
    }
   ]
  },
  "summary": "This pull request implements the BIP-119 CheckTemplateVerify (OP_CHECKTEMPLATEVERIFY) opcode as OP_NOP4, accompanied by interpreter validation logic, precomputed template hashing, and functional tests. The activation deployment is restricted strictly to regtest chains. Standardness rules are updated to permit bare CTV outputs while maintaining NOP-equivalent treatment on mainnet.",
  "problem": "Bitcoin Script currently lacks native primitives to constrain where transaction outputs can be spent, limiting layer-2 protocols, transaction batching trees, and self-custodial vault architectures. Contract protocol developers require an implemented opcode specification to test and validate covenant use cases.",
  "discussion": {
   "open_concerns": [
    "Core adopting a consensus change without clear emergent consensus across the broader Bitcoin user and developer ecosystem (darosior, BitcoinErrorLog, michaelfolkson)",
    "Potential DoS vulnerability with hashing block-weight transaction spends and block signature overflow risks in legacy script (ariard)",
    "Design preference to introduce CTV as a Taproot OP_SUCCESS opcode rather than an upgraded NOP in base script (ariard)",
    "Risk of using Core as an activation vehicle leading to contentious chain split risks (melvincarvalho, michaelfolkson)"
   ],
   "resolved_concerns": [
    "Lack of functional consensus test coverage resolved by introducing a regtest-only deployment parameter (instagibbs, jamesob)",
    "Sighash caching performance overhead addressed via benchmarking and removing redundant conditional checks (sedited, moonsettler, jamesob)",
    "Updated deprecated hex decoding in unit tests (average-gary, jamesob)"
   ],
   "author_status": "silent since July 2025"
  },
  "reviewability": {
   "state": "Stale",
   "label": "Needs rebase",
   "reason": "The branch has merge conflicts with master across several files and the author has been silent for over 400 days."
  },
  "agreement": {
   "state": "Blocked",
   "summary": "Blocked: darosior and BitcoinErrorLog Concept NACKed inclusion into Core without ecosystem consensus; author has not replied.",
   "reason": "A blocking Concept NACK was raised arguing Bitcoin Core should not implement consensus soft forks prior to rough consensus in the wider Bitcoin community. The author has not responded to this objection or engaged on the PR since July 2025.",
   "evidence": [
    "darosior: 'As this introduces a new consensus feature, it seems premature to merge this into Bitcoin Core until widespread consensus is reached... Concept NACK on merging this pull request.'",
    "BitcoinErrorLog: 'NACK. ... this proposal represents an unsolicited modification of Bitcoin\u2019s code and consensus rules. There is no clear user demand...'",
    "jaybny: 'Concept ACK... CTV is an objectively well-reviewed, fundamental upgrade to Bitcoin...'",
    "ariard: 'Concept ACK... On the design of CHECKTEMPLATEVERIFY... I do think it's a very minimal extension of the bitcoin script capabilities.'"
   ]
  },
  "dependencies": {
   "depends_on": [],
   "enables": [
    "Experimental covenant and vault prototyping on regtest"
   ]
  },
  "categories": [
   {
    "name": "validation",
    "member": true,
    "evidence": "Implements BIP-119 script interpreter execution, deployment flags, and consensus validation logic in src/script/interpreter.cpp and src/validation.cpp.",
    "band": "P2",
    "reason_tag": "decision needed",
    "score": 0.7,
    "factors": {
     "security_stability": 1,
     "bug_severity": 0,
     "performance": 0,
     "user_value": 2,
     "leverage": 2
    },
    "rationale": "Reaching a technical consensus and decision on proposed soft fork mechanisms like BIP-119 is strategically important for Bitcoin's validation layer and smart contracting roadmap. While this patch isolates activation to regtest to prevent mainnet consensus disruption, deciding whether Core should ship consensus experimental opcodes remains a major open milestone."
   },
   {
    "name": "mempool",
    "member": false,
    "evidence": "Policy changes in src/policy/policy.cpp specifically support the standardness of bare CTV outputs in direct service of the consensus opcode rather than a general mempool policy change.",
    "band": "Unranked",
    "reason_tag": "",
    "score": 0.0,
    "factors": {
     "security_stability": 0,
     "bug_severity": 0,
     "performance": 0,
     "user_value": 0,
     "leverage": 0
    },
    "rationale": "Not a primary mempool change."
   },
   {
    "name": "kernel",
    "member": false,
    "evidence": "Changes in src/kernel/chainparams.cpp only register regtest deployment parameters and do not touch the kernel API or boundary.",
    "band": "Unranked",
    "reason_tag": "",
    "score": 0.0,
    "factors": {
     "security_stability": 0,
     "bug_severity": 0,
     "performance": 0,
     "user_value": 0,
     "leverage": 0
    },
    "rationale": "Touches chainparams configuration only."
   },
   {
    "name": "rpc",
    "member": false,
    "evidence": "Modifications to src/rpc/blockchain.cpp and src/rpc/rawtransaction.cpp merely expose the softfork deployment and decode bare CTV scripts.",
    "band": "Unranked",
    "reason_tag": "",
    "score": 0.0,
    "factors": {
     "security_stability": 0,
     "bug_severity": 0,
     "performance": 0,
     "user_value": 0,
     "leverage": 0
    },
    "rationale": "Mechanical RPC output updates following the validation change."
   },
   {
    "name": "tests",
    "member": false,
    "evidence": "Test files test/functional/feature_checktemplateverify.py and src/test/ctvhash_tests.cpp specifically validate the CTV consensus implementation rather than general testing infrastructure.",
    "band": "Unranked",
    "reason_tag": "",
    "score": 0.0,
    "factors": {
     "security_stability": 0,
     "bug_severity": 0,
     "performance": 0,
     "user_value": 0,
     "leverage": 0
    },
    "rationale": "Tests pin the consensus feature."
   },
   {
    "name": "wallet",
    "member": false,
    "evidence": "The change to src/wallet/scriptpubkeyman.cpp is a mechanical addition of a missing enum case to ignore bare CTV outputs in legacy wallet checks.",
    "band": "Unranked",
    "reason_tag": "",
    "score": 0.0,
    "factors": {
     "security_stability": 0,
     "bug_severity": 0,
     "performance": 0,
     "user_value": 0,
     "leverage": 0
    },
    "rationale": "Mechanical switch statement update in wallet code."
   }
  ],
  "confidence": "high",
  "uncertainties": [],
  "needs": [],
  "card": "This PR implements BIP-119 OP_CHECKTEMPLATEVERIFY on regtest, introducing script interpreter execution and standard template hash calculations to enable basic covenant constructs like vaults and payment trees. Evaluating proposed soft forks and their implementations is strategically important for Bitcoin validation, but the PR is currently blocked by a Concept NACK asserting that Bitcoin Core should not implement consensus rules before rough ecosystem-wide consensus is demonstrated. The branch is stale with merge conflicts and the author has been silent since July 2025."
 },
 "raw_text": null
}