Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: examples parity #336

Open
2 of 3 tasks
Tomas2D opened this issue Feb 19, 2025 · 15 comments
Open
2 of 3 tasks

feat: examples parity #336

Tomas2D opened this issue Feb 19, 2025 · 15 comments
Assignees
Labels
python Python related functionality

Comments

@Tomas2D
Copy link
Contributor

Tomas2D commented Feb 19, 2025


Note: For all examples, as part of QA, ensure the requirements.txt file reflects any dependencies

Agents

HIGH PRIORITY ✅

TS example PY example Responsible Py example added Example passes QA
agents/bee.ts agents/bee.py @ajbozarth
agents/simple.ts agents/simple.py @ajbozarth
agents/custom_agent.ts agents/custom_agent.py @ajbozarth
agents/granite.ts agents/granite_bee.py (name mismatch?) @ajbozarth
agents/advanced.ts agents/advanced.py @ajbozarth

FUTURE PRIORITY

TS example PY example Responsible Py example added Example passes QA
agents/bee_instrumentation.ts could add, seems redundant TBD 📋
agents/elasticsearch.ts ElasticSearchTool not implemented TBD
agents/sql.ts SQLTool not implemented TBD
agents/bee_reusable.ts needs Agent serialization, check if BaseModel serialization works TBD 📋
agents/experimental/streamlit.ts StreamlitAgent not implemented TBD
agents/experimental/human.ts HumanTool not implemented TBD
agents/experimental/replan.ts RePlanAgent not implemented TBD
agents/experimental/granite_wiki_bee.ts SimilarityTool not implemented TBD

Memory ✅

HIGH PRIORITY ✅

TS example PY example Responsible Py example added Example passes QA
memory/base.ts memory/base.py @AngeloDanducci
memory/llmMemory.ts memory/llm_memory.py @AngeloDanducci
memory/custom.ts memory/custom.py @AngeloDanducci
memory/slidingMemory.ts memory/sliding_memory.py @AngeloDanducci
memory/summarizeMemory.ts summarize_memory.py @AngeloDanducci
memory/tokenMemory.ts token_memory.py @AngeloDanducci
memory/unconstrainedMemory.ts unconstrained_memory.py @AngeloDanducci
memory/agentMemory.ts memory/agent_memory.py @AngeloDanducci

Workflows

HIGH PRIORITY ✅

TS example PY example Responsible Py example added Example passes QA
workflows/simple.ts workflows/simple.py @AngeloDanducci
workflows/nesting.ts workflows/nesting.py @AngeloDanducci
workflows/agent.ts not referenced in docs, similar to multi agents, skipped @AngeloDanducci
workflows/multiAgents.ts workflows/multi_agents.py @AngeloDanducci
workflows/multiAgentsSimple.ts workflows/multiAgentsSimple.py @AngeloDanducci
moved to nesting workflows/advanced.py @AngeloDanducci
no equivalent candidate for removal workflows/memory.py @AngeloDanducci
no equivalent, cant run in CI without searx setup workflows/web_agent.py @AngeloDanducci

FUTURE PRIORITY

TS example PY example Responsible Py example added Example passes QA
workflows/contentCreator.ts could add TBD 📋

Backend

HIGH PRIORITY ✅

TS example PY example Responsible Py example added Example passes QA
backend/providers/watsonx.ts backend/providers/watsonx.py @ajbozarth
backend/providers/ollama.ts backend/providers/ollama.py @ajbozarth
backend/providers/openai.ts backend/providers/openai.py @ajbozarth
backend/providers/groq.ts backend/providers/groq.py @ajbozarth
backend/chat.ts backend/chat.py @ajbozarth
backend/chatStream.ts backend/chatStream.py @ajbozarth
backend/structured.ts backend/structured.py @ajbozarth
backend/toolCalling.ts backend/toolCalling.py @ajbozarth
backend/providers/amazon-bedrock.ts backend/providers/amazon_bedrock #466
backend/providers/vertexai.ts backend/providers/vertexai.py #469

FUTURE PRIORITY

