Skip to content

Add intent-drift skill: detect drift between original goal and current work 🤖🤖🤖 - #6242

Closed
shauryagangrade wants to merge 4 commits into
github:mainfrom
shauryagangrade:add-intent-drift-skill
Closed

shauryagangrade wants to merge 4 commits into
github:mainfrom
shauryagangrade:add-intent-drift-skill

Conversation

@shauryagangrade

Copy link
Copy Markdown
Contributor

What this adds

Adds skills/intent-drift/, a skill that detects intent drift in AI-assisted development. It compares the original goal with the current plan and execution evidence, then reports alignment %, a status band, confidence, and the strongest per-provider evidence.

When invoked (/intent-drift, or phrases like "check intent drift", "are we still on track", "did the plan drift"), the agent gathers the goal, the current plan, and optional repo context, runs the bundled analyzer, and reports the result. If alignment falls below the threshold, the skill tells the agent to pause and confirm intent rather than silently continuing down an off-track plan.

What's bundled

  • SKILL.md — invocation flow and reporting rules
  • analyzer.py — CLI and IntentDriftAnalyzer (parse → analyze → export)
  • providers/ — nine weighted evidence providers: goal, constraints, scope, execution, file graph, dependencies, architecture, requirement coverage, and cross-provider problematic findings
  • exporters/ — text, Markdown, and JSON reports
  • scripts/collect_context.py — repo-only auto-context (git diff, commits, edited files, file changes) with default-on secret scrubbing; shell history is opt-in via --include-shell-history
  • config/defaults.yaml, metadata.json, docs/, examples/
  • bin/intent-drift.js — launcher that provisions a Python venv and installs dependencies on first run

Every bundled asset is referenced from SKILL.md.

Validation

  • npm run skill:validate — passes (all 459 skills valid)
  • npm run build — regenerated docs/README.skills.md with the new row
  • bash eng/fix-line-endings.sh — run
  • Smoke-tested the analyzer from the skill folder with both --format text and --format json

Notes

  • Requires Python 3.10+ and the intent-drift engine package (see requirements.txt). The Node launcher installs it into a private venv automatically, or users can pip install -r requirements.txt.
  • Source project: https://github.com/shauryagangrade/intent-drift-skill (Apache-2.0; the bundled LICENSE is preserved). Submitted by the original author.

Adds the intent-drift skill, which compares an agent's original goal with
its current plan and execution context and reports alignment, drift status,
confidence, and evidence.

Bundles the analyzer CLI, nine evidence providers, text/markdown/JSON
exporters, repo-only auto-context collection with secret scrubbing, config
defaults, examples, reference docs, and a Node launcher that provisions
its Python dependencies in a venv.
@shauryagangrade
shauryagangrade requested review from a team as code owners November 4, 2026 05:16
Copilot AI auto review requested due to automatic review settings November 4, 2026 05:16
@github-actions github-actions Bot added new-submission PR adds at least one new contribution skills PR touches skills labels Nov 4, 2026
@github-actions

github-actions Bot commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

🔒 PR Risk Scan Results

Scanned 31 changed file(s).

