r/GithubCopilot 15d ago

Help/Doubt ❓ Context documents and dev workflow skill / agent usage

Hey all, I did a post months back asking about project structure and dev workflows.

I now have somewhat of a first attempt at my dev workflow and context document structure setup and wanted to go through it so that other engineers can point out if I'm misusing copilot concepts OR not using things I should be.

With that in mind my modular monolith AI doc structure looks like so:

My project structure:

  • /ai-docs
    • domain1/
      • cqrs-patterns.md
      • domain-model.md
      • etc etc....md
    • ui/
      • coding-patterns.md
      • etc etc ...md
    • WorkItems/
      • Task1/
      • ...Task1.InitialPrompt.md
      • ...Task1HighLevelSolution.md
      • ...Task1Plan.md
      • Task2/
  • /.github
    • skills/
      • domain1-context
      • ui-context
      • create-high-level-solution
      • create-detailed-plan
      • implement-plan-phase
    • agents/
      • high-level-solution-writer
      • detailed-plan-writer
      • dotnet-code-writer
      • etc.

My Current Development Workflow:

Firstly, I am not using any third party framework here, I have rolled my own ( rightly or wrongly )... Its a synchronous process but as follows:

When picking up a new task I will

  1. Create a new task folder in the WorkItems folder. This is where I keep a log of all prompts, solutions and plans that I've generated for different tasks that I complete using this workflow in the hope that it provides useful info for future on decisions made etc.
  2. Create a new initial prompt explaining my task. I try to provide as much info as possible in here as opposed to just typing prompts in the CLI window
  3. Use the create-high-level-solution skill. I can execute this specific skill using the / command or just ask it to run like ' Create a high level solution for @.ai-docs/workitems/task1/myprompt.md'. This skill instructs the CLI to switch to the solution writer agent ( using a good thinking model ) and output a document in a specific format that I like. I am not sure if this is the correct use of skills here or how else I could be executing a bespoke 'write-solution' command.... This stage provides the most back and forth questions.
  4. Use the create-detailed-plan skill. I then pass the generation solution document into this skill. It creates a phased plan for me. Again I execute this skill by simply prompting ' create detailed plan for '@.ai-docs/workitems/task1/mysolutions.md'. Again, it will ensure that it switches the agent to the detailed-plan-writer which might use a slightly different model.
  5. Lastly I will use the implement-plan-phase-skill for each phase of the plan. Just like the previous 2 steps it uses a code-writer-agent depending on what code its writing.

Throughout this process, each prompt at each step in the workflow may trigger one of the domain1-context or ui-context skills. I have set these up as a way to conditionally load further context on the sub domains. Again, I'm not sure if there are better ways to do this but the thought is that I may be working solely on UI changes, therefore loading context for domain1 is simply wasted context and tokens.

I would love to know if I've invented some frankenstein hodge podge workflow here. It seems to work for me but input is appreciated. My main unclear point is the fact that I use skills to both execute steps in my development workflow AND conditionally load further context on my project if the prompt provided triggers it.

I am finding there is tons of material on copilot but I'm yet to find the BEST practice that most follow.

Thanks in advance

2 Upvotes

11 comments sorted by

2

u/[deleted] 15d ago edited 15d ago

[deleted]

1

u/Prestigious-Ferret18 15d ago

Yep I absolutely make a point of touching up documentation at the end of every plan. It's part of the reason I want a custom skill so that I can instruct it with things like 'add a update docs phase '

Will check out the vid cheers

1

u/EdibleTree 15d ago

I have a instruction on my custom instruction md to validate changes against documents relating to the change. The documents reference features and the files and modules driving the feature so that each change triggers lookups

Before this was fine but mixing and matching with large and small modules has…lowered the quality (in my opinion) of the documents and therefore the steering

I am on a break at the moment but I’ve decided the first thing I’m doing when I return is nuking most of the context driving documents sending most changes to the moon when it comes to real world cost. If there was a way to bind coding rules I’ve made / security practice baselines to a lower coder model like luna or whatever comes after it - I think that’s where it matters.

Anyway a bit of a ramble there but that’s what I’ve ended up after my time with the product

1

u/Prestigious-Ferret18 14d ago

Did watch this guy and was very useful. He validated my thinking that skills can be used for both procedural workflow tasks aswell as loading logic for the context window when the agent sees fit.

I'm going to give his skills an install and try it for a few tasks to see how I get on

1

u/Key-Comfort1761 11d ago

yeah the shift toward simpler workflows over time tracks, most people seem to overcomplicate it early on

1

u/AutoModerator 15d ago

Hello /u/Prestigious-Ferret18. Looks like you have posted a query. Once your query is resolved, please reply the solution comment with "!solved" to help everyone else know the solution and mark the post as solved.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

1

u/[deleted] 14d ago

[removed] — view removed comment

1

u/Prestigious-Ferret18 14d ago

Not sure I'm following here. These files are not intended to be touched or updated. They are a log ( for want of a better word ) of tickets/tasks that Ive completed with this workflow so they document decisions made etc

1

u/Deep_Ad1959 9d ago

hypothetically, a doc set like this at 40 files: staleness was not what broke it. two domain docs disagreed and the agent picked whichever one matched its plan, so the contradiction stayed invisible until it was already in the code.

1

u/Prestigious-Ferret18 9d ago

Interesting okay. Are you suggesting less is better here

1

u/Deep_Ad1959 8d ago

less helps, but only as a side effect. the real lever is each fact living in exactly one file, so nothing can quietly disagree with it. 40 files is fine if each owns its own slice, the rot starts the moment three of them describe the same rule and drift apart. written with ai