Sponsored by Deepsite.site

Your GPT for coding. Contextualize your codebase with a powerfully chained AI

Created By
StefanKumarasinghe8 months ago
The Search For A Refined Coding ChatGPT for Software Engineers
Content

Your GPT for coding. Contextualize your codebase with a powerfully chained AI

Docker Pulls License

CodeMasterPro is an advanced AI-powered coding assistant designed to elevate the software engineering experience.

Features

  • Understanding User Understands user intentions - could be further enhanced
  • AI-Powered Debugging: Identifies potential errors and suggests fixes, streamlining the debugging process.
  • Comprehensive Documentation: Provides instant access to relevant documentation and examples, enhancing understanding and productivity.
  • Customizable Settings: Tailor CodeMasterPro to your specific coding style and preferences.
  • Multi-Language Support: Supports a wide range of programming languages, ensuring versatility across projects.
  • Mutli-Model Support - Requires you to have a together API to use the Reasoner pro for a diversified answer
  • Runs Python and HTML - Allows you to directly run the codes in a safe environment
  • Memory, Internet and other tools - Has support for many tools including internal docuemntation, web scraping of websites for effective RAG
  • Previous Chats and Snippets - You can now choose to save chats and snippets for later use and CodeMasterPro will always save your last unsaved chat
  • Highly Customized - You can customize the prompt and the preferences as you like that suits you
  • Project Context - We allow you to upload your projects either via Zip, folder or a github repo to be index and use it as context when asking questions
  • Github Search - Use GitHub to get tools online that will provide examples for the llm to use and make better responses

Getting Started

Prerequisites

  • Docker: Ensure Docker is installed and running on your system.
  • Gemini API Key: Required for core AI functionality. Obtain a free API key from Google Gemini.
  • Brave API Key (Optional): Enhances search capabilities. Obtain a free API key from Brave Search API.
  • Together API key (Optional, required for Reasoner Pro): Enhances the answer way more, but way slower, useful for advance coding questions. Obtain a free API key from Together API

Available Tools

  • WEB – Allows access to the internet. Prompt your queries with natural instructions like:
    “Search online how to create an MCP server.”

  • STACK – Searches Stack Overflow for developer-relevant answers and code examples.
    Great for resolving language-specific or library-related issues.

  • INTERNAL – Searches internal documentation or knowledge bases, such as team wikis or private datasets.
    Use when your answer likely exists within internal sources.

  • PYTHON – Executes Python code in an isolated environment.
    Useful for testing logic, calculations, or snippets.

  • COMPUTE – Handles complex mathematical computations or factorial operations.
    Example: “What is 756!?”

  • VISUALIZE – Transforms raw log data into charts or graphs.
    Example: “Provide logs and give me a visualization of CPU usage over time.”

  • SAST – Performs static application security testing (SAST) on Python code.
    Detects vulnerabilities, bad patterns, and unsafe practices.

  • LIGHTNING – Delivers very fast answers to lightweight or fact-based questions.
    Optimized for speed over deep reasoning.

  • DEEP ANALYSIS - Analyses the large codes in detail, mostly 50000+ character codes Can you give me a deep anaysis of the code

  • GITHUB - Uses GitHub API to fetch examples and learn from them more effectively

  • CONTEXT - Allows you to upload your codebase and provide context to your queries

Main Chain of Thought

image

✅ Overview

The workflow follows a structured decision-making and response generation pipeline, enhanced by reinforcement learning and multi-model reasoning.


⚙️ 1. Tool Selection & Execution

  • Checks for an appropriate tool.
  • Executes it immediately if available for a fast, actionable response.

🧠 2. Sentiment & Behavior Analysis

  • Evaluates user sentiment and past interactions.
  • Skipped if no behavioral history exists.

🌐 3. Resource Retrieval

  • Fetches additional resources (e.g., web data, Stack Overflow, internal KBs) when needed.