Severity Count
🔴 High 0
🟠 Medium 2
ℹ️ Info 20
Severity Rule File Line Match
ℹ️ skill-script-touched skills/intent-drift/__init__.py 1 skills/intent-drift/__init__.py
ℹ️ skill-script-touched skills/intent-drift/analyzer.py 1 skills/intent-drift/analyzer.py
ℹ️ skill-script-touched skills/intent-drift/config.py 1 skills/intent-drift/config.py
🟠 package-exec-command skills/intent-drift/config.py 31 # even when the packaged files are missing (e.g. a minimal npx install).
ℹ️ skill-script-touched skills/intent-drift/examples/auto_context.py 1 skills/intent-drift/examples/auto_context.py
ℹ️ skill-script-touched skills/intent-drift/examples/basic.py 1 skills/intent-drift/examples/basic.py
ℹ️ skill-script-touched skills/intent-drift/exporters/__init__.py 1 skills/intent-drift/exporters/__init__.py
ℹ️ skill-script-touched skills/intent-drift/history.py 1 skills/intent-drift/history.py
ℹ️ skill-script-touched skills/intent-drift/providers/__init__.py 1 skills/intent-drift/providers/__init__.py
ℹ️ skill-script-touched skills/intent-drift/providers/architecture_provider.py 1 skills/intent-drift/providers/architecture_provider.py
ℹ️ skill-script-touched skills/intent-drift/providers/base.py 1 skills/intent-drift/providers/base.py
ℹ️ skill-script-touched skills/intent-drift/providers/constraint_provider.py 1 skills/intent-drift/providers/constraint_provider.py
ℹ️ skill-script-touched skills/intent-drift/providers/dependency_provider.py 1 skills/intent-drift/providers/dependency_provider.py
ℹ️ skill-script-touched skills/intent-drift/providers/execution_provider.py 1 skills/intent-drift/providers/execution_provider.py
ℹ️ skill-script-touched skills/intent-drift/providers/file_graph_provider.py 1 skills/intent-drift/providers/file_graph_provider.py
ℹ️ skill-script-touched skills/intent-drift/providers/goal_provider.py 1 skills/intent-drift/providers/goal_provider.py
ℹ️ skill-script-touched skills/intent-drift/providers/problematic_findings_provider.py 1 skills/intent-drift/providers/problematic_findings_provider.py
ℹ️ skill-script-touched skills/intent-drift/providers/requirement_coverage_provider.py 1 skills/intent-drift/providers/requirement_coverage_provider.py
ℹ️ skill-script-touched skills/intent-drift/providers/scope_provider.py 1 skills/intent-drift/providers/scope_provider.py
🟠 unpinned-version-indicator skills/intent-drift/requirements.txt 1 intent-drift>=0.1.0
ℹ️ skill-script-touched skills/intent-drift/scripts/__init__.py 1 skills/intent-drift/scripts/__init__.py
ℹ️ skill-script-touched skills/intent-drift/scripts/collect_context.py 1 skills/intent-drift/scripts/collect_context.py

This is an automated soft-gate report. Findings indicate review targets and do not block merge by themselves.

@github-actions

github-actions Bot commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

🔴 Contributor Reputation Check: HIGH risk

Check Risk
Profile HIGH
Credential audit NONE

Maintainers: please review this contributor before merging.
See the workflow run for full details.
Automated check powered by AGT.

@github-actions

github-actions Bot commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

🚦 Submission status: 🛠️ Requires submitter fixes

Risk tier: merge-risk:high — Privileged execution, automation, or review-policy change
Required to merge: passing submission-gate checks plus 1 approval from reviewers with write access, including a maintainer with admin or maintain permission.

Why this tier
  • skills/intent-drift/__init__.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/analyzer.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/config.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/examples/auto_context.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/examples/basic.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/exporters/__init__.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/history.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/providers/__init__.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/providers/architecture_provider.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/providers/base.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/providers/constraint_provider.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/providers/dependency_provider.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/providers/execution_provider.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/providers/file_graph_provider.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • skills/intent-drift/providers/goal_provider.py is a high-risk path (automation, scripts, MCP config, hooks, or review policy)
  • …and 9 more

Automated checks

Check Status Details
Line endings ✅ Passed Passed · logs
Spelling ✅ Passed Passed · logs
Generated README consistency ❌ Contribution failure Failed step: Fail workflow if files need updating · logs
Skill validation ✅ Passed Passed · logs
Skill lint (vally) ✅ Passed Passed · logs
Risk scan ✅ Passed Passed · logs
Contributor reputation ✅ Passed Passed · logs
Duplicate resource scan ✅ Passed Passed · logs
PR quality signal ⏭️ Skipped Skipped by its workflow · logs

Action needed

  • Generated README consistency failed. Run npm start locally and commit the regenerated files.

Review

  • Approvals: 0/1
  • Assigned reviewer: not assigned yet — comment /request-review to ask for one
  • Review target date: not set
  • Still needed: 1 more approval(s); an approval from a maintainer with admin or maintain permission
  • The core-maintainers pool is not staffed yet; an approver with admin or maintain permission is required instead.

Commands

Command Who What it does
/rerun-checks PR author, maintainers Re-runs failed or incomplete checks and re-evaluates this gate
/request-review PR author, maintainers Asks the review rotation to assign a reviewer (adds needs-reviewer)

Updated for 5ae3c31 · gate run · This comment is maintained automatically — see submission gate docs.

