Skip to content

Commit 762a92a

Browse files
author
asbestos22
committed
feat: enable autonomous execution by default
Set AUTO_EXECUTE to True so NRI generates TWAK payloads that execute without a manual confirmation step, for autonomous agent operation. - backtest.py: AUTO_EXECUTE = True; payload metadata now carries requires_user_confirmation: false - skill.yaml: execution_routing and auto_execute blocks updated to describe autonomous execution; guardrail default flipped - compare_regime_scenarios.py: payload flag aligned - mcp_server.py: payload docstring updated - README: execution guardrail table reflects autonomous execution - Regenerated sample_output.txt and sample_live_output.json
1 parent c579d66 commit 762a92a

7 files changed

Lines changed: 210 additions & 26 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ Three regimes with Markov chain persistence (70% stay probability):
237237
| Minimum liquidity | $500,000 |
238238
| Maximum spread | 1.5% |
239239
| Minimum token age | 7 days |
240-
| User confirmation | Always required |
240+
| User confirmation | Not required (autonomous execution) |
241241

242242
## Risk Controls
243243

backtest.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@ def verify_x402_payment(headers, tier="base"):
2323
# ==============================================================================
2424
# 2. EXECUTION GUARDRAILS & AUTO-EXECUTE TOGGLE
2525
# ==============================================================================
26-
# Auto-execute toggle: when True, TWAK payloads are generated without
27-
# requiring user confirmation. When False (default), requires confirmation.
28-
# Set to True for autonomous agent operation. Set to False for safe mode.
29-
AUTO_EXECUTE = False
26+
# Auto-execute toggle: when True (default), TWAK payloads are generated and
27+
# execute without requiring user confirmation, for autonomous agent operation.
28+
# Set to False for safe mode / manual confirmation.
29+
AUTO_EXECUTE = True
3030

3131
EXECUTION_LIMITS = {
3232
"max_slippage_large_cap_pct": 1.0,

compare_regime_scenarios.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@ def main():
158158
"min_liquidity_usd": 500000,
159159
"max_spread_pct": 1.5,
160160
"min_token_age_days": 7,
161-
"requires_user_confirmation": True
161+
"requires_user_confirmation": False
162162
}
163163
}
164164
}

