mirror of
https://github.com/crewAIInc/crewAI.git
synced 2025-12-24 08:18:31 +00:00
Compare commits
49 Commits
gui/fix-th
...
knowledge
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c0ad4576e2 | ||
|
|
6359b64d22 | ||
|
|
9329119f76 | ||
|
|
38c0d61b11 | ||
|
|
8564f5551f | ||
|
|
8a5404275f | ||
|
|
52189a46bc | ||
|
|
44ab749fda | ||
|
|
3c4504bd4f | ||
|
|
23276cbd76 | ||
|
|
fe18da5e11 | ||
|
|
76da972ce9 | ||
|
|
4663997b4c | ||
|
|
b185b9e289 | ||
|
|
787f2eaa7c | ||
|
|
e7d816fb2a | ||
|
|
8373c9b521 | ||
|
|
ec2fe6ff91 | ||
|
|
58bf2d57f7 | ||
|
|
705ee16c1c | ||
|
|
0c5b6f2a93 | ||
|
|
914067df37 | ||
|
|
de742c827d | ||
|
|
efa8a378a1 | ||
|
|
e882725b8a | ||
|
|
cbfdbe3b68 | ||
|
|
c8bf242633 | ||
|
|
70910dd7b4 | ||
|
|
b104404418 | ||
|
|
d579c5ae12 | ||
|
|
4831dcb85b | ||
|
|
cbfcde73ec | ||
|
|
b2c06d5b7a | ||
|
|
352d05370e | ||
|
|
b90793874c | ||
|
|
cdf5233523 | ||
|
|
cb03ee60b8 | ||
|
|
10f445e18a | ||
|
|
98a708ca15 | ||
|
|
7b59c5b049 | ||
|
|
86ede8344c | ||
|
|
59165cbad8 | ||
|
|
4af263ca1e | ||
|
|
617ee989cd | ||
|
|
6131dbac4f | ||
|
|
1a35114c08 | ||
|
|
a8a2f80616 | ||
|
|
dc314c1151 | ||
|
|
75322b2de1 |
@@ -100,7 +100,7 @@ You can now start developing your crew by editing the files in the `src/my_proje
|
||||
|
||||
#### Example of a simple crew with a sequential process:
|
||||
|
||||
Instantiate your crew:
|
||||
Instatiate your crew:
|
||||
|
||||
```shell
|
||||
crewai create crew latest-ai-development
|
||||
@@ -399,7 +399,7 @@ Data collected includes:
|
||||
- Roles of agents in a crew
|
||||
- Understand high level use cases so we can build better tools, integrations and examples about it
|
||||
- Tools names available
|
||||
- Understand out of the publicly available tools, which ones are being used the most so we can improve them
|
||||
- Understand out of the publically available tools, which ones are being used the most so we can improve them
|
||||
|
||||
Users can opt-in to Further Telemetry, sharing the complete telemetry data by setting the `share_crew` attribute to `True` on their Crews. Enabling `share_crew` results in the collection of detailed crew and task execution data, including `goal`, `backstory`, `context`, and `output` of tasks. This enables a deeper insight into usage patterns while respecting the user's choice to share.
|
||||
|
||||
|
||||
@@ -310,8 +310,8 @@ These are examples of how to configure LLMs for your agent.
|
||||
from crewai import LLM
|
||||
|
||||
llm = LLM(
|
||||
model="llama-3.1-sonar-large-128k-online",
|
||||
base_url="https://api.perplexity.ai/",
|
||||
model="perplexity/mistral-7b-instruct",
|
||||
base_url="https://api.perplexity.ai/v1",
|
||||
api_key="your-api-key-here"
|
||||
)
|
||||
agent = Agent(llm=llm, ...)
|
||||
@@ -400,4 +400,4 @@ This is particularly useful when working with OpenAI-compatible APIs or when you
|
||||
- **API Errors**: Check your API key, network connection, and rate limits.
|
||||
- **Unexpected Outputs**: Refine your prompts and adjust temperature or top_p.
|
||||
- **Performance Issues**: Consider using a more powerful model or optimizing your queries.
|
||||
- **Timeout Errors**: Increase the `timeout` parameter or optimize your input.
|
||||
- **Timeout Errors**: Increase the `timeout` parameter or optimize your input.
|
||||
@@ -1,6 +1,6 @@
|
||||
import io
|
||||
import logging
|
||||
import sys
|
||||
import threading
|
||||
import warnings
|
||||
from contextlib import contextmanager
|
||||
from typing import Any, Dict, List, Optional, Union
|
||||
@@ -13,25 +13,16 @@ from crewai.utilities.exceptions.context_window_exceeding_exception import (
|
||||
)
|
||||
|
||||
|
||||
class FilteredStream:
|
||||
def __init__(self, original_stream):
|
||||
self._original_stream = original_stream
|
||||
self._lock = threading.Lock()
|
||||
|
||||
def write(self, s) -> int:
|
||||
with self._lock:
|
||||
if (
|
||||
"Give Feedback / Get Help: https://github.com/BerriAI/litellm/issues/new"
|
||||
in s
|
||||
or "LiteLLM.Info: If you need to debug this error, use `litellm.set_verbose=True`"
|
||||
in s
|
||||
):
|
||||
return 0
|
||||
return self._original_stream.write(s)
|
||||
|
||||
def flush(self):
|
||||
with self._lock:
|
||||
return self._original_stream.flush()
|
||||
class FilteredStream(io.StringIO):
|
||||
def write(self, s):
|
||||
if (
|
||||
"Give Feedback / Get Help: https://github.com/BerriAI/litellm/issues/new"
|
||||
in s
|
||||
or "LiteLLM.Info: If you need to debug this error, use `litellm.set_verbose=True`"
|
||||
in s
|
||||
):
|
||||
return
|
||||
super().write(s)
|
||||
|
||||
|
||||
LLM_CONTEXT_WINDOW_SIZES = {
|
||||
@@ -69,8 +60,8 @@ def suppress_warnings():
|
||||
# Redirect stdout and stderr
|
||||
old_stdout = sys.stdout
|
||||
old_stderr = sys.stderr
|
||||
sys.stdout = FilteredStream(old_stdout)
|
||||
sys.stderr = FilteredStream(old_stderr)
|
||||
sys.stdout = FilteredStream()
|
||||
sys.stderr = FilteredStream()
|
||||
|
||||
try:
|
||||
yield
|
||||
|
||||
@@ -20,10 +20,10 @@ from pydantic import (
|
||||
from pydantic_core import PydanticCustomError
|
||||
|
||||
from crewai.agents.agent_builder.base_agent import BaseAgent
|
||||
from crewai.tools.base_tool import BaseTool
|
||||
from crewai.tasks.output_format import OutputFormat
|
||||
from crewai.tasks.task_output import TaskOutput
|
||||
from crewai.telemetry.telemetry import Telemetry
|
||||
from crewai.tools.base_tool import BaseTool
|
||||
from crewai.utilities.config import process_config
|
||||
from crewai.utilities.converter import Converter, convert_to_model
|
||||
from crewai.utilities.i18n import I18N
|
||||
@@ -208,9 +208,7 @@ class Task(BaseModel):
|
||||
"""Execute the task asynchronously."""
|
||||
future: Future[TaskOutput] = Future()
|
||||
threading.Thread(
|
||||
daemon=True,
|
||||
target=self._execute_task_async,
|
||||
args=(agent, context, tools, future),
|
||||
target=self._execute_task_async, args=(agent, context, tools, future)
|
||||
).start()
|
||||
return future
|
||||
|
||||
@@ -279,9 +277,7 @@ class Task(BaseModel):
|
||||
content = (
|
||||
json_output
|
||||
if json_output
|
||||
else pydantic_output.model_dump_json()
|
||||
if pydantic_output
|
||||
else result
|
||||
else pydantic_output.model_dump_json() if pydantic_output else result
|
||||
)
|
||||
self._save_file(content)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user