Hey, do metaflow support cycles? My 2 cents says n...
# ask-metaflow
b
Hey, do metaflow support cycles? My 2 cents says no as it is a DAG. I want to test a reasoning/feedback based AI Agent, with below system. This system covers both conditions and looping.
c
Work in progress to support conditional + loops in the FlowSpec node graph! As the Metaflow functionality lands in the coming weeks we'll share agent examples per your diagram 🙂
🎉 1
Would love to see what you cook up with the current PR if you are feeling adventurous.
v
@brainy-truck-72938 do you have PR that has both looping and conditionals?
b
it is on a branch on my fork, but I would wait for conditionals to get merged first and not combine both in a single PR because looping is a big enough change (even though small in number of lines) in itself in the sense that it requires its own exhaustive testing
👍 1
b
Will wait for PR to be merged! I was able to successfully test the conditional statement, where supervisor agent choose one of the 2 agents based on response.
🔥 1
v
nice!
@bland-garden-80695 another thing that would be fun to test is to have a custom decorator that calls an LLM and choose what path to take - you can find inspiration for a custom decorator e.g. here
👍 1
b
Hey Team, I came up 2 basic testing for Agentic workflow with metaflow. This both performs the same tasks, just 1 with conditions and other with decorators. To summarize: "I prompt LLM to choose between 2 choices. Based on the response next step is triggered to perform the task associated with the choice." You can find the source code here. Its under metaflow/tutorials, specifically 09-ai-agent and 10-ai-agent-decorator. I would appreciate any feedback on it.
chef kiss 2
v
awesome! In case you didn't notice, here's the official announcement post about Agentic Metaflow if you want, you could explore using other agent frameworks like LangChain with Metaflow. Here's an example wrapper from the announcement that uses OpenAI Agent SDK
b
Hey Ville, Indeed I read your blog and linkedIn post. Congrats on new achievement! I will play around with different frameworks in Metaflow.
🙌 1
v
awesome! Keep sharing your findings and questions here!
👍 1
b
Hey @victorious-lawyer-58417, I have this idea and want to build with metaflow. The project is called "context Aware Code Search Agent". I want to build an agent, that can answer questions asked by user. The idea is to build around metaflow codebase and documentation. When the new users/existing wants to know something about the metaflow, they can ask the agent and it can search for it inside the code or through documentation. I would like to eventually integrate with this slack channel, so when some ask something, they can Agentic response to it. If possible maybe give agent access to previous slack chat if privacy is not a concern, hence repeated questions can be answered. I want to know few things from you. 1. Your thoughts on this idea. 2. Is metaflow a good platform for this? as this project will uses real time inference? 3. I want this to a real project, something that can add value to my profile. I would like it to be used by real users, if it works as expected.