traderclaw-cli 1.0.91 → 1.0.92

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -756,6 +756,14 @@ function buildOpenClawCronStoreJob(def) {
756
756
  .split("-")
757
757
  .map((w) => (w.length ? w.charAt(0).toUpperCase() + w.slice(1) : w))
758
758
  .join(" ");
759
+ const payload = {
760
+ kind: "agentTurn",
761
+ message: def.message,
762
+ lightContext: def.lightContext !== undefined ? def.lightContext : true,
763
+ };
764
+ if (def.model) payload.model = def.model;
765
+ if (def.thinking !== undefined) payload.thinking = def.thinking;
766
+ const delivery = def.delivery || { mode: "announce", channel: "last", bestEffort: true };
759
767
  return {
760
768
  id: def.id,
761
769
  name: nameFromId.length <= 60 ? nameFromId : nameFromId.slice(0, 59) + "…",
@@ -764,13 +772,8 @@ function buildOpenClawCronStoreJob(def) {
764
772
  sessionTarget: "isolated",
765
773
  wakeMode: "now",
766
774
  agentId: def.agentId,
767
- payload: {
768
- kind: "agentTurn",
769
- message: def.message,
770
- lightContext: true,
771
- },
772
- // OpenClaw: "none" = no channel post; announce + last = summary to user's last chat (see OpenClaw cron delivery docs)
773
- delivery: { mode: "announce", channel: "last", bestEffort: true },
775
+ payload,
776
+ delivery,
774
777
  state: {},
775
778
  };
776
779
  }
@@ -869,74 +872,122 @@ function traderCronPrescriptiveJobs(agentId) {
869
872
  return [
870
873
  {
871
874
  id: "alpha-scan",
872
- schedule: "0 * * * *",
875
+ schedule: "0 */3 * * *",
873
876
  agentId,
874
877
  message:
875
- "CRON_JOB: alpha_scan — Call solana_scan_launches to find new token launches from the last hour. For each candidate, call solana_token_snapshot to check price, volume, and age. Filter for: 24h volume above 50000 USD, market cap above 10000 USD. For tokens that pass, call solana_token_holders to check holder distribution (skip if top holder owns more than 30 percent), then solana_token_risk to check for mint/freeze authority (hard skip if present). If a token passes all checks, use solana_trade_precheck and consider trade execution using solana_trade_execute. Log all scanned tokens and results using solana_memory_write. Do not ask questions.",
878
+ "CRON_JOB: alpha_scan\n\nScan new launches, filter, score, log alpha. Tools: solana_scan_launches filter (vol>30K, mcap>10K, liq>5K) solana_token_snapshot for survivors quality filter (top10 <50%, deployer <3 abandoned, has social) score 0-100 solana_alpha_log for 65+. Summarize results.",
879
+ model: "anthropic/claude-sonnet-4-20250514",
880
+ thinking: false,
881
+ lightContext: true,
882
+ delivery: { mode: "announce", channel: "last", bestEffort: true },
876
883
  enabled: true,
877
884
  },
878
885
  {
879
- id: "dead-money-sweep",
880
- schedule: "0 */2 * * *",
886
+ id: "portfolio-health",
887
+ schedule: "0 */4 * * *",
881
888
  agentId,
882
889
  message:
883
- "CRON_JOB: dead_money_sweep Check all open LOCAL_MANAGED positions for dead money. Exit stale positions. Tag as dead_money.",
890
+ "CRON_JOB: portfolio_health\n\nCombined dead-money + whale + risk audit. solana_capital_status + solana_positions → solana_token_snapshot per position → dead money exit (loss>40% or 90min+down+low vol) → whale flags (>5% supply moves) → risk checks (concentration/drawdown/exposure) → sell if CRITICAL → solana_memory_write tag 'portfolio_health'.",
891
+ model: "anthropic/claude-sonnet-4-20250514",
892
+ thinking: false,
893
+ lightContext: true,
894
+ delivery: { mode: "announce", channel: "last", bestEffort: true },
884
895
  enabled: true,
885
896
  },
886
897
  {
887
- id: "risk-audit",
888
- schedule: "30 */2 * * *",
898
+ id: "trust-refresh",
899
+ schedule: "0 */8 * * *",
889
900
  agentId,
890
901
  message:
891
- "CRON_JOB: portfolio_risk_audit\n\nStep 1: Call solana_capital_status to get wallet balance and portfolio value.\n\nStep 2: Call solana_positions to get all open positions with entry prices and sizes.\n\nStep 3: For each open position, call solana_token_snapshot to get current price, 24h volume, and market cap.\n\nStep 4: Run concentration check — flag WARNING if any single position exceeds 30 percent of total portfolio value, CRITICAL if above 50 percent.\n\nStep 5: Run exposure check — flag WARNING if total exposure exceeds 50 percent of wallet balance, CRITICAL if above 75 percent.\n\nStep 6: Run drawdown check — CRITICAL if portfolio drawdown exceeds 25 percent from peak capital.\n\nStep 7: Calculate portfolio heat (sum of all position risk scores). Flag WARNING above 50 percent, CRITICAL above 75 percent.\n\nStep 8: Run liquidity check — WARNING if any position exceeds 2 percent of its pool depth.\n\nStep 9: Check solana_killswitch_status.\n\nStep 10: Write risk report via solana_memory_write with tag 'risk_audit'.\n\nFORMATTING RULES:\n- Every token reference MUST use SYMBOL (full_CA) format.\n- Do not execute trades. Do not ask questions.",
902
+ "CRON_JOB: trust_refresh\n\nCombined source + deployer trust. solana_source_trust_refresh + solana_deployer_trust_refresh solana_alpha_sources + solana_trades for win rates solana_source_trust_get + solana_deployer_trust_get, flag <30 solana_memory_write tag 'trust_refresh'.",
903
+ model: "anthropic/claude-haiku-4-5",
904
+ thinking: false,
905
+ lightContext: true,
906
+ delivery: { mode: "none" },
892
907
  enabled: true,
893
908
  },
894
909
  {
895
- id: "source-reputation-recalc",
896
- schedule: "0 */3 * * *",
910
+ id: "meta-rotation",
911
+ schedule: "30 */8 * * *",
897
912
  agentId,
898
913
  message:
899
- "CRON_JOB: source_reputation_recalc\n\nStep 1: Call solana_alpha_sources to get per-source performance stats (signal count, conversion rate, avg score).\n\nStep 2: Call solana_alpha_history to get recent signal history with scores and source identifiers.\n\nStep 3: Call solana_trades to get recent trade outcomes. Cross-reference each trade back to its originating signal source.\n\nStep 4: For each source, calculate: win rate (trades that hit TP vs SL), average PnL per trade, signal-to-trade conversion rate.\n\nStep 5: Assign tier rankings:\n- TIER-1 (LOCK): Win rate above 60% AND 5+ trades AND positive avg PnL\n- TIER-2 (CONDITIONAL): Win rate 30-60% OR fewer than 5 trades\n- TIER-3 (BLACKLIST): Win rate below 30% with 5+ trades\n\nStep 6: Write scorecard to memory using solana_memory_write with tag 'source_reputation'.\n\nFORMATTING RULES:\n- Every token reference MUST use SYMBOL (full_CA) format.\n- Do not execute trades. Do not ask questions.",
914
+ "CRON_JOB: meta_rotation_analysis\n\nx_search_tweets trending topics solana_scan_launches categorize by narrative cluster per-cluster metrics compare vs solana_memory_search tag 'meta_rotation' declare hot/fading clusters solana_memory_write tag 'meta_rotation'.",
915
+ model: "anthropic/claude-sonnet-4-20250514",
916
+ thinking: false,
917
+ lightContext: true,
918
+ delivery: { mode: "announce", channel: "last", bestEffort: true },
900
919
  enabled: true,
901
920
  },
902
921
  {
903
- id: "meta-rotation",
904
- schedule: "30 */3 * * *",
922
+ id: "strategy-evolution",
923
+ schedule: "0 6 * * *",
905
924
  agentId,
906
925
  message:
907
- "CRON_JOB: meta_rotation_analysis\n\nStep 0: Call x_search_tweets with queries: 'solana memecoin', 'pump fun gem', 'sol alpha'. Note which token names and narratives appear most frequently in the last 3 hours. Use this social signal to validate or challenge the on-chain data in the following steps.\n\nStep 1: Call solana_scan_launches to get recent token launches (last 3-6 hours).\n\nStep 2: Categorize each token by narrative cluster: AI/Agents, Animal Memes, Political, Celebrity/IP, DeFi, Gaming, Culture/Humor, Other.\n\nStep 3: For each cluster, aggregate: token count, total volume, average market cap.\n\nStep 4: Call solana_memory_search for 'meta_rotation' to compare with prior scan.\n\nStep 5: Classify each narrative: GAINING, SATURATED, COOLING, DORMANT.\n\nStep 6: Write rotation report via solana_memory_write with tag 'meta_rotation'.\n\nFORMATTING RULES:\n- Every token reference MUST use SYMBOL (full_CA) format.\n- Do not execute trades. Do not ask questions.",
926
+ "CRON_JOB: strategy_evolution\n\nDaily strategy review. solana_journal_summary if <10 closed trades since last evolution, log 'insufficient data' and stop. Otherwise: solana_trades to bucket by confidence tier solana_strategy_state for current weights analyze tier performance solana_strategy_update with conservative adjustments (max 10% per weight per cycle) solana_memory_write tag 'strategy_evolution'.",
927
+ model: "anthropic/claude-sonnet-4-20250514",
928
+ thinking: true,
929
+ lightContext: false,
930
+ delivery: { mode: "announce", channel: "last", bestEffort: true },
908
931
  enabled: true,
909
932
  },
910
933
  {
911
- id: "strategy-evolution",
912
- schedule: "0 */4 * * *",
934
+ id: "subscription-cleanup",
935
+ schedule: "15 */8 * * *",
913
936
  agentId,
914
937
  message:
915
- "CRON_JOB: strategy_evolution Review trade journal, compute weight adjustments, update strategy. Only update if sufficient closed trades have accumulated.",
938
+ "CRON_JOB: subscription_cleanup\n\nsolana_positions for open CAs solana_bitquery_subscriptions for active subs (if AUTH_SCOPE_MISSING, log and stop) match subs to positions solana_bitquery_unsubscribe orphaned subs → solana_memory_write tag 'subscription_cleanup'. Summarize before/after counts.",
939
+ model: "anthropic/claude-haiku-4-5",
940
+ thinking: false,
941
+ lightContext: true,
942
+ delivery: { mode: "announce", channel: "last", bestEffort: true },
916
943
  enabled: true,
917
944
  },
918
945
  {
919
- id: "subscription-cleanup",
920
- schedule: "15 * * * *",
946
+ id: "daily-performance-report",
947
+ schedule: "0 4 * * *",
921
948
  agentId,
922
949
  message:
923
- "CRON_JOB: subscription_cleanup\n\nStep 1: Call solana_positions to get all open positions and extract their contract addresses.\n\nStep 2: Call solana_bitquery_subscriptions to list all active Bitquery subscriptions. If this call returns an AUTH_SCOPE_MISSING error, log the error to memory and stop gracefully — do not retry or error out.\n\nStep 3: For each active subscription, check if the associated token CA still has an open position. Build two lists: 'matched' (has position) and 'orphaned' (no position).\n\nStep 4: Unsubscribe orphans via solana_bitquery_unsubscribe.\n\nStep 5: Reopen subscriptions nearing 24h expiry via solana_bitquery_subscription_reopen.\n\nStep 6: Write summary via solana_memory_write with tag 'subscription_cleanup'.\n\nFORMATTING RULES:\n- Every token reference MUST use SYMBOL (full_CA) format.\n- Do not execute trades. Do not ask questions.",
950
+ "CRON_JOB: daily_performance_report\n\nCompile 24h report. solana_journal_summary + solana_capital_status + solana_positions + solana_trades + solana_strategy_state sections: Portfolio Summary, Trading Activity (count/win rate/PnL), Best/Worst Trades, Strategy State, Risk Metrics, Recommendations solana_memory_write tag 'daily_report'. Deliver full report.",
951
+ model: "anthropic/claude-sonnet-4-20250514",
952
+ thinking: false,
953
+ lightContext: false,
954
+ delivery: { mode: "announce", channel: "telegram" },
924
955
  enabled: true,
925
956
  },
926
957
  {
927
- id: "whale-watch",
928
- schedule: "45 */2 * * *",
958
+ id: "intelligence-lab-eval",
959
+ schedule: "0 16 * * *",
929
960
  agentId,
930
961
  message:
931
- "CRON_JOB: whale_activity_scanScan for large wallet movements, deployer activity, accumulation patterns. Detect smart money consensus and fresh wallet surges.",
962
+ "CRON_JOB: intelligence_lab_eval\n\nsolana_candidate_getif <20 labeled candidates, log 'insufficient data' and exit. Otherwise: solana_evaluation_report solana_model_registry for challengers solana_replay_eval if challenger exists → solana_model_promote if challenger beats champion by >5% F1 → solana_memory_write tag 'intelligence_lab'.",
963
+ model: "anthropic/claude-sonnet-4-20250514",
964
+ thinking: true,
965
+ lightContext: false,
966
+ delivery: { mode: "none" },
932
967
  enabled: true,
933
968
  },
934
969
  {
935
- id: "daily-performance-report",
936
- schedule: "0 4 * * *",
970
+ id: "memory-trim",
971
+ schedule: "0 3 * * *",
937
972
  agentId,
938
973
  message:
939
- "CRON_JOB: daily_performance_report Calculate daily PnL, aggregate win/loss stats, source reputation summary, write comprehensive memory entry.",
974
+ "CRON_JOB: memory_trim\n\nsolana_memory_trim dryRun:true first review solana_memory_trim retentionDays:2 solana_memory_write tag 'memory_trim' with summary.",
975
+ model: "anthropic/claude-haiku-4-5",
976
+ thinking: false,
977
+ lightContext: true,
978
+ delivery: { mode: "none" },
979
+ enabled: true,
980
+ },
981
+ {
982
+ id: "balance-watchdog",
983
+ schedule: "0 */2 * * *",
984
+ agentId,
985
+ message:
986
+ "Balance watchdog. 1) solana_capital_status 2) solana_positions 3) solana_context_snapshot_read 4) Compare real vs believed. If mismatch: solana_context_snapshot_write with corrected state, summarize changes. If match: reply WATCHDOG_OK.",
987
+ model: "anthropic/claude-haiku-4-5",
988
+ thinking: false,
989
+ lightContext: true,
990
+ delivery: { mode: "announce", channel: "telegram" },
940
991
  enabled: true,
941
992
  },
942
993
  ];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "traderclaw-cli",
3
- "version": "1.0.91",
3
+ "version": "1.0.92",
4
4
  "description": "Global TraderClaw CLI (install --wizard, setup, precheck). Installs solana-traderclaw as a dependency for OpenClaw plugin files.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -17,7 +17,7 @@
17
17
  "node": ">=22"
18
18
  },
19
19
  "dependencies": {
20
- "solana-traderclaw": "^1.0.91"
20
+ "solana-traderclaw": "^1.0.92"
21
21
  },
22
22
  "keywords": [
23
23
  "traderclaw",