<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Nunna Satya Surya Venkat on Medium]]></title>
        <description><![CDATA[Stories by Nunna Satya Surya Venkat on Medium]]></description>
        <link>https://medium.com/@satyasuryavenkat?source=rss-2fe4b0c3a527------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*DWnZ-7CKKFW9zYQh</url>
            <title>Stories by Nunna Satya Surya Venkat on Medium</title>
            <link>https://medium.com/@satyasuryavenkat?source=rss-2fe4b0c3a527------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 01 Dec 2026 16:23:51 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@satyasuryavenkat/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[AI Session 2 : GitHub Copilot Beyond Prompts: Mastering Custom Instructions and Agent Skills]]></title>
            <link>https://medium.com/@satyasuryavenkat/ai-session-2-github-copilot-beyond-prompts-mastering-custom-instructions-and-agent-skills-58a6a29db544?source=rss-2fe4b0c3a527------2</link>
            <guid isPermaLink="false">https://medium.com/p/58a6a29db544</guid>
            <category><![CDATA[github]]></category>
            <category><![CDATA[github-copilot]]></category>
            <category><![CDATA[instruction]]></category>
            <category><![CDATA[agent-skills]]></category>
            <category><![CDATA[ai-agent]]></category>
            <dc:creator><![CDATA[Nunna Satya Surya Venkat]]></dc:creator>
            <pubDate>Thu, 26 Nov 2026 08:28:31 GMT</pubDate>
            <atom:updated>2026-11-26T08:28:31.948Z</atom:updated>
            <content:encoded><![CDATA[<p><em>AI for Software Developers — Part 2</em></p><p>What if you could teach GitHub Copilot your project’s coding standards, architecture and development workflows once, instead of explaining them every time you write a prompt?</p><p>Most developers use GitHub Copilot to generate code, fix bugs, write unit tests and understand existing applications. However, generating code is only one part of its capabilities.</p><p>The real opportunity lies in customizing how Copilot works within your development environment.</p><p>In the previous session, we explored contextualizing GitHub Copilot. In this article, we will take it further by understanding two powerful customization features:</p><ul><li>Custom Instructions</li><li>Agent Skills</li></ul><p>We will also explore how to implement them in a real-world Java Spring Boot project.</p><h3>1. The problem with traditional prompting</h3><p>Imagine you are working on an enterprise Spring Boot application.</p><p>Your team follows several development standards:</p><ul><li>Controller-Service-Repository architecture</li><li>Constructor-based dependency injection</li><li>DTOs for API requests and responses</li><li>Centralized exception handling</li><li>JUnit and Mockito for testing</li><li>Secure coding and logging practices</li></ul><p>Every time you ask Copilot to generate a REST API, you might find yourself repeating these requirements.</p><p>For example:</p><blockquote><em>Create an Employee REST API using Spring Boot. Follow layered architecture, use DTOs, constructor injection, exception handling, validation and write unit tests.</em></blockquote><p>Repeating these instructions across every task is unnecessary.</p><p>What if we could permanently define these standards within the project?</p><p>That is where custom instructions come into play.</p><h3>2. What are custom instructions?</h3><p>Custom instructions are reusable guidelines that help GitHub Copilot understand how it should work within a project.</p><p>They provide information about:</p><ul><li>Technology stack</li><li>Application architecture</li><li>Coding standards</li><li>Naming conventions</li><li>Testing requirements</li><li>Security guidelines</li><li>Development practices</li></ul><p>Instead of repeating these requirements in every prompt, we can maintain them in dedicated Markdown files.</p><p>The developer focuses on what needs to be implemented, while the instructions provide guidance on how the implementation should follow project standards.</p><h3>Without custom instructions</h3><p>Developer prompt → Copilot → Generated code</p><h3>With custom instructions</h3><p>Developer prompt + Project context + Custom instructions → Copilot → Project-aligned code</p><p>Custom instructions improve consistency, but developers must still review generated code and validate its behavior.</p><h3>3. Repository-wide instructions</h3><p>GitHub Copilot supports repository-wide instructions using the following file:</p><p>.github/copilot-instructions.md</p><p>Create this file inside your project and define the standards your team follows.</p><p>For example:</p><pre># Project Instructions</pre><pre>## Architecture<br>- Follow Controller-Service-Repository architecture.<br>- Use DTOs for API requests and responses.<br>- Use constructor-based dependency injection.<br>- Follow the existing package structure.</pre><pre>## Coding Standards<br>- Follow SOLID principles.<br>- Use meaningful variable and method names.<br>- Avoid unnecessary code duplication.<br>- Use SLF4J for logging.</pre><pre>## Security<br>- Never hardcode credentials.<br>- Validate all incoming requests.<br>- Never log sensitive information.</pre><pre>## Testing<br>- Use JUnit 5 and Mockito.<br>- Cover positive and negative scenarios.<br>- Run relevant tests after implementation.</pre><p>Now, instead of providing a lengthy prompt, you can simply ask:</p><blockquote><em>Create an Employee REST API.</em></blockquote><p>For supported Copilot agent interactions, the repository instructions provide additional guidance automatically.</p><p>Another advantage is that these files can be committed to Git and shared across the development team.</p><h3>4. Path-specific instructions</h3><p>Not every file in a project requires the same instructions.</p><p>A full-stack application may contain Java, React, SQL and configuration files. Each of these technologies may have different standards.</p><p>Path-specific instructions allow us to provide targeted guidance.</p><p>Create the following file:</p><p>.github/instructions/java.instructions.md</p><pre>---<br>applyTo: &quot;**/*.java&quot;<br>---</pre><pre># Java Coding Standards</pre><pre>- Follow Java naming conventions.<br>- Use constructor injection.<br>- Use meaningful method names.<br>- Follow the existing Java version.<br>- Avoid returning null collections.</pre><p>The applyTo property specifies the file patterns to which the instructions apply.</p><p>Similarly, we can create:</p><ul><li>react.instructions.md</li><li>sql.instructions.md</li><li>tests.instructions.md</li><li>security.instructions.md</li></ul><p>For example, a testing-specific instruction file can encourage Arrange-Act-Assert patterns and meaningful assertions.</p><p>This makes customization more modular and easier to maintain.</p><h3>5. What are Agent Skills?</h3><p>Instructions provide standing rules. But what if we want Copilot to follow a complete development procedure?</p><p>For example, developing a REST API may involve:</p><ol><li>Understanding requirements.</li><li>Reviewing existing architecture.</li><li>Creating request and response DTOs.</li><li>Implementing repository and service logic.</li><li>Creating the REST controller.</li><li>Adding validation.</li><li>Handling exceptions.</li><li>Writing unit tests.</li><li>Executing tests and reporting results.</li></ol><p>This is more than a coding standard. It is a reusable workflow.</p><p>Agent Skills allow us to package such workflows so that compatible AI agents can discover and use them for relevant tasks.</p><p>A skill can contain:</p><ul><li>Instructions</li><li>Step-by-step procedures</li><li>Scripts</li><li>Templates</li><li>Reference documents</li><li>Supporting resources</li></ul><p>Agent Skills use an open standard that is supported by multiple AI coding environments.</p><h3>6. How Agent Skills work</h3><p>When a developer requests a task, the agent can examine available skill metadata to identify relevant capabilities.</p><p>For example, if the developer requests a new REST API, a skill named rest-api-development may be relevant.</p><p>The agent can then load its detailed instructions and access supporting resources when needed.</p><p>This approach is known as progressive disclosure.</p><p>Instead of loading every complete skill into every conversation, the agent can retrieve the detailed workflow when it becomes relevant.</p><p>The process can be understood in five stages:</p><p>Developer request → Skill discovery → Relevant skill selection → Workflow execution → Validation</p><p>Automatic selection is not guaranteed. In supported environments, developers can also explicitly request that a particular skill be used.</p><h3>7. Creating your first Agent Skill</h3><p>Inside the project, create the following file:</p><p>.github/skills/rest-api-development/SKILL.md</p><p>Add the following content:</p><pre>---<br>name: rest-api-development<br>description: Develop Spring Boot REST APIs with DTOs,<br>  validation, exception handling and unit tests.<br>---</pre><pre># REST API Development</pre><pre>## Workflow</pre><pre>1. Inspect the existing project architecture.<br>2. Understand the business requirements.<br>3. Reuse existing entities and repositories.<br>4. Create request and response DTOs.<br>5. Implement service-layer business logic.<br>6. Create the REST controller.<br>7. Add input validation.<br>8. Reuse centralized exception handling.<br>9. Write unit tests.<br>10. Run relevant tests and summarize the results.</pre><pre>## Guardrails</pre><pre>- Preserve existing authorization rules.<br>- Avoid unrelated code modifications.<br>- Never expose sensitive information.<br>- Report any tests that could not be executed.</pre><p>The name identifies the skill, while the description helps the agent determine when the workflow is relevant.</p><p>The remaining content explains the procedure and expected behavior.</p><p>Now we can ask Copilot:</p><blockquote><em>Use the rest-api-development skill to create an Employee API.</em></blockquote><p>Rather than defining the entire workflow in the prompt, we can reuse the skill.</p><h3>8. Recommended project structure</h3><p>A project using custom instructions and skills could have the following structure:</p><pre>employee-management/<br>├── .github/<br>│   ├── copilot-instructions.md<br>│   ├── instructions/<br>│   │   ├── java.instructions.md<br>│   │   ├── react.instructions.md<br>│   │   └── tests.instructions.md<br>│   └── skills/<br>│       ├── rest-api-development/<br>│       │   └── SKILL.md<br>│       ├── unit-test-generation/<br>│       │   └── SKILL.md<br>│       └── code-review/<br>│           └── SKILL.md<br>├── src/<br>├── pom.xml<br>└── README.md</pre><p>This approach allows the team to maintain AI customization files alongside the application source code.</p><p>These files can be reviewed, improved and version-controlled like other development artifacts.</p><h3>9. Instructions vs Agent Skills</h3><p>The easiest way to understand the difference is to think about a new employee joining an organization.</p><p>Custom instructions are similar to the company’s employee handbook. They explain the rules, standards and expectations.</p><p>Agent Skills are similar to standard operating procedures. They explain how to perform specific tasks.</p><p>InstructionsAgent SkillsDefine project rulesDefine reusable workflowsApply within a configured scopeLoaded when relevantProvide coding standardsProvide task proceduresMarkdown instruction filesSKILL.md and optional resourcesExample: Always use DTOsExample: Develop and test a REST API</p><p>Both work together to provide a more structured development experience.</p><h3>10. A practical demonstration</h3><p>Let’s consider an Employee Management System built using Java and Spring Boot.</p><p>Perform the following experiment using the same prompt and a clean project baseline.</p><p><strong>Scenario 1: Without customization</strong></p><p>Ask Copilot to create an Employee REST API.</p><p>Observe the generated architecture, validation, exception handling and test coverage.</p><p><strong>Scenario 2: With custom instructions</strong></p><p>Add repository-wide and Java-specific instructions, then repeat the task in a fresh chat using the same baseline.</p><p>Check whether the generated code aligns better with the project’s standards.</p><p><strong>Scenario 3: With instructions and skills</strong></p><p>Add the REST API development skill and repeat the task.</p><p>Observe whether Copilot follows the intended development workflow, including implementation and validation.</p><p>Compare the Git diffs and actual test results across the three scenarios.</p><p>The objective is not simply to generate more code. It is to generate code that fits the project with less repetitive prompting and rework.</p><h3>11. Real-world use cases for Agent Skills</h3><p>Agent Skills can be useful across the software development lifecycle.</p><p>Some examples include:</p><ul><li>REST API development</li><li>Unit test generation</li><li>Pull request reviews</li><li>Bug investigation</li><li>Database migration</li><li>Security analysis</li><li>API documentation</li><li>Application modernization</li><li>Release note generation</li><li>Deployment preparation</li></ul><p>A team can gradually create a library of reusable skills based on its existing development processes.</p><h3>12. How everything fits together</h3><p>An effective AI-assisted development workflow can involve several components.</p><p><strong>Context:</strong> Helps Copilot understand the application and relevant files.</p><p><strong>Prompt:</strong> Defines the immediate task.</p><p><strong>Instructions:</strong> Provide the rules and development standards.</p><p><strong>Skills:</strong> Provide reusable task-specific workflows.</p><p><strong>Tools and MCP:</strong> Allow compatible agents to interact with external systems and development tools.</p><p><strong>Agent:</strong> Coordinates the task, uses available capabilities and processes feedback.</p><p>These components serve different purposes, but together they help customize the development experience.</p><h3>13. Best practices</h3><p>When implementing instructions and skills in enterprise applications:</p><ul><li>Keep instructions concise and specific.</li><li>Avoid conflicting or outdated guidelines.</li><li>Separate general standards from task-specific workflows.</li><li>Create focused skills with meaningful descriptions.</li><li>Review third-party skills and scripts before using them.</li><li>Never include passwords, API keys or confidential information.</li><li>Commit customization files to version control.</li><li>Validate generated code through automated tests and code reviews.</li></ul><p>Remember that AI instructions are not enforcement mechanisms.</p><p>Critical security requirements and quality standards should be enforced through CI/CD pipelines, automated tests, static analysis and access controls.</p><p>Feature availability also varies across IDEs, Copilot clients and organizational policies.</p><h3>Conclusion</h3><p>GitHub Copilot becomes more useful when we move beyond one-time prompts and start giving it reusable project knowledge.</p><p>Custom instructions establish development standards.</p><p>Agent Skills establish repeatable development workflows.</p><p>Together, they can help teams reduce repetitive prompting, improve consistency and make AI-assisted development better aligned with existing engineering practices.</p><p>The goal is not just to write code faster.</p><p><strong>The goal is to make AI understand how your team develops software.</strong></p><p>Start with one instruction file and one skill. Measure their effectiveness, improve them and gradually build a reusable AI-assisted development environment.</p><h3>Official references</h3><ul><li>VS Code Custom Instructions: <a href="https://code.visualstudio.com/docs/agent-customization/custom-instructions">https://code.visualstudio.com/docs/agent-customization/custom-instructions</a></li><li>VS Code Agent Skills: <a href="https://code.visualstudio.com/docs/agent-customization/agent-skills">https://code.visualstudio.com/docs/agent-customization/agent-skills</a></li><li>GitHub Copilot Instruction Support: <a href="https://docs.github.com/en/copilot/reference/custom-instructions-support">https://docs.github.com/en/copilot/reference/custom-instructions-support</a></li><li>Awesome GitHub Copilot: <a href="https://github.com/github/awesome-copilot">https://github.com/github/awesome-copilot</a></li></ul><p><em>Follow this AI for Software Developers series for more practical insights into GitHub Copilot, AI agents, context engineering and modern software development.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=58a6a29db544" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[AI Session 1 : Contextualizing Copilot]]></title>
            <link>https://medium.com/@satyasuryavenkat/ai-session-1-contextualizing-copilot-60ca6459e4f8?source=rss-2fe4b0c3a527------2</link>
            <guid isPermaLink="false">https://medium.com/p/60ca6459e4f8</guid>
            <category><![CDATA[contextualizing-copilot]]></category>
            <category><![CDATA[github-copilot]]></category>
            <category><![CDATA[copilot-context]]></category>
            <dc:creator><![CDATA[Nunna Satya Surya Venkat]]></dc:creator>
            <pubDate>Tue, 17 Nov 2026 08:48:08 GMT</pubDate>
            <atom:updated>2026-11-17T08:48:08.934Z</atom:updated>
            <content:encoded><![CDATA[<p>How GitHub Copilot Actually Works — and Why Context Is the Secret to Better Code</p><p><em>An illustrated, practical guide to GitHub Copilot, context engineering, and more reliable AI-assisted development with Java, Spring Boot, and React.</em></p><p>GitHub Copilot can generate code in seconds. But does it really understand your application?</p><p>Imagine asking Copilot to <strong>“Create a patient update API.”</strong> It might produce a valid Spring Boot controller — but use the wrong DTO, ignore your service layer, invent exception classes, or accidentally update fields that should never be changed.</p><p>Now imagine giving it the controller, service, DTO, validation requirements, and tests, then asking it to update only two fields. The second request gives Copilot a much better chance of producing code that actually fits your system.</p><p>That difference is <strong>contextualization</strong>: providing the information Copilot needs to work with your real codebase instead of guessing.</p><p>In this article, we’ll explore what GitHub Copilot is, how it works behind the scenes, what context it can use, and how to improve its suggestions in everyday development.</p><p><strong>1. What is GitHub Copilot?</strong></p><p>GitHub Copilot is an AI-powered coding assistant available in supported editors and GitHub experiences. Depending on your environment, it can:</p><p>Suggest code as you type.</p><p>Explain unfamiliar methods or classes.</p><p>Help create tests, documentation, and refactorings.</p><p>Answer questions about code you reference.</p><p>In supported agent workflows, inspect files, propose edits, and use permitted tools.</p><p><strong>Copilot is not a replacement for your IDE or for code review.</strong> It is an assistant whose output still needs developer verification.</p><p><strong>2. How does GitHub Copilot actually work?</strong></p><p>Here’s a simplified view of the process:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MhFXG08CCuIEjKEUw_so2Q.png" /></figure><p><em>Figure 1: A simplified model of how a request becomes an AI-generated suggestion.</em></p><p><strong>Step 1 — You make a request.</strong> You type code, open Copilot Chat, select a function, or ask an agent to complete a task.</p><p><strong>Step 2 — The integration assembles context.</strong> Depending on the feature and settings, it may include nearby code, the selected text, explicitly referenced files, previous conversation messages, project instructions, or retrieved results.</p><p><strong>Step 3 — Copilot sends the assembled request to a model.</strong> A large language model (LLM) generates text or code based on the supplied information and its learned patterns. The exact request construction differs across Copilot features.</p><p><strong>Step 4 — You get a suggestion or response.</strong> Inline completion may propose the next few lines. Chat may explain an error or propose an implementation.</p><p><strong>Step 5 — Tools may be involved.</strong> In an agent workflow, Copilot may inspect more files, edit code, or run approved commands, then use the results to continue.</p><p><strong>Step 6 — You verify the outcome.</strong> Review the changes, run the tests, check edge cases, and make the final decision.</p><p>An important detail: <strong>generating plausible code is not the same as executing or validating it.</strong> An LLM may produce fluent but incorrect output.</p><p><strong>What exactly is an LLM?</strong></p><p>A large language model is trained to identify patterns in text and code and generate likely continuations. It does not automatically possess a live, complete model of your application. For a specific question, the context supplied to it is crucial.</p><p><strong>3. Three ways developers interact with Copilot</strong></p><p><strong>Inline suggestions</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SSUFUBzJKJ5e7bwbZ04eRw.png" /></figure><p><em>Figure 2: Inline completion suggests code while the developer types.</em></p><p>Suppose you start a Java method named calculateTotalPrice. Copilot may suggest the body based on the name and surrounding code. This is fast, but it may not know your discount rules unless they are visible in context.</p><p><strong>Copilot Chat</strong></p><p>Chat is useful for explaining, designing, and debugging. For instance:</p><p><em>Explain why OrderService#createOrder throws an exception when the inventory count is zero. Refer to the existing business rules and tests.</em></p><p><strong>Agent workflows</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*uAhvYb2IBFYgEqlCV5dQng.png" /></figure><p><em>Figure 3: In supported environments, agents can work iteratively with files and tools.</em></p><p>An agent can perform a multi-step task, such as inspecting the API, editing a service method, and running tests — subject to its available tools and permissions. You still need to inspect its changes.</p><p><strong>4. What is context, and why does it matter?</strong></p><p>Context is the information available to Copilot when it generates a response. Useful context might include:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*deAAGm7aTYKUt6SbCY7YbQ.png" /></figure><p><em>Figure 4: From immediate code to project guidance and external information.</em></p><p><strong>Immediate code:</strong> Current selection, cursor-adjacent code, or active file.</p><p><strong>Project evidence:</strong> Relevant controllers, services, repositories, DTOs, tests, and error logs.</p><p><strong>Project rules:</strong> Coding standards, architecture conventions, or custom instructions.</p><p><strong>Task requirements:</strong> Expected behavior, constraints, acceptance criteria, and output format.</p><p><strong>Approved external context:</strong> Documentation or tools connected through supported integrations.</p><p>A useful rule is: <strong>Copilot does not necessarily see the entire repository just because it is open in your editor.</strong> Context access depends on the tool, feature, permissions, and indexing or retrieval behavior. Be explicit about what matters.</p><p><strong>Weak prompt vs. contextualized prompt</strong></p><p><strong>Weak:</strong></p><p><em>Create a patient update API.</em></p><p><strong>Better:</strong></p><p><em>Inspect PatientController, PatientService, PatientRepository, and PatientUpdateRequest. Add a PATCH endpoint that updates only phone number and address. Reuse the existing validation and exception-handling patterns. Do not modify other patient fields or the database schema. Add JUnit tests for success, patient not found, and invalid input. Summarize the files changed.</em></p><p>The improved prompt explains <strong>what to do, where to work, what to preserve, and how to verify success.</strong></p><p><strong>5. How to provide the right context in VS Code</strong></p><p>In supported Copilot Chat experiences, you can select code, reference files or symbols, and use the available context controls. The precise labels and syntax vary with the extension and version.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/938/1*Fh4PKdzzSSv-IUczK6pK2g.png" /></figure><p><em>Figure 5: Provide the request and the evidence needed to answer it.</em></p><p>For common tasks:</p><p><strong>Bug fix:</strong> Include the stack trace, failing test, and relevant implementation.</p><p><strong>New feature:</strong> Include the existing API pattern, DTO, repository, acceptance criteria, and tests.</p><p><strong>Refactor:</strong> Include the current behavior, public contract, tests, and boundaries of the change.</p><p>Avoid attaching dozens of unrelated files. Context windows are finite, and excessive irrelevant information can reduce focus.</p><p><strong>6. A prompt template that works for real projects</strong></p><p>I use this simple structure:</p><p><strong>TASK + FILES + RULES + OUTPUT + CHECKS</strong></p><p>TASK: Add pagination to GET /api/products.</p><p>FILES: Inspect ProductController, ProductService,</p><p>ProductRepository, ProductResponse, and existing tests.</p><p>RULES: Reuse existing response DTOs and exception handling.</p><p>Do not change the existing API fields.</p><p>OUTPUT: Show the proposed changes and explain key decisions.</p><p>CHECKS: Add tests for default pagination, custom page size,</p><p>and invalid parameters. Report any tests not run.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/938/1*8UYuWF35avpzCn8lVn-04A.png" /></figure><p><em>Figure 6: Inspect, plan, implement, test, and review — rather than prompting blindly.</em></p><p>When the task is complex, ask Copilot to <strong>summarize the existing flow and propose a plan before editing</strong>. This can expose misunderstandings early.</p><p><strong>7. Give Copilot repeatable project rules</strong></p><p>You don’t want to repeat the same architecture and testing instructions in every conversation. Copilot offers several customization mechanisms, with support varying by environment.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/938/1*xcwoPcAznfUkxBdreROzqA.png" /></figure><p><em>Figure 7: Different files serve different types of guidance.</em></p><p><strong>Repository-wide custom instructions</strong></p><p>A common file is .github/copilot-instructions.md.</p><p># Project conventions</p><p>- Java 21, Spring Boot 3, PostgreSQL.</p><p>- Follow controller -&gt; service -&gt; repository layering.</p><p>- Reuse existing DTOs and API error responses.</p><p>- Use JUnit 5 and Mockito for tests.</p><p>- Never expose credentials or personal data in logs.</p><p><strong>Path-specific instructions</strong></p><p>Supported environments can apply rules to particular paths, such as Java test files, using instruction files under .github/instructions/.</p><p><strong>Reusable prompts</strong></p><p>Store repeatable tasks, such as API reviews, in supported prompt files under .github/prompts/. Developers can invoke them when needed rather than retyping the same checklist.</p><p><strong>Agent instructions</strong></p><p>An AGENTS.md file can guide supported coding agents. The exact discovery and priority rules depend on the Copilot environment. Test customizations in your team’s actual editor and configuration.</p><p><strong>8. Real debugging example: duplicate customer registration</strong></p><p>Suppose your Spring Boot application should reject an email already registered, but duplicate entries are being stored.</p><p>A vague prompt — <strong>“Fix duplicate customer issue”</strong> — leaves too many unanswered questions.</p><p>Try this instead:</p><p>Inspect CustomerController, CustomerService,</p><p>CustomerRepository, CustomerRequest, and existing tests.</p><p>Problem: A duplicate customer email is accepted.</p><p>Expected behavior: Return HTTP 409 using the application’s</p><p>existing error format.</p><p>First explain the current registration flow and the likely</p><p>root cause. Then propose the smallest safe fix.</p><p>Preserve the API contract and add tests for duplicate email</p><p>and normal registration. Report assumptions and tests run.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/938/1*Dar9HqshdyYKhbWWeqmn9Q.png" /></figure><p><em>Figure 8: Diagnose with evidence before changing code.</em></p><p><strong>Important production consideration:</strong> If duplicate email must be impossible under concurrent requests, an application-level existence check alone may be insufficient. The database may also need an appropriate uniqueness constraint, with conflicts handled consistently.</p><p><strong>9. MCP: when context comes from external tools</strong></p><p>Model Context Protocol (MCP) is a way for supported AI clients to use configured tools and data sources. Depending on the setup, a tool might retrieve documentation or issue details useful for a development task.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/938/1*Q7vj2lbOfbV7YSUup62gZg.png" /></figure><p><em>Figure 9: An agent may retrieve additional information through permitted tools.</em></p><p>MCP is optional. You do <strong>not</strong> need it just to reference your local Java service or DTO. Connect only trusted sources, use minimum necessary permissions, and treat external tool output as information to validate rather than instructions to obey automatically.</p><p><strong>10. Five mistakes to avoid</strong></p><p><strong>Asking “fix this” with no evidence.</strong> Include the failure, files, and expected behavior.</p><p><strong>Assuming Copilot knows every project rule.</strong> Provide essential constraints or configure reusable instructions.</p><p><strong>Attaching the entire codebase without focus.</strong> Start with the smallest useful set of files.</p><p><strong>Accepting invented classes or APIs.</strong> Verify references against actual project code.</p><p><strong>Skipping review and tests.</strong> Copilot can accelerate development, but it cannot take responsibility for correctness.</p><p>Also avoid entering secrets, access tokens, sensitive customer details, or internal information your organization does not permit you to share.</p><p><strong>11. A mini exercise for your team</strong></p><p>Open an existing Spring Boot application and perform the following comparison:</p><p><strong>Round 1:</strong> Ask Copilot, “Add an order status update API.”</p><p><strong>Round 2:</strong> Reference the existing controller, service, DTO, and tests. Specify allowed status transitions, error responses, and test cases. Ask for a plan before code changes.</p><p>Compare the two outputs: Did Copilot reuse the correct layers? Did it invent methods? Were the error responses compatible? How much manual correction was needed?</p><p>The purpose is not to prove Copilot is always right with more context. It’s to show how good context makes suggestions <strong>more relevant, easier to inspect, and easier to test</strong>.</p><p><strong>Final thoughts</strong></p><p>The most useful GitHub Copilot skill is not writing complicated prompts. It’s knowing <strong>which evidence, constraints, and tests matter</strong> for the task.</p><p><strong>Better context → more relevant suggestions → smaller changes → easier verification.</strong></p><p>Start with the real code. State the expected behavior. Limit the scope. Review every change.</p><p>That’s how GitHub Copilot becomes a practical development assistant rather than a code generator you have to constantly correct.</p><p>— — — — — — — — — — — — — — — — — — — — — — — —</p><p><strong>Further reading</strong></p><p>[About GitHub Copilot](https://docs.github.com/en/copilot/get-started/about-github-copilot)</p><p>[VS Code Copilot context](https://code.visualstudio.com/docs/chat/copilot-chat-context)</p><p>[GitHub Copilot custom instructions](https://docs.github.com/en/copilot/concepts/prompting-and-context/custom-instructions)</p><p>[Medium: Writing and publishing a story](https://help.medium.com/hc/en-us/articles/225168768-Writing-and-publishing-your-first-story)</p><p><em>Note: Copilot features, names, and supported configuration files can change by editor, plan, version, and organizational policy. Check current documentation for your environment.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=60ca6459e4f8" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>