How dhyanshah22/hacknuthon-rapidops works
Project Type and Purpose
• This project is an AI-powered tool that generates structured test cases from API documentation PDFs.
• It combines several integrations: AI (Google Gemini API) for processing, FAISS for vector search, GitHub for repository updates, and Figma for syncing UI/UX components.
• The tool is built as a full-stack application where a Streamlit front end (app.py) interacts with backend logic to process the API docs, generate test cases, and handle external integrations.
File Structure Insights
• Multiple directories (e.g., Chat-Bot, FigmaTestCase, GenerateTestCase) suggest that the project might have modular components addressing different integrations or functionalities.
• Each folder contains an “app.py” file hinting at potentially separate entry points or experimental branches/modules.
• There is a common “data” folder across modules; this folder stores essential files like JSON test cases and API documentation PDFs.
• Presence of CI/CD related files (jenkinsfile, and the README’s reference to the .github/workflows folder) informs us about the automated deployment and testing pipeline.
Main Components
a. User Interface Layer:
• Streamlit Application: Represents the primary user interface where users can upload API documentation PDFs.
• Entry point: app.py (from the main directory and possibly the different modules where the UI may handle specific integrations).
b. Backend / Processing Engine:
• PDF Parser & FAISS Integration: Handles PDF parsing for extracting textual content and uses FAISS for vector storage and retrieval.
• AI-based Test Case Generator: Uses Google Gemini API to generate structured test cases from the parsed data.
• Unique Test Data Generator: Creates randomized test inputs (like email, password) for each test case.
c. Integration Components:
• Figma Integration Module: Communicates with the Figma API to fetch UI design elements and synchronizes these with test case definitions.
d. Data Storage:
• Data directory (data/test_cases.json): Acts as a persistence layer where generated test cases are saved.
• Any additional files (PDFs or intermediary JSON files) that are stored in the data folders of the various modules.
e. CI/CD and Automation:
• CI/CD Pipeline Component: Indicated by the Jenkinsfile and GitHub Actions workflow (as described in the README). It triggers processes such as automated testing and deployment upon new commits.
Relationships and Interactions
• The UI (Streamlit app) accepts inputs (PDF uploads, Figma updates, etc.) which are passed to the backend.
• The backend uses the PDF Parser (with FAISS) to extract data, then sends the data to the AI-powered module (Google Gemini API) for test case generation.
• Generated test cases are stored locally in the “data” folder as JSON files.
• A GitHub integration module automatically pushes these JSON files to a GitHub repository.
• Separately, Figma integration continuously polls or receives updates from UI/UX designs to adjust test cases accordingly.
• The CI/CD pipeline kicks off upon changes, automates tests, and deploys any updates – these processes are explicitly defined in the GitHub Actions workflow and in the jenkinsfile.
Architectural Patterns & Design Principles
• Modularity: Different modules handle distinct functionalities (e.g., PDF parsing, test case generation, integrations).
• Separation of Concerns: Clear division between UI (Streamlit) and backend processing.
• Automation and Continuous Deployment: The CI/CD pipeline illustrates a DevOps approach.
• Integration-centric: The project encapsulates multiple external APIs (Google Gemini, GitHub, Figma) which each are critical to the overall flow.