Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,13 @@ Fork the repository.
Create a new branch for your feature.
Add your feature or improvement.
Send a pull request.

We appreciate your input!

## Installing Dependencies

```cmd
poetry lock
poetry install
pre-commit install
```
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ for response in flo.stream("Write about recent AI developments"):
```

**Note:** You can make each of the above agents including the router to different models, giving flexibility to combine the power of different LLMs.
To know more, check multi-model integration in detailed [documentation](https://flo-ai.rootflo.ai)
To know more, check multi-model integration in detailed [documentation](https://flo-ai.rootflo.ai/advanced/model-switching)

### Lets Create a AI team using code

Expand Down Expand Up @@ -203,7 +203,7 @@ Along with that FloAI has a decorator `@flotool` which makes any function into a
Creating a simple tool using `@flotool`:

```python
from flo_ai import flotool
from flo_ai.tools import flotool
from pydantic import BaseModel, Field

# define argument schema
Expand Down
13 changes: 6 additions & 7 deletions ROADMAP.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,7 @@ Core features improve the library itself to cater wider range of functionalities

| Name | Description | Status | Release version |
|------|-------------|--------|-----------------|
| Full composability | Right now teams can only be combined with teams and agents with agents. We want to extend this to team + agent composibility | ✅ | 0.0.4 |
| Error handling | Ability to handle errors autonomously | ✅ | 0.0.4|
|LLM Extensibilty| Ability to different LLMs across different agents and teams| ✅ | 0.0.4|
|Async Tools| Ability create tools easily within asyncio | ✅ | 0.0.4|
|Observer| Observer framework for raising agent decision events and other important events | ✅ | 0.0.4|
|Output formatter| Ability to templatize output format using pydantic| Yet to start| 0.0.4|
|Auto-Query RAG| Ability to make metadata query within the agentic, which can automatically add metadata while rag query runs, like timestamp or other data|Yet to start|TBD|
|Parellel Router| A router to execute tasks or agents in parallel if the tasks are independent | Yet to start | TBD

## Observability
Expand All @@ -24,7 +18,6 @@ These features improve logging and debugging abilities while building.
| Name | Description | Status | Release version |
|------|-------------|--------|-----------------|
|Recursion control| Expose parameters like recursion control to limit recursions and policy in case of recursion etc | Yet to start | 0.0.5
|Set up tests| Create a framework for unit-testing flo-ai and its internal functionalities| ✅ | 0.0.4

## Community

Expand All @@ -47,6 +40,12 @@ The community is welcome to suggest changes to the roadmap, through a pull reque
|Reflection| Reflection lets you build a component that can make the AI retrospectively look at the current output and retry or work again on the task at hand| ✅ | 0.0.3|
|Delegator| Delegator lets you build a component that can help delegate a flo to a particular agent, by some condition| ✅ | 0.0.3|
|Logging Framework|Better logging framework which can be extended to parent application (with log level control)| ✅|0.0.3|
| Full composability | Right now teams can only be combined with teams and agents with agents. We want to extend this to team + agent composibility | ✅ | 0.0.4 |
| Error handling | Ability to handle errors autonomously | ✅ | 0.0.4|
|LLM Extensibilty| Ability to different LLMs across different agents and teams| ✅ | 0.0.4|
|Async Tools| Ability create tools easily within asyncio | ✅ | 0.0.4|
|Observer| Observer framework for raising agent decision events and other important events | ✅ | 0.0.4|
|Set up tests| Create a framework for unit-testing flo-ai and its internal functionalities| ✅ | 0.0.4



2 changes: 1 addition & 1 deletion examples/agent_of_flo_ai.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -429,7 +429,7 @@
}
],
"source": [
"from flo_ai import flotool\n",
"from flo_ai.tools import flotool\n",
"from langchain.tools import BaseTool\n",
"\n",
"@flotool(\"print_tool\", \"To print the state\")\n",
Expand Down
2 changes: 1 addition & 1 deletion examples/python/llm_extensibility.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from pydantic import BaseModel, Field
from langchain_openai import ChatOpenAI
from flo_ai.tools.flo_tool import flotool
from flo_ai.state.flo_callbacks import flo_agent_callback, FloCallbackResponse
from flo_ai.callbacks.flo_callbacks import flo_agent_callback, FloCallbackResponse

from dotenv import load_dotenv
import warnings
Expand Down
2 changes: 1 addition & 1 deletion examples/python/tool_error_handling.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from pydantic import BaseModel, Field
from typing import List
from dotenv import load_dotenv
from flo_ai import flotool
from flo_ai.tools import flotool
import asyncio

load_dotenv()
Expand Down
1 change: 0 additions & 1 deletion flo_ai/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
from flo_ai.core import Flo as Flo
from flo_ai.tools.flo_tool import flotool as flotool
from flo_ai.models.flo_team import FloTeam as FloTeam
from flo_ai.models.flo_agent import FloAgent as FloAgent
from flo_ai.router.flo_linear import FloLinear as FloLinear
Expand Down
13 changes: 13 additions & 0 deletions flo_ai/callbacks/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
from flo_ai.callbacks.flo_callbacks import (
flo_agent_callback,
flo_router_callback,
flo_tool_callback,
flo_call_back,
)

__all__ = [
'flo_agent_callback',
'flo_router_callback',
'flo_tool_callback',
'flo_call_back',
]
File renamed without changes.
2 changes: 1 addition & 1 deletion flo_ai/common/flo_langchain_logger.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
from langchain.callbacks.base import BaseCallbackHandler
from langchain.schema import AgentAction, AgentFinish, LLMResult
from flo_ai.common.flo_logger import get_logger
from flo_ai.state.flo_callbacks import FloToolCallback
from flo_ai.callbacks.flo_callbacks import FloToolCallback


class FloLangchainLogger(BaseCallbackHandler):
Expand Down
6 changes: 5 additions & 1 deletion flo_ai/models/flo_node.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,11 @@
from flo_ai.models.flo_executable import ExecutableType
from flo_ai.state.flo_session import FloSession
from typing import Optional, Type, List
from flo_ai.state.flo_callbacks import FloAgentCallback, FloRouterCallback, FloCallback
from flo_ai.callbacks.flo_callbacks import (
FloAgentCallback,
FloRouterCallback,
FloCallback,
)


class FloNode:
Expand Down
2 changes: 1 addition & 1 deletion flo_ai/state/flo_session.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from flo_ai.common.flo_logger import get_logger
from flo_ai.common.flo_langchain_logger import FloLangchainLogger
from flo_ai.helpers.utils import random_str
from flo_ai.state.flo_callbacks import (
from flo_ai.callbacks.flo_callbacks import (
FloToolCallback,
FloAgentCallback,
FloRouterCallback,
Expand Down
3 changes: 3 additions & 0 deletions flo_ai/tools/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
from flo_ai.tools.flo_tool import flotool

__all__ = ['flotool']