This repository contains code to load crewAI configuration usin gq Grqdio UI from excel xls and generate the python code for a crew-job combination. A job is a sequence of tasks. The source of the crews is defined in the xls. It allows for quick prototyping and iterations without having to edit code, There is a set of basic agents which have tools defined. This is only a subset of what currently is available through crewai tools.
A new clean requirements.txt is generated; command is in .sh file
Default pip install of the package
Default install of the crewai tools
Other langchain packages that are used are listed in requirements.txt
Excel format is xlsx, list of sheets are read and loaded. The actual preparation of the crews is done beforehand as the crew details do not change much once developed.
API keys need to be provided as part of the environment, both running straight from source and when using docker container eg when hosting on render.com
First get the project dependencies installed
pip install -r requirements.txt
just run locally as
python3 main.py
and follow the gradio instructions on screen to open your browser and use the UI.
To allow easy deployment a docker image is provided;
When you're ready, start your application by running:
docker compose up --build
.
Your application will be available at http://localhost:8000.
First, build your image, e.g.: docker build -t myapp .
.
If your cloud uses a different CPU architecture than your development
machine (e.g., you are on a Mac M1 and your cloud provider is amd64),
you'll want to build the image for that platform, e.g.:
docker build --platform=linux/amd64 -t myapp .
.
Then, push it to your registry, e.g. docker push myregistry.com/myapp
.
Consult Docker's getting started docs for more detail on building and pushing.
The excel file contains the complete setup to run a crew. Please note , not all parameters are implemented yet, but most are and up-to-date with version 0.41 from crewAI.
Supporting additonal parameters entails adding the column, matching the name to the template {variable} taking care of quoteds strings when needed. If something more fancy is needed, you have to either add to the generate_crew code, or within the class constructor.
Defining the providers and available models. The templates/llm_class_template.py has the import statement for the provider. To support additional providers, you need to add these to the class template, additional models for already configured providders, you only need to add a row in the xls sheet with the details.
To stick to crewAI terminology, a job is a collection of tasks
The xls contains the trip planner example, other jobs and tasks are development test cases, not necessarily working well.
Crews are defined to tackle specific jobs. Agens have the tools and are assebled into crews.