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: content/blog/llm-agentic-tool-mesh-harnessing-agent-services-and-multi-agent-ai-for-next-level-gen-ai.md
+67-68Lines changed: 67 additions & 68 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,11 @@ date: 2024-12-12T17:08:46.212Z
5
5
author: Antonio Fin
6
6
authorimage: /img/afin_photo.jpg
7
7
disable: false
8
+
tags:
9
+
- HPE
10
+
- GenAI
11
+
- LAT-Mesh
12
+
- MultiAgents
8
13
---
9
14
<style>
10
15
li {
@@ -16,7 +21,7 @@ li {
16
21
17
22
In our previous blog post, we explored the [Chat Service](https://developer.hpe.com/blog/ll-mesh-exploring-chat-service-and-factory-design-pattern/) of [LLM Agentic Tool Mesh](https://developer.hpe.com/blog/ll-mesh-democratizing-gen-ai-through-open-source-innovation-1/), an [open-source project](https://github.com/HewlettPackard/llmesh) aimed at democratizing Generative AI (Gen AI).
18
23
19
-
Today, we'll delve into another core feature: the **Agent Service**. We'll discuss what agents are, explain the LLM Agentic Tool Mesh related services, and showcase examples from the LLM Agentic Tool Mesh repository.
24
+
Today, we'll delve into another core feature: the **Agent Service**. We'll discuss what agents are, explain the LLM Agentic Tool Mesh related services, and showcase examples from its repository.
20
25
21
26
## Understanding LLM agents
22
27
@@ -45,8 +50,6 @@ LLM Agentic Tool Mesh provides all the necessary tools to build a powerful agent
45
50
2. Reasoning engine
46
51
3. Multi-agent task force
47
52
48
-
Let's explore each of these components in detail.
49
-
50
53
### Tool repository
51
54
52
55
Agents in LLM Agentic Tool Mesh rely on tools to perform specialized tasks like information retrieval, document summarization, or data analysis. These tools extend the agents' capabilities, allowing them to efficiently complete complex operations. The **tool repository** service in LLM Agentic Tool Mesh simplifies and automates the storage, management, and retrieval of these tools.
@@ -111,8 +114,6 @@ Key Features:
111
114
***Memory management**: Handles storage and retrieval of relevant memory for ongoing tasks or conversations.
112
115
***Dynamic configuration**: Allows users to adjust the Reasoning Engine's behavior dynamically, tailoring interactions between LLMs and tools.
113
116
114
-
Architecture Overview:
115
-
116
117

117
118
118
119
### Task force
@@ -127,42 +128,51 @@ Key Features:
127
128
***Tool integration**: Agents utilize a suite of tools to complete their tasks, dynamically loaded and executed during task completion.
128
129
129
130
Example Usage:
131
+
130
132
```python
131
133
from athon.agents import TaskForce
134
+
from custom_tools import DataFetcher, SalesSummarizer, PresentationBuilder
132
135
133
-
#Configuration for the Task Force Multi-Agents
136
+
#Example configuration for the Task Force Multi-Agents
134
137
TASK_FORCE_CONFIG= {
135
138
'type': 'CrewAIMultiAgent',
136
139
'plan_type': 'Sequential',
137
-
'tasks': \[
140
+
'tasks': [
138
141
{
139
-
'description': 'Perform research to gather information for a blog post on {request}.',
140
-
'expected_output': 'A summary of key insights related to the topic.',
142
+
'description': 'Analyze the recent sales data.',
143
+
'expected_output': 'A summary report of sales trends.',
141
144
'agent': {
142
-
'role': 'Research Agent',
143
-
'goal': 'Gather relevant information for the blog post',
144
-
'backstory': 'Expert in researching and summarizing information',
145
-
'tools': []
145
+
'role': 'Data Analyst',
146
+
'goal': 'Summarize sales data',
147
+
'backstory': 'Experienced in sales data analysis',
148
+
'tools': ['DataFetcher', 'SalesSummarizer']
146
149
}
147
150
},
148
-
# Additional tasks...
151
+
{
152
+
'description': 'Prepare a presentation based on the report.',
153
+
'expected_output': 'A presentation deck summarizing the sales report.',
154
+
'agent': {
155
+
'role': 'Presentation Specialist',
156
+
'goal': 'Create a presentation',
157
+
'backstory': 'Expert in creating engaging presentations',
158
+
'tools': ['PresentationBuilder']
159
+
}
160
+
}
149
161
],
150
162
'llm': {
151
163
'type': 'LangChainChatOpenAI',
152
-
'api_key': 'your-api-key',
153
-
'model_name': 'openai/gpt-4',
154
-
'base_url': 'your-base-url'
164
+
'api_key': 'your-api-key-here',
165
+
'model_name': 'gpt-4o-mini'
155
166
},
156
167
'verbose': True,
157
168
'memory': False
158
169
}
159
170
160
-
# Initialize the Task Force
171
+
# Initialize the Task Force with the provided configuration
161
172
task_force = TaskForce.create(TASK_FORCE_CONFIG)
162
-
Running the task force with an input message:
163
173
164
174
# Run the task force with an input message
165
-
input_message ="Write a blog post about the importance of renewable energy."
175
+
input_message ="Generate a sales analysis report and prepare a presentation."
166
176
result = task_force.run(input_message)
167
177
168
178
# Handle the response
@@ -174,74 +184,63 @@ else:
174
184
175
185
## LLM Agentic Tool Mesh in Action: Examples from the Repository
176
186
177
-
178
187
The LLM Agentic Tool Mesh GitHub repository includes several examples demonstrating the versatility and capabilities of the agent services.
179
188
180
-
181
189
### Chatbot application (examples/app_chatbot)
182
190
183
191
This chatbot is capable of reasoning and invoking appropriate LLM tools to perform specific actions. You can configure the chatbot using files that define LLM Agentic Tool Mesh platform services, project settings, toolkits, and memory configurations. The web app orchestrates both local and remote LLM tools, allowing them to define their own HTML interfaces, supporting text, images, and code presentations.
184
192
185
-
186
193
Configuration Example:
187
194
188
195
```yaml
189
-
190
-
projects:
191
-
- name: "Personal Chat"
192
-
memory:
193
-
type: LangChainBuffer
194
-
memory_key: chat_history
195
-
return_messages: true
196
-
tools:
197
-
- "https://127.0.0.1:5002/"# Basic Copywriter
198
-
- name: "Project 5G Network"
199
-
memory:
200
-
type: LangChainRemote
201
-
memory_key: chat_history
202
-
return_messages: true
203
-
base_url: "https://127.0.0.1:5010/"
204
-
timeout: 100
205
-
cert_verify: false
206
-
tools:
207
-
- "https://127.0.0.1:5005/"# OpenAPI Manager
208
-
- "https://127.0.0.1:5006/"# IMS Expert
209
-
- name: "Project Meteo"
210
-
memory:
211
-
type: LangChainBuffer
212
-
memory_key: chat_history
213
-
return_messages: true
214
-
tools:
215
-
- "https://127.0.0.1:5003/"# Temperature Finder
196
+
projects:
197
+
- name: "Personal Chat"
198
+
memory:
199
+
type: LangChainBuffer
200
+
memory_key: chat_history
201
+
return_messages: true
202
+
tools:
203
+
- "https://127.0.0.1:5002/"# Basic Copywriter
204
+
- name: "Project 5G Network"
205
+
memory:
206
+
type: LangChainRemote
207
+
memory_key: chat_history
208
+
return_messages: true
209
+
base_url: "https://127.0.0.1:5010/"
210
+
timeout: 100
211
+
cert_verify: false
212
+
tools:
213
+
- "https://127.0.0.1:5005/"# OpenAPI Manager
214
+
- "https://127.0.0.1:5006/"# IMS Expert
215
+
- name: "Project Meteo"
216
+
memory:
217
+
type: LangChainBuffer
218
+
memory_key: chat_history
219
+
return_messages: true
220
+
tools:
221
+
- "https://127.0.0.1:5003/"# Temperature Finder
216
222
- "https://127.0.0.1:5004/"# Temperature Analyzer
217
223
```
218
224
219
-
220
225
### OpenAPI manager (examples/tool_agents)
221
226
222
-
223
227
The OpenAPI Manager is a multi-agent tool that reads OpenAPI documentation and provides users with relevant information based on their queries. It uses the Task Force service to answer questions related to 5G APIs.
224
228
225
-
226
229
Capabilities:
227
230
228
-
229
-
* ListOpenApis: Lists all OpenAPI specifications present in the system.
230
-
* SelectOpenApi: Selects a specific OpenAPI specification.
231
-
* GetOpenApiVersion: Returns the OpenAPI version of the selected specification.
232
-
* GetInfo: Returns the information dictionary of the selected specification.
233
-
* GetMethodsByTag: Lists all methods of the selected specification for a specific tag.
234
-
* GetMethodById: Returns detailed information about a method selected by ID.
235
-
* GetRequestBody: Returns the request body schema of the selected specification.
231
+
* ListOpenApis: Lists all OpenAPI specifications present in the system.
232
+
* SelectOpenApi: Selects a specific OpenAPI specification.
233
+
* GetOpenApiVersion: Returns the OpenAPI version of the selected specification.
234
+
* GetInfo: Returns the information dictionary of the selected specification.
235
+
* GetMethodsByTag: Lists all methods of the selected specification for a specific tag.
236
+
* GetMethodById: Returns detailed information about a method selected by ID.
237
+
* GetRequestBody: Returns the request body schema of the selected specification.
236
238
* GetResponse: Returns the response schema of the selected specification.
237
239
238
-
239
-
240
-
Conclusion
240
+

241
241
242
-
243
-
The LLM Agentic Tool Mesh Agent Services exemplify how advanced design principles and innovative prompt engineering simplify and enhance the adoption of Gen AI. By abstracting complexities and providing versatile examples, LLM Agentic Tool Mesh enables developers and users alike to unlock the transformative potential of Gen AI in various domains.
242
+
## Conclusion
244
243
245
-
246
-
Stay tuned for our next post, where we'll explore another key service of LLM Agentic Tool Mesh and continue our journey to democratize Gen AI!
244
+
The **LLM Agentic Tool Mesh Agent Service** exemplifies how advanced design principles and innovative prompt engineering simplify and enhance the adoption of Gen AI. By abstracting complexities and providing versatile examples, LLM Agentic Tool Mesh enables developers and users alike to unlock the transformative potential of Gen AI in various domains.
247
245
246
+
Stay tuned for our next post, where we'll explore another key service of LLM Agentic Tool Mesh and continue our journey to democratize Gen AI!
0 commit comments