{"id":29744680,"url":"https://github.com/developerpuneet/codecharm","last_synced_at":"2026-04-17T23:32:20.296Z","repository":{"id":304450461,"uuid":"1018809503","full_name":"DeveloperPuneet/CodeCharm","owner":"DeveloperPuneet","description":"VS Code extension that adds AI-powered inline comments to selected code using Google Gemini. Simple, fast, and emoji-rich 💬✨","archived":false,"fork":false,"pushed_at":"2025-10-23T10:16:40.000Z","size":9793,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-10-23T12:22:17.370Z","etag":null,"topics":["ai","ai-powered-tools","ai-tool","extension","mit-license","open-source","tool","vscode-extension","vscode-tool"],"latest_commit_sha":null,"homepage":"https://marketplace.visualstudio.com/items?itemName=DeveloperPuneet.CodeCharm","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DeveloperPuneet.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null},"funding":{"github":["DeveloperPuneet"],"patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"lfx_crowdfunding":null,"polar":null,"buy_me_a_coffee":"DeveloperPuneet","thanks_dev":null,"custom":[]}},"created_at":"2025-07-13T05:01:36.000Z","updated_at":"2025-10-23T10:16:45.000Z","dependencies_parsed_at":"2025-08-04T14:17:34.483Z","dependency_job_id":"0f43b3e3-ff89-408a-b8bf-f1bd1123f9c0","html_url":"https://github.com/DeveloperPuneet/CodeCharm","commit_stats":null,"previous_names":["developerpuneet/codewhiz","developerpuneet/codecharm"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/DeveloperPuneet/CodeCharm","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperPuneet%2FCodeCharm","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperPuneet%2FCodeCharm/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperPuneet%2FCodeCharm/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperPuneet%2FCodeCharm/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DeveloperPuneet","download_url":"https://codeload.github.com/DeveloperPuneet/CodeCharm/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DeveloperPuneet%2FCodeCharm/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31950238,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-17T17:29:20.459Z","status":"ssl_error","status_checked_at":"2026-04-17T17:28:47.801Z","response_time":62,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai","ai-powered-tools","ai-tool","extension","mit-license","open-source","tool","vscode-extension","vscode-tool"],"created_at":"2025-07-26T05:33:04.662Z","updated_at":"2026-04-17T23:32:20.290Z","avatar_url":"https://github.com/DeveloperPuneet.png","language":"JavaScript","funding_links":["https://github.com/sponsors/DeveloperPuneet","https://buymeacoffee.com/DeveloperPuneet","https://buymeacoffee.com/developerpuneet"],"categories":[],"sub_categories":[],"readme":"# 🧠 CodeCharm — AI-Powered Code Comment Generator for VS Code\n\nCodeCharm is your intelligent VS Code extension that generates **inline code comments** using Google Gemini models. It uses your selected code and enhances it with **emoji-rich, concise comments** or **refactors it for readability**.\n\n\u003e 🚀 Now updated with **multi-model fallback support** and **secure API key input**!\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://img.shields.io/visual-studio-marketplace/v/DeveloperPuneet.codecharm?color=brightgreen\u0026label=VS%20Marketplace\" alt=\"Version\"/\u003e\n  \u003cimg src=\"https://img.shields.io/visual-studio-marketplace/i/DeveloperPuneet.codecharm?color=blue\" alt=\"Installs\"/\u003e\n  \u003cimg src=\"https://img.shields.io/visual-studio-marketplace/d/DeveloperPuneet.codecharm?color=blueviolet\" alt=\"Downloads\"/\u003e\n  \u003cimg src=\"https://img.shields.io/visual-studio-marketplace/r/DeveloperPuneet.codecharm?color=yellow\" alt=\"Rating\"/\u003e\n  \u003cimg src=\"https://img.shields.io/github/stars/DeveloperPuneet/CodeCharm?style=social\" alt=\"Stars\"/\u003e\n  \u003cimg src=\"https://img.shields.io/github/license/DeveloperPuneet/CodeCharm\" alt=\"License\"/\u003e\n\u003c/p\u003e\n\u003cp align=\"center\"\u003e\n  🌐 \u003ca href=\"https://codecharm.netlify.app/\" target=\"_blank\"\u003e\u003cb\u003e🔗 Visit CodeCharm Web\u003c/b\u003e\u003c/a\u003e  \n\u003c/p\u003e\n\n---\n\n## 🌟 Features\n\n- ✍️ Generate **inline code comments** with emojis — clean and fun.\n- ♻️ Refactor messy code to improve readability.\n- ⌨️ **Shortcut support**:\n  - `Ctrl + Win + J` → Add Inline Comments\n  - `Ctrl + Win + G` → Refactor Code\n  - `Ctrl + Win + H` → Comment + Refactor (adds inline emoji comments AND refactors the code)\n  - `Ctrl + Win + K` → Run only the instruction inside `cmd()` (no other changes)\n- 🔁 **Model Fallback Support**: Uses the following Gemini models in this order:\n  1. `gemini-2.0-flash-lite`\n  2. `gemini-2.0-flash`\n  3. `gemini-2.5-flash-lite`\n  4. `gemini-2.5-pro`\n  5. `gemini-2.0-flash-exp`\n  6. `learnlm-2.0-flash-experimental`\n  7. `gemini-2.0-flash-live`\n  8. `gemini-2.5-flash-live`\n  9. `gemini-2.5-flash-native-audio-dialog`\n- 🔐 **Secure API Key Storage** in VS Code settings.\n- 🧠 Uses your **API key**, no sharing required.\n- 🆕 **Execute `cmd()` instructions inside your code**  \n  - Add a line like: `cmd(import pandas)` at the top of your code block.  \n  - CodeCharm will first apply your instruction (e.g., add imports, modify setup)  \n    and then generate inline comments or refactor the code. You can also run the combined action with `Ctrl + Win + H` to perform both at once.\n    - Press `Ctrl + Win + K` to run only the `cmd()` instruction found in the selection (the extension sends only the `cmd()` instruction to the assistant and returns the modified code).\n    \u003e **Tip:** You can add a `cmd()` instruction before running CodeCharm  \n\u003e Example:\n\u003e ```js\n\u003e cmd(import pandas)\n\u003e df = pd.DataFrame({...})\n\u003e ```\n\u003e This will automatically insert the required import before processing.\n\n\n---\n\n## 🔑 Setup — Add Your API Key\n\nTo use CodeCharm, you'll need your **own Google Gemini API key**:\n\n1. Go to [Google AI Studio](https://aistudio.google.com/app/apikey).\n2. Copy your API key.\n3. Open VS Code.\n4. Press `Ctrl + Win + J` or `Ctrl + Win + G` for the first time.\n  - Or press `Ctrl + Win + H` to run both commenting and refactoring in one step.\n  - Press `Ctrl + Win + K` to run only the instruction inside `cmd()` in your selection.\n5. A secure input box will appear → paste your key there.\n6. It will be saved automatically in:  \n\u003e **Tip:** You can add a `cmd()` instruction before running CodeCharm  \n\u003e Example:\n\u003e ```js\n\u003e cmd(import pandas)\n\u003e df = pd.DataFrame({...})\n\u003e ```\n\u003e This will automatically insert the required import before processing.\n\n   **`CodeCharm.zetaFlux`** in your VS Code settings.\n\n\u003e 🔐 Your key stays local \u0026 secure — not shared or stored remotely.\n\n---\n\n## 🚀 How to Use\n\n1. Select a block of code.\n2. Press:\n   - `Ctrl + Win + J` → for inline comments\n   - `Ctrl + Win + G` → to refactor code\n  - `Ctrl + Win + H` → to both refactor and add inline emoji comments (follows any `cmd()` instructions)\n  - `Ctrl + Win + K` → to only execute the `cmd()` instruction and return the modified code (no other changes)\n3. CodeCharm will generate and replace your selection with an improved version.\n\u003e **Tip:** You can add a `cmd()` instruction before running CodeCharm  \n\u003e Example:\n\u003e ```js\n\u003e cmd(import pandas)\n\u003e df = pd.DataFrame({...})\n\u003e ```\n\u003e This will automatically insert the required import before processing.\n\n\n---\n\n## 🧪 Example Output\n\n### Before:\n```js\nfunction getUser(id) {\n  return db.query(\"SELECT * FROM users WHERE id = \" + id);\n}\n```\n\n## After (Ctrl + Win + J):\n```js\nfunction getUser(id) {\n  return db.query(\"SELECT * FROM users WHERE id = \" + id); // 🧑‍💻 Query user by ID\n}\n```\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"./CodeCharm_python_showcase.gif\" alt=\"CodeCharm Demo\" width=\"700\"/\u003e\n\u003c/p\u003e\n\n## 📦 Extension Info\n\n- 📁 **Extension ID**: `CodeCharm`\n- 👨‍💻 **Publisher**: [`DeveloperPuneet`](https://github.com/DeveloperPuneet)\n- 🔗 **GitHub Repo**: [CodeCharm](https://github.com/DeveloperPuneet/CodeCharm)\n- 🧩 **VS Code Version**: `^1.50.0` and above\n- 🧠 **AI Models Used**:\n  - `gemini-2.0-flash-lite` (primary)\n  - `gemini-2.0-flash`\n  - `gemini-2.5-flash-lite`\n  - `gemini-2.5-pro`\n  - + other fallback models\n\n## 🛟 Troubleshooting\n\n- ❌ **Getting No Output or Errors?**\n  - Make sure your Gemini API key is valid.\n  - If it's missing or expired, you'll be prompted to input it when you try using the extension.\n  - To manually update or check your key:  \n    `Settings → Extensions → CodeCharm → zetaFlux`\n\n- ⚠️ **Network Errors?**\n  - Check your internet connection or if Google's Gemini API is reachable.\n  - Avoid hammering it with hundreds of requests/minute — Google don’t play 😬\n\n## 🧤 Contributions\n\n- 💬 Ideas, feature requests, and PRs are all welcome!\n- Fork it, star it ⭐, break it, rebuild it — just don’t write spaghetti 🍝\n- All feedback = good feedback, especially with emojis.\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://buymeacoffee.com/developerpuneet\" target=\"_blank\"\u003e\n    \u003cimg src=\"https://cdn.buymeacoffee.com/buttons/v2/default-yellow.png\" width=\"180\" alt=\"Buy Me A Coffee\" /\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n## 📜 License\n\n**MIT** — Use it, hack it, improve it.  \nYou break it, you own it. 💥\n\n\u003e 💬 Built with brain, bugs \u0026 caffeine by [@DeveloperPuneet](https://github.com/DeveloperPuneet)  \n\u003e *“If your code can’t explain itself, at least let it drop some emoji bars 🎯.”*\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeveloperpuneet%2Fcodecharm","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdeveloperpuneet%2Fcodecharm","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdeveloperpuneet%2Fcodecharm/lists"}