Improve the prompts#283
Merged
Merged
Conversation
e14cdfb to
a8757c0
Compare
Contributor
There was a problem hiding this comment.
Some food for thought. View full project report here.
Co-authored-by: code-review-doctor[bot] <72320148+code-review-doctor[bot]@users.noreply.github.com>
…an/FluentAI into feat/prompt-improv
There was a problem hiding this comment.
Pull Request Overview
This PR refactors prompt generation and model configuration, adds new utilities for syllabification and n-gram probabilities, and updates dependencies and pipelines.
- Updated
config.yamlwith new LLM/IMAGE_GEN model names and parameters, including FLUX LoRA settings - Expanded
requirements.txtwith language‐processing libraries and platform‐specific Nunchaku wheels - Introduced
syllabifier.pyandngram_probs.py; refactoredVerbalCueandImageGenservices for improved prompt templates and FLUX integration
Reviewed Changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| config.yaml | Swapped model names; added MNEMONIC_CANDIDATES, params |
| backend/requirements.txt | Downgraded transformers; added pyphen/lingpy/epitran, nunchaku wheels |
| backend/mnemorai/utils/syllabifier.py | New language syllabification utility |
| backend/mnemorai/utils/ngram_probs.py | New n-gram probability utility with corpus downloads |
| backend/mnemorai/services/pre/translator.py | Improved logging around language code mapping |
| backend/mnemorai/services/imagine/verbal_cue_gen.py | Refactored mnemonic/verbal-cue prompt templates |
| backend/mnemorai/services/imagine/image_gen.py | Replaced SanaPipeline with FLUXPipeline; seed & offload logic |
| backend/mnemorai/run.py | Updated example invocation |
Comments suppressed due to low confidence (3)
config.yaml:33
- Ensure that
MNEMONIC_CANDIDATESis correctly indented under theLLMsection and consider documenting this new parameter in the README so users know how to adjust it.
MNEMONIC_CANDIDATES: 20
backend/mnemorai/services/imagine/image_gen.py:57
- The old
SanaPipelinebranch was removed; ensure that any users or docs referencing Sana pipelines are updated and that the default branch (AutoPipelineForText2Image) still covers all intended models.
if "flux" in self.model_name.lower():
backend/requirements.txt:4
- Downgrading Transformers from 4.52.4 to 4.51.3 may reintroduce bugs or security issues; please confirm that this change is intentional and update any related compatibility tests or documentation.
transformers[sentencepiece]==4.51.3
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.
Description
This PR [adds/removes/fixes/replaces] the [feature/bug/etc].
Related Tickets & Documents
Fixes # (issue)
What type of PR is this? (check all applicable)
Added to documentation?