@github-actions github-actions Bot added the needs-review:HIGH Contributor reputation check flagged HIGH risk label Nov 4, 2026
@github-actions

github-actions Bot commented Nov 4, 2026

Copy link
Copy Markdown
Contributor

🔍 Vally Lint Results

✅ All checks passed

Scope Checked
Skills 1
Agents 0
Total 1
Severity Count
❌ Errors 0
⚠️ Warnings 0
ℹ️ Advisories 0

Summary

Level Finding
ℹ️ ✅ intent-drift (2/2 checks passed)
ℹ️ ✓ [spec-compliance] All 1 skill(s) are spec-compliant.
ℹ️ ✓ spec-compliance: All spec checks passed.
ℹ️ ✓ [valid-refs] All file references across 1 skill(s) are valid.
ℹ️ ✓ valid-refs: All file references resolve to existing files within the skill directory.
ℹ️ 1 skill(s) linted, 1 passed
Full linter output
### Linting skills/intent-drift
✅ intent-drift (2/2 checks passed)
    ✓ [spec-compliance] All 1 skill(s) are spec-compliant.
        ✓ spec-compliance: All spec checks passed.
    ✓ [valid-refs] All file references across 1 skill(s) are valid.
        ✓ valid-refs: All file references resolve to existing files within the skill directory.

1 skill(s) linted, 1 passed

@github-actions github-actions Bot added ready-for-review Submission passed intake validation and is ready for maintainer review and removed awaiting-automation labels Nov 4, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Unresolved credential-scrubbing gaps can expose plaintext secrets to the analyzer, while concurrent history updates can silently discard analysis runs.

12 open issues
What changed in this PR

Adds an intent-drift skill to the Copilot resource collection for comparing a user's original goal with ongoing plans and execution evidence.

Changes:

  • Adds a Python analyzer, nine evidence providers, and text, Markdown, and JSON reporting.
  • Includes repository context collection with default-on secret scrubbing, configurable settings, and persisted score history.
  • Adds invocation guidance, examples, reference documentation, and a skill catalog entry.
File Description
skills/​intent-drift/​SKILL.md Defines invocation, setup, and reporting instructions.
skills/​intent-drift/​scripts/​weekly_summary.py Produces a weekly maintainer activity digest.
skills/​intent-drift/​scripts/​collect_context.py Collects repository context and scrubs secret-like content.
skills/​intent-drift/​scripts/​__init__.py Exposes the context collector.
skills/​intent-drift/​requirements.txt Declares Python dependencies.
skills/​intent-drift/​providers/​scope_provider.py Evaluates scope expansion and reduction.
skills/​intent-drift/​providers/​requirement_coverage_provider.py Checks plan coverage of success criteria.
skills/​intent-drift/​providers/​problematic_findings_provider.py Identifies potential drift patterns.
skills/​intent-drift/​providers/​goal_provider.py Scores goal and plan keyword overlap.
skills/​intent-drift/​providers/​file_graph_provider.py Examines edited-file counts, types, and sizes.
skills/​intent-drift/​providers/​execution_provider.py Evaluates commands, edits, and reasoning.
skills/​intent-drift/​providers/​dependency_provider.py Examines dependency-related changes.
skills/​intent-drift/​providers/​constraint_provider.py Checks constraints against plan steps.
skills/​intent-drift/​providers/​base.py Defines the evidence-provider interface.
skills/​intent-drift/​providers/​architecture_provider.py Identifies architectural change patterns.
skills/​intent-drift/​providers/​__init__.py Exports bundled provider classes.
skills/​intent-drift/​metadata.json Describes skill parameters and dependencies.
skills/​intent-drift/​LICENSE Preserves the Apache-2.0 license.
skills/​intent-drift/​history.py Persists score history and formats trends.
skills/​intent-drift/​exporters/​__init__.py Implements report exporters.
skills/​intent-drift/​examples/​basic.py Demonstrates manual-context analysis.
skills/​intent-drift/​examples/​auto_context.py Demonstrates automatic context collection.
skills/​intent-drift/​docs/​providers.md Documents providers and extension guidance.
skills/​intent-drift/​docs/​customizing.md Explains provider and exporter customization.
skills/​intent-drift/​docs/​config.md Documents configuration and overrides.
skills/​intent-drift/​docs/​architecture.md Describes components and scoring flow.
skills/​intent-drift/​docs/​api.md Documents Python and CLI interfaces.
skills/​intent-drift/​config/​defaults.yaml Supplies default analysis and collection settings.
skills/​intent-drift/​config.py Loads, merges, and validates configuration.
skills/​intent-drift/​analyzer.py Connects CLI inputs, engine evaluation, history, and output.
skills/​intent-drift/​__init__.py Exposes engine types and an analyzer factory.
docs/​README.skills.md Registers the skill in the generated catalog.