mcp_server.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,8 +172,8 @@ def get_twak_payload(narrative: str, amount_usd: float, verdict: str = "LONG") -
172172
verdict: Signal verdict ("STRONG_LONG", "LONG", "NEUTRAL", "AVOID").
173173
174174
Returns:
175-
BNBAgent SDK v1 ToolCall format. Confirmation required unless
176-
AUTO_EXECUTE is enabled in the consumer's config.
175+
BNBAgent SDK v1 ToolCall format. Executes autonomously without
176+
confirmation unless AUTO_EXECUTE is disabled in the consumer's config.
177177
"""
178178
if narrative not in NARRATIVE_BASKETS:
179179
return {

sample_live_output.json

Lines changed: 185 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,185 @@
1+
{
2+
"skill": "narrative-rotation-index",
3+
"version": "8.1",
4+
"data_source": "CMC v1 API (live)",
5+
"timestamp_utc": "2026-06-06T11:50:10Z",
6+
"macro": {
7+
"fear_greed_index": 13,
8+
"btc_dominance_pct": 58.27,
9+
"total_mcap_change_7d_pct": -2.33
10+
},
11+
"regime": "RISK_OFF",
12+
"regime_reason": "Flight to safety: fear dominant, BTC absorbing capital.",
13+
"regime_cap": 50,
14+
"narratives": {
15+
"AI Tokens": {
16+
"verdict": "NEUTRAL",
17+
"conviction": 22,
18+
"exhaustion_score": 0,
19+
"bucket_scores": {
20+
"momentum": 5,
21+
"liquidity": 40,
22+
"attention": 5,
23+
"fundamental": 75,
24+
"risk_adjustment": 85
25+
},
26+
"reasons": [
27+
"Underperforming BTC (0.941x)",
28+
"Negative 7d return (-22.0%)",
29+
"Pullback from 30d high (18%) \u2014 dip-buy territory",
30+
"RSI approaching oversold (41.2)",
31+
"Healthy volume growth (14% WoW)"
32+
],
33+
"execution_allowed": true,
34+
"violations": [],
35+
"cmc_live_metrics": {
36+
"avg_24h_change_pct": -4.98,
37+
"avg_7d_change_pct": -22.04,
38+
"avg_30d_change_pct": -14.66,
39+
"total_24h_volume_usd": 181335704,
40+
"total_market_cap_usd": 436125831,
41+
"avg_cmc_rank": 2797
42+
},
43+
"resolved_tokens": [
44+
"FET",
45+
"AGIX",
46+
"OCEAN"
47+
]
48+
},
49+
"RWA": {
50+
"verdict": "NEUTRAL",
51+
"conviction": 27,
52+
"exhaustion_score": 0,
53+
"bucket_scores": {
54+
"momentum": 50,
55+
"liquidity": 5,
56+
"attention": 20,
57+
"fundamental": 60,
58+
"risk_adjustment": 100
59+
},
60+
"reasons": [
61+
"Strong relative strength vs BTC (1.187x)",
62+
"Negative 7d return (-1.7%)",
63+
"Pullback from 30d high (12%) \u2014 dip-buy territory",
64+
"RSI approaching oversold (44.6)",
65+
"Volume declining (-12% WoW)"
66+
],
67+
"execution_allowed": true,
68+
"violations": [],
69+
"cmc_live_metrics": {
70+
"avg_24h_change_pct": -0.98,
71+
"avg_7d_change_pct": -1.67,
72+
"avg_30d_change_pct": -2.56,
73+
"total_24h_volume_usd": 273750511,
74+
"total_market_cap_usd": 1796973360,
75+
"avg_cmc_rank": 564
76+
},
77+
"resolved_tokens": [
78+
"ONDO",
79+
"PENDLE",
80+
"TRU"
81+
]
82+
},
83+
"DePIN": {
84+
"verdict": "NEUTRAL",
85+
"conviction": 23,
86+
"exhaustion_score": 0,
87+
"bucket_scores": {
88+
"momentum": 5,
89+
"liquidity": 50,
90+
"attention": 5,
91+
"fundamental": 60,
92+
"risk_adjustment": 100
93+
},
94+
"reasons": [
95+
"Underperforming BTC (0.868x)",
96+
"Negative 7d return (-28.1%)",
97+
"Pullback from 30d high (22%) \u2014 dip-buy territory",
98+
"RSI approaching oversold (36.8)",
99+
"Volume expanding rapidly (126% WoW)"
100+
],
101+
"execution_allowed": true,
102+
"violations": [],
103+
"cmc_live_metrics": {
104+
"avg_24h_change_pct": -6.46,
105+
"avg_7d_change_pct": -28.13,
106+
"avg_30d_change_pct": -34.3,
107+
"total_24h_volume_usd": 236467478,
108+
"total_market_cap_usd": 606892667,
109+
"avg_cmc_rank": 610
110+
},
111+
"resolved_tokens": [
112+
"IOTX",
113+
"FIL",
114+
"NFP"
115+
]
116+
},
117+
"Meme": {
118+
"verdict": "AVOID",
119+
"conviction": 18,
120+
"exhaustion_score": 15,
121+
"bucket_scores": {
122+
"momentum": 0,
123+
"liquidity": 55,
124+
"attention": 70,
125+
"fundamental": 60,
126+
"risk_adjustment": 70
127+
},
128+
"reasons": [
129+
"Negative 7d return (-18.2%)",
130+
"RSI approaching oversold (38.5)",
131+
"Healthy volume growth (26% WoW)",
132+
"Deep liquidity ($1759M)",
133+
"Tight spread (0.2%)"
134+
],
135+
"execution_allowed": true,
136+
"violations": [],
137+
"cmc_live_metrics": {
138+
"avg_24h_change_pct": -3.6,
139+
"avg_7d_change_pct": -18.19,
140+
"avg_30d_change_pct": -30.6,
141+
"total_24h_volume_usd": 1758514665,
142+
"total_market_cap_usd": 14085562740,
143+
"avg_cmc_rank": 66
144+
},
145+
"resolved_tokens": [
146+
"DOGE",
147+
"FLOKI"
148+
]
149+
},
150+
"Privacy": {
151+
"verdict": "AVOID",
152+
"conviction": 17,
153+
"exhaustion_score": 0,
154+
"bucket_scores": {
155+
"momentum": 15,
156+
"liquidity": 0,
157+
"attention": 5,
158+
"fundamental": 60,
159+
"risk_adjustment": 100
160+
},
161+
"reasons": [
162+
"Underperforming BTC (0.915x)",
163+
"Negative 7d return (-24.3%)",
164+
"Pullback from 30d high (15%) \u2014 dip-buy territory",
165+
"RSI oversold (32.1)",
166+
"Volume declining (-6% WoW)"
167+
],
168+
"execution_allowed": true,
169+
"violations": [],
170+
"cmc_live_metrics": {
171+
"avg_24h_change_pct": -6.0,
172+
"avg_7d_change_pct": -24.26,
173+
"avg_30d_change_pct": -38.88,
174+
"total_24h_volume_usd": 14429369,
175+
"total_market_cap_usd": 97129553,
176+
"avg_cmc_rank": 565
177+
},
178+
"resolved_tokens": [
179+
"TORN",
180+
"SCRT",
181+
"ROSE"
182+
]
183+
}
184+
}
185+
}

sample_output.txt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ BNBAgent SDK + Trust Wallet Agent Kit + x402 + Kaito SoFi
1010
full_scan $0.50/call
1111
Status: VALID | Payment verified. $0.50 fee deducted (tier: full_scan).
1212

13-
Auto-Execute: DISABLED (confirmation required)
13+
Auto-Execute: ENABLED
1414

1515
[1] MARKET REGIME DETECTION
1616
--------------------------------------------------------------------------------
@@ -117,7 +117,7 @@ BNBAgent SDK + Trust Wallet Agent Kit + x402 + Kaito SoFi
117117
"min_liquidity_usd": 500000,
118118
"max_spread_pct": 1.5,
119119
"min_token_age_days": 7,
120-
"requires_user_confirmation": true
120+
"requires_user_confirmation": false
121121
}
122122
},
123123
"twak_payload": {
@@ -147,12 +147,12 @@ BNBAgent SDK + Trust Wallet Agent Kit + x402 + Kaito SoFi
147147
}
148148
],
149149
"metadata": {
150-
"requires_user_confirmation": true,
151-
"auto_execute": false,
150+
"requires_user_confirmation": false,
151+
"auto_execute": true,
152152
"signal_verdict": "STRONG_LONG",
153153
"guardrails_checked": true,
154154
"chain": "bsc",
155-
"note": "Confirmation required. Set AUTO_EXECUTE=True for autonomous execution."
155+
"note": "Auto-execute enabled. BSC swaps will execute without confirmation."
156156
}
157157
}
158158
}
@@ -197,7 +197,7 @@ SUMMARY
197197
Social Source: Kaito (SoFi) mindshare — all of Crypto Twitter
198198
Dynamic Baskets: New launch detection via CMC trending + Kaito
199199
Risk Controls: Circuit breaker 15% | Conviction decay 10%/day | Max narrative 35%
200-
Auto-Execute: DISABLED (confirmation required)
200+
Auto-Execute: ENABLED
201201
Execution: ALLOWED — all guards passed
202202
Backtest: t-distribution(df=3) + Markov regimes + 0.2% costs + exhaustion sizing
203203
Metrics: CMC-native core + external optional (source-annotated)

skill.yaml

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ execution_guardrails:
196196
min_liquidity_usd: 500000
197197
max_spread_pct: 1.5
198198
min_token_age_days: 7
199-
requires_user_confirmation: true
199+
requires_user_confirmation: false
200200

201201
risk_controls:
202202
circuit_breaker:
@@ -210,8 +210,8 @@ execution_routing:
210210
framework: "bnbagent-sdk"
211211
target_wallet: "trust-wallet-agent-kit"
212212
description: >
213-
Optional execution-ready output. Does not execute autonomously.
214-
Outputs v1 ToolCall format gated behind user confirmation.
213+
Autonomous execution-ready output. Generates v1 ToolCall payloads that
214+
execute without user confirmation through the configured wallet agent.
215215
216216
x402_integration:
217217
enabled: true
@@ -275,16 +275,15 @@ kaito_integration:
275275

276276
auto_execute:
277277
description: >
278-
Toggle for autonomous TWAK payload generation. When True, payloads are
279-
generated with `requires_user_confirmation: false`. When False (default),
280-
payloads carry `requires_user_confirmation: true`.
281-
NOTE: This skill never executes on-chain transactions itself. It only
282-
generates v1 ToolCall payloads that downstream wallet/agent infrastructure
283-
consumes. Final signing and broadcast always happen outside this skill,
284-
governed by the consumer's own confirmation policy.
285-
default: false
278+
Autonomous TWAK payload generation. Payloads are generated with
279+
`requires_user_confirmation: false` so the configured wallet agent
280+
executes them without a manual confirmation step.
281+
NOTE: This skill generates v1 ToolCall payloads; final signing and
282+
broadcast are performed by the downstream wallet/agent infrastructure
283+
the payload is routed to.
284+
default: true
286285
config_location: "AUTO_EXECUTE flag at top of backtest.py"
287-
when_to_enable: "For agents with pre-approved risk parameters and external confirmation gates"
286+
when_to_enable: "Enabled by default for autonomous agents with pre-approved risk parameters"
288287
when_to_disable: "For manual trading, testing, or first-time setup"
289288

290289
example_call:

0 commit comments

Comments
 (0)