You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: _sources/index.rst.txt
+1-219Lines changed: 1 addition & 219 deletions
Original file line number
Diff line number
Diff line change
@@ -553,231 +553,13 @@ Example Custom Guardrails - Optional
553
553
Tools
554
554
~~~~~~
555
555
556
-
Solana Transfer
556
+
Solana Agent Kit
557
557
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
558
558
559
559
.. code-block:: bash
560
-
561
-
pip install sakit
562
-
563
-
.. code-block:: python
564
-
565
-
from solana_agent import SolanaAgent
566
-
567
-
config = {
568
-
"tools": {
569
-
"solana_transfer": {
570
-
"rpc_url": "my-rpc-url", # Required - your RPC URL - Helius is recommended
571
-
"private_key": "my-private-key", # Required - base58 string - please use env vars to store the key as it is very confidential
572
-
},
573
-
},
574
-
"agents": [
575
-
{
576
-
"name": "solana_expert",
577
-
"instructions": "You are a Solana expert that can transfer tokens.",
578
-
"specialization": "Solana Blockchain",
579
-
"tools": ["solana_transfer"], # Enable the tool for this agent
580
-
}
581
-
],
582
-
}
583
-
584
-
solana_agent = SolanaAgent(config=config)
585
-
586
-
asyncfor response in solana_agent.process("user123", "Transfer 0.01 Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB to DzvqBkUHUhuhHtNKGWSCVEAm2rHdm9bxxdQYC6mZBZyF"):
587
-
print(response, end="")
588
-
589
-
Solana Swap
590
-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
591
-
592
-
.. code-block:: bash
593
-
594
-
pip install sakit
595
-
596
-
.. code-block:: python
597
-
598
-
from solana_agent import SolanaAgent
599
-
600
-
config = {
601
-
"tools": {
602
-
"solana_swap": {
603
-
"rpc_url": "my-rpc-url", # Required - your RPC URL - Helius is recommended
604
-
"private_key": "my-private-key", # Required - base58 string - please use env vars to store the key as it is very confidential
605
-
"jupiter_url": "my-custom-url"# Optional - if you are using a custom Jupiter service like Metis from QuickNode
606
-
},
607
-
},
608
-
"agents": [
609
-
{
610
-
"name": "solana_expert",
611
-
"instructions": "You are a Solana expert that can swap tokens.",
612
-
"specialization": "Solana Blockchain",
613
-
"tools": ["solana_swap"], # Enable the tool for this agent
614
-
}
615
-
],
616
-
}
617
-
618
-
solana_agent = SolanaAgent(config=config)
619
-
620
-
asyncfor response in solana_agent.process("user123", "Swap 0.01 Es9vMFrzaCERmJfrF4H2FYD4KCoNkY11McCe8BenwNYB to So11111111111111111111111111111111111111112"):
621
-
print(response, end="")
622
-
623
-
624
-
Internet Search
625
-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
626
560
627
-
.. code-block:: bash
628
-
629
561
pip install sakit
630
562
631
-
.. code-block:: python
632
-
633
-
from solana_agent import SolanaAgent
634
-
635
-
config = {
636
-
"openai": {
637
-
"api_key": "your-openai-api-key",
638
-
},
639
-
"tools": {
640
-
"search_internet": {
641
-
"api_key": "your-openai-api-key",
642
-
},
643
-
},
644
-
"agents": [
645
-
{
646
-
"name": "news_specialist",
647
-
"instructions": "You are an expert news agent. You use your search_internet tool to get the latest information.",
648
-
"specialization": "News researcher and specialist",
649
-
"tools": ["search_internet"], # Enable the tool for this agent
650
-
}
651
-
],
652
-
}
653
-
654
-
solana_agent = SolanaAgent(config=config)
655
-
656
-
asyncfor response in solana_agent.process("user123", "What is the latest news on Elon Musk?"):
657
-
print(response, end="")
658
-
659
-
660
-
MCP
661
-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
662
-
663
-
Zapier MCP has been tested, works, and is supported.
664
-
665
-
Other MCP servers may work but are not supported.
666
-
667
-
.. code-block:: bash
668
-
669
-
pip install sakit
670
-
671
-
.. code-block:: python
672
-
673
-
from solana_agent import SolanaAgent
674
-
675
-
config = {
676
-
"tools": {
677
-
"mcp": {
678
-
"url": "my-zapier-mcp-url",
679
-
}
680
-
},
681
-
"agents": [
682
-
{
683
-
"name": "zapier_expert",
684
-
"instructions": "You are an expert in using Zapier integrations using MCP. You always use the mcp tool to perform Zapier AI like actions.",
685
-
"specialization": "Zapier service integration expert",
686
-
"tools": ["mcp"], # Enable the tool for this agent
687
-
}
688
-
]
689
-
}
690
-
691
-
solana_agent = SolanaAgent(config=config)
692
-
693
-
asyncfor response in solana_agent.process("user123", "Send an email to bob@bob.com to clean his room!"):
694
-
print(response, end="")
695
-
696
-
697
-
Image Generation
698
-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
699
-
700
-
Generate images using OpenAI, Grok, or Gemini image models and upload them to S3-compatible storage.
701
-
702
-
.. code-block:: bash
703
-
704
-
pip install sakit
705
-
706
-
.. code-block:: python
707
-
708
-
from solana_agent import SolanaAgent
709
-
710
-
config = {
711
-
"tools": {
712
-
"image_gen": {
713
-
"provider": "openai", # Required: either "openai", "grok", or "gemini"
714
-
"api_key": "your-api-key", # Required: your OpenAI or Grok or Gemini API key
"s3_access_key_id": "YOUR_S3_ACCESS_KEY", # Required: Your S3 access key ID
717
-
"s3_secret_access_key": "YOUR_S3_SECRET_KEY", # Required: Your S3 secret access key
718
-
"s3_bucket_name": "your-bucket-name", # Required: The name of your S3 bucket
719
-
"s3_region_name": "your-region", # Optional: e.g., "nyc3", needed by some providers
720
-
"s3_public_url_base": "https://your-cdn-or-bucket-url.com/", # Optional: Custom base URL for public links (include trailing slash). If omitted, a standard URL is constructed.
721
-
}
722
-
},
723
-
"agents": [
724
-
{
725
-
"name": "image_creator",
726
-
"instructions": "You are a creative assistant that generates images based on user descriptions. Use the image_gen tool to create and store the image.",
727
-
"specialization": "Image generation and storage",
728
-
"tools": ["image_gen"], # Enable the tool for this agent
729
-
}
730
-
]
731
-
}
732
-
733
-
solana_agent = SolanaAgent(config=config)
734
-
735
-
asyncfor response in solana_agent.process("user123", "Generate an image of a smiling unicorn!"):
736
-
print(response, end="")
737
-
738
-
739
-
### Nemo Agent
740
-
741
-
This plugin allows the agent to generate python programs using [Nemo Agent](https://nemo-agent.com) and uploads the files in a ZIP file to s3-compatible storage. It returns the public URL of the zip file.
742
-
743
-
This has been tested using [Cloudflare R2](https://developers.cloudflare.com/r2/).
744
-
745
-
.. code-block:: bash
746
-
747
-
pip install sakit
748
-
749
-
.. code-block:: python
750
-
751
-
from solana_agent import SolanaAgent
752
-
753
-
config = {
754
-
"tools": {
755
-
"nemo_agent": {
756
-
"provider": "openai", # Required: either "openai" or "gemini"
757
-
"api_key": "your-api-key", # Required: your OpenAI or Gemini API key
"s3_access_key_id": "YOUR_S3_ACCESS_KEY", # Required: Your S3 access key ID
760
-
"s3_secret_access_key": "YOUR_S3_SECRET_KEY", # Required: Your S3 secret access key
761
-
"s3_bucket_name": "your-bucket-name", # Required: The name of your S3 bucket
762
-
"s3_region_name": "your-region", # Optional: e.g., "nyc3", needed by some providers
763
-
"s3_public_url_base": "https://your-cdn-or-bucket-url.com/", # Optional: Custom base URL for public links (include trailing slash). If omitted, a standard URL is constructed.
764
-
}
765
-
},
766
-
"agents": [
767
-
{
768
-
"name": "python_dev",
769
-
"instructions": "You are an expert Python Developer. You always use your nemo_agent tool to generate python code.",
770
-
"specialization": "Python Developer",
771
-
"tools": ["nemo_agent"], # Enable the tool for this agent
772
-
}
773
-
]
774
-
}
775
-
776
-
solana_agent = SolanaAgent(config=config)
777
-
778
-
asyncfor response in solana_agent.process("user123", "Generate an example leetcode medium in Python and give me the zip file."):
0 commit comments