Skip to content
/

Getting started

Your first crewChapter 5 of 142 min read

Set up the project environment, configure language model access, and download the commercial contract your agents will review.


Project setup#

Create an isolated workspace and install the required dependencies:

Terminal
$ mkdir contract-crew && cd contract-crew
$ python3.13 -m venv env
$ source env/bin/activate

(env)$ pip install crewai==1.15.28 crewai-tools==1.15.28

Choose a model#

CrewAI reads provider configurations from environment variables. Set MODEL to your target language model in a .env file:

.env
# .env

MODEL=gpt-4.1-mini
OPENAI_API_KEY=<your-openai-api-key>

To run models locally without API fees, install Ollama and pull an open-weights model:

Terminal
$ ollama pull llama3.2
.env
# .env

MODEL=ollama/llama3.2

Exclude credentials and build artifacts from version control:

.gitignore
# .gitignore
.envenvoutput__pycache__

Sample contract#

The crew reviews a commercial software agreement between Acme Analytics and Northwind Traders. Download the document into a contracts directory:

Terminal
(env)$ mkdir contracts
(env)$ curl -o contracts/acme-saas-agreement.md https://textview.ai/learn-files/introduction-to-agentic-systems/acme-saas-agreement.md

Review the renewal and pricing terms in Section 2:

Markdown
## 2. Term and renewal

2.1 The initial term starts on the Effective Date and lasts 12 months.

2.2 After the initial term, this Agreement renews automatically for successive 12-month renewal terms unless either party gives written notice of non-renewal at least 60 days before the end of the then-current term.

2.3 Provider may increase the fees for any renewal term by up to 7% by giving Customer notice at least 30 days before that renewal term starts.

Verify your initial directory structure:

Project structure
contract-crew├── .env├── .gitignore└── contracts    └── acme-saas-agreement.md

Initialize version control to track project changes:

Terminal
(env)$ git init && git add . && git commit -m "Initial commit"