{"id":27899194,"url":"https://github.com/seamusmullan/ampere","last_synced_at":"2026-03-07T23:02:26.135Z","repository":{"id":291423259,"uuid":"977580132","full_name":"SeamusMullan/Ampere","owner":"SeamusMullan","description":"A modern desktop application template that combines Electron and Vite for frontend with Python and FastAPI for backend.","archived":false,"fork":false,"pushed_at":"2025-07-18T06:34:17.000Z","size":1529,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-09T21:08:36.350Z","etag":null,"topics":["electron","fastapi","npm-package","python","template","uv","vite","vitejs"],"latest_commit_sha":null,"homepage":"https://amp.auxkit.dev","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/SeamusMullan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-05-04T14:32:31.000Z","updated_at":"2025-07-18T06:34:21.000Z","dependencies_parsed_at":"2025-05-05T19:23:09.135Z","dependency_job_id":"328f36be-761e-4f4d-8845-d7deaa185705","html_url":"https://github.com/SeamusMullan/Ampere","commit_stats":null,"previous_names":["seamusmullan/ampere"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/SeamusMullan/Ampere","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SeamusMullan%2FAmpere","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SeamusMullan%2FAmpere/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SeamusMullan%2FAmpere/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SeamusMullan%2FAmpere/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SeamusMullan","download_url":"https://codeload.github.com/SeamusMullan/Ampere/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SeamusMullan%2FAmpere/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30236047,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-07T19:01:10.287Z","status":"ssl_error","status_checked_at":"2026-03-07T18:59:58.103Z","response_time":53,"last_error":"SSL_read: 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":["electron","fastapi","npm-package","python","template","uv","vite","vitejs"],"created_at":"2025-05-05T19:22:53.737Z","updated_at":"2026-03-07T23:02:26.130Z","avatar_url":"https://github.com/SeamusMullan.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Ampere\n\n![Ampere Logo](assets/logo_128x128.png)\n\n## ⚡ A supercharged Electron/Vite + Python/FastAPI application template ⚡\n\n[![License](https://img.shields.io/github/license/SeamusMullan/ampere?style=flat-square)](LICENSE)\n[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](CONTRIBUTING.md)\n\n## 🚀 Overview\n\nAmpere is a modern desktop application template that combines Electron and Vite for frontend with Python and FastAPI for backend. This powerful combination provides a clean, versatile development environment for building high-performance, cross-platform desktop applications with a robust API layer.\n\n## NOTE: AMPERE IS WORK IN PROGRESS, NOT GUARANTEED TO WORK IN PROD. HERE BE DRAGONS.\n\n## ✨ Features\n\n- **Electron + Vite**: Lightning-fast frontend development with hot module replacement\n- **Python + FastAPI**: High-performance, easy-to-use backend API framework\n- **Interactive Setup**: Frontend scaffolding with customizable framework options\n- **Cross-Platform**: Works on Windows, macOS, and Linux\n- **Modern Python Tooling**: Uses `uv` for fast, reliable Python dependency management\n- **Development Tools**: Built-in debugging, linting, and testing setup\n- **Streamlined Workflow**: Integrated NPM scripts for managing both frontend and backend\n\n## 🔧 Tech Stack\n\n- **Frontend**:\n  - Electron\n  - Vite\n  - TypeScript/JavaScript\n  - React, Vue, Svelte, or Vanilla (selectable during setup)\n\n- **Backend**:\n  - Python 3.11+\n  - FastAPI\n  - Uvicorn\n  - uv (Python package manager)\n\n## 🏁 Getting Started\n\n### Prerequisites\n\n- Node.js 16+\n- Python 3.11+\n- npm\n- uv (install with `pip install uv`)\n\n### Quick Start with CLI\n\n```bash\n# Install ampere-cli globally\nnpm install -g ampere-cli\n\n# Create a new project (interactive setup)\nampere create my-awesome-app\n\n# Navigate to project\ncd my-awesome-app\n\n# Install all dependencies\nnpm run install:all\n\n# Start development (runs both frontend and backend)\nnpm run dev\n```\n\nDuring project creation, you'll be prompted to select your preferred frontend framework and configuration options through the interactive electron-vite installer.\n\n### Known issues\n\nOn some terminals, fastapi cannot render unicode characters when using concurrently. To fix this, please export the following in your terminal.\n\n```text\nexport PYTHONIOENCODING=utf-8\n```\n\n### Project Scripts\n\nAfter creating your project, you can use these npm scripts:\n\n```bash\n# Install all dependencies for both frontend and backend\nnpm run install:all\n\n# Run both frontend and backend in development mode\nnpm run dev\n\n# Run only the frontend in development mode\nnpm run dev:frontend\n\n# Run only the backend\nnpm run dev:backend\n\n# Build for production\nnpm run build\n\n# Start the built application\nnpm run start\n```\n\n### Manual Installation\n\nIf you prefer to set up manually:\n\n```bash\n# Clone the repository\ngit clone https://github.com/SeamusMullan/ampere.git\ncd ampere\n\n# Setup frontend\ncd frontend\nnpm install\n\n# Setup backend\ncd backend\nuv venv\nuv sync\nuv pip install -r requirements.txt\n\n# Start the development environment\n# In one terminal (frontend):\ncd frontend\nnpm run dev\n\n# In another terminal (backend):\ncd backend\nuv run main.py\n```\n\n## 🧪 Testing Ampere CLI Locally\n\nIf you're developing the Ampere CLI tool, you can test it locally using:\n\n```bash\n# Navigate to the CLI directory\ncd ampere-cli\n\n# Install dependencies\nnpm install\n\n# Create a global symlink\nnpm link\n\n# Now you can use the CLI from anywhere\nampere create test-project\n\n# To unlink when done\nnpm unlink ampere-cli\n```\n\nAlternatively, you can run the CLI directly without linking:\n\n```bash\n# Navigate to the CLI directory\ncd ampere-cli\n\n# Install dependencies\nnpm install\n\n# Run CLI commands directly\nnode bin/ampere.js create test-project\n```\n\n## 💻 Development\n\n### Project Structure\n\nThe generated project will have the following structure:\n\n```text\n\u003cproject_name\u003e\n├── package.json         # Root package.json with scripts for both frontend and backend\n├── README.md\n├── .gitignore\n├── backend/\n│   ├── api/             # FastAPI route definitions\n│   │   ├── __init__.py\n│   │   ├── data.py\n│   │   └── status.py\n│   ├── core/            # Core application logic\n│   │   ├── __init__.py\n│   │   ├── config.py\n│   │   └── models.py\n│   ├── services/        # Business logic services\n│   │   ├── __init__.py\n│   │   ├── data_service.py\n│   │   └── status_service.py\n│   ├── main.py          # FastAPI application entry point\n│   ├── requirements.txt # Python dependencies\n│   └── uv.lock          # Lock file for uv\n└── frontend/\n    ├── electron/        # Electron-specific code\n    ├── src/             # Frontend source code\n    ├── public/          # Static assets\n    ├── package.json     # Frontend dependencies\n    └── vite.config.js   # Vite configuration\n```\n\n## 🔄 How It Works\n\nAmpere uses Electron as the application shell, embedding a Python FastAPI server that runs as a subprocess. The frontend communicates with the backend via HTTP requests, allowing for a clean separation of concerns while maintaining the performance benefits of local processing.\n\nWhen you start the application in development mode:\n\n1. The Electron/Vite frontend starts with hot module replacement enabled\n2. The Python/FastAPI backend starts as a separate process\n3. The frontend connects to the backend API endpoints\n4. Changes to either codebase are automatically detected and reloaded\n\n## 📦 Building for Production\n\nTo build your application for distribution:\n\n```bash\nnpm run build\n```\n\nThis creates a packaged Electron application in the `frontend/out` directory, ready for distribution.\n\n## 🤝 Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n1. Fork the repository\n2. Create your feature branch (`git checkout -b feature/amazing-feature`)\n3. Commit your changes (`git commit -m 'Add some amazing feature'`)\n4. Push to the branch (`git push origin feature/amazing-feature`)\n5. Open a Pull Request\n\n## 📄 License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseamusmullan%2Fampere","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fseamusmullan%2Fampere","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fseamusmullan%2Fampere/lists"}