Review effort: Balanced (auto)

Comment thread skills/intent-drift/analyzer.py Resolved
Comment thread skills/intent-drift/analyzer.py Resolved
Comment thread skills/intent-drift/analyzer.py Resolved
Comment thread skills/intent-drift/analyzer.py Resolved
Comment thread skills/intent-drift/SKILL.md Outdated
Comment on lines +63 to +66
**Setup:** the analyzer needs Python 3.10+ and the engine package. Either run
`pip install -r requirements.txt`, or use the bundled launcher
`node "$SKILL_DIR/bin/intent-drift.js" ...`, which creates a venv and installs
dependencies on first run.
- Transactional history append with an exclusive lock so concurrent runs
  cannot silently drop each other's timeline points
- Quoted secret values are now scrubbed, including JSON/dict literals
- Recursive scrubbing of nested context data
- context_collection.methods switches are honored per source
- analysis.providers.enabled and analysis.weights now configure the engine
- Evidence markers use the 0-100 thresholds already used by the exporters
- --compare output goes to stderr in JSON mode
- Bundled launcher moved under scripts/ (bin/ is git-ignored)
- Examples resolve the bundled skill dir instead of ~/.claude
- file_graph_provider clamps the declining score at zero
- goal_provider no longer emits assumed constraint compliance
- requirement_coverage_provider uses the same filtered keyword set for
  matching and coverage
- git status parsing preserves the leading status columns
Copilot AI auto review requested due to automatic review settings November 4, 2026 05:58
@github-actions github-actions Bot added awaiting-automation and removed ready-for-review Submission passed intake validation and is ready for maintainer review labels Nov 4, 2026
@github-actions github-actions Bot added requires-submitter-fixes Submission has quality-gate findings that submitter must fix before maintainer review and removed awaiting-automation labels Nov 4, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Unresolved setup vulnerabilities can delete unrelated user files or execute repository-local code, while incomplete context scrubbing can expose credentials to the analyzer.

8 open issues
6 previously missed issues

In code that hasn't changed since last review

Medium severity Register bundled providers or remove the unused copies

skills/​intent-drift/​analyzer.py:94

[P2] The analyzer never imports or registers the nine bundled providers; it only filters and wraps the external engine's built-ins, as docs/providers.md:50–59 confirms. Fixes to the bundled checks therefore cannot affect normal skill reports, despite SKILL.md describing them as its implementation. Register the intended local providers with compatible scoring semantics, or remove the unused copies and document the external implementation as authoritative.

Medium severity Validate CLI thresholds against the 0–100 range

skills/​intent-drift/​analyzer.py:203

[P2] CLI thresholds bypass the configuration-file range check, so --threshold -1 makes every valid score pass and --threshold 101 makes every valid score fail. Reject values outside the documented 0–100 range before analysis.

Medium severity Render report timelines in text and Markdown exports

skills/​intent-drift/​analyzer.py:375

[P2] Text and Markdown reports use private implementations that never render report.timeline, so they omit the persisted trend promised in docs/api.md:33. Consolidate these paths with the bundled exporters, or add timeline rendering to both active implementations while preserving include_metadata behavior.

Medium severity Apply or remove the unused confidence threshold setting

skills/​intent-drift/​config/​defaults.yaml:4

[P2] confidence_threshold is loaded and documented but never read by the analyzer or passed to the engine, so changing it has no effect on whether a low-confidence assessment is treated as reliable. Apply it in reporting or decision handling, or remove it from the supported configuration.

Medium severity Classify untracked files as added changes

skills/​intent-drift/​scripts/​collect_context.py:394

