{"id":31644563,"url":"https://github.com/jean-cheramy/votewise","last_synced_at":"2026-05-03T01:37:28.500Z","repository":{"id":315067997,"uuid":"1057787394","full_name":"jean-cheramy/VoteWise","owner":"jean-cheramy","description":"VoteWise is a prototype system that helps users explore and summarize political party positions in Belgium. It leverages retrieval-augmented generation (RAG) using a local Ollama language model (llama3) and FAISS embeddings to efficiently summarize party programs from documents.","archived":false,"fork":false,"pushed_at":"2025-09-16T13:01:05.000Z","size":5045,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-09-16T14:56:21.342Z","etag":null,"topics":["faiss","langchain","llm","ollama","python","rag-chatbot","streamlit"],"latest_commit_sha":null,"homepage":"","language":"Python","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/jean-cheramy.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":"2025-09-16T07:56:12.000Z","updated_at":"2025-09-16T13:00:37.000Z","dependencies_parsed_at":"2025-09-16T15:09:37.167Z","dependency_job_id":null,"html_url":"https://github.com/jean-cheramy/VoteWise","commit_stats":null,"previous_names":["jean-cheramy/votewise"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/jean-cheramy/VoteWise","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jean-cheramy%2FVoteWise","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jean-cheramy%2FVoteWise/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jean-cheramy%2FVoteWise/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jean-cheramy%2FVoteWise/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jean-cheramy","download_url":"https://codeload.github.com/jean-cheramy/VoteWise/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jean-cheramy%2FVoteWise/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278722768,"owners_count":26034461,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-07T02:00:06.786Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["faiss","langchain","llm","ollama","python","rag-chatbot","streamlit"],"created_at":"2025-10-07T04:53:59.162Z","updated_at":"2026-05-03T01:37:28.494Z","avatar_url":"https://github.com/jean-cheramy.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# VoteWise — Belgian Political Program Comparator\n\n## Overview\n\nVoteWise is a Retrieval-Augmented Generation (RAG) system designed to help users explore, summarize, and compare political party positions in Belgium. It combines **Azure AI Search** for document indexing and vector search with **Azure AI Foundry** for embeddings and language model reasoning. Users can ask natural-language questions about party programs, and the system retrieves the most relevant information before generating precise, context-aware answers.\n\n## Architecture\n\n### Key Components\n\n#### Document Storage \u0026 Indexing\n\n* Documents are preprocessed, split into chunks, and indexed in **Azure Cognitive Search** with vector embeddings.\n* **Vector search** allows efficient retrieval of the most relevant document chunks for a given query.\n\n#### Embedding \u0026 Language Model\n\n* **Azure AI Foundry embeddings** are used to represent each document chunk in vector space.\n* **Azure AI Foundry LLMs** generate context-aware summaries and answers.\n* Filtering by party ensures results are relevant to the user’s query.\n\n#### API Layer\n\n* **FastAPI** serves as the REST API endpoint (`/rag`), receiving queries as JSON.\n* Returns both the model-generated answer and the retrieved context chunks with source metadata.\n* Example query for testing in Swagger UI:\n\n```json\n{\n  \"question\": \"Quels sont les points clés du programme de l'Ecolo pour l'environnement ?\",\n  \"party\": \"ecolo\"\n}\n```\n\n#### Deployment on Azure (in progress...)\n\n* Party programs, news articles, and other political documents will be stored in **Azure Blob Storage**.\n* **Web App for Containers** will host the FastAPI RAG service and/or a streamlit app.\n* **Azure Container Registry (ACR)** will store the container images.\n* **Managed Identity** with **AcrPull** role will allow secure container pull.\n* CI/CD pipeline will deploy new container versions automatically via **GitHub Actions**.\n* Logs and monitoring through **Azure Log Analytics**.\n\n\n## Usage\n\n### Local Docker Testing\n\n```bash\ndocker build -t votewise-rag:latest .\ndocker run -p 8000:8000 --env-file .env votewise-rag:latest\n```\n\n* Access `http://localhost:8000/docs` for Swagger UI.\n* Use example queries to test RAG retrieval.\n\n## Possible Improvements \u0026 Next Steps\n\n* Integrate automated scraping from **RTBF news** to enrich document corpus with up-to-date political articles.\n* Add social media streams (e.g., **X/Twitter**) for party mentions.\n* Implement comparison between party programs and actual government measures.\n* Extend language support for Flemish parties (Dutch).\n* Test RAG performance. \n* Improve document ingestion (PDF loading) and chunking.\n* Introduce unit testing, CI/CD pipelines, and scheduled updates for automated indexing.\n\n## Notes on Filtering\n\n* Filtering by party ensures that only relevant documents are retrieved.\n* Example: querying MR pension proposals will only retrieve MR-related content.\n\nSource chunk used for question on MR pension without filtering activated:\n```text\ntravail des mesures pour les fins de carrière. Le PS propose de : ... (Source: ps-federal-2024.pdf)\n```\n\n## Free Tier Limitations\n\nUsing Azure free tiers for VoteWise RAG is fine for prototyping, but comes with constraints: limited Cognitive Search index size (50MB) and query throughput, restricted OpenAI/Foundry requests and models, single-instance Web App with no auto-scaling, and small Blob storage capacity. Free tiers are not suitable for large datasets, real-time monitoring, or production workloads.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjean-cheramy%2Fvotewise","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjean-cheramy%2Fvotewise","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjean-cheramy%2Fvotewise/lists"}