TS example PY example Responsible Py example added Example passes QA
backend/backend.ts Backend not implemented TBD
backend/providers/anthropic.ts AnthropicChatModel not implemented TBD
backend/providers/azure-openai.ts backend/providers/azure_openai.py #514 📋
backend/providers/langchain.ts LangChainChatModel not implemented TBD
backend/providers/watsonx_debug.ts could add, maybe in backend/providers/watsonx.py TBD 📋

Tools

HIGH PRIORITY ✅

TS example PY example Responsible Py example added Example passes QA
is there a TS equivalent? tools/duckduckgo.py @AngeloDanducci
is there a TS equivalent? tools/decorator.py @AngeloDanducci
is there a TS equivalent? tools/openmeteo.py @AngeloDanducci
is there a TS equivalent? tools/wikipedia.py @AngeloDanducci
tools/advanced.ts tools/advanced.py @AngeloDanducci
tools/agent.ts tools/agent.py @AngeloDanducci
tools/base.ts tools/base.py @AngeloDanducci
tools/mcp.ts tools/mcp_agent.py #481
- tools/mcp_tool_creation.py #481
tools/langchain.ts tools/langchain.py #474
tools/custom/base.ts tools/custom/base.py @AngeloDanducci
tools/custom/openLibrary.ts tools/custom/openlibrary.py @AngeloDanducci

FUTURE PRIORITY

TS example PY example Responsible Py example added Example passes QA
tools/llm.ts LLMTool not implemented TBD
tools/openapi.ts OpenAPITool not implemented TBD
tools/custom/dynamic.ts DynamicTool not implemented TBD
tools/custom/extending.ts Tool.extend not implemented TBD
tools/custom/piping.ts SimilarityTool not implemented TBD
tools/custom/python.ts CustomTool not implemented TBD
tools/experimental/human.ts could add TBD 📋
tools/instrumentation.ts could add TBD 📋

Emitter ✅

HIGH PRIORITY ✅

TS example PY example Responsible Py example added Example passes QA
emitter/base.ts emitter/base.py @ajbozarth
emitter/advanced.ts emitter/advanced.py @ajbozarth
emitter/matchers.ts emitter/matchers.py @ajbozarth
emitter/piping.ts emitter/piping.py @ajbozarth
emitter/agentMatchers.ts emitter/agent_matchers.py @ajbozarth

Errors ✅

HIGH PRIORITY ✅

TS example PY example Responsible Py example added Example passes QA
errors/base.ts errors/base.py @AngeloDanducci
errors/tool.ts errors/tool.py @AngeloDanducci
errors/cast.ts errors/cast.py @AngeloDanducci

Logger ✅

HIGH PRIORITY ✅

TS example PY example Responsible Py example added Example passes QA
logger/base.ts logger/base.py @AngeloDanducci
logger/agent.ts logger/agent.py @AngeloDanducci
logger/pino.ts python doesn't use pino @AngeloDanducci

Templates ✅

HIGH PRIORITY ✅

TS example PY example Responsible Py example added Example passes QA
templates/primitives.ts templates/basic_template.py (diff name due to broader example) @ajbozarth
templates/arrays.ts templates/arrays.py @ajbozarth
templates/objects.ts templates/objects.py @ajbozarth
templates/forking.ts templates/forking.py @ajbozarth
templates/functions.ts templates/functions.py @ajbozarth
No TS equivalent templates/system_prompt.py @ajbozarth

Serialization

FUTURE PRIORITY

TS example PY example Responsible Py example added Example passes QA
serialization/base.ts could add, Serializer exists TBD 📋
serialization/memory.ts BaseMemory does not implement Serializable TBD
serialization/customExternal.ts could add, Serializer exists TBD 📋
serialization/customInternal.ts could add, Serializable exists TBD 📋
serialization/context.ts BaseMemory does not implement Serializable TBD

Cache

FUTURE PRIORITY