[P2] New files have porcelain status ?? before staging, so none of these branches adds them to file_changes['added']. Classify untracked entries as added so automatic context records new-file additions during the normal edit-before-staging workflow.

Low severity Remove or document the unsupported maintainer script

skills/​intent-drift/​scripts/​weekly_summary.py:10

[P3] This upstream-maintainer script is not referenced in SKILL.md, contrary to the bundled-asset requirement in .github/copilot-instructions.md:73. Its roadmap milestones, weekly-review workflow, and three-PR author cap are unrelated to the installed analyzer, and the referenced roadmap/workflow are not bundled. Remove the unused asset, or adapt it and document a supported invocation and prerequisites.

10 resolved since last review

Review effort: Balanced (auto)

Comment thread skills/intent-drift/analyzer.py Resolved
Comment thread skills/intent-drift/docs/config.md Resolved
Copilot AI auto review requested due to automatic review settings November 4, 2026 11:23
@github-actions github-actions Bot added awaiting-automation and removed requires-submitter-fixes Submission has quality-gate findings that submitter must fix before maintainer review labels Nov 4, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

Unresolved critical issues allow deletion of unrelated directories, credential exposure through context collection, and execution of repository-controlled Python modules during bootstrap.

7 open issues
14 previously missed issues

In code that hasn't changed since last review

High severity Regenerate the README asset list with the launcher

docs/​README.skills.md:255

The generated asset list omits the bundled scripts/intent-drift.js launcher. eng/yaml-parser.mjs:140–165 includes this file, so the README validation workflow will regenerate a different row and fail its clean-diff check. Regenerate and commit docs/README.skills.md after the bundle is finalized.

High severity Treat constraint mentions as unverified, not compliance

skills/​intent-drift/​providers/​constraint_provider.py:61

When this bundled provider is used, a constraint mention is treated as proof of compliance even if the plan explicitly violates it. For Do not remove authentication and plan step Remove authentication, it reports all constraints satisfied with score 100 and confidence 0.9. Handle prohibitions and negation, or report keyword matches as unverified mentions rather than satisfied constraints.

Medium severity Register bundled providers or remove unused copies

skills/​intent-drift/​analyzer.py:94

None of the bundled providers/ classes is imported or registered here; evaluation uses only the external engine's self-registered providers, as docs/providers.md:50–59 also confirms. Consequently, editing or fixing the bundled implementations has no effect on a normal skill run, despite SKILL.md presenting them as its implementation. Establish one source of truth: register the bundled providers explicitly, or remove the unused copies and document that scoring implementations come from the dependency.

Medium severity Enforce threshold bounds in the CLI

skills/​intent-drift/​analyzer.py:203

The CLI accepts any integer here, bypassing the 0–100 bounds enforced for the same setting in config.py:125–129. For example, --threshold -1 silently disables the alignment gate, while --threshold 101 makes every valid score fail. Reject out-of-range CLI values before running the analysis.

Medium severity Reject another option when a flag value is missing

skills/​intent-drift/​analyzer.py:228

Reject a following option when a flag's value is missing. For example, --original-goal fix --current-plan --auto-context is accepted with the literal plan --auto-context, and automatic context collection remains disabled. Check whether the next token is another recognized option before consuming it as a value.

Medium severity Scope and bound persisted history

skills/​intent-drift/​analyzer.py:285

Runs from every repository and goal append to the same history without a scope identifier, so --compare N can report improvement or decline between unrelated tasks. The entire ever-growing history is also embedded in each JSON report. Scope stored points and comparisons by repository and goal, and bound retained or exported history.

Medium severity Consolidate exporters and preserve timeline rendering

skills/​intent-drift/​analyzer.py:381

The text and Markdown paths bypass the bundled exporters and use private renderers that never read report.timeline. Ordinary reports therefore omit the persisted trend promised in docs/api.md:33, and edits to the bundled human-readable exporters have no effect. Consolidate each format into one implementation, preserving timeline rendering, metadata controls, and support for both dictionary and object breakdown entries.

Medium severity Send errors to stderr and reserve exit code 1 for drift

skills/​intent-drift/​analyzer.py:531

Analysis failures and missing required arguments print non-JSON text to stdout and exit with 1, the documented below-threshold signal. Hooks therefore cannot distinguish invalid or failed runs from detected drift. Send diagnostics to stderr and use exit 2 in this handler and the required-argument branches at analyzer.py:483–496.

