Skip to content

PoC of repository ai bootstrap#7585

Open
JanKrivanek wants to merge 4 commits intomainfrom
dev/jankrivanek/ai-bootstrap
Open

PoC of repository ai bootstrap#7585
JanKrivanek wants to merge 4 commits intomainfrom
dev/jankrivanek/ai-bootstrap

Conversation

@JanKrivanek
Copy link
Member

Motivation

Experimentation with improving the repository ai readiness through generated ai bootstrap (https://github.com/kotlarmilos/ai-dotnet-bootstrap)

==============================================

We are excited to review your PR.

So we can do the best job, please check:

  • There's a descriptive title that will make sense to other developers some time from now.
  • There's associated issues. All PR's should have issue(s) associated - unless a trivial self-evident change such as fixing a typo. You can use the format Fixes #nnnn in your description to cause GitHub to automatically close the issue(s) when your PR is merged.
  • Your change description explains what the change does, why you chose your approach, and anything else that reviewers should know.
  • You have included any necessary tests in the same PR.

@kotlarmilos
Copy link
Member

@copilot Remove the skills for now. Merge README-AI.md and copilot-instructios.md, refine it with https://github.com/anthropics/skills/blob/main/skills/skill-creator/SKILL.md. For issues triage use https://github.github.com/gh-aw/ instead.

@JanKrivanek JanKrivanek marked this pull request as ready for review March 11, 2026 11:44
Copilot AI review requested due to automatic review settings March 11, 2026 11:44
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Adds “AI-native” repository scaffolding to help GitHub Copilot/agents build, test, and contribute to ML.NET, plus new GitHub Actions workflows for issue similarity detection and comment tone/heat monitoring.

Changes:

  • Added Copilot/AI instruction docs (global + scoped) and an onboarding README.
  • Introduced agent/skill markdown definitions to standardize PR/test workflows for AI agents.
  • Added two GitHub Actions workflows: AI similar-issue detection and an “inclusive heat sensor” for comments.

Reviewed changes

Copilot reviewed 22 out of 22 changed files in this pull request and generated 8 comments.

Show a summary per file
File Description
README-AI.md Documents the added AI-native infrastructure and how to use it.
.github/workflows/inclusive-heat-sensor.yml Adds a workflow to detect heated/offensive language in issues/PR comments.
.github/workflows/find-similar-issues.yml Adds an AI-assisted workflow to comment with similar issues on new issue creation.
.github/skills/verify-tests-fail/SKILL.md Adds a skill definition to verify tests fail without a fix and pass with it.
.github/skills/try-fix/SKILL.md Adds a single-attempt “try fix + test + revert” skill definition.
.github/skills/run-tests/SKILL.md Adds guidance/commands for running builds and tests with filtering.
.github/skills/pr-finalize/SKILL.md Adds a PR finalization/review checklist skill definition.
.github/skills/pr-build-status/SKILL.md Adds guidance for reading CI status from Azure Pipelines and GitHub Actions.
.github/skills/learn-from-pr/SKILL.md Adds a skill definition for extracting lessons from completed PRs.
.github/skills/issue-triage/SKILL.md Adds a skill definition for triaging issues via gh.
.github/skills/find-reviewable-pr/SKILL.md Adds a skill definition to find/prioritize PRs for review.
.github/skills/ai-summary-comment/SKILL.md Adds a skill definition for posting/updating a unified PR progress comment.
.github/prompts/release-notes.prompt.md Adds a prompt template for generating categorized release notes.
.github/instructions/tokenizers.instructions.md Adds scoped Copilot guidance for the Tokenizers area.
.github/instructions/tests.instructions.md Adds scoped Copilot guidance for test conventions and commands.
.github/instructions/genai.instructions.md Adds scoped Copilot guidance for GenAI/TorchSharp projects.
.github/copilot-instructions.md Adds repo-wide Copilot guidance: build/test commands, structure, conventions.
.github/agents/write-tests-agent.md Adds an agent workflow for locating/writing tests per repo conventions.
.github/agents/pr/SHARED-RULES.md Adds shared rules/config for the PR agent’s multi-phase workflow.
.github/agents/pr/post-gate.md Adds post-gate phases for multi-model fix exploration and reporting.
.github/agents/pr.md Adds pre-flight + gate phases for the PR agent workflow.
.github/agents/learn-from-pr.md Adds an agent workflow to apply improvements based on PR retrospectives.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

Comment on lines +55 to +63
const words=extractWords(`${title}\n${body}`);
const candidates=issues.map(i=>({issue:i,score:jaccard(words,extractWords(`${i.title}\n${i.body||''}`))}))
.filter(c=>c.score>0.1).sort((a,b)=>b.score-a.score).slice(0,30);
const results=[];
for(const{issue}of candidates){
try{
const r=await fetch(`${endpoint}/chat/completions`,{method:"POST",headers:{"Content-Type":"application/json","Authorization":`Bearer ${token}`},
body:JSON.stringify({model,temperature:0.3,max_tokens:150,messages:[
Copy link

Copilot AI Mar 11, 2026

Choose a reason for hiding this comment

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

This workflow can make up to ~30 model inference calls per newly opened issue (one per candidate in the candidates list). On a high-traffic repo this can become slow/expensive and may hit rate limits. Consider reducing the candidate cap, adding an opt-in label/command gate, and/or early-exiting after collecting enough high-confidence matches.

Copilot uses AI. Check for mistakes.
@kotlarmilos
Copy link
Member

@copilot Remove the skills for now. Merge README-AI.md and copilot-instructios.md, refine it with https://github.com/anthropics/skills/blob/main/skills/skill-creator/SKILL.md. For issues triage use https://github.github.com/gh-aw/ instead.

JanKrivanek and others added 3 commits March 12, 2026 08:46
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…7592)

This workflow automates the process of analyzing newly opened issues, applying appropriate labels, and providing comments based on the issue content. It includes definitions for various labels, instructions for triaging, and hints for relevant project areas.
@codecov
Copy link

codecov bot commented Mar 13, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 69.54%. Comparing base (f79b8fa) to head (8232a34).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #7585      +/-   ##
==========================================
- Coverage   69.54%   69.54%   -0.01%     
==========================================
  Files        1484     1484              
  Lines      273209   273209              
  Branches    27919    27919              
==========================================
- Hits       190007   190003       -4     
- Misses      75837    75842       +5     
+ Partials     7365     7364       -1     
Flag Coverage Δ
Debug 69.54% <ø> (-0.01%) ⬇️
production 63.81% <ø> (-0.01%) ⬇️
test 89.59% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.
see 5 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants