@@ -10,7 +10,7 @@ import { DiscordClientInterface } from "@elizaos/client-discord";
10
10
import { TelegramClientInterface } from "@elizaos/client-telegram" ;
11
11
import { TwitterClientInterface } from "@elizaos/client-twitter" ;
12
12
// import { ReclaimAdapter } from "@elizaos/plugin-reclaim";
13
- import { DirectClient } from "@elizaos/client-direct" ;
13
+ // import { DirectClient } from "@elizaos/client-direct";
14
14
import {
15
15
AgentRuntime ,
16
16
CacheManager ,
@@ -33,8 +33,8 @@ import {
33
33
} from "@elizaos/core" ;
34
34
35
35
//import { zgPlugin } from "@elizaos/plugin-0g";
36
- // import { bootstrapPlugin } from "@elizaos/plugin-bootstrap";
37
- import createGoatPlugin from "@elizaos/plugin-goat" ;
36
+ import { bootstrapPlugin } from "@elizaos/plugin-bootstrap" ;
37
+ // import createGoatPlugin from "@elizaos/plugin-goat";
38
38
// import { intifacePlugin } from "@elizaos/plugin-intiface";
39
39
import { DirectClient } from "@elizaos/client-direct" ;
40
40
import createGoatPlugin from "@elizaos/plugin-goat" ;
@@ -44,7 +44,7 @@ import { solanaPlugin } from "@elizaos/plugin-solana";
44
44
import { solanaAgentkitPlguin } from "@elizaos/plugin-solana-agentkit" ;
45
45
//import { storyPlugin } from "@elizaos/plugin-story";
46
46
//import { suiPlugin } from "@elizaos/plugin-sui";
47
- // import { TEEMode, teePlugin } from "@elizaos/plugin-tee";
47
+ import { TEEMode , teePlugin } from "@elizaos/plugin-tee" ;
48
48
//import { teeMarlinPlugin } from "@elizaos/plugin-tee-marlin";
49
49
//import { tonPlugin } from "@elizaos/plugin-ton";
50
50
//import { webSearchPlugin } from "@elizaos/plugin-web-search";
@@ -368,7 +368,7 @@ export function getTokenForProvider(
368
368
function initializeDatabase ( dataDir : string ) {
369
369
if ( process . env . POSTGRES_URL ) {
370
370
elizaLogger . info ( "Initializing PostgreSQL connection..." ) ;
371
- const db = new PostgresDatabaseAdapter ( {
371
+ /* const db = new PostgresDatabaseAdapter({
372
372
connectionString: process.env.POSTGRES_URL,
373
373
parseInputs: true,
374
374
});
@@ -385,13 +385,17 @@ function initializeDatabase(dataDir: string) {
385
385
});
386
386
387
387
return db;
388
+ */
389
+ return undefined ;
388
390
} else if ( process . env . PGLITE_DATA_DIR ) {
391
+ /*
389
392
elizaLogger.info("Initializing PgLite adapter...");
390
393
// `dataDir: memory://` for in memory pg
391
394
const db = new PGLiteDatabaseAdapter({
392
395
dataDir: process.env.PGLITE_DATA_DIR,
393
396
});
394
397
return db;
398
+ */
395
399
} else {
396
400
const filePath =
397
401
process . env . SQLITE_FILE ?? path . resolve ( dataDir , "db.sqlite" ) ;
@@ -438,16 +442,16 @@ export async function initializeClients(
438
442
439
443
if ( clientTypes . includes ( Clients . FARCASTER ) ) {
440
444
// why is this one different :(
441
- const farcasterClient = new FarcasterAgentClient ( runtime ) ;
445
+ /* const farcasterClient = new FarcasterAgentClient(runtime);
442
446
if (farcasterClient) {
443
447
farcasterClient.start();
444
448
clients.farcaster = farcasterClient;
445
- }
449
+ }*/
446
450
}
447
451
if ( clientTypes . includes ( "lens" ) ) {
448
- const lensClient = new LensAgentClient ( runtime ) ;
452
+ /* const lensClient = new LensAgentClient(runtime);
449
453
lensClient.start();
450
- clients . lens = lensClient ;
454
+ clients.lens = lensClient;*/
451
455
}
452
456
453
457
elizaLogger . log ( "client keys" , Object . keys ( clients ) ) ;
@@ -456,8 +460,8 @@ export async function initializeClients(
456
460
// Initialize clients as an object
457
461
458
462
if ( clientTypes . includes ( "slack" ) ) {
459
- const slackClient = await SlackClientInterface . start ( runtime ) ;
460
- if ( slackClient ) clients . slack = slackClient ; // Use object property instead of push
463
+ // const slackClient = await SlackClientInterface.start(runtime);
464
+ // if (slackClient) clients.slack = slackClient; // Use object property instead of push
461
465
}
462
466
463
467
function determineClientType ( client : Client ) : string {
@@ -576,126 +580,117 @@ export async function createAgent(
576
580
// character.plugins are handled when clients are added
577
581
plugins : [
578
582
bootstrapPlugin ,
579
- dominosPlugin ,
580
- getSecret ( character , "CONFLUX_CORE_PRIVATE_KEY" )
581
- ? confluxPlugin
582
- : null ,
583
+ // dominosPlugin,
584
+ // getSecret(character, "CONFLUX_CORE_PRIVATE_KEY")
585
+ // ? confluxPlugin
586
+ // : null,
583
587
nodePlugin ,
584
- coinPricePlugin ,
585
- getSecret ( character , "TAVILY_API_KEY" ) ? webSearchPlugin : null ,
588
+ // coinPricePlugin,
589
+ // getSecret(character, "TAVILY_API_KEY") ? webSearchPlugin : null,
586
590
getSecret ( character , "SOLANA_PUBLIC_KEY" ) ||
587
591
( getSecret ( character , "WALLET_PUBLIC_KEY" ) &&
588
592
! getSecret ( character , "WALLET_PUBLIC_KEY" ) ?. startsWith ( "0x" ) )
589
593
? solanaPlugin
590
594
: null ,
591
- getSecret ( character , "SOLANA_PRIVATE_KEY" )
592
- ? solanaAgentkitPlguin
593
- : null ,
594
- ( getSecret ( character , "NEAR_ADDRESS" ) ||
595
- getSecret ( character , "NEAR_WALLET_PUBLIC_KEY" ) ) &&
596
- getSecret ( character , "NEAR_WALLET_SECRET_KEY" )
597
- ? nearPlugin
598
- : null ,
599
- getSecret ( character , "EVM_PUBLIC_KEY" ) ||
600
- ( getSecret ( character , "WALLET_PUBLIC_KEY" ) &&
601
- getSecret ( character , "WALLET_PUBLIC_KEY" ) ?. startsWith ( "0x" ) )
602
- ? evmPlugin
603
- : null ,
604
- getSecret ( character , "COSMOS_RECOVERY_PHRASE" ) &&
605
- getSecret ( character , "COSMOS_AVAILABLE_CHAINS" ) &&
606
- createCosmosPlugin ( ) ,
607
- ( getSecret ( character , "SOLANA_PUBLIC_KEY" ) ||
608
- ( getSecret ( character , "WALLET_PUBLIC_KEY" ) &&
609
- ! getSecret ( character , "WALLET_PUBLIC_KEY" ) ?. startsWith (
610
- "0x"
611
- ) ) ) &&
612
- getSecret ( character , "SOLANA_ADMIN_PUBLIC_KEY" ) &&
613
- getSecret ( character , "SOLANA_PRIVATE_KEY" ) &&
614
- getSecret ( character , "SOLANA_ADMIN_PRIVATE_KEY" )
615
- ? nftGenerationPlugin
616
- : null ,
617
- getSecret ( character , "ZEROG_PRIVATE_KEY" ) ? zgPlugin : null ,
618
- getSecret ( character , "COINMARKETCAP_API_KEY" )
619
- ? coinmarketcapPlugin
620
- : null ,
621
- getSecret ( character , "COINBASE_COMMERCE_KEY" )
622
- ? coinbaseCommercePlugin
623
- : null ,
624
- getSecret ( character , "FAL_API_KEY" ) ||
625
- getSecret ( character , "OPENAI_API_KEY" ) ||
626
- getSecret ( character , "VENICE_API_KEY" ) ||
627
- getSecret ( character , "NINETEEN_AI_API_KEY" ) ||
628
- getSecret ( character , "HEURIST_API_KEY" ) ||
629
- getSecret ( character , "LIVEPEER_GATEWAY_URL" )
630
- ? imageGenerationPlugin
631
- : null ,
632
- getSecret ( character , "FAL_API_KEY" ) ? ThreeDGenerationPlugin : null ,
633
- ...( getSecret ( character , "COINBASE_API_KEY" ) &&
634
- getSecret ( character , "COINBASE_PRIVATE_KEY" )
635
- ? [
636
- coinbaseMassPaymentsPlugin ,
637
- tradePlugin ,
638
- tokenContractPlugin ,
639
- advancedTradePlugin ,
640
- ]
641
- : [ ] ) ,
642
- ...( teeMode !== TEEMode . OFF && walletSecretSalt ? [ teePlugin ] : [ ] ) ,
643
- getSecret ( character , "COINBASE_API_KEY" ) &&
644
- getSecret ( character , "COINBASE_PRIVATE_KEY" ) &&
645
- getSecret ( character , "COINBASE_NOTIFICATION_URI" )
646
- ? webhookPlugin
647
- : null ,
648
- goatPlugin ,
649
- getSecret ( character , "COINGECKO_API_KEY" ) ? coingeckoPlugin : null ,
650
- getSecret ( character , "EVM_PROVIDER_URL" ) ? goatPlugin : null ,
651
- getSecret ( character , "ABSTRACT_PRIVATE_KEY" )
652
- ? abstractPlugin
653
- : null ,
654
- getSecret ( character , "BINANCE_API_KEY" ) &&
655
- getSecret ( character , "BINANCE_SECRET_KEY" )
656
- ? binancePlugin
657
- : null ,
658
- getSecret ( character , "FLOW_ADDRESS" ) &&
659
- getSecret ( character , "FLOW_PRIVATE_KEY" )
660
- ? flowPlugin
661
- : null ,
662
- getSecret ( character , "APTOS_PRIVATE_KEY" ) ? aptosPlugin : null ,
663
- getSecret ( character , "MVX_PRIVATE_KEY" ) ? multiversxPlugin : null ,
664
- getSecret ( character , "ZKSYNC_PRIVATE_KEY" ) ? zksyncEraPlugin : null ,
665
- getSecret ( character , "CRONOSZKEVM_PRIVATE_KEY" )
666
- ? cronosZkEVMPlugin
667
- : null ,
668
- getSecret ( character , "TEE_MARLIN" ) ? teeMarlinPlugin : null ,
669
- getSecret ( character , "TON_PRIVATE_KEY" ) ? tonPlugin : null ,
670
- getSecret ( character , "THIRDWEB_SECRET_KEY" ) ? thirdwebPlugin : null ,
671
- getSecret ( character , "SUI_PRIVATE_KEY" ) ? suiPlugin : null ,
672
- getSecret ( character , "STORY_PRIVATE_KEY" ) ? storyPlugin : null ,
673
- getSecret ( character , "FUEL_PRIVATE_KEY" ) ? fuelPlugin : null ,
674
- getSecret ( character , "AVALANCHE_PRIVATE_KEY" )
675
- ? avalanchePlugin
676
- : null ,
677
- getSecret ( character , "ECHOCHAMBERS_API_URL" ) &&
678
- getSecret ( character , "ECHOCHAMBERS_API_KEY" )
679
- ? echoChambersPlugin
680
- : null ,
681
- getSecret ( character , "LETZAI_API_KEY" ) ? letzAIPlugin : null ,
682
- getSecret ( character , "STARGAZE_ENDPOINT" ) ? stargazePlugin : null ,
683
- getSecret ( character , "GIPHY_API_KEY" ) ? giphyPlugin : null ,
684
- getSecret ( character , "GENLAYER_PRIVATE_KEY" )
685
- ? genLayerPlugin
686
- : null ,
687
- getSecret ( character , "AVAIL_SEED" ) &&
688
- getSecret ( character , "AVAIL_APP_ID" )
689
- ? availPlugin
690
- : null ,
691
- getSecret ( character , "OPEN_WEATHER_API_KEY" )
692
- ? openWeatherPlugin
693
- : null ,
694
- // getSecret(character, "OBSIDIAN_API_TOKEN") ? obsidianPlugin : null,
695
- getSecret ( character , "ARTHERA_PRIVATE_KEY" ) ?. startsWith ( "0x" )
696
- ? artheraPlugin
697
- : null ,
698
- getSecret ( character , "ALLORA_API_KEY" ) ? alloraPlugin : null ,
595
+ //getSecret(character, "SOLANA_PRIVATE_KEY")
596
+ // ? solanaAgentkitPlguin
597
+ // : null,
598
+ //(getSecret(character, "NEAR_ADDRESS") ||
599
+ //getSecret(character, "NEAR_WALLET_PUBLIC_KEY")) &&
600
+ //getSecret(character, "NEAR_WALLET_SECRET_KEY") ? nearPlugin : null,
601
+ // getSecret(character, "EVM_PUBLIC_KEY") ||
602
+ //(getSecret(character, "WALLET_PUBLIC_KEY") && getSecret(character, "WALLET_PUBLIC_KEY")?.startsWith("0x")) ? evmPlugin : null,
603
+ // getSecret(character, "COSMOS_RECOVERY_PHRASE") && getSecret(character, "COSMOS_AVAILABLE_CHAINS") && createCosmosPlugin(),
604
+ //(getSecret(character, "SOLANA_PUBLIC_KEY") ||
605
+ // (getSecret(character, "WALLET_PUBLIC_KEY") &&
606
+ // !getSecret(character, "WALLET_PUBLIC_KEY")?.startsWith(
607
+ // "0x"
608
+ // ))) &&
609
+ // getSecret(character, "SOLANA_ADMIN_PUBLIC_KEY") &&
610
+ //getSecret(character, "SOLANA_PRIVATE_KEY") &&
611
+ // getSecret(character, "SOLANA_ADMIN_PRIVATE_KEY") ? nftGenerationPlugin : null,
612
+ // getSecret(character, "ZEROG_PRIVATE_KEY") ? zgPlugin : null,
613
+ // getSecret(character, "COINMARKETCAP_API_KEY")
614
+ // ? coinmarketcapPlugin
615
+ // : null,
616
+ // getSecret(character, "COINBASE_COMMERCE_KEY")
617
+ // ? coinbaseCommercePlugin
618
+ // : null,
619
+ // getSecret(character, "FAL_API_KEY") ||
620
+ //getSecret(character, "OPENAI_API_KEY") ||
621
+ // getSecret(character, "VENICE_API_KEY") ||
622
+ // getSecret(character, "NINETEEN_AI_API_KEY") ||
623
+ // getSecret(character, "HEURIST_API_KEY") ||
624
+ // getSecret(character, "LIVEPEER_GATEWAY_URL")
625
+ // ? imageGenerationPlugin
626
+ // : null,
627
+ // getSecret(character, "FAL_API_KEY") ? ThreeDGenerationPlugin : null,
628
+ // ...(getSecret(character, "COINBASE_API_KEY") &&
629
+ // getSecret(character, "COINBASE_PRIVATE_KEY")
630
+ // ? [
631
+ // coinbaseMassPaymentsPlugin,
632
+ // tradePlugin,
633
+ // tokenContractPlugin,
634
+ // advancedTradePlugin,
635
+ // ]
636
+ // : []),
637
+ // ...(teeMode !== TEEMode.OFF && walletSecretSalt ? [teePlugin] : []),
638
+ // getSecret(character, "COINBASE_API_KEY") &&
639
+ // getSecret(character, "COINBASE_PRIVATE_KEY") &&
640
+ // getSecret(character, "COINBASE_NOTIFICATION_URI")
641
+ // ? webhookPlugin
642
+ // : null,
643
+ // goatPlugin,
644
+ // getSecret(character, "COINGECKO_API_KEY") ? coingeckoPlugin : null,
645
+ // getSecret(character, "EVM_PROVIDER_URL") ? goatPlugin : null,
646
+ // getSecret(character, "ABSTRACT_PRIVATE_KEY")
647
+ // ? abstractPlugin
648
+ // : null,
649
+ // getSecret(character, "BINANCE_API_KEY") &&
650
+ // getSecret(character, "BINANCE_SECRET_KEY")
651
+ // ? binancePlugin
652
+ // : null,
653
+ // getSecret(character, "FLOW_ADDRESS") &&
654
+ // getSecret(character, "FLOW_PRIVATE_KEY")
655
+ // ? flowPlugin
656
+ // : null,
657
+ // getSecret(character, "APTOS_PRIVATE_KEY") ? aptosPlugin : null,
658
+ // getSecret(character, "MVX_PRIVATE_KEY") ? multiversxPlugin : null,
659
+ // getSecret(character, "ZKSYNC_PRIVATE_KEY") ? zksyncEraPlugin : null,
660
+ // getSecret(character, "CRONOSZKEVM_PRIVATE_KEY")
661
+ // ? cronosZkEVMPlugin
662
+ // : null,
663
+ // getSecret(character, "TEE_MARLIN") ? teeMarlinPlugin : null,
664
+ // getSecret(character, "TON_PRIVATE_KEY") ? tonPlugin : null,
665
+ // getSecret(character, "THIRDWEB_SECRET_KEY") ? thirdwebPlugin : null,
666
+ // getSecret(character, "SUI_PRIVATE_KEY") ? suiPlugin : null,
667
+ // getSecret(character, "STORY_PRIVATE_KEY") ? storyPlugin : null,
668
+ // getSecret(character, "FUEL_PRIVATE_KEY") ? fuelPlugin : null,
669
+ // getSecret(character, "AVALANCHE_PRIVATE_KEY")
670
+ // ? avalanchePlugin
671
+ // : null,
672
+ // getSecret(character, "ECHOCHAMBERS_API_URL") &&
673
+ // getSecret(character, "ECHOCHAMBERS_API_KEY")
674
+ // ? echoChambersPlugin
675
+ // : null,
676
+ // getSecret(character, "LETZAI_API_KEY") ? letzAIPlugin : null,
677
+ // getSecret(character, "STARGAZE_ENDPOINT") ? stargazePlugin : null,
678
+ // getSecret(character, "GIPHY_API_KEY") ? giphyPlugin : null,
679
+ // getSecret(character, "GENLAYER_PRIVATE_KEY")
680
+ // ? genLayerPlugin
681
+ // : null,
682
+ // getSecret(character, "AVAIL_SEED") &&
683
+ // getSecret(character, "AVAIL_APP_ID")
684
+ // ? availPlugin
685
+ // : null,
686
+ // getSecret(character, "OPEN_WEATHER_API_KEY")
687
+ // ? openWeatherPlugin
688
+ // : null,
689
+ // // getSecret(character, "OBSIDIAN_API_TOKEN") ? obsidianPlugin : null,
690
+ // getSecret(character, "ARTHERA_PRIVATE_KEY")?.startsWith("0x")
691
+ // ? artheraPlugin
692
+ // : null,
693
+ // getSecret(character, "ALLORA_API_KEY") ? alloraPlugin : null,
699
694
] . filter ( Boolean ) ,
700
695
providers : [ ] ,
701
696
actions : [ ] ,
@@ -736,6 +731,7 @@ function initializeCache(
736
731
db ?: IDatabaseCacheAdapter
737
732
) {
738
733
switch ( cacheStore ) {
734
+ /*
739
735
case CacheStore.REDIS:
740
736
if (process.env.REDIS_URL) {
741
737
elizaLogger.info("Connecting to Redis...");
@@ -751,7 +747,7 @@ function initializeCache(
751
747
} else {
752
748
throw new Error("REDIS_URL environment variable is not set.");
753
749
}
754
-
750
+ */
755
751
case CacheStore . DATABASE :
756
752
if ( db ) {
757
753
elizaLogger . info ( "Using Database Cache..." ) ;
0 commit comments