solana-agent 22.0.11__tar.gz → 23.0.1__tar.gz
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.
- {solana_agent-22.0.11 → solana_agent-23.0.1}/PKG-INFO +68 -6
- {solana_agent-22.0.11 → solana_agent-23.0.1}/README.md +67 -5
- {solana_agent-22.0.11 → solana_agent-23.0.1}/pyproject.toml +2 -2
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/client/solana_agent.py +1 -1
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/interfaces/client/client.py +1 -1
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/interfaces/services/agent.py +1 -1
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/interfaces/services/query.py +1 -1
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/services/agent.py +1 -1
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/services/query.py +1 -1
- {solana_agent-22.0.11 → solana_agent-23.0.1}/LICENSE +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/__init__.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/adapters/__init__.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/adapters/llm_adapter.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/adapters/mongodb_adapter.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/client/__init__.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/domains/__init__.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/domains/agent.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/domains/routing.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/factories/__init__.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/factories/agent_factory.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/interfaces/__init__.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/interfaces/plugins/plugins.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/interfaces/providers/data_storage.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/interfaces/providers/llm.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/interfaces/providers/memory.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/interfaces/services/routing.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/plugins/__init__.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/plugins/manager.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/plugins/registry.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/plugins/tools/__init__.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/plugins/tools/auto_tool.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/repositories/__init__.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/repositories/memory.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/services/__init__.py +0 -0
- {solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/services/routing.py +0 -0
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.3
|
2
2
|
Name: solana-agent
|
3
|
-
Version:
|
3
|
+
Version: 23.0.1
|
4
4
|
Summary: Agentic IQ
|
5
5
|
License: MIT
|
6
6
|
Keywords: ai,openai,ai agents,agi
|
@@ -81,6 +81,47 @@ You can install Solana Agent using pip:
|
|
81
81
|
|
82
82
|
`pip install solana-agent`
|
83
83
|
|
84
|
+
## Flows
|
85
|
+
|
86
|
+
In both flows of single and multiple agents - it is one user query to one agent using one tool (if needed).
|
87
|
+
|
88
|
+
An agent can have multiple tools and will choose the best one to answer the user query.
|
89
|
+
|
90
|
+
Routing is determined by optimal domain expertise of the agent for the user query.
|
91
|
+
|
92
|
+
Keep this in mind while designing your agentic systems using Solana Agent.
|
93
|
+
|
94
|
+
```ascii
|
95
|
+
Single Agent
|
96
|
+
|
97
|
+
┌────────┐ ┌─────────┐ ┌────────┐
|
98
|
+
│ │ │ │ │ │
|
99
|
+
│ │ │ │ │ │
|
100
|
+
│ User │◄──────►│ Agent │◄──────►│ Tool │
|
101
|
+
│ │ │ │ │ │
|
102
|
+
│ │ │ │ │ │
|
103
|
+
└────────┘ └─────────┘ └────────┘
|
104
|
+
|
105
|
+
|
106
|
+
|
107
|
+
|
108
|
+
|
109
|
+
Multiple Agents
|
110
|
+
|
111
|
+
┌────────┐ ┌──────────┐ ┌─────────┐ ┌────────┐
|
112
|
+
│ │ │ │ │ │ │ │
|
113
|
+
│ │ │ │ │ │ │ │
|
114
|
+
┌───►│ User ├───────►│ Router ├───────►│ Agent │◄──────►│ Tool │
|
115
|
+
│ │ │ │ │ │ │ │ │
|
116
|
+
│ │ │ │ │ │ │ │ │
|
117
|
+
│ └────────┘ └──────────┘ └────┬────┘ └────────┘
|
118
|
+
│ │
|
119
|
+
│ │
|
120
|
+
│ │
|
121
|
+
│ │
|
122
|
+
└───────────────────────────────────────────────┘
|
123
|
+
```
|
124
|
+
|
84
125
|
## Usage
|
85
126
|
|
86
127
|
### Text/Text Streaming
|
@@ -244,10 +285,18 @@ config = {
|
|
244
285
|
}
|
245
286
|
```
|
246
287
|
|
247
|
-
###
|
288
|
+
### Internet Search
|
289
|
+
|
290
|
+
This mode is great for text output where the default response from OpenAI is enough.
|
291
|
+
|
292
|
+
However, it is also found to sometimes not not call tools when the tool should be called.
|
293
|
+
|
294
|
+
It is faster than calling `search_internet` from `sakit` and saves at least 2 API calls.
|
295
|
+
|
296
|
+
The default mode is disabled due to the issue of not calling tools properly and is not suitable for audio output.
|
248
297
|
|
249
298
|
```python
|
250
|
-
async for response in solana_agent.process("user123", "
|
299
|
+
async for response in solana_agent.process("user123", "What is the latest news on Canada?", internet_search=True):
|
251
300
|
print(response, end="")
|
252
301
|
```
|
253
302
|
|
@@ -292,7 +341,8 @@ config = {
|
|
292
341
|
},
|
293
342
|
"tools": {
|
294
343
|
"search_internet": {
|
295
|
-
"api_key": "your-
|
344
|
+
"api_key": "your-api-key", # Required - either a Perplexity or OpenAI API key
|
345
|
+
"provider": "perplexity", # Optional, defaults to perplexity - can also be openai (lowercase)
|
296
346
|
},
|
297
347
|
},
|
298
348
|
"agents": [
|
@@ -312,7 +362,7 @@ config = {
|
|
312
362
|
|
313
363
|
solana_agent = SolanaAgent(config=config)
|
314
364
|
|
315
|
-
async for response in solana_agent.process("user123", "What are the latest AI developments?"
|
365
|
+
async for response in solana_agent.process("user123", "What are the latest AI developments?"):
|
316
366
|
print(response, end="")
|
317
367
|
```
|
318
368
|
|
@@ -489,7 +539,19 @@ The official example app written in FastAPI and Next.js
|
|
489
539
|
|
490
540
|
## Agent Framework Comparisons
|
491
541
|
|
492
|
-
[Compare Python Agent Frameworks](https://github.com/truemagic-coder/solana-agent/
|
542
|
+
[Compare Python Agent Frameworks](https://github.com/truemagic-coder/solana-agent/wiki/Agent-Framework-Comparisons)
|
543
|
+
|
544
|
+
## Contributing
|
545
|
+
|
546
|
+
If you have a question, feedback, or feature request - please open a GitHub discussion.
|
547
|
+
|
548
|
+
If you find a bug - please open a GitHub issue.
|
549
|
+
|
550
|
+
We are currently not accepting pull requests at the moment.
|
551
|
+
|
552
|
+
To run the documentation site locally run `make livehtml` in the root directory.
|
553
|
+
|
554
|
+
To run the test suite locally run `poetry run pytest --cov=solana_agent --cov-report=html` in the root directory.
|
493
555
|
|
494
556
|
## License
|
495
557
|
|
@@ -57,6 +57,47 @@ You can install Solana Agent using pip:
|
|
57
57
|
|
58
58
|
`pip install solana-agent`
|
59
59
|
|
60
|
+
## Flows
|
61
|
+
|
62
|
+
In both flows of single and multiple agents - it is one user query to one agent using one tool (if needed).
|
63
|
+
|
64
|
+
An agent can have multiple tools and will choose the best one to answer the user query.
|
65
|
+
|
66
|
+
Routing is determined by optimal domain expertise of the agent for the user query.
|
67
|
+
|
68
|
+
Keep this in mind while designing your agentic systems using Solana Agent.
|
69
|
+
|
70
|
+
```ascii
|
71
|
+
Single Agent
|
72
|
+
|
73
|
+
┌────────┐ ┌─────────┐ ┌────────┐
|
74
|
+
│ │ │ │ │ │
|
75
|
+
│ │ │ │ │ │
|
76
|
+
│ User │◄──────►│ Agent │◄──────►│ Tool │
|
77
|
+
│ │ │ │ │ │
|
78
|
+
│ │ │ │ │ │
|
79
|
+
└────────┘ └─────────┘ └────────┘
|
80
|
+
|
81
|
+
|
82
|
+
|
83
|
+
|
84
|
+
|
85
|
+
Multiple Agents
|
86
|
+
|
87
|
+
┌────────┐ ┌──────────┐ ┌─────────┐ ┌────────┐
|
88
|
+
│ │ │ │ │ │ │ │
|
89
|
+
│ │ │ │ │ │ │ │
|
90
|
+
┌───►│ User ├───────►│ Router ├───────►│ Agent │◄──────►│ Tool │
|
91
|
+
│ │ │ │ │ │ │ │ │
|
92
|
+
│ │ │ │ │ │ │ │ │
|
93
|
+
│ └────────┘ └──────────┘ └────┬────┘ └────────┘
|
94
|
+
│ │
|
95
|
+
│ │
|
96
|
+
│ │
|
97
|
+
│ │
|
98
|
+
└───────────────────────────────────────────────┘
|
99
|
+
```
|
100
|
+
|
60
101
|
## Usage
|
61
102
|
|
62
103
|
### Text/Text Streaming
|
@@ -220,10 +261,18 @@ config = {
|
|
220
261
|
}
|
221
262
|
```
|
222
263
|
|
223
|
-
###
|
264
|
+
### Internet Search
|
265
|
+
|
266
|
+
This mode is great for text output where the default response from OpenAI is enough.
|
267
|
+
|
268
|
+
However, it is also found to sometimes not not call tools when the tool should be called.
|
269
|
+
|
270
|
+
It is faster than calling `search_internet` from `sakit` and saves at least 2 API calls.
|
271
|
+
|
272
|
+
The default mode is disabled due to the issue of not calling tools properly and is not suitable for audio output.
|
224
273
|
|
225
274
|
```python
|
226
|
-
async for response in solana_agent.process("user123", "
|
275
|
+
async for response in solana_agent.process("user123", "What is the latest news on Canada?", internet_search=True):
|
227
276
|
print(response, end="")
|
228
277
|
```
|
229
278
|
|
@@ -268,7 +317,8 @@ config = {
|
|
268
317
|
},
|
269
318
|
"tools": {
|
270
319
|
"search_internet": {
|
271
|
-
"api_key": "your-
|
320
|
+
"api_key": "your-api-key", # Required - either a Perplexity or OpenAI API key
|
321
|
+
"provider": "perplexity", # Optional, defaults to perplexity - can also be openai (lowercase)
|
272
322
|
},
|
273
323
|
},
|
274
324
|
"agents": [
|
@@ -288,7 +338,7 @@ config = {
|
|
288
338
|
|
289
339
|
solana_agent = SolanaAgent(config=config)
|
290
340
|
|
291
|
-
async for response in solana_agent.process("user123", "What are the latest AI developments?"
|
341
|
+
async for response in solana_agent.process("user123", "What are the latest AI developments?"):
|
292
342
|
print(response, end="")
|
293
343
|
```
|
294
344
|
|
@@ -465,7 +515,19 @@ The official example app written in FastAPI and Next.js
|
|
465
515
|
|
466
516
|
## Agent Framework Comparisons
|
467
517
|
|
468
|
-
[Compare Python Agent Frameworks](https://github.com/truemagic-coder/solana-agent/
|
518
|
+
[Compare Python Agent Frameworks](https://github.com/truemagic-coder/solana-agent/wiki/Agent-Framework-Comparisons)
|
519
|
+
|
520
|
+
## Contributing
|
521
|
+
|
522
|
+
If you have a question, feedback, or feature request - please open a GitHub discussion.
|
523
|
+
|
524
|
+
If you find a bug - please open a GitHub issue.
|
525
|
+
|
526
|
+
We are currently not accepting pull requests at the moment.
|
527
|
+
|
528
|
+
To run the documentation site locally run `make livehtml` in the root directory.
|
529
|
+
|
530
|
+
To run the test suite locally run `poetry run pytest --cov=solana_agent --cov-report=html` in the root directory.
|
469
531
|
|
470
532
|
## License
|
471
533
|
|
@@ -1,6 +1,6 @@
|
|
1
1
|
[tool.poetry]
|
2
2
|
name = "solana-agent"
|
3
|
-
version = "
|
3
|
+
version = "23.0.1"
|
4
4
|
description = "Agentic IQ"
|
5
5
|
authors = ["Bevan Hunt <bevan@bevanhunt.com>"]
|
6
6
|
license = "MIT"
|
@@ -30,7 +30,7 @@ zep-cloud = "^2.9.0"
|
|
30
30
|
|
31
31
|
[tool.poetry.group.dev.dependencies]
|
32
32
|
pytest = "^8.3.5"
|
33
|
-
pytest-cov = "^6.1.
|
33
|
+
pytest-cov = "^6.1.1"
|
34
34
|
pytest-asyncio = "^0.26.0"
|
35
35
|
pytest-mock = "^3.14.0"
|
36
36
|
pytest-github-actions-annotate-failures = "^0.3.0"
|
@@ -56,7 +56,7 @@ class SolanaAgent(SolanaAgentInterface):
|
|
56
56
|
"flac", "mp3", "mp4", "mpeg", "mpga", "m4a", "ogg", "wav", "webm"
|
57
57
|
] = "mp4",
|
58
58
|
router: Optional[RoutingInterface] = None,
|
59
|
-
internet_search: bool =
|
59
|
+
internet_search: bool = False,
|
60
60
|
) -> AsyncGenerator[Union[str, bytes], None]: # pragma: no cover
|
61
61
|
"""Process a user message and return the response stream.
|
62
62
|
|
@@ -24,7 +24,7 @@ class SolanaAgent(ABC):
|
|
24
24
|
"flac", "mp3", "mp4", "mpeg", "mpga", "m4a", "ogg", "wav", "webm"
|
25
25
|
] = "mp4",
|
26
26
|
router: Optional[RoutingInterface] = None,
|
27
|
-
internet_search: bool =
|
27
|
+
internet_search: bool = False,
|
28
28
|
) -> AsyncGenerator[Union[str, bytes], None]:
|
29
29
|
"""Process a user message and return the response stream."""
|
30
30
|
pass
|
@@ -34,7 +34,7 @@ class AgentService(ABC):
|
|
34
34
|
"flac", "mp3", "mp4", "mpeg", "mpga", "m4a", "ogg", "wav", "webm"
|
35
35
|
] = "mp4",
|
36
36
|
prompt: Optional[str] = None,
|
37
|
-
internet_search: bool =
|
37
|
+
internet_search: bool = False,
|
38
38
|
) -> AsyncGenerator[Union[str, bytes], None]:
|
39
39
|
"""Generate a response from an agent."""
|
40
40
|
pass
|
@@ -20,7 +20,7 @@ class QueryService(ABC):
|
|
20
20
|
"flac", "mp3", "mp4", "mpeg", "mpga", "m4a", "ogg", "wav", "webm"
|
21
21
|
] = "mp4",
|
22
22
|
prompt: Optional[str] = None,
|
23
|
-
internet_search: bool =
|
23
|
+
internet_search: bool = False,
|
24
24
|
) -> AsyncGenerator[Union[str, bytes], None]:
|
25
25
|
"""Process the user request and generate a response."""
|
26
26
|
pass
|
@@ -177,7 +177,7 @@ class AgentService(AgentServiceInterface):
|
|
177
177
|
"flac", "mp3", "mp4", "mpeg", "mpga", "m4a", "ogg", "wav", "webm"
|
178
178
|
] = "mp4",
|
179
179
|
prompt: Optional[str] = None,
|
180
|
-
internet_search: bool =
|
180
|
+
internet_search: bool = False,
|
181
181
|
) -> AsyncGenerator[Union[str, bytes], None]: # pragma: no cover
|
182
182
|
"""Generate a response with support for text/audio input/output."""
|
183
183
|
agent = next((a for a in self.agents if a.name == agent_name), None)
|
@@ -49,7 +49,7 @@ class QueryService(QueryServiceInterface):
|
|
49
49
|
] = "mp4",
|
50
50
|
prompt: Optional[str] = None,
|
51
51
|
router: Optional[RoutingServiceInterface] = None,
|
52
|
-
internet_search: bool =
|
52
|
+
internet_search: bool = False,
|
53
53
|
) -> AsyncGenerator[Union[str, bytes], None]: # pragma: no cover
|
54
54
|
"""Process the user request with appropriate agent.
|
55
55
|
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{solana_agent-22.0.11 → solana_agent-23.0.1}/solana_agent/interfaces/providers/data_storage.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|