mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-01-08 15:48:29 +00:00
@@ -31,14 +31,17 @@ pip install crewai
|
||||
2. **Setting Up Your Crew**:
|
||||
|
||||
```python
|
||||
import os
|
||||
from crewai import Agent, Task, Crew, Process
|
||||
|
||||
os.environ["OPENAI_API_KEY"] = "Your Key"
|
||||
|
||||
# Define your agents with roles and goals
|
||||
researcher = Agent(
|
||||
role='Researcher',
|
||||
goal='Discover new insights',
|
||||
backstory="You're a world class researcher working on a major data science company",
|
||||
verbose=True
|
||||
verbose=True,
|
||||
allow_delegation=False
|
||||
# llm=OpenAI(temperature=0.7, model_name="gpt-4"). It uses langchain.chat_models, default is GPT4
|
||||
)
|
||||
@@ -46,7 +49,7 @@ writer = Agent(
|
||||
role='Writer',
|
||||
goal='Create engaging content',
|
||||
backstory="You're a famous technical writer, specialized on writing data related content",
|
||||
verbose=True
|
||||
verbose=True,
|
||||
allow_delegation=False
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user