Introduction
This is a second part of getting started with Agentic AI development, if you missed part 1 you probably should read it as context for this post. In this post I will show you how I actually build a small application that gets data out of HAF on Hive and show you my process from the very start as well as show you my cost optimization techniques in action.
I am going to skip the part of where you connect your GitHub Copilot subscription to VS Code, you can read all about that here: https://code.visualstudio.com/docs/setup/copilot
VS Code Chat
VS Code Chat is where most of our interaction with Agents happens and there are a couple important things I would like to point out:
As you can see on the bottom I have a place to describe my goal and what I want to do. Notices that I have it set to Plan mode and LLM Model selection to Auto. There is a reason I set these this way for the example Hive coding project. Of-course you can set it into Agent mode and go ahead and Vibe code. That is not the best way!
At my job we use what is called Spec-Driven Agentic Development so we use an open source framework called Spec-Kit
Spec-Kit is what I would recommend for serious professional development projects, but here we have a very basic task in front of us, so I am going to show you how you can do small projects very effectively and cost efficiently.
You see the problem with Vibe coding is that it is too unstructured and let's your AI agents drift and do things that are not what you want and will basically result in low quality code and waste of tokens. To address this we are going to start with a plan.
Plan Mode
In the Plan Mode we want to describe what we want to build giving the AI as much detail about what we are building and what we are going to use for it as well as rules and things to do and not to do. We are basically going to have AI come up with a detailed plan of what we want it to build.
In the Plan Mode I asked GitHub Copilot to come up with the plan for a simple tool I wanted to build. Since we were in Auto selection of LLM model mode the AI picked the best model for this task, in this case the most expensive model and the most thinking model from Anthropic: Claude Sonnet 5:
In GitHub Copilot when you are in Auto mode not only you get AI to select the most appropriate model for the task, but you also get 10% discount on your token usage. I think that picking a modern thinking model that is on the more expensive side is correct choice for the planning task. Because coming up with the right plan and a great architectural solution is a critical part of making your development project a success. Those who fail to plan, plan to fail...
You can see that after taking a look at some web resources Claude Sonnet is asking me to answer 5 questions. I like the second question:
Here Claude is asking me to pick between storing the tool locally or publishing it to Azure website, I think that local storage makes more sense for this use case.
Here I am going to select the first option as it makes more sense that my first post should be numbered as number one :) Here is how I have answered these questions:
After I have answered the questions Claude Sonnet 5 came up with the implementation plan. And here I would like to point out this little circle in the Chat tool. See the 5% that is 5% of the context for this session was used. The higher the usage of the Context the higher the cost of each request you make during your Chat session and the lower the quality of the output usually becomes. That has to do with Agent having to maintain the context of your conversation with it. So start new sessions with your AI frequently, though sometimes you want it to have some context and then you continue the conversation so it is a balance... But once you get over 50% of the context it is probably time for a new session.
Also, notice in the box that pops up once you mouse over this circle there is a cost of 31.9 credits that is how much the plan has cost. It also offers you to start implementation right here. We are going to review the plan first and save it. I found the plan to be pretty good, and told it to save it so that the plan is accessible beyond this current conversation:
Now that we have our plan, I start a new session to have clean context and switched to Agent mode as you can see in the screen shot below to let AI pick the most appropriate model for this task:
GPT 5.6 Luna is cheap and faster than Claude Sonnet 5 because it doesn't need to think much, it has a great plan that it can use to build the tool. Here is part of this plan:
About five minutes later we have our tool:
Notice how few credits we actually used to build this tool, only 8.1 credits! And it even used @blocktrades account to validate the tool. Now we can run the tool using that command above without using any AI credits. Here you can see how the output of this looks:
Now we can open PowerShell and run the following:
A very short time later we have all 7788 posts from @tarazkp :
As you can see this is a very easy process that didn't really require any programming or software development knowledge. If you can describe what you want done and follow this process with AI building a detailed technical plan you can build anything you want fairly easily...
To be continued in Part 3.
I am a Hive Witness and would really appreciate your vote for me as a witness: https://vote.hive.uno/@seattlea