Kevin, an adept AI software engineer, possesses the capability to understand human prompts, deconstruct them into actionable steps, conduct pertinent research, and generate code to accomplish specified goals. Leveraging expansive language models, strategic planning algorithms, and adept web browsing skills, Kevin adeptly crafts software solutions.
His mission is to transform software development practices by offering an AI programmer capable of tackling intricate coding challenges with minimal human intervention. Whether it's crafting new functionalities, rectifying bugs, or initiating projects from inception, Kevin stands ready to provide invaluable assistance.
NOTE: Keivn is a simpler version of the Cognition AI's Devin, partially trying to be an open-source alternative to it.
NOTE: Kevins' prompt templates and project structure are inspired by Devika; an actual try to clone Cognition's AI Devin.
To install Kevin locally:
git clone https://github.com/MohammedAly22/Kevin.git
cd kevin
python -m venv kevin-env
kevin-env/Scripts/activate # On Windows
source kevin-env/bin/activate # On macOS/Linux
pip install -r requirements.txt
streamlit run frontend/main.py
Kevin functions as an AI-powered software engineer, capable of transforming user prompts into structured, functional codebases. Here's how Kevin's intelligent workflow unfolds:
The journey begins when the user selects a base model — currently supporting advanced LLMs like Cohere
and Gemini-Pro
. After entering a valid API_KEY
, the user is taken to Kevin’s workspace dashboard to kickstart their project.
Within the workspace, the user submits a task-related prompt, typically a code-related request. This triggers Kevin’s core logic.
Kevin’s DecisionTaker
agent analyzes the prompt and determines the next course of action:
- For code assistance tasks, it proceeds with planning.
- For general programming questions, it responds directly.
- For unrelated topics, Kevin courteously reminds users of his code-focused expertise.
📊 Diagram Suggestion: Kevin's Workflow Decision Tree
(DecisionTaker → [Code Prompt → Planner] | [Query → Response] | [Other → Reminder])
If the task involves code generation, Kevin's Planner
agent builds a structured, step-by-step plan, which is displayed in the Kevin Planner tab. This plan guides the rest of the process.
Kevin’s KeywordExtractor
processes the user’s prompt using:
- BERT: Captures the semantic essence of the task.
- KeyBERT: Extracts and ranks the most relevant keywords.
These keywords are used to drive intelligent research.
📊 Diagram Suggestion: Keyword Extraction Pipeline
(Prompt → BERT → KeyBERT → Top Keywords)
Using the extracted keywords, Kevin performs targeted research:
- Generates smart queries via
googlesearch-python
. - Fetches web pages using
requests
. - Parses content using
BeautifulSoup
. - Outputs results as structured JSON for downstream agents.
📊 Diagram Suggestion: Kevin Research Loop
(Keywords → Queries → Web Pages → Parsed Content → JSON)
Kevin’s Coder
agent writes high-quality code using the plan and research:
- Structure: Builds classes, functions, and modules.
- Implementation: Fills in the logic using research insights and programming principles.
- Presentation: Displays code in the Kevin Coder tab.
📊 Diagram Suggestion: Code Generation Flow
(Plan + Research + Prompt → Code Blocks)
The final stage involves organizing and finalizing the project:
- Uses the
os
module to create Python scripts. - Automatically sets up file and folder structure.
- Ensures everything is ready for execution or collaboration.
✅ Kevin’s core philosophy: "From idea to code."
Kevin’s Planner
is responsible for converting big-picture goals into concrete tasks:
- Objective Comprehension — Interprets the prompt to understand the user's intent.
- Step Formulation — Breaks down the objective into sequential steps.
- Execution Coordination — Delegates steps to relevant agents (e.g.,
Researcher
,Coder
).
The KeywordExtractor
streamlines research by isolating meaningful keywords:
- Contextual Extraction — Uses BERT to analyze the prompt.
- Relevance Ranking — Applies KeyBERT to prioritize the most critical terms.
This allows Kevin to focus his research precisely on what matters.
Kevin’s Researcher
agent supports intelligent knowledge acquisition:
- Generates search queries based on extracted keywords.
- Uses
googlesearch-python
to find relevant pages. - Fetches content with
requests
. - Extracts meaningful data using
BeautifulSoup
. - Structures output for the
Coder
to consume.
The Coder
agent transforms plans into functional code:
- Designs a scalable code structure.
- Implements the logic using research and programming knowledge.
- Produces readable, testable, and extensible code.
Supports multiple programming languages and project types.
The Project Creator
finalizes the development process:
- Generates a starter script using Python.
- Sets up file/folder organization.
- Verifies the completeness of the project environment.
🧠 Kevin lives by the motto:
“From idea to code — intelligently, reliably, and fast.”