🧬 4. Reinforcement Learning Feedback

  • Uses sentiment data to reward or penalize the RL agent.
  • Influences future decisions and model behaviors.

🧾 5. Response Generation

  • Combines sentiment, context, and history to produce an initial response.

🪞 6. Response Refinement

  • Enhances clarity, quality, and coherence of the response.

🧠 7. Multi-Model Reasoning

  • Invokes models like Gemini and others for deeper, more diverse insights based on reasoning level.

⚡ 8. Fast Path Return

  • Skips validation when speed is critical and returns the response immediately.

🔁 9. Quick Reasoning Path

  • Uses a lightweight reasoner.
  • Validates up to 3 times using the best prior answer.
  • Iterates without external model input.

🧩 10. Pro-Level Reasoning

  • Engages advanced models and third-party outputs.
  • Ensures broader context and selects the best response.

🧠 11. RL Agent Optimization

  • Continuously tunes the RL agent via rewards/penalties.
  • Chooses the optimal result after multiple iterations.

🎯 12. Greedy Optimization Strategy

  • Prioritizes the best possible outcome.
  • May settle early if minimum quality is met.

Code Analyst Chain

image

Designed for deep analysis of large codebases, CodeAnalystPro excels at code explanation and modification. Below is the step-by-step workflow:

1. Code Chunking

  • Splits the source code into manageable segments of 2,000–5,000 characters.

2. Chunk Analysis with Retry Logic

  • Each chunk is analyzed.
  • Up to 5 retry attempts are allowed to improve accuracy.

3. Context-Aware Modification

  • Modifications are made with awareness of:

    • The current chunk.
    • Previously generated outputs.
  • Ensures output consistency across chunks.

4. Fallback Mechanism

  • If a chunk fails validation:

    • The best previous version is reused.
    • The context window is reduced to limit hallucinations.

5. Validation Threshold

  • Chunks must meet a 90% validation score to proceed.
  • If validation passes, the system advances to the next chunk.

6. Iterative Refinement

  • Each chunk is either corrected or explained before moving on.

7. Final Output Reconstruction

  • All chunks are reassembled into a final version.
  • A lightweight Gemini model performs final polishing and cleanup.

Python Chain

image

Installation

  1. Pull the Docker image:
docker pull stefankumarasinghe/codemasterpro

Please use the relevant tags, for best performance, there is amd64, arm64 and latest which is compatible for both (but heavy)

  1. Run the Docker container:
docker run -e GOOGLE_API_KEY=YOUR_GEMINI_API_KEY -p 8000:8000 stefankumarasinghe/codemasterpro

While you can also have the BRAVE_API_KEY and TOGETHER_AI_API_KEY using -e and other Integrations, CodeMasterPro allows you to set via the UI

  • Replace YOUR_GEMINI_API_KEY with your actual Gemini API key.

  • Replace YOUR_BRAVE_API_KEY with your Brave API key (if you have one).

  • Replace TOGETHER_AI_API_KEY with your Together key

  • Make sure to create an .env, if you are doing it via the terminal (root-level)

  • Make sure to have the port 8000 ready as well

  • New update no longer requires you to put these variables as it can be set via the UI

  1. Access CodeMasterPro:

