-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Convert ai_news_generator to use CrewAI flows for agentic workflow #171
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
base: main
Are you sure you want to change the base?
Convert ai_news_generator to use CrewAI flows for agentic workflow #171
Conversation
- Replaced simple Crew implementation with CrewAI Flow architecture - Added @start decorator for research phase (Senior Research Analyst) - Added @listen decorator for writing phase (Content Writer) - Created structured two-phase workflow ensuring proper task sequencing - Updated README with architecture documentation and improved formatting - Fixed title capitalization in README Resolves issue patchy631#168: use crewai flow instead of simple crew 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
WalkthroughThe changes refactor the AI news generator application to use CrewAI Flows, transitioning from a simple sequential agent setup to a structured, two-phase agentic workflow. The README is updated to reflect these architectural changes, and the application logic is encapsulated within a new flow class, enhancing modularity and clarity. Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant Streamlit UI
participant NewsGeneratorFlow
participant Senior Research Analyst
participant Content Writer
User->>Streamlit UI: Enter topic & submit
Streamlit UI->>NewsGeneratorFlow: generate_content(topic)
NewsGeneratorFlow->>Senior Research Analyst: research_phase(topic)
Senior Research Analyst-->>NewsGeneratorFlow: research_output
NewsGeneratorFlow->>Content Writer: writing_phase(research_output)
Content Writer-->>NewsGeneratorFlow: final_blog_post
NewsGeneratorFlow-->>Streamlit UI: Return final_blog_post
Streamlit UI-->>User: Display blog post
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~15 minutes Assessment against linked issues
Assessment against linked issues: Out-of-scope changesNo out-of-scope changes found. Possibly related PRs
Poem
Note ⚡️ Unit Test Generation is now available in beta!Learn more here, or try it out under "Finishing Touches" below. 📜 Recent review detailsConfiguration used: CodeRabbit UI ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (2)
🔇 Additional comments (9)
✨ Finishing Touches
🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
Summary
This PR solves issue #168 by converting the ai_news_generator project from a simple CrewAI crew to use CrewAI Flows, creating a proper agentic workflow.
Key Changes
• Replaced simple Crew with CrewAI Flow architecture
NewsGeneratorFlow
class extendingFlow
• Phase 1: Research Phase (@start)
• Phase 2: Writing Phase (@listen)
• Updated Documentation
Technical Implementation
@start()
decorator to mark the initial research phase@listen(research_phase)
for proper task sequencingBenefits
Test Plan
Closes #168
🤖 Generated with Claude Code
Summary by CodeRabbit
Documentation
Refactor