TS example PY example Responsible Py example added Example passes QA
cache/cacheFn.ts CacheFn not implemented TBD
cache/custom.ts could add, BaseCache exists TBD 📋
cache/decoratorCache.ts Cache decorator not implemented TBD
cache/decoratorCacheComplex.ts Cache decorator not implemented TBD
cache/fileCache.ts could add FileCache exists TBD 📋
cache/fileCacheCustomProvider.ts could add, UnconstrainedCache and FileCache exist TBD 📋
cache/llmCache.ts ChatModel.cache not implemented TBD
cache/slidingCache.ts could add, SlidingCache exists TBD 📋
cache/toolCache.ts Tool.cache not implemented TBD
cache/unconstrainedCache.ts could add, UnconstrainedCache exists TBD 📋
cache/unconstrainedCacheFunction.ts could add, UnconstrainedCache exists TBD 📋

Integrations

FUTURE PRIORITY

TS example PY example Responsible Py example added Example passes QA
integrations/langgraph.ts LangChainOllamaChat not implemented TBD
@Tomas2D Tomas2D added the python Python related functionality label Feb 19, 2025
@Tomas2D Tomas2D added this to the Hackaton (python_v0.1.1) milestone Feb 19, 2025
@ajbozarth
Copy link
Member

I believe we can move this out of the Hackathon milestone and I'll continue work in it into next week

@jenna-winkler
Copy link
Contributor

jenna-winkler commented Feb 24, 2025

@ajbozarth Can we please prioritize examples/agents/custom_agent.py 🙏
docs: https://github.com/i-am-bee/beeai-framework/blob/main/python/docs/agents.md#creating-your-own-agent

@jenna-winkler
Copy link
Contributor

jenna-winkler commented Feb 24, 2025

@ajbozarth please also prioritize /python/examples/workflows/nesting.py
docs: https://github.com/i-am-bee/beeai-framework/blob/main/python/docs/workflows.md#nesting

@jenna-winkler
Copy link
Contributor

jenna-winkler commented Feb 24, 2025

Flagging a todo item within this sample code /python/examples/workflows/web_agent.py

Image

**this one we can skip for now, its not mentioned in the docs

@jenna-winkler
Copy link
Contributor

jenna-winkler commented Feb 25, 2025

@mmurad2 mmurad2 added the blocked Waiting for an external factor to be completed. label Feb 25, 2025
@mmurad2 mmurad2 assigned AngeloDanducci and ajbozarth and unassigned ajbozarth Feb 25, 2025
@mmurad2 mmurad2 removed the blocked Waiting for an external factor to be completed. label Feb 25, 2025
@mmurad2
Copy link
Contributor

mmurad2 commented Feb 25, 2025

@jenna-winkler to include references of docs with examples to update

@jenna-winkler
Copy link
Contributor

@ajbozarth added docs reference points above

@jenna-winkler
Copy link
Contributor

I created a table in the body of this issue to keep things organized @ajbozarth @AngeloDanducci

@jenna-winkler
Copy link
Contributor

@ajbozarth @AngeloDanducci I did a complete comparison of TS and PY examples and documented our status above

@ajbozarth
Copy link
Member

FYI I added section folding to the tables at the top for easier reading. The LOWER PRIORITY tables are now hidden by default and any table can be folded or opened for easier reading while we work on this

@ajbozarth
Copy link
Member

@planetf1
Copy link
Contributor

planetf1 commented Mar 6, 2025

I didn't see it in the list, but there is a version.py just containing a TODO.

@ajbozarth
Copy link
Member

I've gone through the tables and opened all the FUTURE PRIORITY tables and added each examples current state in the PY example column and if there no implementation blocker I added a 📋 in the Py example added.

From this we can see what's blocked by what implementation and what items are ready to pick up.

@planetf1
Copy link
Contributor

planetf1 commented Mar 6, 2025

There were basic examples for ollama/watsonx/openai. Recently I've added groq, xai, amazon bedrock, google vertex, microsoft openai (draft PR) providers, so have made sure to include samples as part of that .

Anthropic is next on the list which I'll likely start looking at tomorrow.

That gets us to a baseline, but there's a lot more we can do

Did you have any specific thoughts about the provider examples? In one regard they're little more than a one-shot technical example of a few usage patterns with a specific provider/model. I think we can do more in futures and have some ideas we could discuss

@ajbozarth
Copy link
Member

I like how much more robust the python backend provider examples are. The TS versions are trivial

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
python Python related functionality
Projects
None yet
Development

No branches or pull requests

6 participants