Hack23/euparliamentmonitor

GitHub: Hack23/euparliamentmonitor

欧盟议会情报平台,通过AI代理自动生成14种语言的政治新闻,实现欧盟议会活动的系统性透明监控。

Stars: 2 | Forks: 2

Hack23 Logo

🏛️ 欧盟议会监控器

欧洲议会情报平台
以系统性透明度监控政治活动

Owner Version Classification Review Cycle

EU Parliament Monitor

European Parliament Intelligence Platform — an automated multi-language news platform that monitors EU Parliament activities with 14-language support, covering plenary sessions, committee reports, propositions, and breaking news.

[![OpenSSF 记分卡](https://api.securityscorecards.dev/projects/github.com/Hack23/euparliamentmonitor/badge)](https://scorecard.dev/viewer/?uri=github.com/Hack23/euparliamentmonitor) [![OpenSSF 最佳实践](https://www.bestpractices.dev/projects/12068/badge)](https://www.bestpractices.dev/projects/12068) [![SLSA 3](https://slsa.dev/images/gh-badge-level3.svg)](https://github.com/Hack23/euparliamentmonitor/attestations) [![新闻生成](https://github.com/Hack23/euparliamentmonitor/actions/workflows/news-generation.yml/badge.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/news-generation.yml) [![测试与报告](https://static.pigsec.cn/wp-content/uploads/repos/2026/03/16fa703189075623.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/test-and-report.yml) [![许可证](https://img.shields.io/github/license/Hack23/euparliamentmonitor)](https://github.com/Hack23/euparliamentmonitor/blob/main/LICENSE) [![ISMS](https://img.shields.io/badge/Hack23-ISMS-blue)](https://github.com/Hack23/ISMS-PUBLIC) [![询问 DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/Hack23/euparliamentmonitor) ## 🎯 状态徽章 ### 工作流状态 [![新闻生成](https://github.com/Hack23/euparliamentmonitor/actions/workflows/news-generation.yml/badge.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/news-generation.yml) [![CodeQL](https://static.pigsec.cn/wp-content/uploads/repos/2026/03/92d342f040075624.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/codeql.yml) [![测试与报告](https://static.pigsec.cn/wp-content/uploads/repos/2026/03/16fa703189075623.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/test-and-report.yml) [![发布](https://static.pigsec.cn/wp-content/uploads/repos/2026/03/2a5583b073075625.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/release.yml) [![E2E 测试](https://static.pigsec.cn/wp-content/uploads/repos/2026/03/46a5da2c27075626.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/e2e.yml) [![OpenSSF 记分卡](https://api.securityscorecards.dev/projects/github.com/Hack23/euparliamentmonitor/badge)](https://scorecard.dev/viewer/?uri=github.com/Hack23/euparliamentmonitor) ### 文档与报告 [![API 文档](https://img.shields.io/badge/API-Documentation-blue?logo=javascript)](https://euparliamentmonitor.com/docs/api/index.html) [![覆盖率](https://img.shields.io/badge/Coverage-82%25-green?logo=vitest)](https://euparliamentmonitor.com/docs/coverage/index.html) [![E2E 报告](https://img.shields.io/badge/E2E-Report-purple?logo=playwright)](https://euparliamentmonitor.com/playwright-report/index.html) [![SLSA 3](https://img.shields.io/badge/SLSA-Level%203-brightgreen?logo=github)](https://github.com/Hack23/euparliamentmonitor/attestations) ## 📚 文档中心 **📖 快速链接:** - [📘 架构文档](SECURITY_ARCHITECTURE.md) - 包含 C4 图的完整安全架构 - [📗 安全流程](FLOWCHART.md) - 包含安全控制的流程图 - [📙 数据模型](DATA_MODEL.md) - 数据结构与 API 集成 - [📕 发布流程](docs/RELEASE_PROCESS.md) - 如何创建发布版本 - [📔 API 文档](https://euparliamentmonitor.com/docs/api/index.html) - TypeDoc 生成的 API 参考 - [📓 测试覆盖率](https://euparliamentmonitor.com/docs/coverage/index.html) - 交互式覆盖率报告 **🔒 ISMS 合规性:** - [🛡️ Hack23 ISMS 框架](https://github.com/Hack23/ISMS-PUBLIC) - 信息安全管理体系 - [🔐 安全开发策略](https://github.com/Hack23/ISMS-PUBLIC/blob/main/Secure_Development_Policy.md) - 开发标准 - [📋 分类框架](https://github.com/Hack23/ISMS-PUBLIC/blob/main/CLASSIFICATION.md) - CIA 三要素分类 ## 当前状态 **MCP Server 集成**:该项目设计使用 [European-Parliament-MCP-Server](https://github.com/Hack23/European-Parliament-MCP-Server) 来访问真实的欧盟议会数据。 - **MCP Server 状态**:MCP 服务器目前处于开发阶段(骨架实现) - **回退模式**:当 MCP 服务器不可用时,新闻生成使用占位符内容运行 - **环境变量**:设置 `USE_EP_MCP=false` 以禁用 MCP 客户端连接尝试 ### 当 MCP Server 就绪时 一旦 European-Parliament-MCP-Server 完全实现,系统将自动: 1. 连接到 MCP 服务器以获取实时欧盟议会数据 2. 获取全体会议、委员会会议和文件 3. 生成包含真实议会信息的文章 4. 提供适当的翻译或每种语言的内容生成 ### 当前限制 **注意**:当前实现会在 MCP 服务器不可用时为所有语言生成英文占位符内容。要启用完整功能: 1. **完成 MCP Server**:European-Parliament-MCP-Server 需要实现: - `get_plenary_sessions` 工具 - `search_documents` 工具 - `get_parliamentary_questions` 工具 - `get_committee_info` 工具 2. **安装 MCP Server**:一旦就绪,安装 MCP 服务器: npm install -g european-parliament-mcp-server # 或克隆并在本地构建 3. **启用 MCP Client**:当服务器可用时,新闻生成器将自动连接 EU Parliament Monitor 是一个自动化新闻生成平台,用于监控欧洲议会活动并生成多语言新闻文章,涵盖: - **前瞻 (Week Ahead)**:即将举行的议会事件和委员会会议预览 - **委员会报告**:委员会活动和决策分析 - **提案**:政府和议会立法提案 - **议案**:议会动议和决议 - **突发新闻**:重大进展的快速响应报道 ## 功能特性 - 📰 **自动化新闻生成**:生成关于欧盟议会活动的新闻文章 - 🌍 **多语言支持**:支持 14 种语言,包括英语、瑞典语、德语、法语、西班牙语、阿拉伯语、日语等 - 📅 **前瞻覆盖**:预览即将举行的议会事件 - 🤖 **GitHub Actions 集成**:自动化每日新闻生成 - 📊 **SEO 优化**:适当的元数据、结构化数据和站点地图生成 - ✅ **代码质量**:ESLint、Prettier 和自动化质量门禁 ## 🔒 安全架构 EU Parliament Monitor 实施**安全设计 (security-by-design)**,配备全面的安全控制和 ISMS 合规性。 ### 安全文档 - 📋 **[安全架构](SECURITY_ARCHITECTURE.md)** - 包含 C4 图、威胁模型和合规性映射的完整安全实现概述 - 🚀 **[未来安全架构](FUTURE_SECURITY_ARCHITECTURE.md)** - 安全增强路线图 (2026-2027) - 📊 **[数据模型](DATA_MODEL.md)** - 数据结构和欧洲议会 API 集成 - 📈 **[安全流程图](FLOWCHART.md)** - 包含安全控制的详细流程图 ### 安全态势 **分类**(依据 [ISMS 分类框架](https://github.com/Hack23/ISMS-PUBLIC/blob/main/CLASSIFICATION.md)): - **机密性**:公开 (级别 1) - 欧洲议会开放数据 - **完整性**:中等 (级别 2) - 新闻准确性对民主透明度至关重要 - **可用性**:中等 (级别 2) - 预期每日更新,24 小时 RTO 可接受 **关键安全控制**: - ✅ **最小攻击面**:静态站点,无数据库,无服务器端执行 - ✅ **自动化安全**:CodeQL SAST、Dependabot SCA、npm audit - ✅ **供应链安全**:SHA 固定的 GitHub Actions、SBOM 生成 - ✅ **输入验证**:多层 XSS 防护、HTML 净化 - ✅ **基础设施安全**:GitHub 托管的临时运行器、HTTPS 强制执行 - ✅ **合规性**:符合 ISO 27001、GDPR、NIS2、EU CRA 标准 **安全指标**: - 零已知漏洞(npm audit 干净) - 82%+ 代码覆盖率及安全测试 - 100% 依赖扫描覆盖率 - 0 个 CodeQL 严重/高危发现 ### ISMS 一致性 本项目遵循 [Hack23 ISMS 安全开发策略](https://github.com/Hack23/ISMS-PUBLIC/blob/main/Secure_Development_Policy.md): - ✅ 安全架构文档(使用 Mermaid 的 C4 模型) - ✅ 威胁建模(STRIDE 分析) - ✅ 安全测试(SAST、SCA、单元测试) - ✅ 合规性映射(ISO 27001、GDPR、NIS2) ## 🤝 社区与治理 EU Parliament Monitor 是一个开源项目,具有透明的治理和社区标准。 ### 开源标准 - **[贡献指南](CONTRIBUTING.md)** - 开发工作流、代码标准和贡献准则 - **[行为准则](CODE_OF_CONDUCT.md)** - 基于 Contributor Covenant 2.1 的社区标准 - **[安全策略](SECURITY.md)** - 漏洞披露和安全实践 - **[作者与贡献者](AUTHORS.md)** - 项目贡献者致谢 - **[许可证](LICENSE)** - Apache License 2.0 全文 ### 社区渠道 - **GitHub Issues**:错误报告和功能请求 - **GitHub Discussions**:问题和社区讨论 - **Security**:[security@hack23.com](mailto:security@hack23.com) 用于漏洞报告 - **Conduct**:[conduct@hack23.com](mailto:conduct@hack23.com) 用于行为准则问题 ### 治理合规性 本项目遵守: - ✅ **OpenSSF 最佳实践**:遵循 CII 最佳实践标准 - ✅ **ISMS 合规性**:与 Hack23 ISMS 策略保持一致 - ✅ **透明开发**:公共仓库、开放讨论 - ✅ **安全至上**:全面的安全披露策略 ## 代码质量与测试 EU Parliament Monitor 通过全面的测试维持高代码质量标准: ### 代码质量 - **ESLint**:包含安全、复杂度和文档检查的全面 linting - **Prettier**:所有 JavaScript 文件的一致代码格式化 - **Pre-commit Hooks**:每次提交前自动 linting 和格式化 - **CI/CD 质量门禁**:每个 Pull Request 的自动检查 - **TypeDoc/JSDoc**:所有函数的完整文档 **代码标准**:参见 [docs/CODE_STANDARDS.md](docs/CODE_STANDARDS.md) 获取详细的编码指南。 ### 测试基础设施 使用 **Vitest** 和 **Playwright** 的全面测试套件,覆盖所有功能: #### 单元与集成测试 - **单元测试**:文章生成、MCP 客户端、索引/站点地图生成 - **集成测试**:完整工作流、MCP 集成、多语言支持 - **覆盖率**:≥80% 行覆盖率,≥75% 分支覆盖率 - **测试数量**:169+ 个测试覆盖关键路径 ``` # 运行单元测试与集成测试 npm test # 运行覆盖率测试 npm run test:coverage # 在 watch 模式下运行测试 npm run test:watch # 运行 with UI (browser interface) npm run test:ui ``` #### 端到端测试 - **E2E 测试**:完整的用户体验验证 - **跨浏览器**:Chromium、Firefox、WebKit - **移动端支持**:Mobile Chrome、Mobile Safari - **无障碍性**:使用 axe-core 的 WCAG 2.1 AA 合规性 - **响应式设计**:多种视口尺寸 - **测试数量**:60+ 个 E2E 测试覆盖用户旅程 ``` # 运行 E2E 测试 npm run test:e2e # 运行 with UI (interactive) npm run test:e2e:ui # 在 headed 模式下运行 (see browser) npm run test:e2e:headed # 查看测试报告 npm run test:e2e:report ``` **测试文档**: - [test/README.md](test/README.md) - 单元与集成测试 - [e2e/README.md](e2e/README.md) - E2E 测试指南 ## 自定义代理 EU Parliament Monitor 包含 **8 个专门的 GitHub Copilot 自定义代理** 以简化开发: - 🤖 **[product-task-agent](.github/agents/product-task-agent.md)** - 负责 Issue 创建和协调的产品专家 - 📰 **[news-journalist](.github/agents/news-journalist.md)** - 经济学人风格的欧洲议会报道 - 🎨 **[frontend-specialist](.github/agents/frontend-specialist.md)** - HTML5/CSS3/WCAG 2.1 AA UI/UX 专家 - 🔄 **[data-pipeline-specialist](.github/agents/data-pipeline-specialist.md)** - 欧洲议会 MCP 集成专家 - ⚙️ **[devops-engineer](.github/agents/devops-engineer.md)** - CI/CD 和 GitHub Actions 自动化 - 🔒 **[security-architect](.github/agents/security-architect.md)** - ISMS、 GDPR、NIS2 合规专家 - 📚 **[documentation-architect](.github/agents/documentation-architect.md)** - C4 模型和架构文档 - ✅ **[quality-engineer](.github/agents/quality-engineer.md)** - 测试、 验证和无障碍性 **使用示例**: ``` # 使用 product-task-agent 分析 repository 并创建改进 issues @product-task-agent analyze the multi-language support and create issues for any gaps # 使用 news-journalist 生成内容 @news-journalist create a week-ahead article for the upcoming plenary session # 使用 frontend-specialist 进行 UI 改进 @frontend-specialist make the language switcher fully keyboard accessible ``` **了解更多**:参见 [自定义代理文档](.github/agents/README.md) 获取详细的代理能力、使用模式和示例。 ## 支持的语言 - **北欧**:英语、瑞典语、丹麦语、挪威语、芬兰语 - **欧盟核心**:德语、法语、西班牙语、荷兰语- **中东**:阿拉伯语、希伯来语 - **东亚**:日语、韩语、中文 ## 系统要求 - **Node.js**:版本 24 或更高 - **npm**:版本 10 或更高(随 Node.js 24 附带) - **Git**:用于克隆仓库 你可以使用以下命令验证 Node.js 版本: ``` node --version # Should be v24.x.x or higher npm --version # Should be 10.x.x or higher ``` ## 安装 ``` # Clone the repository git clone https://github.com/Hack23/euparliamentmonitor.git cd euparliamentmonitor # Install dependencies npm install ``` ### 可选:欧洲议会 MCP Server 要集成真实的欧盟议会数据,请安装 MCP 服务器: ``` # Clone the MCP server repository git clone https://github.com/Hack23/European-Parliament-MCP-Server.git cd European-Parliament-MCP-Server # Install dependencies 并 build npm install npm run build # Server 将在 dist/index.js 可用 # 您可以全局安装或引用该路径 ``` 在环境变量中配置 MCP 服务器路径: ``` export EP_MCP_SERVER_PATH="/path/to/European-Parliament-MCP-Server/dist/index.js" ``` **注意**:MCP 服务器目前处于开发阶段。新闻生成可以在没有它的情况下使用占位符内容运行。 ## 使用 ### 生成新闻文章 ``` # 生成英文 week ahead 文章 npm run generate-news -- --types=week-ahead --languages=en # 生成多种语言类型的多种文章 npm run generate-news -- --types=week-ahead,committee-reports --languages=en,de,fr # 在所有 eu-core preset 语言中生成 npm run generate-news -- --types=week-ahead --languages=eu-core # 在所有支持的语言中生成 npm run generate-news -- --types=week-ahead --languages=all ``` ### 生成索引和站点地图 ``` # 生成特定语言的 index pages npm run generate-news-indexes # 生成 sitemap.xml npm run generate-sitemap ``` ### 本地开发 ``` # 在本地 Serve 站点 npm run serve # 在浏览器中打开 http://localhost:8080 ``` ## 项目结构 ``` euparliamentmonitor/ ├── .github/ │ ├── agents/ # Custom GitHub Copilot agents │ ├── workflows/ # CI/CD workflow configurations │ └── release-drafter.yml # Release notes configuration ├── src/ # TypeScript source (compiles to scripts/) │ ├── constants/ # Language data, configuration │ ├── generators/ # News, index, sitemap generators │ ├── mcp/ # European Parliament MCP client │ ├── templates/ # HTML article templates │ ├── types/ # Shared TypeScript interfaces │ └── utils/ # File utilities, metadata ├── scripts/ # Compiled JavaScript output │ ├── constants/ # Compiled constants │ ├── generators/ # Compiled generators │ ├── mcp/ # Compiled MCP client │ ├── templates/ # Compiled templates │ ├── types/ # Compiled type definitions │ └── utils/ # Compiled utilities ├── news/ # Generated news articles │ └── metadata/ # Generation metadata ├── test/ # Vitest unit & integration tests ├── e2e/ # Playwright E2E tests ├── docs/ # Generated documentation ├── styles.css # Article styling ├── index-{lang}.html # Language-specific index pages ├── typedoc.json # TypeDoc configuration ├── tsconfig.json # TypeScript configuration ├── sitemap.xml # SEO sitemap └── package.json # Project dependencies ``` ## CI/CD 与自动化 ### GitHub Actions 工作流 该仓库包含用于自动化和质量保证的全面 GitHub Actions 工作流: #### 📰 新闻生成 - **计划**:每天 UTC 时间 06:00 运行 - **手动触发**:可以使用自定义参数手动触发 - **自动提交**:自动提交并推送生成的文章 - **工作流**:`.github/workflows/news-generation.yml` **工作流输入:** - `article_types`:逗号分隔的文章类型列表(默认值:`week-ahead`) - `languages`:要生成的语言(`en`、`eu-core`、`all` 或自定义列表) - `force_generation`:即使存在最近的文章也强制生成 #### 🏷️ PR 标签 - **自动**:根据文件更改标记 PR - **配置**:`.github/labeler.yml` - **工作流**:`.github/workflows/labeler.yml` - **设置**:运行一次 `.github/workflows/setup-labels.yml` 以创建所有标签 #### 📦 发布管理 - **自动发布说明**:通过 Release Drafter - **语义版本控制**:基于 PR 标签 - **SBOM 与证明**:带有工件证明的安全合规性 - **工作流**:`.github/workflows/release.yml` - **配置**:`.github/release-drafter.yml` #### 🔒 安全扫描 - **CodeQL**:在 push、PR 和每周计划上运行自动化安全分析 - **OpenSSF Scorecard**:供应链安全评估(每周,在分支保护更改时) - **Dependabot**:npm 和 GitHub Actions 的每周依赖项更新 - **依赖项审查**:Pull Request 上的漏洞扫描 - **漏洞扫描**:PR 验证中的自动 npm audit - **工作流**:`.github/workflows/codeql.yml`、`.github/workflows/scorecards.yml`、`.github/dependabot.yml`、`.github/workflows/dependency-review.yml` #### 🏆 合规性与质量 - **REUSE 合规性**:许可证头部验证(FSFE REUSE 规范) - **SonarCloud 分析**:自动服务器端代码质量、安全漏洞和技术债务跟踪 - **SLSA 来源**:发布时带有 SBOM 生成的级别 3 构建证明 - **工作流**:`.github/workflows/reuse.yml`、`.github/workflows/slsa-provenance.yml` #### ✅ 测试与验证 - **HTML 验证**:自动 htmlhint 检查 - **功能测试**:新闻生成、索引和站点地图验证 - **安全检查**:npm audit 漏洞检查 - **工作流**:`.github/workflows/test-and-report.yml` **📊 证据:** 参见 README 顶部的 [工作流状态徽章](#-status-badges)。 ### 工作流状态徽章 **核心工作流:** [![新闻生成](https://github.com/Hack23/euparliamentmonitor/actions/workflows/news-generation.yml/badge.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/news-generation.yml) [![测试与报告](https://static.pigsec.cn/wp-content/uploads/repos/2026/03/16fa703189075623.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/test-and-report.yml) [![E2E 测试](https://static.pigsec.cn/wp-content/uploads/repos/2026/03/46a5da2c27075626.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/e2e.yml) **安全工作流:** [![CodeQL](https://static.pigsec.cn/wp-content/uploads/repos/2026/03/92d342f040075624.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/codeql.yml) [![OpenSSF 记分卡](https://static.pigsec.cn/wp-content/uploads/repos/2026/03/39b9db32db075627.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/scorecards.yml) [![依赖项审查](https://static.pigsec.cn/wp-content/uploads/repos/2026/03/43788caaa3075627.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/dependency-review.yml) **合规性工作流:** [![REUSE 合规性](https://static.pigsec.cn/wp-content/uploads/repos/2026/03/94e0ed7f7e075628.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/reuse.yml) [![SLSA 来源](https://static.pigsec.cn/wp-content/uploads/repos/2026/03/1e6c7bcf22075629.svg)](https://github.com/Hack23/euparliamentmonitor/actions/workflows/slsa-provenance.yml) ### 手动发布流程 要创建新版本: 1. 前往 **Actions** → **Release** 工作流 2. 点击 **Run workflow** 3. 输入版本号(例如 `v1.0.0`) 4. 选择是否为预发布 5. 工作流将: - 运行验证和测试(169 个单元测试、E2E 测试) - 生成 API 文档 - 生成测试覆盖率报告(Vitest HTML) - 生成 E2E 测试报告 - 创建文档索引 - 将文档提交到 main 分支 - 生成 SBOM 和证明(SLSA Level 3) - 创建带有工件的 GitHub Release - 自动更新发布说明 **🔒 ISMS 证据:** - [发布工作流](.github/workflows/release.yml) - 完整自动化 - [SLSA 证明](https://github.com/Hack23/euparliamentmonitor/attestations) - 构建来源 - [发布流程指南](docs/RELEASE_PROCESS.md) - 分步文档 ### 文档即代码 每次发布都会自动生成全面的文档: | 文档 | 描述 | 链接 | |--------------|-------------|------| | **API 文档** | 从 TypeScript 源代码生成的 TypeDoc API 参考 | [查看文档](https://hack23.github.io/euparliamentmonitor/docs/api/) | | **测试覆盖率** | 交互式 Vitest 覆盖率报告 (82%+) | [查看覆盖率](https://hack23.github.io/euparliamentmonitor/docs/coverage/) | | **E2E 测试报告** | 包含截图的 Playwright 测试结果 | [查看报告](https://hack23.github.io/euparliamentmonitor/playwright-report/) | | **文档索引** | 链接所有报告的精美中心页 | [查看索引](https://hack23.github.io/euparliamentmonitor/docs/) | **📋 工作原理:** 1. 发布工作流运行所有测试 2. 使用 TypeDoc 生成 API 文档 3. 将覆盖率报告复制到 `docs/` 4. 创建文档索引页面 5. 将所有内容提交到 `main` 分支 6. 文档受到版本控制和可追溯 **🎯 本地运行:** ``` npm run docs:generate # Generate all documentation npm run docs:api # Generate API docs only npm run docs:index # Generate index page ``` **🔒 ISMS 合规性:** - 文档即代码遵循 [Hack23 ISMS 安全开发策略 §3.2](https://github.com/Hack23/ISMS-PUBLIC/blob/main/Secure_Development_Policy.md#32-architecture-documentation) - 所有版本都包含完整的文档证据 - 文档提交到仓库以实现完全的可审计性 ### 设置标签 首次设置需要运行标签创建工作流: 1. 前往 **Actions** → **Setup Repository Labels** 2. 点击 **Run workflow** 3. 等待完成 4. 标签将自动应用于未来的 PR ## 配置 ### 语言预设 - `en` - 仅英语 - `eu-core` - 英语、德语、法语、西班牙语、荷兰语 - `nordic` - 英语、瑞典语、丹麦语、挪威语、芬兰语 - `all` - 所有 14 种支持的语言 ### 文章类型 - `week-ahead` - 即将举行的议会事件预览 - `committee-reports` - 委员会活动分析(即将推出) - `propositions` - 立法提案分析(即将推出) - `motions` - 议会动议分析(即将推出) - `breaking` - 突发新闻报道(即将推出) ## 贡献 我们欢迎来自开发者、记者、翻译和安全研究人员的贡献! ### 如何贡献 请阅读我们全面的 [贡献指南](CONTRIBUTING.md),了解: - 开发工作流和设置说明 - 代码质量要求和测试标准 - Pull Request 流程和审查指南 - 安全最佳实践和 ISMS 合规性 - 多语言贡献指南 ### 行为准则 本项目遵守 [Contributor Covenant 行为准则](CODE_OF_CONDUCT.md)。参与本项目即表示您同意遵守该准则。请向 [conduct@hack23.com](mailto:conduct@hack23.com) 报告不可接受的行为。 ### 安全 如果您发现安全漏洞,请遵循我们的 [安全策略](SECURITY.md) 进行负责任披露。**切勿**通过公开的 GitHub Issues 报告安全问题。 ### 贡献者 请参阅 [AUTHORS.md](AUTHORS.md) 获取帮助实现本项目的贡献者列表。 欢迎贡献!请参阅 [CONTRIBUTING.md](CONTRIBUTING.md) 获取以下方面的详细指南: - 代码质量要求 - 测试要求(80% 行覆盖率,75% 分支覆盖率) - 安全要求(输入验证、XSS 防护、依赖项扫描) - 提交消息格式(约定式提交) - Pull Request 流程 **安全关键贡献**:所有与安全相关的更改必须符合 [SECURITY_ARCHITECTURE.md](SECURITY_ARCHITECTURE.md) 和 [Hack23 ISMS 安全开发策略](https://github.com/Hack23/ISMS-PUBLIC/blob/main/Secure_Development_Policy.md)。 ## 安全策略 有关安全漏洞报告和披露流程,请参阅 [SECURITY.md](SECURITY.md)。 **负责任披露**: - 通过 GitHub Security Advisories 私下报告漏洞 - 48 小时确认,7 天验证,30 天修复严重问题 - 安全研究人员的公开认可(除非要求匿名) ## 徽章维护 ### 维护安全徽章状态 EU Parliament Monitor 通过持续遵守 OpenSSF 最佳实践来维护安全卓越性: #### OpenSSF Scorecard(目标:≥7.0) **当前优化**: - ✅ `main` 分支的分支保护 - ✅ Pull Request 的必要代码审查 - ✅ SHA 固定的 GitHub Actions - ✅ 启用 CodeQL SAST - ✅ 启用 Dependabot 警报 - ✅ 存在 SECURITY.md - ✅ 无危险的工作流模式 **监控**:在 [OpenSSF Scorecard Dashboard](https://scorecard.dev/viewer/?uri=github.com/Hack23/euparliamentmonitor) 查看当前分数 #### CII 最佳实践(目标:通过 → 银牌 → 金牌) **已满足要求**: - ✅ 公开版本控制 - ✅ 公开问题追踪器 - ✅ LICENSE 文件(Apache-2.0) - ✅ 包含清晰指南的 CONTRIBUTING.md - ✅ CODE_OF_CONDUCT.md - ✅ 包含漏洞报告的 SECURITY.md - ✅ README 中的文档 - ✅ 自动化测试(Vitest + Playwright,≥80% 覆盖率) - ✅ 静态分析(CodeQL、ESLint) - ✅ 依赖项扫描(Dependabot、npm audit) **注册**:在 [CII Best Practices](https://bestpractices.coreinfrastructure.org/) 完成问卷 #### SLSA Level 3(状态:✅ 已实现) **来源生成**: - ✅ 通过 `.github/workflows/slsa-provenance.yml` 在发布时自动执行 - ✅ 使用 `actions/attest-build-provenance@v2` 的构建证明 - ✅ 使用 CycloneDX 的 SBOM 生成 - ✅ 工件上传到 GitHub Releases **验证**:在 `https://github.com/Hack23/euparliamentmonitor/attestations/` 查看证明 #### FOSSA 许可证合规性 **所需设置**: 1. 在 [FOSSA](https://fossa.com/) 注册 2. 连接 GitHub 仓库 3. 配置许可证策略(仅限 Apache-2.0 兼容) **徽章**:扫描完成后自动更新 #### REUSE 合规性(状态:✅ 已实现) **合规性验证**: - ✅ `.reuse/dep5` 覆盖所有无头文件 - ✅ Apache-2.0 许可证应用于所有项目文件 - ✅ 版权声明:"2024-2026 Hack23 AB" **工作流**:通过 `.github/workflows/reuse.yml` 在 push、pull requests 和每周运行 ### ISMS 策略参考 本项目遵守 [Hack23 ISMS](https://github.com/Hack23/ISMS-PUBLIC) 策略: | 策略 | 相关性 | 实现 | |--------|-----------|----------------| | [**开源策略**](https://github.com/Hack23/ISMS-PUBLIC/blob/main/Open_Source_Policy.md) | 安全徽章要求 | 所有必需徽章已实现 | | [**安全开发策略**](https://github.com/Hack23/ISMS-PUBLIC/blob/main/Secure_Development_Policy.md) | 开发安全标准 | SECURITYITECTURE.md、SAST/SCA/DAST | | [**威胁建模策略**](https://github.com/Hack23/ISMS-PUBLIC/blob/main/Threat_Modeling.md) | 威胁分析要求 | SECURITY_ARCHITECTURE.md 中的 STRIDE 分析 | | [**漏洞管理**](https://github.com/Hack23/ISMS-PUBLIC/blob/main/Vulnerability_Management.md) | 修复 SLA | SECURITY.md 披露时间表 | | [**分类框架**](https://github.com/Hack23/ISMS-PUBLIC/blob/main/CLASSIFICATION.md) | 数据分类 | 公开/中等/中等 (L1/L2/L2) | | [**事件响应计划**](https://github.com/Hack23/ISMS-PUBLIC/blob/main/Incident_Response_Plan.md) | 安全事件程序 | 在 SECURITY.md 中链接 | ### 合规框架 EU Parliament Monitor 与多个合规框架保持一致: | 框架 | 控制 | 证据 | |-----------|----------|----------| | **ISO 27001** | A.12.6.1(漏洞管理)、A.14.2.8(安全测试) | CodeQL、Dependabot、npm audit | | **NIST CSF 2.0** | 识别、保护、检测、响应、恢复 | SECURITY_ARCHITECTURE.md 合规矩阵 | | **CIS Controls v8.1** | 18.3(修复漏洞)、2.7(允许列表) | 自动化扫描、SBOM | | **GDPR** | 设计数据保护 | 欧洲议会开放数据(公开) | | **NIS2** | 第 20、21 条(网络安全风险管理) | 威胁模型、安全控制 | | **EU 网络弹性法案** | SBOM、漏洞披露 | SLSA 来源、SECURITY.md | ## 🤖 AI 驱动的新闻生成与代理智能 EU Parliament Monitor 不仅仅是报道欧洲议会活动——它以机器速度**自主生成深度政治情报**,其编辑质量足以让传统新闻编辑室感到压力。每篇文章都由 AI 代理进行研究、撰写、本地化并准备发布,这些代理默认通过 [MCP Server](https://github.com/Hack23/European-Parliament-MCP-Server)(46 个工具、实时数据)处理实时欧洲议会数据,并在实时访问不可用时透明地回退到占位符/测试数据(如上所述)。代理自动生成内容并打开可发布的 Pull Request;当人工审查并合并这些 PR 时,即发布到网站。 ### 📰 代理式新闻生成架构 **8 个自主新闻工作流**按精确计划运行,每个工作流由专门的 GitHub Copilot 代理工作流驱动,获取实时 EP 数据(具有记录的回退行为),生成经济学人风格的分析,并为所有 14 种语言打开可发布的 Pull Request: ``` graph LR subgraph "📅 Daily Cycle (Mon-Fri)" CR["🏛️ Committee Reports
04:00 UTC"] PR["📜 Propositions
05:00 UTC"] MO["⚖️ Motions
06:00 UTC"] end subgraph "📆 Weekly Cycle" WA["📋 Week Ahead
Fri 07:00 UTC"] WR["📊 Weekly Review
Sat 09:00 UTC"] end subgraph "📅 Monthly Cycle" MA["🔭 Month Ahead
1st 08:00 UTC"] MR["📈 Monthly Review
28th 10:00 UTC"] end subgraph "🎛️ On-Demand" AG["🚀 Article Generator
Manual Dispatch"] end MCP["🔌 EP MCP Server
46 Tools · Live Data"] MCP --> CR & PR & MO & WA & WR & MA & MR & AG style CR fill:#1a5276,color:#fff style PR fill:#1a5276,color:#fff style MO fill:#1a5276,color:#fff style WA fill:#117a65,color:#fff style WR fill:#117a65,color:#fff style MA fill:#7d3c98,color:#fff style MR fill:#7d3c98,color:#fff style AG fill:#b9770e,color:#fff style MCP fill:#c0392b,color:#fff ``` | 工作流 | 计划 | 重点 | 输出 | |----------|----------|-------|--------| | 🏛️ **委员会报告** | 周一–周五 04:00 UTC | 委员会决策与活动 | 14 种语言文章 | | 📜 **提案** | 周一–周五 05:00 UTC | 立法提案分析 | 14 种语言文章 | | ⚖️ **议案** | 周一–周五 06:00 UTC | 动议与决议分析 | 14 种语言文章 | | 📋 **前瞻** | 周五 07:00 UTC | 即将举行的议会预览 | 14 种语言文章 | | 📊 **每周回顾** | 周六 09:00 UTC | 过去一周回顾 | 14 种语言文章 | | 🔭 **下月展望** | 每月 1 日 08:00 UTC | 战略月度展望 | 14 种语言文章 | | 📈 **月度回顾** | 每月 28 日 10:00 UTC | 月度回顾分析 | 14 种语言文章 | | 🚀 **文章生成器** | 手动调度 | 多类型文章生成 | 可配置 | ### 🧠 智能栈 该平台将 **8 个核心新闻管道 AI 代理**(来自 22+ 个专门代理目录)、**39+ 个 TypeScript 源模块**、**21 个 CI/CD 工作流**和 **46 个 MCP 数据工具**组合成一个完全自主的政治情报管道: ``` graph TB subgraph "🤖 8 Core News Pipeline Agents" A1["📰 News Journalist
Economist-style reporting"] A2["🔄 Data Pipeline
MCP integration"] A3["🎨 Frontend
WCAG 2.1 AA"] A4["✅ Quality Engineer
Testing & validation"] A5["🔒 Security Architect
ISMS compliance"] A6["📚 Documentation
C4 & architecture"] A7["⚙️ DevOps Engineer
CI/CD automation"] A8["📋 Product Task
Issue management"] end subgraph "⚙️ 21 CI/CD Workflows" W1["8 News Generation"] W2["5 Security & Compliance"] W3["2 Testing"] W4["2 Release & Deploy"] W5["4 Automation & Infra"] end subgraph "📊 Data Layer" MCP["🔌 EP MCP Server
46 Tools"] TS["📦 39+ TypeScript Modules"] L14["🌍 14 Languages"] end A1 --> W1 A2 --> MCP A7 --> W2 & W3 & W4 W1 --> TS --> L14 style A1 fill:#2e86c1,color:#fff style A2 fill:#2e86c1,color:#fff style A3 fill:#2e86c1,color:#fff style A4 fill:#2e86c1,color:#fff style A5 fill:#2e86c1,color:#fff style A6 fill:#2e86c1,color:#fff style A7 fill:#2e86c1,color:#fff style A8 fill:#2e86c1,color:#fff style W1 fill:#1a5276,color:#fff style W2 fill:#7d3c98,color:#fff style W3 fill:#117a65,color:#fff style W4 fill:#b9770e,color:#fff style MCP fill:#c0392b,color:#fff style TS fill:#1c2833,color:#fff style L14 fill:#117a65,color:#fff ``` ### 🚀 未来展望:AI 演进路线图 (2026–2037) 该平台经历六个阶段,从代理式新闻生成演变为 AGI 增强的变革性民主。详情请参阅 **[未来思维导图](FUTURE_MINDMAP.md)** 和 **[未来工作流](FUTURE_WORKFLOWS.md)**。 ``` timeline title EU Parliament Monitor — AI Evolution Roadmap section Phase 1 (2026) Agentic News : 8 autonomous workflows : 14-language generation : MCP data integration : Economist-style analysis section Phase 2 (2027) Predictive Analytics : Voting outcome prediction : Legislative impact forecasting : Cross-party coalition detection : Automated trend analysis section Phase 3 (2028–2029) Multi-Modal Intelligence : Video plenary analysis : Real-time debate tracking : Infographic auto-generation : Autonomous content pipelines section Phase 4 (2030–2031) Near-Expert Analysis : 50+ parliament coverage : Expert-level policy briefs : Predictive governance models : Universal language support section Phase 5 (2032–2033) Global Coverage : 100+ parliaments : Pre-AGI capabilities : Real-time policy impact : Cross-jurisdiction analysis section Phase 6 (2034–2037) AGI Era : Transformative democracy : 195 national legislatures : Policy prediction before proposal : Human oversight maintained ``` ### 🤖 第六阶段:AGI 时代与变革性民主 (2034–2037) 当 AGI 或近 AGI 系统可用时,平台架构设计为可负责任地扩展: | 能力 | 描述 | |-----------|-------------| | 🤖 **自主分析** | AGI 驱动的实时政治情报,覆盖所有 195 个国家立法机构 | | 🌐 **通用语言支持** | 原生支持所有联合国语言——无翻译管道,原生生成 | | 📊 **预测性治理** | 在立法提案之前预测政策影响——预期情报 | | ⚖️ **伦理 AI 治理** | 无论 AI 能力水平如何,都保持人工监督——民主保障措施已硬编码 | | 🛡️ **民主保障** | 平台架构防止武器化或操纵——设计透明 | ### 📈 AI 模型演进策略 **假设:** 每年主要 AI 模型升级,每次发布时评估竞争对手(OpenAI、Google、Meta、欧盟主权 AI)。架构适应潜在的范式转变(量子 AI、神经形态计算)。 下面的预计工作流计数包括平台上的所有 CI/CD 工作流定义、代理工作流源码和计划变体。2026 年基线(约 44 个)建立在当前 21 个已部署的 `.yml` 工作流 + 8 个代理 `.md` 源码(目前共 29 个)加上计划中的安全、本地化和数据管道新增内容之上。 | 年份 | 预计工作流定义数 | AI 模型 | 关键能力 | |------|-------------------------------|----------|----------------| | **2026** | 44–50 | Opus 4.6–4.9 | 🟢 代理式新闻生成 | | **2027** | 50–55 | Opus 5.x | 🔵 预测性分析 | | **2028** | 55–65 | Opus 6.x | 🟣 多模态内容 | | **2029** | 65–75 | Opus 7.x | 🟠 自主管道 | | **2030** | 75–85 | Opus 8.x | 🔴 近专家分析 | | **2031–2033** | 85–100 | Opus 9–10.x / Pre-AGI | ⚪ 全球覆盖 | | **2034–2037** | 100–120+ | AGI / Post-AGI | ⭐ 变革性平台 | ``` %%{init: {'theme': 'base', 'themeVariables': {'primaryColor': '#1a5276', 'primaryTextColor': '#fff', 'lineColor': '#2e86c1', 'secondaryColor': '#117a65'}}}%% xychart-beta title "Projected Workflow Definitions & Variants (2026–2037)" x-axis ["2026", "2027", "2028", "2029", "2030", "2031", "2032", "2033", "2034", "2035", "2036", "2037"] y-axis "Workflow definitions & variants" 0 --> 130 bar [44, 53, 60, 70, 80, 88, 94, 100, 105, 110, 115, 120] line [44, 53, 60, 70, 80, 88, 94, 100, 105, 110, 115, 120] ``` ### 📚 详细路线图文档 | 文档 | 重点 | 覆盖范围 | |----------|-------|----------| | 📘 **[未来思维导图](FUTURE_MINDMAP.md)** | 能力演进与系统愿景 | 2026–2037 AI/ML 路线图、多议会扩展、API 生态系统 | | 📗 **[未来工作流](FUTURE_WORKFLOWS.md)** | CI/CD 演进与自动化路线图 | 安全加固、性能优化、AGI 就绪管道 | ## 许可证 版权所有 2024-2026 Hack23 AB 根据 Apache License, Version 2.0("许可证")授权; 除非遵守本许可证,否则您不得使用本文件。 您可以在以下位置获取许可证副本: ``` http://www.apache.org/licenses/LICENSE-2.0 ``` 除非适用法律要求或书面同意,否则根据许可证分发的软件 是按"原样"分发的, 没有任何形式的明示或暗示的担保或条件。 请参阅许可证以了解许可证下的特定语言管理权限和 限制。 有关完整详细信息,请参阅 [LICENSE](LICENSE) 文件。 ## 致谢 本项目基于 [Hack23/riksdagsmonitor](https://github.com/Hack23/riksdagsmonitor) 的新闻生成实现。 ## 作者 Hack23 AB - 情报运营团队
标签:ESC4, MITM代理, OSINT, 会议记录, 公共事务, 后端开发, 后端开发, 国际政治, 多语言新闻, 委员会报告, 情报平台, 提案追踪, 政务透明, 政治监控, 欧盟议会, 特征检测, 突发新闻, 自动监控