chore: import upstream snapshot with attribution
This commit is contained in:
@@ -0,0 +1,38 @@
|
||||
---
|
||||
name: Bug report
|
||||
about: Create a report to help us improve
|
||||
title: ''
|
||||
labels: ''
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
**Describe the bug**
|
||||
A clear and concise description of what the bug is.
|
||||
|
||||
**To Reproduce**
|
||||
Steps to reproduce the behavior:
|
||||
1. Go to '...'
|
||||
2. Click on '....'
|
||||
3. Scroll down to '....'
|
||||
4. See error
|
||||
|
||||
**Expected behavior**
|
||||
A clear and concise description of what you expected to happen.
|
||||
|
||||
**Screenshots**
|
||||
If applicable, add screenshots to help explain your problem.
|
||||
|
||||
**Desktop (please complete the following information):**
|
||||
- OS: [e.g. iOS]
|
||||
- Browser [e.g. chrome, safari]
|
||||
- Version [e.g. 22]
|
||||
|
||||
**Smartphone (please complete the following information):**
|
||||
- Device: [e.g. iPhone6]
|
||||
- OS: [e.g. iOS8.1]
|
||||
- Browser [e.g. stock browser, safari]
|
||||
- Version [e.g. 22]
|
||||
|
||||
**Additional context**
|
||||
Add any other context about the problem here.
|
||||
@@ -0,0 +1,73 @@
|
||||
---
|
||||
description: 'Expert .NET and documentation transformation agent that migrates Polyglot Jupyter notebooks into clean Markdown and companion .NET sample code.'
|
||||
tools: ['runCommands', 'edit/createFile', 'edit/editFiles', 'search', 'usages', 'problems', 'fetch']
|
||||
name: '.NET-Notebook-Migration-Agent'
|
||||
model: Auto (copilot)
|
||||
---
|
||||
|
||||
You are a meticulous .NET educational content migration specialist.
|
||||
|
||||
You transform a Jupyter notebook (${input:file}) into:
|
||||
1. A single Markdown file (same base name, .md) with all markdown plus rendered code blocks.
|
||||
2. (Optional) A scaffolded .NET Single File App (refer to https://devblogs.microsoft.com/dotnet/announcing-dotnet-run-app/ for info on that format) if C# code is detected.
|
||||
|
||||
Core Objectives:
|
||||
|
||||
- Preserve instructional flow.
|
||||
- Normalize headings (first markdown cell becomes H1 if not already).
|
||||
- Detect language for code fences (python, csharp, bash, json, yaml, etc.).
|
||||
- Remove execution artifacts (outputs, execution_count).
|
||||
- Collapse multi-line sources into continuous blocks.
|
||||
- Trim trailing blank lines.
|
||||
|
||||
Language Detection Heuristics (in order):
|
||||
|
||||
- If cell has "using " statements, namespaces, or csproj hint => csharp
|
||||
- If it has "def ", "import ", or "# %%", => python
|
||||
- If it starts with "#!/bin/bash" or typical shell commands (echo, ls, cat) => bash
|
||||
- If braces with "class" and "static void" => csharp
|
||||
Fallback: plaintext
|
||||
|
||||
Behavior:
|
||||
|
||||
- Read notebook JSON.
|
||||
- Iterate cells in order.
|
||||
- For markdown cells: write their source verbatim.
|
||||
- For code cells: wrap in ```<language> fences.
|
||||
- Never include outputs, metadata, or empty code cells.
|
||||
- Ensure a blank line between top-level sections.
|
||||
- Avoid more than one consecutive blank line.
|
||||
|
||||
If C# code detected:
|
||||
|
||||
- Create a file alongside named <name>.cs aggregating all C# code cells in original order.
|
||||
- Use the .NET Single File App format.
|
||||
- Import NuGet packages using `#:package PackageName@Version` syntax at the top.
|
||||
- Add the shebang `#!/usr/bin/dotnet run` at the top of the .cs file and make it executable (if on Linux/Unix/MacOS).
|
||||
- Update the markdown to reference this .cs file for code samples, rather than the original code blocks from the notebook.
|
||||
|
||||
File Naming:
|
||||
|
||||
- Input: <name>.ipynb
|
||||
- Output Markdown: <name>.md
|
||||
- Output .NET sample (if any): <name>.cs
|
||||
|
||||
Constraints:
|
||||
|
||||
- Do not invent code.
|
||||
- Do not execute code.
|
||||
- Keep Markdown pure (no notebook JSON fragments).
|
||||
- Preserve relative order strictly.
|
||||
|
||||
Validation Steps (internal):
|
||||
|
||||
1. Parse JSON safely.
|
||||
2. Count cells; abort if none.
|
||||
3. Track languages encountered.
|
||||
4. Confirm at least one markdown or code cell; else emit an error note.
|
||||
|
||||
Output:
|
||||
|
||||
Primary artifact is the Markdown file replacing the notebook for documentation purposes.
|
||||
|
||||
Now perform the migration.
|
||||
@@ -0,0 +1,21 @@
|
||||
---
|
||||
description: 'Cherrypick a file deleted from the given commit between branches using Git.'
|
||||
mode: 'agent'
|
||||
---
|
||||
|
||||
# Cherry-picking a File Between Branches Using Git
|
||||
|
||||
Your goal is to cherry-pick a specific file deleted from a given commit between branches in a Git repository. Use the Git command line interface to accomplish this task.
|
||||
|
||||
## Inputs
|
||||
|
||||
- **Commit Hash**: $COMMIT - The hash of the commit from which to cherry-pick the file.
|
||||
- **File Path**: $FILE_PATH - The path of the file to be cherry-picked.
|
||||
|
||||
If you don't have the commit hash or file path, please ask the user for these details.
|
||||
|
||||
## Instructions
|
||||
|
||||
1. **Identify the Commit**: Determine the commit hash from which you want to cherry-pick the file.
|
||||
2. **Cherry-pick the File**: Use the `git checkout` command to cherry-pick the specific file from the identified commit. If the file doesn't exist in the given commit, find the closest commit where the file exists.
|
||||
3. **Commit the Changes**: Ask the user to stage and commit the changes to finalize the cherry-pick.
|
||||
@@ -0,0 +1,34 @@
|
||||
name: Welcome to the AI Agents for Beginners Course
|
||||
on:
|
||||
# Trigger the workflow on new issue
|
||||
issues:
|
||||
types: [opened]
|
||||
permissions:
|
||||
contents: read
|
||||
issues: write
|
||||
jobs:
|
||||
asses-issue:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Add Label and thanks comment to Issue
|
||||
uses: actions/github-script@v8
|
||||
with:
|
||||
script: |
|
||||
const issueAuthor = context.payload.sender.login
|
||||
github.rest.issues.addLabels({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
labels: ['needs-review']
|
||||
})
|
||||
github.rest.issues.createComment({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
body: `👋 Thanks for contributing @${ issueAuthor }! We will review the issue and get back to you soon.`
|
||||
})
|
||||
- name: Auto-assign issue
|
||||
uses: pozil/auto-assign-issue@v2
|
||||
with:
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
assignees: koreyspace
|
||||
@@ -0,0 +1,34 @@
|
||||
name: Welcome to the AI Agents for Beginners
|
||||
on:
|
||||
# Trigger the workflow on pull request
|
||||
pull_request_target:
|
||||
types: [opened]
|
||||
permissions:
|
||||
contents: read
|
||||
pull-requests: write
|
||||
jobs:
|
||||
asses-pull-request:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Add Label and thanks comment to Pull request
|
||||
uses: actions/github-script@v8
|
||||
with:
|
||||
script: |
|
||||
const issueAuthor = context.payload.sender.login
|
||||
github.rest.issues.addLabels({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
labels: ['needs-review']
|
||||
})
|
||||
github.rest.issues.createComment({
|
||||
issue_number: context.issue.number,
|
||||
owner: context.repo.owner,
|
||||
repo: context.repo.repo,
|
||||
body: `👋 Thanks for contributing @${ issueAuthor }! We will review the pull request and get back to you soon.`
|
||||
})
|
||||
- name: Auto-assign issue
|
||||
uses: pozil/auto-assign-issue@v2
|
||||
with:
|
||||
repo-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
assignees: koreyspace
|
||||
Reference in New Issue
Block a user