Open your web browser and navigate to [CodeMasterPro](https://dwr4zchmi6x24.cloudfront.net/). You need to run the docker container, you can stop when you don't need it and start it without entering the token again

Environment Variables

  • GOOGLE_API_KEY: Your Gemini API key. This is required.
  • Other tokens and intergrations can be added when you load the app

Customization

CodeMasterPro can be further customized through the UI

  • Model Selection: Choose between different AI models for code completion and debugging.
  • Language Preferences: Specify your preferred programming languages.
  • UI Themes: Customize the look and feel of the CodeMasterPro interface.
  • So much more ...

Usage

  1. Code Editor Integration: Integrate CodeMasterPro with your favorite code editor (e.g., VS Code, Sublime Text, Atom) using the provided plugins or extensions.
  2. Large and Accurate Code Generations Can produce large outputs and also take in large inputs, thanks to Gemini's 1million token window
  3. Real-Time Assistance: As you type, CodeMasterPro will provide real-time code suggestions, error detection, and documentation snippets.
  4. Debugging Tools: Utilize the AI-powered debugging tools to identify and resolve issues quickly.
  5. Documentation Lookup: Access comprehensive documentation for various programming languages and libraries directly within the CodeMasterPro interface.

Example Prompt

Example 1: Can you correct and improve this code Example 2: Can you check for vunerabilties in the python code Example 3: Visualize my logs please Example 4: Give me a full working chess game in HTML with all the logic and rules Example 5: Run this python code

Contributing

We welcome contributions to CodeMasterPro! Please follow these guidelines:

  1. Fork the repository.
  2. Create a new branch for your feature or bug fix.
  3. Submit a pull request with a clear description of your changes.
  4. If you were to fork this REPO, while this project is licensed under Non-commercial, you must credit me

License

This project is licensed under the Non Commercial License - see the LICENSE file for details. However, you must credit me, if you are using the app

Support

For questions, bug reports, or feature requests, please raise an issue or PR

Acknowledgements

  • Powered by Google Gemini and Brave Search API and Together AI and CodeMasterPro's Chain of Thought
Recommend Servers
TraeBuild with Free GPT-4.1 & Claude 3.7. Fully MCP-Ready.
Tavily Mcp
EdgeOne Pages MCPAn MCP service designed for deploying HTML content to EdgeOne Pages and obtaining an accessible public URL.
Jina AI MCP ToolsA Model Context Protocol (MCP) server that integrates with Jina AI Search Foundation APIs.
TimeA Model Context Protocol server that provides time and timezone conversion capabilities. This server enables LLMs to get current time information and perform timezone conversions using IANA timezone names, with automatic system timezone detection.
CursorThe AI Code Editor
WindsurfThe new purpose-built IDE to harness magic
Amap Maps高德地图官方 MCP Server
Visual Studio Code - Open Source ("Code - OSS")Visual Studio Code
Baidu Map百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Context7Context7 MCP Server -- Up-to-date code documentation for LLMs and AI code editors
ChatWiseThe second fastest AI chatbot™
MCP AdvisorMCP Advisor & Installation - Use the right MCP server for your needs
BlenderBlenderMCP connects Blender to Claude AI through the Model Context Protocol (MCP), allowing Claude to directly interact with and control Blender. This integration enables prompt assisted 3D modeling, scene creation, and manipulation.
Serper MCP ServerA Serper MCP Server
AiimagemultistyleA Model Context Protocol (MCP) server for image generation and manipulation using fal.ai's Stable Diffusion model.
Zhipu Web SearchZhipu Web Search MCP Server is a search engine specifically designed for large models. It integrates four search engines, allowing users to flexibly compare and switch between them. Building upon the web crawling and ranking capabilities of traditional search engines, it enhances intent recognition capabilities, returning results more suitable for large model processing (such as webpage titles, URLs, summaries, site names, site icons, etc.). This helps AI applications achieve "dynamic knowledge acquisition" and "precise scenario adaptation" capabilities.
Howtocook Mcp基于Anduin2017 / HowToCook (程序员在家做饭指南)的mcp server,帮你推荐菜谱、规划膳食,解决“今天吃什么“的世纪难题; Based on Anduin2017/HowToCook (Programmer's Guide to Cooking at Home), MCP Server helps you recommend recipes, plan meals, and solve the century old problem of "what to eat today"
MiniMax MCPOfficial MiniMax Model Context Protocol (MCP) server that enables interaction with powerful Text to Speech, image generation and video generation APIs.
DeepChatYour AI Partner on Desktop
Playwright McpPlaywright MCP server