What is this Lab About
Well, this lab gave us a first exposure to open source development, which including picking a partners repo,forking it into ours and finally adding changes and submitting for a Pull Request. The main objective was to add a flag that returns the LLM's API call token for sending and completing.
What i did in this Lab
As you guys know Liam from Lab01, i choose his repo for this addition. We had some instructions to follow which include:
- Forking their repo into ours
- Create a issue about the addition that we are going to make
- Create a new branch with the same name of the issue.
- Update their code and push it or new branch
- Compare and send for Pull Request Approval
- Receive FeedBack from them
The main changes i made for the code include:
I have completed the issue #4, A brief explanation for the changes/ additions that i made are:
FILES
index.js
I have set a token flag to recognize the flag call for token which will be --token-usage
or '--t
.
The next thing was making sure that createREADME function receives both token usage and token completion from the api. and print that to the console.
ai.js
There is no major change in this, just incorporating javascript with the Gorq documentation to extract tokens. I made a function called getTokenUsage()
. To store the token data.
You can find the whole issue here:Issue in my partners Repo
Feedback from my partner
He mentioned that my solution was working as indented and there is no requirement of a further change to the addition Comment
What happened in my Repo
My code was also taken by my partner to add a similar function to my tool called DocBot, he was successfully able to implement that feature in mine.
Issue my partner made in my Repo
Conclusion
This was a very fun yet, informative lab i believe it gave us a clear insight how contribution in open world works and what it takes for your code to get approved.
GitHub Link of my tool: DocBot
GitHub Link of my partner's tool: Auto-README
AJO GEORGE 20-09-2024
Top comments (0)