{"id":49580277,"url":"https://github.com/xavier2code/healix","last_synced_at":"2026-05-03T19:03:29.293Z","repository":{"id":346500913,"uuid":"1183834233","full_name":"xavier2code/healix","owner":"xavier2code","description":"Automated Self-Healing Software System — monitors logs, detects exceptions, generates fixes, and commits patches automatically","archived":false,"fork":false,"pushed_at":"2026-03-25T02:18:08.000Z","size":34276,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-25T06:57:22.771Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/xavier2code.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-03-17T01:54:26.000Z","updated_at":"2026-03-25T02:18:11.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/xavier2code/healix","commit_stats":null,"previous_names":["xavier2code/healix"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/xavier2code/healix","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xavier2code%2Fhealix","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xavier2code%2Fhealix/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xavier2code%2Fhealix/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xavier2code%2Fhealix/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/xavier2code","download_url":"https://codeload.github.com/xavier2code/healix/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xavier2code%2Fhealix/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32581023,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-03T06:36:36.687Z","status":"ssl_error","status_checked_at":"2026-05-03T06:36:09.306Z","response_time":103,"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":[],"created_at":"2026-05-03T19:03:28.405Z","updated_at":"2026-05-03T19:03:29.287Z","avatar_url":"https://github.com/xavier2code.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Healix\n\nAutomated Self-Healing Software System\n\nHealix monitors application logs, detects exceptions, locates problematic code, generates fixes, and commits patches automatically -- creating a complete closed-loop from error detection to code repair without human intervention.\n\n## Badges\n\n[![Node.js](https://img.shields.io/badge/Node.js-18%2B-green.svg)](https://nodejs.org/)\n[![NestJS](https://img.shields.io/badge/NestJS-11-red.svg)](https://nestjs.com/)\n[![TypeScript](https://img.shields.io/badge/TypeScript-5.x-blue.svg)](https://typescriptlang.org/)\n[![Docker](https://img.shields.io/badge/Docker-20.10%2B-blue.svg)](https://docker.com/)\n[![License](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE)\n[![Test Suites](https://img.shields.io/badge/test%20suites-46-brightgreen.svg)](#)\n[![Tests](https://img.shields.io/badge/tests-448%20passed-brightgreen.svg)](#)\n\n## Features\n\n- **Real-time Log Collection** -- Ingest logs from multiple sources (files, stdout, remote services)\n- **Multi-language Exception Parsing** -- Supports Java, TypeScript/JavaScript, and Python stack traces\n- **Stable Fingerprinting** -- SHA-256 based exception fingerprinting to track and deduplicate issues\n- **Fault Localization** -- Map stack traces to precise source code locations\n- **Fix Generation** -- Generate patches using templates, AST manipulation, and AI models\n- **Docker-based Validation** -- Validate fixes in isolated containers before applying\n- **VCS Integration** -- Automatic branch creation, commits, and PR/MR creation\n- **Memory System** -- Persistent fix history to prevent duplicate fix attempts\n\n## Quick Start\n\n### Option 1: Docker (Recommended)\n\n```bash\n# Clone the repository\ngit clone https://github.com/xavier2code/healix.git\ncd healix\n\n# Start infrastructure + application with hot reload\ndocker compose -f docker-compose.yml -f docker-compose.dev.yml up\n```\n\nAccess at http://localhost:3000\n\n### Option 2: Local Development\n\n```bash\n# Clone the repository\ngit clone https://github.com/xavier2code/healix.git\ncd healix\n\n# Install dependencies\nnpm install\n\n# Build the project\nnpm run build\n\n# Start infrastructure (PostgreSQL + Redis)\ndocker compose -f docker-compose.quickstart.yml up -d\n\n# Run in development mode\nnpm run start:dev\n```\n\n## Architecture\n\nThe system follows an event-driven architecture where modules communicate via `EventEmitter2`:\n\n1. **Log Collection** -- Monitors configured log sources and streams log lines\n2. **Exception Detection** -- Identifies stack traces and extracts structured data\n3. **Fingerprinting** -- Creates SHA-256 hash of type, message, and top stack frames\n4. **Memory Check** -- Checks if exception has been seen before and its fix status\n5. **Fault Localization** -- Maps stack frames to actual source code locations\n6. **Fix Generation** -- Generates potential fixes based on exception context\n7. **Validation** -- Tests fixes in isolated Docker containers\n8. **VCS Integration** -- Commits validated fixes to a new branch\n9. **PR Creation** -- Creates pull/merge request for human review\n10. **Verification** -- Post-merge monitoring ensures the fix resolved the issue\n\n## Modules\n\n| Module               | Description                                                    |\n| -------------------- | -------------------------------------------------------------- |\n| `log-collector`      | Real-time log ingestion from files, stdout, and remote sources |\n| `exception-parser`   | Multi-language stack trace parsing (Java, TypeScript, Python)  |\n| `memory`             | Exception fingerprinting, fix history, and deduplication       |\n| `fault-localization` | Map stack traces to source code locations                      |\n| `fix-generation`     | Generate patches using templates, AST, and AI                  |\n| `validation`         | Validate fixes in isolated Docker containers                   |\n| `vcs-integration`    | Git operations (branch, commit, push)                          |\n| `pr-creation`        | Create pull/merge requests on GitHub/GitLab                    |\n| `verification`       | Post-fix monitoring and automatic rollback                     |\n\n## Requirements\n\n- Node.js 18+\n- Docker 20.10+ (required for containerized deployment and fix validation)\n- Docker Compose v2+\n\n### Optional (for local development without Docker)\n\n- PostgreSQL 14+ (runs in-memory mode if not configured)\n- Redis 6+ (runs without cache if not configured)\n- Git\n\n## Configuration\n\nCopy `.env.example` to `.env` and configure:\n\n```env\n# Server\nPORT=3000\nNODE_ENV=development\n\n# Database (optional)\nDATABASE_URL=postgresql://healix:healix_dev@localhost:5432/healix\n\n# Redis (optional)\nREDIS_URL=redis://localhost:6379\n\n# Docker (required for validation)\nDOCKER_SOCKET=/var/run/docker.sock\n\n# AI Provider (optional -- for LLM-based fix generation)\nANTHROPIC_API_KEY=sk-ant-your-key-here\n\n# VCS Integration (optional)\nGITHUB_TOKEN=ghp_your_token\nGITLAB_TOKEN=glpat-your-token\n```\n\n## Docker Deployment\n\n### Development Mode\n\n```bash\ndocker compose -f docker-compose.yml -f docker-compose.dev.yml up\n```\n\nFeatures:\n\n- Hot reload via volume mounts\n- Source code mounted as read-only\n- Debugging friendly\n\n### Production Mode\n\n```bash\ndocker compose -f docker-compose.yml -f docker-compose.prod.yml up --build\n```\n\nFeatures:\n\n- Multi-stage build for small images (~200MB)\n- Non-root user for security\n- Resource limits (CPU/memory)\n- Health checks enabled\n- Restart policy\n\n### Container Registry\n\nThe GitHub Actions workflow automatically builds and pushes images to `ghcr.io`:\n\n```bash\n# Pull latest\ndocker pull ghcr.io/xavier2code/healix:latest\n\n# Run production\ndocker run -d --env-file .env -v /var/run/docker.sock:/var/run/docker.sock \\\n  ghcr.io/xavier2code/healix:latest\n```\n\nSee [docs/containerization.md](docs/containerization.md) for detailed documentation.\n\n## Available Scripts\n\n| Script               | Description                          |\n| -------------------- | ------------------------------------ |\n| `npm run build`      | Build the project                    |\n| `npm run start`      | Start the server                     |\n| `npm run start:dev`  | Start in development mode with watch |\n| `npm run start:prod` | Start in production mode             |\n| `npm test`           | Run all tests                        |\n| `npm run test:watch` | Run tests in watch mode              |\n| `npm run test:cov`   | Run tests with coverage              |\n| `npm run lint`       | Lint and fix code                    |\n| `npm run format`     | Format code with Prettier            |\n\n## Supported Languages\n\n| Language   | Parser | Compiler | Fix Templates |\n| ---------- | ------ | -------- | ------------- |\n| TypeScript | Yes    | Yes      | Yes           |\n| JavaScript | Yes    | Yes      | Yes           |\n| Python     | Yes    | Yes      | Yes           |\n| Java       | Yes    | Yes      | Yes           |\n\n## Project Structure\n\n```\nhealix/\n├── src/\n│   ├── main.ts                      # Application entry point\n│   ├── app.module.ts                # Root module\n│   └── modules/\n│       ├── exception-parser/         # Stack trace parsing\n│       │   ├── parsers/             # Language-specific parsers\n│       │   └── interfaces/          # Type definitions\n│       ├── fault-localization/      # Source code mapping\n│       ├── fix-generation/          # Patch generation\n│       ├── log-collector/           # Log ingestion\n│       ├── memory/                  # Fingerprinting \u0026 history\n│       │   ├── entities/           # TypeORM entities\n│       │   ├── storage/            # Redis \u0026 PostgreSQL repos\n│       │   └── interfaces/          # Type definitions\n│       ├── pr-creation/             # PR/MR creation\n│       ├── validation/              # Docker-based validation\n│       │   └── compilers/           # Language-specific compilers\n│       ├── vcs-integration/         # Git operations\n│       └── verification/            # Post-fix monitoring\n├── docs/                            # Documentation\n├── scripts/                         # Utility scripts\n├── package.json\n├── tsconfig.json\n├── nest-cli.json\n├── Dockerfile                      # Multi-stage Docker build\n├── docker-compose.yml               # Base services (PostgreSQL, Redis)\n├── docker-compose.dev.yml           # Development profile\n├── docker-compose.prod.yml          # Production profile\n└── docker-compose.quickstart.yml   # Legacy quickstart\n```\n\nhealix/\n├── src/\n│ ├── main.ts # Application entry point\n│ ├── app.module.ts # Root module\n│ └── modules/\n│ ├── exception-parser/ # Stack trace parsing\n│ │ ├── parsers/ # Language-specific parsers\n│ │ └── interfaces/ # Type definitions\n│ ├── fault-localization/ # Source code mapping\n│ ├── fix-generation/ # Patch generation\n│ ├── log-collector/ # Log ingestion\n│ ├── memory/ # Fingerprinting \u0026 history\n│ │ ├── entities/ # TypeORM entities\n│ │ ├── storage/ # Redis \u0026 PostgreSQL repos\n│ │ └── interfaces/ # Type definitions\n│ ├── pr-creation/ # PR/MR creation\n│ ├── validation/ # Docker-based validation\n│ │ └── compilers/ # Language-specific compilers\n│ ├── vcs-integration/ # Git operations\n│ └── verification/ # Post-fix monitoring\n├── docs/ # Documentation\n├── scripts/ # Utility scripts\n├── package.json\n├── tsconfig.json\n├── nest-cli.json\n└── docker-compose.quickstart.yml\n\n````\n\n## Testing\n\n```bash\n# Run all tests\nnpm test\n\n# Run tests in watch mode\nnpm run test:watch\n\n# Generate coverage report\nnpm run test:cov\n````\n\n## Contributing\n\n1. Fork the repository\n2. Create a feature branch (`git checkout -b feature/amazing-feature`)\n3. Commit your changes (`git commit -m 'Add amazing feature'`)\n4. Push to the branch (`git push origin feature/amazing-feature`)\n5. Open a Pull Request\n\n## License\n\nMIT License -- see [LICENSE](LICENSE) for details.\n\n## Acknowledgments\n\n- Built with [NestJS](https://nestjs.com/)\n- AST parsing powered by [tree-sitter](https://tree-sitter.github.io/)\n- AI fix generation by [Anthropic Claude](https://www.anthropic.com/)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxavier2code%2Fhealix","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxavier2code%2Fhealix","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxavier2code%2Fhealix/lists"}