Medium severity Pass example inputs through the supported analysis path

skills/​intent-drift/​examples/​auto_context.py:33

This example passes the plan only under text, bypassing the summary/plan keys that analyzer.py:251–265 supplies for the engine. It can therefore score a missing plan rather than the stated JSON-export work. Pass the collected context through parse_arguments() and analyze() so the example follows the supported input path.

Medium severity Avoid masking ordinary file paths as base64 secrets

skills/​intent-drift/​scripts/​collect_context.py:79

The base64 heuristic also masks ordinary long paths: src/main/java/com/mycompany/myapp/controllers/UserController.java becomes ***REDACTED***.java. Because default sanitization applies to edited_files, file_changes, and diffs, it removes the directory and filename evidence needed for file and architecture analysis. Distinguish path fields and diff headers from secret-bearing content while retaining redaction for actual base64 credentials.

Medium severity Exclude clean tracked files from the mtime scan

skills/​intent-drift/​scripts/​collect_context.py:295

[P2] Do not classify clean tracked files as edited solely from their mtime. A fresh clone or checkout gives tracked files recent timestamps, so the default 24-hour lookback can add the entire clean checkout to edited_files despite an empty git status. This produces false modification counts for the scope/file analysis. Tracked working-tree changes are already collected from git status; restrict this additional mtime scan to untracked files, or use actual Git change history for committed edits.

Medium severity Classify untracked files and normalize rename destinations

skills/​intent-drift/​scripts/​collect_context.py:399

Untracked files have porcelain status ??, so they never appear in file_changes['added'] until staged. Rename records also keep the literal old -> new string instead of the destination filename. Classify untracked files as additions and normalize rename destinations as get_edited_files() already does.

Medium severity Use a CommonJS extension for the launcher

skills/​intent-drift/​scripts/​intent-drift.js:17

[P2] Give the CommonJS launcher an explicit module extension. When this skill is installed inside a project whose package.json declares "type": "module", Node treats this .js file as ESM and fails at the first require before provisioning Python. The bundled folder has no package-scope override. Rename the launcher to .cjs and update its SKILL.md references, or convert it to an .mjs implementation.

Medium severity Probe python.exe as a Windows fallback

skills/​intent-drift/​scripts/​intent-drift.js:52

On Windows installations that expose Python as python.exe but provide no working python3 executable, this candidate list never probes the installed interpreter. The launcher then reports that Python is missing despite its explicit Windows venv support. Add python as a final fallback; the existing version check still rejects interpreters older than 3.10.

1 resolved since last review

Review effort: Max (auto)

@shauryagangrade

Copy link
Copy Markdown
Contributor Author

@aaronpowell some checks have been running for 2 days, and haven't completed. Please Investigate.

Fix Authorization scrubbing for unquoted and curl headers, preserve history
entries outside the current repo/goal scope, keep bundled providers in place
of engine defaults with correct evidence scaling, and apply the configured
confidence threshold. Also remove the unused weekly summary script and refresh
the generated skill index.

🤖 Generated with Codebuff
Co-Authored-By: Codebuff <noreply@codebuff.com>
Copilot AI auto review requested due to automatic review settings November 7, 2026 11:00
@github-actions github-actions Bot added requires-submitter-fixes Submission has quality-gate findings that submitter must fix before maintainer review and removed awaiting-automation labels Nov 7, 2026
@shauryagangrade

shauryagangrade commented Nov 7, 2026 •

Copy link
Copy Markdown
Contributor Author

@aaronpowell thanks for the review — I've pushed a new commit (5ae3c31) addressing the remaining feedback: Authorization scrubbing, history scoping, provider replacement/scaling, confidence threshold handling, the .cjs launcher, and removal of the unused weekly summary script. Could you take another look when you have a moment?

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Unresolved critical flaws can execute repository-controlled code during context collection or analyzer startup and expose multiline credentials despite default secret scrubbing.

19 open issues
6 resolved since last review

Review effort: Max (auto)

