-
Notifications
You must be signed in to change notification settings - Fork 1
Installation
This step-by-step guide will walk you through the process of setting up the LLM Agentic Tool Mesh platform on your machine. Whether you're a developer or a non-technical user, we've made the installation process straightforward and easy to follow. By the end of this guide, you will have LLM Agentic Tool Mesh fully installed and ready to use, allowing you to start creating and managing your Gen AI tools and applications.
- Python Version: LLM Agentic Tool Mesh requires Python ^3.11.9. Ensure you have the correct version installed, which can be downloaded from the official Python website.
-
API Key: Set your LLM API key, for instance for ChatGPT by assigning it to the
OPENAI_API_KEY
environment variable.
You can choose between two setup methods based on your needs:
-
LLM Agentic Tool Mesh Services Only: For users who only need the core LLM Agentic Tool Mesh services, this option allows for a straightforward
pip
installation without example applications, enabling quick access to core functionalities. - Full Example Setup: Ideal for those looking to explore the full capabilities of LLM Agentic Tool Mesh, this setup includes example applications and tools, along with necessary dependencies and configuration steps to get the complete environment up and running.
If you only need the core LLM Agentic Tool Mesh services without the example applications, you can install them directly via pip
:
pip install 'llmesh[all]'
After installation, refer to the Usage Guide for instructions on using platform services.
If you want to install the full LLM Agentic Tool Mesh setup, including example applications, follow these steps:
First, clone the project repository to your local machine using Git:
git clone https://github.com/HewlettPackard/llmesh
cd athon
Create and activate a virtual environment for the project:
cd llmesh # Navigate to the project directory if you haven't already.
python3.11 -m venv .venv
source .venv/bin/activate
This will create a new virtual environment in the directory .venv
and activate it.
Install the necessary project dependencies using Poetry:
poetry install --all-extras
Alternatively, install using pip
with the published wheel file:
pip install "path/to/ll_mesh-0.1.0-py3-none-any.whl[all]"
All dependencies are specified in the pyproject.toml
file.
Configure the required environment variables for the reasoning engine and other services:
-
Open the virtual environment's activate script:
vi .venv/bin/activate
-
Add the following lines at the end of the file:
export OPENAI_API_KEY=[Your OpenAI API Key] export GOOGLE_API_KEY=[Your Google Gemini API Key] export ANTHROPIC_API_KEY=[Your Anthropic Claude API Key] export MISTRAL_API_KEY=[Your Mistral API Key] export NVIDIA_API_KEY=[Your NVIDIA API Key] export TAVILY_API_KEY=[Your Tavily API Key] export HPE_DEPLOYMENT=[Your HPE Deployment] export HPE_API_KEY=[Your HPE API Key] export HPE_ENDPOINT=[Your HPE Endpoint]
Replace the bracketed sections with your actual keys and endpoints. Note that you should set
HPE_*
variables if you use ChatHPE andOPENAI_API_KEY
if you use ChatGPT (look Usage Guide for details). -
Save and exit the file, then reactivate your virtual environment:
deactivate source .venv/bin/activate
Two example tools require additional data that is not included in the Git repository to function properly:
tool_analyzer
tool_rag
Follow the steps below to prepare the necessary data for each tool.
-
Create Data Directory
First, create the required data folder for thetool_analyzer
:mkdir -p ./examples/tool_analyzer/data # This will create the necessary directories.
-
Download Data File
Next, download the temperature data file GlobalLandTemperaturesByCountry.csv from the web and copy it into the newly createddata
folder:# Example command to download the file directly to the directory (Linux/MacOS) wget -O ./examples/tool_analyzer/data/GlobalLandTemperaturesByCountry.csv https://github.com/gindeleo/climate/raw/master/GlobalLandTemperaturesByCountry.csv
-
Create Data Directory
Similarly, create the data folder for thetool_rag
:mkdir -p ./examples/tool_rag/data # This will create the necessary directories.
-
Obtain Documentation
Download the 5G specifications 23.501 and 23.502 from 3GPP website, , ensuring that the versions match those specified in the configuration file:data: path: examples/tool_rag/data/ files: - source: 23501-i60.docx # Ensure the version is correct (e.g. i60) - source: 23502-i60.docx # Ensure the version is correct (e.g. i60)
-
Inject File into Vector Database
To load the document into the vector database, enable theload_files
option in theexamples/tool_rag/config.yaml
file:function: ... debug: load_files: true
-
Run the Tool
Run themain.py
script to process the document:python examples/tool_rag/main.py
After running the script, make a request to trigger the file load:
-
Reset Configuration
Once the file has been successfully loaded, set theload_files
option back tofalse
in theconfig.yaml
file to prevent reloading the files in future runs:function: ... debug: load_files: false
-
Download and Prepare the API Files
First, download the API YAML files from the repository at https://github.com/jdegre/5GC_APIs. Extract the downloaded.zip
file into the./examples/tool_agents/data/
directory. For example, if you download the5GC_APIs-Rel-18
version, extract it to create a folder like:./examples/tool_agents/data/5GC_APIs-Rel-18/
-
Update the Configuration File
After extracting the files, update the configuration file to specify the path to the newly created folder. For example, update the path in the configuration file to:path: examples/tool_agents/data/5GC_APIs-Rel-18/
After completing the above steps, your project environment should be set up and ready to go.