Adiciona fluxo de trabalho para gerar resumo semanal de notícias#44
Draft
cleissonbarbosa wants to merge 1 commit intomainfrom
Draft
Adiciona fluxo de trabalho para gerar resumo semanal de notícias#44cleissonbarbosa wants to merge 1 commit intomainfrom
cleissonbarbosa wants to merge 1 commit intomainfrom
Conversation
…tegra ao processo de geração de posts
Contributor
There was a problem hiding this comment.
Code Review
This pull request introduces a new feature to generate a weekly news digest using the Gemini API with Google Search grounding. It includes a new service class, a corresponding use case, and updates to the CLI handler and main entry point to support a --weekly-digest flag. Feedback was provided regarding the use of potentially invalid model names, the unused parameter in the prompt creation method, and a suggestion to refactor the instantiation logic in the main entry point to reduce code duplication.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces an automated workflow and supporting backend logic to generate a weekly news digest post using Gemini's Google Search grounding. The workflow is integrated into GitHub Actions, and the backend is extended to support content and image generation for the digest, as well as validation and automated merging of the generated post. The main highlights are the addition of a new workflow, backend service, use case, and CLI support for generating and publishing these weekly digests.
GitHub Actions Workflow Integration:
.github/workflows/generate-weekly-digest.ymlthat automatically generates a weekly news digest post every Sunday, creates a pull request with the generated content and image, validates the format and image, and auto-merges the PR if validation passes..github/workflows/pages-deploy.ymlto trigger deployment after the new weekly digest workflow completes.Backend: Digest Generation Support:
GeminiNewsDigestServiceingenerate_post/adapters/api/gemini_news_digest_service.pyto generate a weekly digest post using Gemini with Google Search grounding, including prompt creation, content generation, parsing, and source attribution.GeminiNewsDigestServicein the API adapter module for use in the application.GenerateWeeklyDigestUseCaseingenerate_post/core/use_cases/generate_weekly_digest_use_case.pyto orchestrate the generation, image creation, and saving of the weekly digest post.CLI and Application Entry Point:
generate_post/main.pyto support a--weekly-digestflag, enabling digest generation from the command line, and to wire up the new use case and service accordingly. [1] [2] [3]