-
Notifications
You must be signed in to change notification settings - Fork 0
fix: prompt hardening and state-management policy alignment #18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
This file was deleted.
Oops, something went wrong.
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| # Prompt Execution Guardrails | ||
|
|
||
| Use these rules for all command prompts. | ||
|
|
||
| ## Required inputs (before execution) | ||
|
|
||
| - Goal: what outcome is required. | ||
| - Scope: target modules/files and out-of-scope areas. | ||
| - Constraints: architecture/state-management/tooling constraints. | ||
| - Validation: exact commands to prove success. | ||
|
|
||
| If any required input is missing, stop and request clarification instead of guessing. | ||
|
|
||
| ## Fail-fast rules | ||
|
|
||
| - Do not fabricate external context (Figma node IDs, CI logs, credentials, API contracts). | ||
| - If prerequisites are unavailable (tools, credentials, build context), report blocker and minimal next input needed. | ||
| - For security/review commands, require explicit target: diff, branch, or file set. | ||
|
|
||
| ## Change scope limits | ||
|
|
||
| - Keep blast radius small: modify only files needed for the stated goal. | ||
| - No unrelated refactors in the same run. | ||
| - If migration is large, split into batches with per-batch validation. | ||
|
|
||
| ## Output quality | ||
|
|
||
| - Tie claims to concrete checks run. | ||
| - Prefer precise file references and command results. | ||
| - Explicitly call out residual risks and unverified assumptions. |
This file was deleted.
Oops, something went wrong.
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,58 @@ | ||
| # Validation Matrix | ||
|
|
||
| Deterministic validation baseline per command. | ||
|
|
||
| ## implement-flutter-feature | ||
|
|
||
| - `flutter analyze` | ||
| - `flutter test` (targeted for changed feature/tests) | ||
|
|
||
| ## implement-figma-screen | ||
|
|
||
| - `flutter analyze` | ||
| - `flutter test` (widget tests for implemented screen) | ||
|
|
||
| ## generate-flutter-tests | ||
|
|
||
| - `flutter test` for created/changed test files | ||
|
|
||
| ## review-flutter-code | ||
|
|
||
| - Evidence-based findings against changed files/diff | ||
| - Security pass included (`security-audit` scope) | ||
|
|
||
| ## security-review | ||
|
|
||
| - Secrets scan command(s) executed or explicitly unavailable | ||
| - Findings with severity + remediation + verification steps | ||
|
|
||
| ## update-flutter-dependencies | ||
|
|
||
| - `flutter --version` (before/after) | ||
| - `flutter pub outdated` | ||
| - `flutter analyze` | ||
| - impacted `flutter test` suite | ||
|
|
||
| ## resolve-flutter-build-error | ||
|
|
||
| - Reproduction command captured | ||
| - Re-run reproduction command after fix | ||
| - `flutter analyze` + impacted tests | ||
|
|
||
| ## prepare-mobile-release | ||
|
|
||
| - `flutter analyze` | ||
| - `flutter test` (required suite) | ||
| - release artifact build commands documented (`.aab`/`.ipa` path) | ||
|
|
||
| ## integrate-firebase | ||
|
|
||
| - `flutter analyze` | ||
| - `flutter test` (impacted) | ||
| - platform config verification (Android/iOS init) | ||
|
|
||
| ## migrate-flutter-code | ||
|
|
||
| - Per-batch `flutter analyze` | ||
| - Per-batch impacted tests | ||
| - migration checklist completion status | ||
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
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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This new matrix is presented as the deterministic validation source “per command”, and multiple updated commands now require it, but there are no entries for
write-widget-test,write-bloc-test,write-e2e-test,setup-mobile-github-pipeline, orsync-official-flutter-ai-rules; those command paths therefore cannot follow the stated guardrail consistently and will produce non-deterministic validation behavior.Useful? React with 👍 / 👎.