Comment on lines +45 to +48
_SECRET_ASSIGNMENT = re.compile(
r"(?i)(\b[a-z0-9_.-]*(?:secret|token|password|passwd|api[_-]?key|access[_-]?key|"
r"private[_-]?key|client[_-]?secret|credential|auth[_-]?key)[a-z0-9_.-]*[\"']?\s*[:=]\s*)"
r"(?:\"((?:\\.|[^\"\\])*)\"|'((?:\\.|[^'\\])*)'|([^&\s\"'#]+))"
"""Get git diff for uncommitted changes."""
try:
result = subprocess.run(
["git", "diff", "HEAD"],
}
const install = spawnSync(
py,
["-I", "-m", "pip", "install", "--quiet", "--disable-pip-version-check", "intent-drift", "PyYAML"],
}

const py = ensureVenv(found.py);
const run = spawnSync(py, [ANALYZER, ...process.argv.slice(2)], {
Comment on lines +10 to +14
from intent_alignment.engine import IntentAlignmentEngine
from intent_alignment.models import AlignmentContext, AlignmentReport

import history
from config import effective_config, load_config
Comment on lines +36 to +37
original_keywords = set(original_text.lower().split())
current_keywords = set(current_text.lower().split())
Comment on lines +97 to +98
if not any(word in plan_text for word in criterion_lower.split() if len(word) > 4):
unaddressed += 1
Comment on lines +355 to +365
tracked_res = subprocess.run(
["git", "ls-files", "-z"],
cwd=self.repo_path,
capture_output=True,
text=True,
timeout=10,
)
if tracked_res.returncode == 0:
tracked_names = {
n for n in (tracked_res.stdout + "").split("\0") if n
}
Comment on lines +119 to +124
if (create.status !== 0) {
process.stderr.write(
"intent-drift: failed to create virtualenv. Install Python 3.10+ " +
"or set INTENT_DRIFT_PYTHON to a Python 3.10+ binary.\n"
);
process.exit(1);
Comment thread docs/README.skills.md
| [import-infrastructure-as-code](../skills/import-infrastructure-as-code/SKILL.md)<br />`gh skills install github/awesome-copilot import-infrastructure-as-code` | Import existing Azure resources into Terraform using Azure CLI discovery and Azure Verified Modules (AVM). Use when asked to reverse-engineer live Azure infrastructure, generate Infrastructure as Code from existing subscriptions/resource groups/resource IDs, map dependencies, derive exact import addresses from downloaded module source, prevent configuration drift, and produce AVM-based Terraform files ready for validation and planning across any Azure resource type. | None |
| [incident-postmortem](../skills/incident-postmortem/SKILL.md)<br />`gh skills install github/awesome-copilot incident-postmortem` | Use when an outage, production incident, or significant service degradation has occurred and the team needs to write a structured blameless post-mortem. Triggers on phrases like "write a post-mortem", "incident review", "what went wrong", "outage report", "root cause analysis", or "RCA". Covers timeline reconstruction, contributing factor analysis, impact quantification, and action item generation with owners. | None |
| [integrate-context-matic](../skills/integrate-context-matic/SKILL.md)<br />`gh skills install github/awesome-copilot integrate-context-matic` | Discovers and integrates third-party APIs using the context-matic MCP server. Uses `fetch_api` to find available API SDKs, `ask` for integration guidance, `model_search` and `endpoint_search` for SDK details. Use when the user asks to integrate a third-party API, add an API client, implement features with an external API, or work with any third-party API or SDK. | None |
| [intent-drift](../skills/intent-drift/SKILL.md)<br />`gh skills install github/awesome-copilot intent-drift` | Detects intent drift in AI-assisted development by comparing the original goal against the current plan and execution context. Run /intent-drift to evaluate whether ongoing work has drifted from what was asked. Triggers on "check intent drift", "are we still on track", "is this aligned with the goal", "did the plan drift", "intent alignment", "scope creep check", "am I off track". | `LICENSE`<br />`__init__.py`<br />`__pycache__/analyzer.cpython-314.pyc`<br />`__pycache__/config.cpython-314.pyc`<br />`__pycache__/history.cpython-314.pyc`<br />`analyzer.py`<br />`config.py`<br />`config/defaults.yaml`<br />`docs/api.md`<br />`docs/architecture.md`<br />`docs/config.md`<br />`docs/customizing.md`<br />`docs/providers.md`<br />`examples/__pycache__/auto_context.cpython-314.pyc`<br />`examples/__pycache__/basic.cpython-314.pyc`<br />`examples/auto_context.py`<br />`examples/basic.py`<br />`exporters/__init__.py`<br />`exporters/__pycache__/__init__.cpython-314.pyc`<br />`history.py`<br />`metadata.json`<br />`providers/__init__.py`<br />`providers/__pycache__/__init__.cpython-314.pyc`<br />`providers/__pycache__/architecture_provider.cpython-314.pyc`<br />`providers/__pycache__/base.cpython-314.pyc`<br />`providers/__pycache__/constraint_provider.cpython-314.pyc`<br />`providers/__pycache__/dependency_provider.cpython-314.pyc`<br />`providers/__pycache__/execution_provider.cpython-314.pyc`<br />`providers/__pycache__/file_graph_provider.cpython-314.pyc`<br />`providers/__pycache__/goal_provider.cpython-314.pyc`<br />`providers/__pycache__/problematic_findings_provider.cpython-314.pyc`<br />`providers/__pycache__/requirement_coverage_provider.cpython-314.pyc`<br />`providers/__pycache__/scope_provider.cpython-314.pyc`<br />`providers/architecture_provider.py`<br />`providers/base.py`<br />`providers/constraint_provider.py`<br />`providers/dependency_provider.py`<br />`providers/execution_provider.py`<br />`providers/file_graph_provider.py`<br />`providers/goal_provider.py`<br />`providers/problematic_findings_provider.py`<br />`providers/requirement_coverage_provider.py`<br />`providers/scope_provider.py`<br />`requirements.txt`<br />`scripts/__init__.py`<br />`scripts/__pycache__/collect_context.cpython-314.pyc`<br />`scripts/collect_context.py`<br />`scripts/intent-drift.cjs` |
@aaronpowell aaronpowell closed this Nov 8, 2026
@aaronpowell

Copy link
Copy Markdown
Contributor

Thanks for the time you put into this and for working through the automated review rounds. We're not able to take this one: we don't see what it adds beyond what Copilot can already do when asked whether work is still on track, and the part that is new, the scoring, doesn't look like a dependable signal.

  • Guidance: the instructions in SKILL.md ("infer and state your assumptions" L31-32, "suggest pausing to confirm intent before continuing" L74-75, "Below-threshold results are a call to confirm, not a reason to abandon good work" L98) describe things an agent already does, and it already has the request, its own plan and the repo state (git diff, git log) to compare directly.
  • Scoring: providers/goal_provider.py L36-57 is word-set overlap (set(text.lower().split()), intersection over union, times 100), which SKILL.md L86 calls "Semantic overlap", so a plan that restates the goal in different words scores as low overlap. providers/execution_provider.py L93-97 emits a constant 80.0 for any non-empty list of edited files, and providers/architecture_provider.py never reads the goal (editing main.py or app.py scores 85 as "significant architectural work"). A percentage built on that is less likely to be reliable than the model reading the request, the plan and the diff, and it adds false precision to what is a judgement call.
  • Structure: the engine is the separate intent-drift package on PyPI, and the skill also bundles its own implementations of the same nine providers that override the package's (analyzer.py L391-416), so there are two parallel sets to keep consistent.
  • Validation: the PR description lists skill:validate, build and a smoke test of the analyzer run directly. There's no GitHub Copilot session showing the skill being invoked on real work and changing the outcome, and the module docstrings are written for Claude Code (__init__.py L1, analyzer.py L2).
  • Security: the security findings in the latest automated review still apply on the current head. scripts/collect_context.py masks secrets line by line, so multi-line values (YAML | blocks, PEM keys) aren't reliably covered; git diff HEAD (L234) runs without --no-ext-diff or --no-textconv; and scripts/intent-drift.cjs (L128) pip-installs intent-drift and PyYAML unpinned into a shared ~/.intent-drift-venv. That's a lot of surface for a heuristic score.

If you have a real GitHub Copilot session where an agent drifted from the request and a short, specific instruction fixed it, a much smaller submission built around that would be a different conversation, and we'd be happy to take a look.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

merge-risk:high needs-review:HIGH Contributor reputation check flagged HIGH risk new-submission PR adds at least one new contribution requires-submitter-fixes Submission has quality-gate findings that submitter must fix before maintainer review skills PR touches skills

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants