{"id":49569974,"url":"https://github.com/pfei/invoice-cleaner","last_synced_at":"2026-05-03T13:13:54.038Z","repository":{"id":354602323,"uuid":"1224355978","full_name":"pfei/invoice-cleaner","owner":"pfei","description":null,"archived":false,"fork":false,"pushed_at":"2026-04-29T08:19:05.000Z","size":118,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-04-29T09:33:06.688Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","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/pfei.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,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-04-29T07:47:05.000Z","updated_at":"2026-04-29T08:19:09.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/pfei/invoice-cleaner","commit_stats":null,"previous_names":["pfei/invoice-cleaner"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/pfei/invoice-cleaner","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pfei%2Finvoice-cleaner","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pfei%2Finvoice-cleaner/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pfei%2Finvoice-cleaner/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pfei%2Finvoice-cleaner/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/pfei","download_url":"https://codeload.github.com/pfei/invoice-cleaner/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/pfei%2Finvoice-cleaner/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32570016,"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-03T13:13:37.438Z","updated_at":"2026-05-03T13:13:54.025Z","avatar_url":"https://github.com/pfei.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Invoice Cleaner\n\nA lightweight Python tool designed to extract structured data (amount, date) from PDF invoices using optimized regex patterns.\n\n## ⚠️ Status\n\nThis project is in early development (alpha stage).  \nAPI, structure and extraction rules are subject to change.\n\n## 🎯 Purpose\n\nThis project demonstrates a **\"Fast-Path\" parsing strategy**. Before resorting to complex AI models, `invoice-cleaner` uses high-performance heuristic extraction to process known invoice formats (like Free Telecom) in milliseconds.\n\n## 🛠️ Features\n\n*   **Speed**: Near-instant extraction using `pdfplumber` and `re`.\n*   **Robustness**: Handles multi-page PDFs and text sanitization.\n*   **Extensibility**: Structured with modular functions to easily add new providers.\n*   **Open Data**: Includes sample invoices for immediate testing.\n\n## 📂 Project Structure\n\n```text\n.\n├── examples/           # Sample PDF invoices for testing\n├── output/             # Generated JSON/CSV reports (ignored by git)\n├── .gitignore\n├── main.py\n├── requirements.txt\n├── LICENSE\n└── README.md\n```\n\n## 🚀 Getting Started\n\n### 1. Prerequisites\nEnsure you have Python 3.8+ installed.\n\n### 2. Installation\nClone the repository and install the required dependencies:\n\n```bash\ngit clone https://github.com/pierre-feilles/invoice-cleaner.git\ncd invoice-cleaner\npip install pdfplumber\n```\n\n### 3. Usage\nRun the main script to process the default example:\n\npython main.py\n\n## 📊 Performance Logic\n\nThe script follows a deterministic extraction flow:\n1.  **Layout Analysis**: Extracts raw text while maintaining logical groupings.\n2.  **Regex Anchoring**: Locates financial data based on semantic anchors like \"Somme à payer\".\n3.  **Sanitization**: Cleans up formatting artifacts to return pure data (e.g., 29.99).\n\n## 📜 Acknowledgments \u0026 License\n\n*   **Data Sources**: Some PDF samples in the `examples/` directory are sourced from the [invoice2data](https://github.com/invoice-x/invoice2data) project (MIT License).\n*   **License**: This project is licensed under the **MIT License** - see the [LICENSE](LICENSE) file for details.\n\nDeveloped by **Pierre Feilles** (2026).","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpfei%2Finvoice-cleaner","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpfei%2Finvoice-cleaner","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpfei%2Finvoice-cleaner/lists"}