OpenAI Codex Complete Tutorial — Transcript
Full transcript
- 0:00Hi everyone, my name is On Paria and in
- 0:02this complete oneshot video we will talk
- 0:04about Codeex. So whether you have used
- 0:06Codex before or you are completely new
- 0:08to Codeex, this video will help you out
- 0:11because we are going to start everything
- 0:13from scratch to building our own
- 0:15fullstack application using Codeex. So
- 0:18with that note let's get started.
- 0:22So what is Codeex? See we already know
- 0:24that when Chat JD was launched in 2022,
- 0:27people used it so aggressively. Not
- 0:29because it was something new but because
- 0:32it gives them in-person feel. They
- 0:34actually feel like that there's someone
- 0:36who chatting with them and solving their
- 0:38queries based on their questions and
- 0:41whatever the response it generate they
- 0:43just copy and paste it wherever they
- 0:45want to use and even most of the people
- 0:47consume AI for the very first time
- 0:49because of chat GPD although AI was
- 0:51available way back but they were not
- 0:53aware about it. And for this type of AI
- 0:56workflow, we got the term in AI which is
- 0:58known as generative AI. But now in 2026,
- 1:02things has changed. AI has evolved a
- 1:04lot. This time it's not only about
- 1:06generating the response but also letting
- 1:09the AI to do the task on the behalf of
- 1:11you and also parallelly with you. And
- 1:13for these type of capabilities in AI, we
- 1:16call it them as AI agents. And Codex is
- 1:20one of the AI agent which is built by
- 1:22OpenAI. And there are some other AI
- 1:23agents also available like we have cloud
- 1:26code from anthropic and we have replet
- 1:28bolt new and others and all the main
- 1:31purpose of this AI agents to do the task
- 1:34whatever the instructions you have given
- 1:35to it. Now just like we humans when we
- 1:37do any task how we actually perform that
- 1:39task we first do planning in our mind
- 1:41that we gather all the resources that
- 1:43are required to take action for that
- 1:45task and once we done all the planning
- 1:47we start executing it with the help of
- 1:49actions. Same like that these agents
- 1:52work. So this agents works on these
- 1:54three principle. First one is reasoning
- 1:57where does the planning and thinking
- 1:58based on the task you have given then it
- 2:01will do act. Now when it comes to act,
- 2:03it actually acts with the help of tools.
- 2:05But now what is tools? See tools are
- 2:08some external set of programs or
- 2:10instructions which help AI agents to get
- 2:12the resources outside of your
- 2:14environment. Now what does that mean?
- 2:15Suppose you are using codeex inside your
- 2:17project and inside the project you want
- 2:20your codeex to get access to the API
- 2:22which is a part of internet. So to get
- 2:24access to that API how will it get
- 2:26access? It will get access with the help
- 2:28of tools. And now it's not only limited
- 2:30to the API although if you want to
- 2:32access to any file from your project and
- 2:34want to edit any code inside that all
- 2:36those things will be done with the help
- 2:37of tools. In short, tools give the
- 2:40capabilities to AI agents to get access
- 2:42to that particular thing which is
- 2:44required for the task. So it will act
- 2:47based on the tools. And now the next
- 2:49thing is access memory. So just like we
- 2:52human store the things in our mind so
- 2:54that later on if you want to do the same
- 2:56task again, we do not start everything
- 2:58from a scratch. Instead we will get it
- 3:01from our memory and then execute it.
- 3:03Same like that the AI agents also have
- 3:06short-term and long-term memory based on
- 3:08the task we have given and later on if
- 3:10the same task you want to do it again it
- 3:12will do it from its memory instead of
- 3:14starting everything from a scratch and
- 3:16this reasoning and act we together call
- 3:18them as react which basically means
- 3:21planning and then taking actions now if
- 3:23you want to show the entire workflow of
- 3:24AI agents with the help of an example so
- 3:27suppose a user ask a question which says
- 3:29what's the weather in my city now when
- 3:31user ask these type of questions
- 3:32The first thing AI agents will do, it
- 3:34will do the planning. It will first see
- 3:37users didn't specify the city. All the
- 3:39plannings it will do. It will see that
- 3:41my city determine users locations, need
- 3:43weather informations and then plan what
- 3:46is the plan. Now here find locations
- 3:48fetch weather and summarize the result.
- 3:50So these are the planning or the
- 3:52thinking your AI agents will do. And
- 3:54once this is complete, it will start
- 3:56taking an action. Now the first thing is
- 3:58that it needs a location of your city
- 4:01otherwise how will it get to know the
- 4:02weather of it. So it will take the help
- 4:04of tool as we discussed before that act
- 4:07basically takes the help of tools
- 4:09through which it will get access to the
- 4:10external resources. So here also it will
- 4:13take the help of location tool and it
- 4:15will observe that location is XY Z or
- 4:19name of the city in India and once it is
- 4:21done it will reason again. Now planning
- 4:24is required because first we need to
- 4:26fetch the location and once that agent
- 4:28is done it will now know the city it
- 4:31will now fetch the current weather. So
- 4:33again action take and here it will call
- 4:36weather API and again once the weather
- 4:38API get fetched it will do the 34° C
- 4:41partially cloud humidity 58%. So this is
- 4:44the response it generate for you and
- 4:46this is your final result in the form of
- 4:48natural language answer and you got the
- 4:50response. So this is how the entire AI
- 4:52agents actually work and not only with
- 4:53the codeex but all the AI agents works
- 4:55in the same principle. Now the flow I
- 4:57have shown you here it's just a win-win
- 4:59flow means everything works successfully
- 5:01here but in case if anything gets failed
- 5:04in between let's say when it doing the
- 5:06action for the calling the weather API
- 5:08and in between the weather API gets
- 5:10failed due to some catastrophic events
- 5:12let's say a network issue or some uh
- 5:14HTTPS code whatever the reason if it get
- 5:17failed then what will happen it will run
- 5:20the loop again it will again do the
- 5:22planning just like it does here for the
- 5:24planning same if any error occurs in
- 5:26between it will do the same thing again
- 5:28and that we call them as agentic loop
- 5:30means if any error comes in between we
- 5:33don't have to uh put the error again
- 5:35back to it and then ask that solve this
- 5:37error instead it will look at the result
- 5:39and based on that it will do the things
- 5:41again until it receive the final output
- 5:44for us based on our query so this is how
- 5:46the AI agents work now if we talk about
- 5:48the codeex particularly then codex is
- 5:51not only limited to the software
- 5:52engineering field that means you are not
- 5:54going to use codeex for instruction
- 5:56based on your codebase. Even though if
- 5:58you are a non-technical person and you
- 6:00want the codeex to do some task for your
- 6:03work, let's say you want to send email
- 6:05to that particular email address through
- 6:07your Gmail app and want to send
- 6:09particular subject at that time also
- 6:11codeex will work there and even though
- 6:13if you want to execute the codeex to the
- 6:15particular app in your computer then
- 6:17also your codeex will work there but the
- 6:20thing is that the main purpose of codeex
- 6:22is to design or trained in a software
- 6:25engineering field that's why openi
- 6:27basically use JPD 5.5 5.4 models which
- 6:30has specifically trained in software
- 6:32engineering field. So it's a win
- 6:34situation for people who are using it
- 6:36codex for the developer point of view
- 6:37but for the nontechnical person it will
- 6:39work but not up to the mark or not up to
- 6:42the desired output. So that's all about
- 6:43the codex. I hope you get the clear
- 6:45picture what is codex and how this
- 6:47codeex AI agents actually works.
- 6:51So as we discussed now that just like
- 6:52Codex there are bunch of agents out
- 6:54there like cloud code, cursor, copilot
- 6:57and few more and when we start exploring
- 7:00them only one thing keeps increasing and
- 7:02that is confusion. We feel like that why
- 7:05all these agents available when they all
- 7:07works on the same principle like first
- 7:09they do planning then taking actions and
- 7:12then storing in the memory for
- 7:13reference. See the thing is that
- 7:16although these all agents work on the
- 7:17same principle there is something which
- 7:19makes them different not in terms of
- 7:21feature because that of course remains
- 7:23same in them but in terms of personality
- 7:26while it doing the actions. See there
- 7:28are some agents who work on the fast
- 7:30environment means as soon as you give
- 7:32them the task they do not spend much
- 7:34time in reasoning and planning instead
- 7:36they start taking action as soon as
- 7:38possible. And even though there are some
- 7:40agents who works on the local
- 7:42environment while there are some agents
- 7:44who works on cloud environment too. So
- 7:46if we talk about specifically to codeex
- 7:48it comes under the fast agent category
- 7:50with cloud environment. That means if
- 7:53you have given some task with the codeex
- 7:55it will take actions without doing much
- 7:57research and planning. Now while it do
- 7:59so it comes with advantages and
- 8:01disadvantages. Now the disadvantage is
- 8:04that the output it will generate will
- 8:05not up to the mark. It requires more
- 8:07iteration to fix the error that it has
- 8:09generated in the output. And the reason
- 8:11for that is that because it has not
- 8:13spent much time in reasoning. It just
- 8:15take the actions based on your task as
- 8:17soon as possible. But the good part is
- 8:19that it will use less token. And the
- 8:21reason of using it the less token is
- 8:23that because it has not spent much time
- 8:25in reasoning. It just take the actions
- 8:27based on your task as soon as you have
- 8:29given them. Now in the whole room of
- 8:32this agents there are two everyone keeps
- 8:34comparing and that is codeex and clot
- 8:36code and I think their comparison makes
- 8:38sense also because if you have ever used
- 8:40cloud code before you know how powerful
- 8:42it is when it comes to coding and the
- 8:44reason of it for being so powerful is
- 8:46because it takes more time in planning
- 8:49before taking an action and because of
- 8:51that the output it will generate will be
- 8:53perfect in the one go itself but it
- 8:55doesn't mean that you should blindly
- 8:56follow cloud code over codecs because
- 8:58there are some other factors that you
- 9:00need to keep in mind when you are using
- 9:01the clot code. It will give you the
- 9:03output for sure which is better than
- 9:05codeex but it will also use more tokens.
- 9:08So if budget is not your concern and you
- 9:10are happy with the token usage limit,
- 9:12you can definitely go with a clot code.
- 9:14But if you could ask me that which one
- 9:16is better then I would say no one
- 9:19because the question is not which one is
- 9:21better or which one is not. The question
- 9:23is which one you should prefer based on
- 9:25your workflow. See if you think that
- 9:27your task requires a less token and
- 9:29requires a less planning you can go with
- 9:31a codeex to save your tokens. But if
- 9:33your task is complex and requires a more
- 9:35planning and your output is your
- 9:37concern, you can definitely go with the
- 9:39cloud code. So decide based on your task
- 9:41not based on the performance. So
- 9:43although these agents keeps improving
- 9:45day by day. So maybe today cloud code is
- 9:47better but tomorrow it will be codeex.
- 9:49So keep an eye on these agents and based
- 9:51on the performance and your workflow you
- 9:54should decide which agents you should go
- 9:56with. So I hope it is clear to you that
- 9:57which agent you should choose while
- 9:59giving it to the task.
- 10:02So only one last thing is left before we
- 10:03start exploring codeex and that is
- 10:05understanding its pricing and usage
- 10:07limit and it's important to know
- 10:09otherwise if a codex stop working in the
- 10:11middle of any session you might come
- 10:12back and blame me for not explaining how
- 10:15Codex usage limit actually works. Jokes
- 10:17apart. See basically codeex uses are
- 10:19divided into two categories. One is
- 10:21subscription based and another one is AP
- 10:24based and even we can use codeex for
- 10:26free also and later on once we
- 10:27understand our requirement we can
- 10:29explore any one of these category. So as
- 10:31you can see here if you're using codex
- 10:32for the lightweight coding task you can
- 10:34go with a$18 per month plan with co but
- 10:36if you're using codex with extra
- 10:38features with the latest model like GPD
- 10:405.5 GBD 5.4 four and you also want the
- 10:42chipity other features like image
- 10:44generation model and video generation
- 10:46you can go with the plus plan with $120
- 10:48per month and people mostly prefer this
- 10:50one because it is affordable and it is
- 10:52also more than enough for day-to-day
- 10:54task but if you are using codex for more
- 10:56than one people then pro plan makes
- 10:58sense here with $100 per month but if
- 11:01you are not happy with this subscription
- 11:03based method where you have to pay the
- 11:04specific amount every month then you can
- 11:06also explore the API based method where
- 11:09you will only pay for the token you will
- 11:11consume while using the codeex. Now once
- 11:13we understand this pricing then let's
- 11:15also see about usage limit. So as you
- 11:17can see on the screen previously codex
- 11:19keeps the track how much we have used it
- 11:21based on the message we have sent to it
- 11:22but later in April 2026 it has not
- 11:25changed instead of keeping it based on
- 11:27the messages they keeps it based on how
- 11:29many tokens we have consumed. And if we
- 11:31talk about the usage limit in codeex
- 11:33then they basically shares a fiveour
- 11:35rolling window limit and the weekly
- 11:36limit. So let's say if you have consumed
- 11:38your entire token within that 5 hour
- 11:39window limit then your token will start
- 11:41getting reset after 5 hours and the
- 11:43token that you will receive after that 5
- 11:45hours will be in the rolling window
- 11:46manner or we can say that in the sliding
- 11:48window manner. Now what this basically
- 11:50mean so after 5 hours you will receive
- 11:51only those tokens that you have consumed
- 11:54exactly 5 hours ago from that time
- 11:55period. Okay, I know this sounds
- 11:57confusing. So let's take an examples to
- 11:58make it more clear. So suppose within a
- 12:015 hours budget you have 100% token and
- 12:04you have start using codex at 9:00 a.m.
- 12:06where you have done the heavy coding
- 12:07sessions and you have used 60% of token.
- 12:10Now once you use the 60% token then only
- 12:1240% will left out of 100. Now let's say
- 12:14at 10:30 a.m. you again use codeex and
- 12:17you have consumed next 20%. So total 80%
- 12:20you have consumed out of 100%. And now
- 12:22only 20% is left. Now what will happen
- 12:25at 2 p.m. your 60% token will get rolls
- 12:28off because that token you have used
- 12:30exactly 5 hours ago at 9:00 a.m. So that
- 12:3360% will comes back to you and the 20%
- 12:36which is left previously 5 hours window
- 12:38limit will also sum up in your 60% token
- 12:41limit. So total you will get 80% token
- 12:43limit at 2 p.m. And then at 3:30 p.m.
- 12:46your 20% will also get rolled off that
- 12:48you have used at 10:30 a.m. because from
- 12:5010:30 a.m. to 3:30 a.m. that 5 hours
- 12:53window period also completed. So that
- 12:54token will also get rolls off and
- 12:56totally you will get 100 tokens limit.
- 12:58So you don't have to wait exactly after
- 13:005 hours to get your token limit reset.
- 13:02It will gradually keeps resetting within
- 13:04that 5 hours window limit. Now as I told
- 13:06you before that it is not only based on
- 13:07the five hour rolling window but also
- 13:09the weekly limit which basically means
- 13:11that how much token you have consumed
- 13:13across that week and you need to also
- 13:15make sure that you have enough token in
- 13:17that weekly limit otherwise if your
- 13:18weekly limit get exhausted then you have
- 13:20to wait for the weekly limit get reset
- 13:22even though your 5 hour window limit has
- 13:24recovered. So it's very important to
- 13:26make sure that your weekly limit and
- 13:27your five hour rolling window limit both
- 13:29has token so that you can continue using
- 13:31codeex. Now once we understood how codex
- 13:33usage limit actually works. The next
- 13:35question comes how we can actually keep
- 13:37a track that how many tokens we have
- 13:38consumed during session. See in codex
- 13:41there is no any built-in system where it
- 13:42wants or alerts you when you are about
- 13:44to reach the codex limit. But there are
- 13:46some ways through which you manually get
- 13:48to know that how many tokens you have
- 13:49consumed and rest of the information
- 13:51about your token limits. So the one way
- 13:52of getting the information about this is
- 13:54going to the open platform and here you
- 13:56can go to the usage section and here you
- 13:58will find all the details about overall
- 14:00usage and the consumption of your
- 14:02tokens. As you can see here I have a
- 14:03$120 credits and out of them I have used
- 14:06$2.15
- 14:08in July and total I have spent $3.18. So
- 14:11you can get all those details here. And
- 14:13the next way of getting is throw a
- 14:15command which is a status command in
- 14:17Codex CLI. I'll discuss about this
- 14:18command later in the video also. But if
- 14:20you use this command then you will get
- 14:22the current snapshot of the tokens that
- 14:24have used so far. So once you type this
- 14:26command it will let you know that how
- 14:28many tokens you have used what is the
- 14:29your weekly limit has been reached and
- 14:31rest of the informations as a current
- 14:33snapshot. But if you want a more
- 14:34real-time information and in a more
- 14:36convenient way then you can use a third
- 14:38party tool also but again they are not
- 14:40free. You have to pay a onetime
- 14:41subscription and one of the tool is
- 14:43session watcher which is basically for
- 14:44codeex only and only available in Mac
- 14:47OS. If you use that tool then it will
- 14:49give you the real-time alerts as well as
- 14:50all the informations about how much you
- 14:52have used the tokens and rest of the
- 14:54details. As you can see on the monitor
- 14:55also that how it can shows all the
- 14:57informations about your token usage and
- 14:59the weekly limits. So these are all the
- 15:00ways through which you can get to know
- 15:02about the codeex pricing and the usage
- 15:04limit and how you can monitor it.
- 15:07Now there are multiple ways of using
- 15:09codeex. We can use it directly through
- 15:10codeex app run it as a CLI tool
- 15:13integrate it into our ID as an extension
- 15:15or we can use directly in the cloud. So
- 15:17explore all these approaches one by one
- 15:18and later when we dive deeper into Codex
- 15:20concept we'll focus mainly on using
- 15:22Codex through CLI and ID extension
- 15:24because that is what we most often use
- 15:26while coding. So let's see the first one
- 15:28which is using through codex app. So go
- 15:30to the chatgity.com/codex
- 15:32and here you will find the download
- 15:33button. So click on this download and
- 15:35download it based on your operating
- 15:36system. And once you download and
- 15:38install it then this is how the
- 15:40application will look like on your
- 15:41desktop. Now although the application
- 15:42has a name chat GPT instead of codex
- 15:45because codex is a part of chat GPT
- 15:47only. So codex will available inside the
- 15:49chat GPT app. Now when you open this app
- 15:51for the first time it will ask you for
- 15:52login. So simply sign in with your chd
- 15:54account and once you sign in this is how
- 15:56the application will look like. Now
- 15:57let's have a quick walk through of this
- 15:59entire application. So as you can see
- 16:01the first thing we have new task. So
- 16:02here you can assign a task to CHGPD or
- 16:05the codeex and at the time it is running
- 16:07the task you can define a new task also
- 16:09which will run parallelly in the
- 16:11background. Although we'll come back to
- 16:12this part after some time where we can
- 16:14assign the task to codeex once we
- 16:15understand all the features. So if you
- 16:17look at the another thing which is
- 16:18schedule task. So if you want to
- 16:20schedule a task which should run at a
- 16:22particular time every day weekly or the
- 16:24custom time you can select here. Now
- 16:26there are two ways of creating the
- 16:27schedule task. You can just click on
- 16:28this create then you can create it with
- 16:30chat GPD or you can set up manually. So
- 16:32if I go with the setup manually option
- 16:34here you can schedule the task title.
- 16:36You can describe what chat GP should do
- 16:38with the task and you can just do the
- 16:40minimal configuration like where it
- 16:41should run a new task or in the existing
- 16:43task or in which project it should run.
- 16:45Then which model it should use and how
- 16:47much time it should take in the
- 16:48reasoning or planning. You can define
- 16:50all those things and you can also set
- 16:51the frequency like it should run this
- 16:53task on daily basis or in weekly. You
- 16:56can define that and at which time it
- 16:57should run you can define that also and
- 16:59once you can define it so let's say you
- 17:01want to get a summary of your calendar
- 17:02every day in the morning so you can just
- 17:03define a task here and then the next day
- 17:05when you open your chat gypty or the
- 17:07codeex you will automatically get the
- 17:08summary of your calendar which is
- 17:09generated by the codeex now if you look
- 17:12at the another feature which is plug-in
- 17:14so here if you want to use or give the
- 17:15access to the tools to codeex you can
- 17:17just install that particular plug-in and
- 17:19give it access so as you can see here I
- 17:21have already installed some of the
- 17:22plugins like documents PDF spreadsheets
- 17:24and presentations and rest of the tool.
- 17:26So just install based on your use case
- 17:28like notions and all. As you can see I
- 17:30have also installed the computer use
- 17:31which basically means if I want to open
- 17:33any application I want to give the full
- 17:35control to this Mac I can use the
- 17:37computer use plug-in which will give
- 17:38full access to my Mac. Now another
- 17:40feature is sites. Now this is very
- 17:42useful when you want to turn your ideas
- 17:43into the live website. So let's say you
- 17:45want to share something with your
- 17:46friends or with the colleagues. You can
- 17:48just describe your idea or build
- 17:49something which will automatically
- 17:51generated by the chat GP itself inside
- 17:52this codeex. So you don't have to
- 17:54manually go to the hosting platform
- 17:55where you will deploy it and generate
- 17:57the live URL. The jibility will take
- 17:59care of this and which you can share
- 18:00with other also. Now the another thing
- 18:02is pull request. So here you will review
- 18:04and track all the requests that you have
- 18:05done in your GitHub account. But you
- 18:07need to make sure that your GitHub CLI
- 18:08is set up and you have installed it in
- 18:10your codeex app. Now the another thing
- 18:12is chat. Now this is just a normal chat.
- 18:14It's nothing related to the codeex. So
- 18:15if you want to do any chat with just
- 18:17based on the query and the output
- 18:18generation, you can use the chat GPT
- 18:20here itself in CEX. Just open it and you
- 18:22can just type the chat GPD prompt here.
- 18:24You can just ask a query and it will
- 18:25generate the output for you. And all the
- 18:27entire chat history is available here
- 18:28because you're using the same account
- 18:30which you have login with the chat GPD.
- 18:32So once you understand all these feature
- 18:33the next thing is project section. So
- 18:35here you can create any project and then
- 18:37you can do any task inside that project
- 18:39or if you want to use any existing
- 18:41project you can select that also. As you
- 18:42can see here we have two options. Now
- 18:44the next thing is task. So if you don't
- 18:46want to create any project or go with
- 18:47any existing project, you can just
- 18:48simply define or assign a task to Codex
- 18:51which will also work here. Now after
- 18:52understanding all these features, let's
- 18:54go to the profile section also. So if
- 18:55you click on here, you can see here the
- 18:57first thing we have a usage remaining.
- 18:58So this will tell how much you have used
- 19:00CEX till now. So if you click on here,
- 19:02it will tell that this is your weekly
- 19:04limit and I have used 92% out of 100 and
- 19:06my weekly limit will get reset on 20
- 19:08July. So as we discussed before that
- 19:10codex is basically uh track the usage
- 19:12limit of your codeex based on two things
- 19:15which is a five hour rolling window
- 19:16limit as well as weekly limit. So here
- 19:18you will only see the weekly limit but
- 19:20if you want to see the token limit also
- 19:22then we have discussed the ways like/
- 19:24status command or the third party tool.
- 19:26So you can see from there itself. Now if
- 19:28you want to upgrade to pro that also
- 19:29option available here. Now there are one
- 19:31option available which is four resets.
- 19:33So let's say if you have already
- 19:35exhausted your limit before the vehicle
- 19:36limit reach then you can just have an
- 19:39option to reset the limit. As you can
- 19:41see here my vehicle limit will get reset
- 19:42on 20 July but if I reach my limit
- 19:44before then I have an option to reset it
- 19:46before 20 July also but that option is
- 19:48available only for the four time. So if
- 19:50you have used these four options also
- 19:52and still you want to uh reset your
- 19:54limit before your weekly limit then you
- 19:56can add more credit also. So when you
- 19:58click on this add credit here you can
- 19:59just select any one of the plan let's
- 20:01say $120 here you'll get a 500 credits.
- 20:04So you can start using codex wherever
- 20:05you have left off without upgrading your
- 20:06plan. Now the another option we have a
- 20:08show pad. Now this is only for the UI.
- 20:10So if I click on the show pad you can
- 20:11see this we have this cute patch
- 20:13available here. You can just drag and
- 20:15put it anywhere you want to put it just
- 20:17give you the information that what is
- 20:18currently running on your codeex uh in
- 20:20the form of pop-up or the tool tip. And
- 20:22also it looks cute here. So if you want
- 20:24to keep you can just keep it or if you
- 20:26want to hide just click on hide and it
- 20:28will get hide here. Now let's go to the
- 20:30settings also. Now in settings we have a
- 20:32personal option where you can uh
- 20:34personalize your codex based on your
- 20:36requirement. And here you can see the
- 20:37pets option also available. So as you
- 20:39can see right now we are using the
- 20:40default codex pet. But if you want to
- 20:42use some different pet also you can
- 20:43select one of them from here. Now if you
- 20:45look at the integration section there
- 20:47are four options available which is
- 20:48appshot. Now this is very useful because
- 20:50if you want to give a snapshot of any
- 20:53application let's say you are using
- 20:54chrome and you want to ask any question
- 20:56to that snapshot you can just take a
- 20:58screenshot of that and then put it to
- 20:59the chat GPD. Now before this appshot
- 21:02feature how we usually do it we just
- 21:04take a screenshot and then upload it
- 21:05from our system. But with the help of
- 21:07appshot you can use the shortcut command
- 21:09which will automatically take the
- 21:10screenshot and attach it to the chat.
- 21:12I'll show you how to do this. So you can
- 21:14see here it says a hot key where it will
- 21:16says if you use both commands in your
- 21:18keyword together then it will capture
- 21:19the screenshot and it will attach to the
- 21:21chat. So let me open a chrome browser
- 21:24here. Let's say if I want to give this
- 21:25screenshot to my codeex app. So I can
- 21:27just click my both commands together.
- 21:29And as you can see here as soon as I
- 21:31click it just capture the screenshot and
- 21:33automatically attached to my chat. So
- 21:34this is very useful and now you can ask
- 21:36any questions related to the chat. Let's
- 21:38say what is available here and how can I
- 21:40fix any UI like what is available here.
- 21:42Now let's look at another feature also.
- 21:44Now in appshot uh we have a appshot
- 21:47destination also like automatic like by
- 21:49default it is selected to automatically
- 21:50which basically means uses the current
- 21:51chat if you use recently otherwise it
- 21:53starts a new chat but if you always want
- 21:55your snapshot to be available in the
- 21:56current chat then you can select this
- 21:57one and if you want it to the new chat
- 21:59then you can select this one and then if
- 22:01you want to play a sound effect you can
- 22:02enable and disable it from here based on
- 22:04your preference. Now the another thing
- 22:05is plugins. So this is the same thing
- 22:07that we have seen before also it will
- 22:09list all the plugins that you have
- 22:10installed in your codeex app. Now the
- 22:12third one is browser. Now this is the
- 22:14chat GPT inbuilt browser. It will tell
- 22:15how you want to manage your browser like
- 22:17if you want to open any web URL where it
- 22:19should get open. It should get open
- 22:21inside your chat GPT app or the default
- 22:23browser. You can select it from here and
- 22:24whatever the site you will generate like
- 22:25the live URL it will generate that URL
- 22:27will get open by default inside your
- 22:29chat GPT browser. So you can manage how
- 22:31that browser should look like and what
- 22:32are the things available there. Now the
- 22:34next thing is the computer use. So this
- 22:36is the integration I have done. Now in
- 22:38the computer use I have given uh
- 22:39permission to my any app that means
- 22:41whatever the app I want to open it
- 22:42through my codeex app I'm able to use
- 22:44it. I'll show you how you can do this
- 22:46but as you can see I have given the
- 22:47permission to my all the app and the
- 22:49Google chrome as well Microsoft Excel
- 22:51PowerPoint and I can also enable this
- 22:52also. So if my MacBook get logged then
- 22:54also JJ will run the task in the
- 22:56background. If you look at the coding
- 22:58section here the first thing is hooks.
- 23:00Now what does it basically mean? This is
- 23:02basically useful to automate your work.
- 23:04So let's say you have given access to
- 23:05the one of the repository to the codeex
- 23:07and you want that before it take any
- 23:09actions to that repository it should
- 23:10first always run a pull command so that
- 23:12it will get the latest changes. So
- 23:14instead of manually typing all these
- 23:16instructions every time in the prompt
- 23:18you can just define a hook here which
- 23:19will automatically get inject at the
- 23:21time it will take action for that
- 23:22repository. Now another example also
- 23:24let's say uh when the task get completed
- 23:26inside your repository you want that it
- 23:28should always run a test command using
- 23:30the increment test. So you can create a
- 23:31hook for that also. That hook will
- 23:33automatically get injected in the task
- 23:35and when it gets completed. So this is
- 23:36basically used to automate your task.
- 23:38Now the another thing is connections.
- 23:39Now this is basically used when you want
- 23:41to control this Mac remotely from
- 23:43another devices like from your mobile
- 23:44phone or from the another desktop. So
- 23:46you can just simply click on this add
- 23:47button and here if you want to connect
- 23:49it with your mobile phone just click on
- 23:51this phone. It will generate the QR
- 23:52code. Just scan it from your mobile
- 23:54phone and your CEX app will get connect
- 23:56there. But if you want to connect it
- 23:57with your desktop then click on the
- 23:58computer button. here if it will
- 24:00generate the code just go to this
- 24:01particular path like settings
- 24:02connections control other devices and
- 24:05then enter this code then you're able to
- 24:06control this Mac from that device
- 24:08although I have tried the phone method I
- 24:09tried my phone to connect with this
- 24:11codeex app so I want to show you that so
- 24:13I'll just enter my password here so as
- 24:15you can see it says uh nan's MacBook
- 24:17Airloc so I've already connected it
- 24:19before but I don't know what's the issue
- 24:21it's been in the loading phase for 10
- 24:22minutes so maybe I need to reconnect it
- 24:24again or maybe restart the application
- 24:26but although I'm able to connect it and
- 24:28I am able to control my Mac from my
- 24:30mobile application. So in this way you
- 24:31can also connect your also and then you
- 24:33can remotely work with that. Now the
- 24:35another option is available here which
- 24:36is git. Now you can define how your git
- 24:39repository should work in the codeex.
- 24:40Let's say codex is generating any branch
- 24:42to that repository. So you can define
- 24:44that when it generate the branch and
- 24:45what should be the name like you can
- 24:46define here that it should always start
- 24:48with the prefix which is codex. So later
- 24:50you can identify that this branch is
- 24:51generated by the codeex. And another
- 24:53thing you can define that how it should
- 24:55merge your pull request and which method
- 24:56it should use. Like by default it use
- 24:58the merge method which basically means
- 25:00that merging all the commits whatever
- 25:02the codeex had generated. But if you
- 25:03want to use the squash command also then
- 25:05you can use that also which basically
- 25:06means before merging all the commit it
- 25:09will first generate a single commit
- 25:10which is a clean commit then it will
- 25:12merge. I basically prefer the squares
- 25:13command because I don't want to make all
- 25:15the commits available in my repository
- 25:17because agents by default create
- 25:19multiple commits for each output. So I
- 25:21first prefer to create a clean commit
- 25:22over those all those commit message and
- 25:24then merge it to my repository. So based
- 25:26on your requirement you can select any
- 25:27one of the method. Now the another thing
- 25:29we can select here always force push by
- 25:31default it is disabled but you can
- 25:32enable it but you need to understand
- 25:34that it force with the lease which
- 25:35basically means that if any changes are
- 25:37already available in that repository
- 25:39then it will not forcefully push your
- 25:40changes. So it will not always uh force
- 25:42push it always force with lease. Now the
- 25:45another thing is create a draft pull
- 25:46request. So it will create a pull
- 25:48request draft. And another thing is
- 25:49review delivery. So you can just uh
- 25:51review it based on the inline and the
- 25:52detached. And the another thing is
- 25:54commit instructions and the pull request
- 25:56instructions. If you want to give any
- 25:57instruction like how the commit method
- 25:58should generate, what should be the
- 26:00format there, you can just define the
- 26:01instruction here. And same instruction
- 26:03you can define for the pull request
- 26:04also. So yeah, this is all about the git
- 26:06instructions. Now let's go to the
- 26:08another one which is environment. So
- 26:09environment if you want to define any
- 26:11environment variable to the project, you
- 26:12can just select the project here and
- 26:14give all the access to the environment
- 26:15variable to that project here. So later
- 26:17if codex are working on that particular
- 26:19project and they want to access to that
- 26:20any particular environment variable they
- 26:22can get access from there itself. Now
- 26:24the next thing is work tree. Now just
- 26:25like get work tree we have a codex work
- 26:27tree also which basically means if codex
- 26:30is working on a repository then it will
- 26:31not make changes directly to your main
- 26:33repository. Instead it will create a
- 26:35copy of that main repository and apply
- 26:37changes there. Now this is useful
- 26:38because if codex is doing any changes
- 26:40which you do not want directly on your
- 26:41main repository. Now once it get a copy
- 26:43of that repository you can just review
- 26:44all the changes and then apply in your
- 26:46main repository. Now the thing is that
- 26:48as you can see it is a work tree root
- 26:49which basically means you can define
- 26:51that where that copy repository should
- 26:53be generated at which directory. If you
- 26:54leave it as by default which basically
- 26:56means it will automatically decide at
- 26:58which path it should keep the copy of
- 26:59your repository. But if you want to
- 27:01define a particular directory let's say
- 27:02inside a user folder or inside a
- 27:04particular folder you can just define
- 27:05the path here. Now the next thing is
- 27:07that automatically delete old work
- 27:08trees. So if you don't want to keep the
- 27:09old work trees, you can just keep
- 27:11disable or enabled based on your
- 27:12requirement. And then you can also set
- 27:14the limit also like how many work trees
- 27:15it should keep. So if you select here 15
- 27:17then only the latest 15 work trees will
- 27:18be available and rest all will get
- 27:20delete automatically. So the next thing
- 27:21is archive task. So whatever the task
- 27:23you have archived you can manage it from
- 27:25here. So now let's go back to the new
- 27:26task option and assign a task to the
- 27:28codeex. So if I go back here and the new
- 27:30task let's say I want to define a task
- 27:32without any project. I don't want to
- 27:34give any project or use any existing
- 27:36project. it will be the normal task
- 27:38only. So let's say I want to build a
- 27:39normal website and want to deploy it
- 27:41within a chat juty itself. So I can just
- 27:43use a at the rate site plug-in. So as
- 27:46you know we have discussed about this
- 27:47before also using the site plug-in it
- 27:50will not only build your application but
- 27:51also create a live URL which you can
- 27:53share with others. So let's say I want
- 27:54to build a to application just a normal
- 27:56application. I'm just testing out how
- 27:58codeex will execute my task. So if I
- 28:00just write here build a todo website.
- 28:03Okay. And when I click enter it will
- 28:04start generating my website. Now before
- 28:06generating I want to show what are the
- 28:08things available in this chat. Like the
- 28:10first thing is that model. Here you can
- 28:11select that which model you should use
- 28:12here. Right now I'm able to access my
- 28:145.6 or the latest model because I'm in
- 28:17the plus plan. That's why I'm able to
- 28:18access all those latest models. I can
- 28:20define the effort also that how much
- 28:21effort it should take while executing my
- 28:23task and then the speed also like
- 28:25standard or the fast. And then we have
- 28:27the option which is approval. So by
- 28:29default it is asked for approval. That
- 28:31means if we do any changes in my
- 28:32external files or if you want to get
- 28:34access to the internet it will always
- 28:36takes my permission. But if I want to
- 28:38keep the permission only for the
- 28:39sensitive information then I can go with
- 28:40the approve for me option. But if I want
- 28:42to give full access to my codex that
- 28:44means it will not ask any question to me
- 28:45just take actions by themselves then I
- 28:47can go with the full access method also.
- 28:49But let it be asked for approval for
- 28:51now. And now let's click on the enter
- 28:52button. By the way, you can click on
- 28:54this plus icon also where you can just
- 28:56define other feature also like uh add
- 28:58other plugins or maybe you want to
- 28:59upload any files and folder from your
- 29:00system. You can upload from this plus
- 29:02icon. It will also generate the summary
- 29:03here in the sidebar. As you can see here
- 29:05the output it says create a file or site
- 29:07sources attach a file or connect tab. So
- 29:10you can see the summary also here. Uh
- 29:12now it asks me the approval. So I can
- 29:13just click on allow once. Okay. So now
- 29:15it get the network permission. Uh it
- 29:17does the thinking which is comes under
- 29:19the reasoning part. It again needs a
- 29:21permission. So I just click on allow
- 29:22once.
- 29:28By the way, if you want to see that what
- 29:30are the files it has generated and what
- 29:32are the code available in this file, you
- 29:33can just open in the VS code as you can
- 29:35see this option. So when you click on
- 29:36this it will open your entire project in
- 29:38your VS code and but if you want to see
- 29:40the folder only then you can code with
- 29:41the finder or the terminal or you want
- 29:43to select the another ID also and later
- 29:45on if any other changes it will do you
- 29:47just need to open it again in the VS
- 29:48code those later changes will also
- 29:50available in that code and at the time
- 29:52it is building the website I can also
- 29:54show you that how much token I have used
- 29:55till now as we discussed before we have
- 29:57option of using the / status command. So
- 29:59if I type here SL status when I click
- 30:01enter you can see that it shows that uh
- 30:04this is the current session which I can
- 30:06copy also and the context that I have
- 30:08only 73% left that means I have used 69
- 30:11tokens so far out of 258k tokens and
- 30:14this is my weekly limit also available
- 30:16here. So I can see the entire stats of
- 30:18my current conversation through status
- 30:19command. Okay it says that your site is
- 30:21ready. I'm publishing it privately now.
- 30:23Let's see how well it generate. I can
- 30:25review the changes also by clicking
- 30:26here. So these are all the changes it is
- 30:28doing. So it has now generated the
- 30:30website. As we can see here this is a
- 30:31website and when I click on it here it
- 30:34will open the chatgity browser in my
- 30:36codeex app itself. And this is how the
- 30:38website looks like. And at the first
- 30:39glance website is very good. It looks
- 30:41very neat and clean. Uh let's see the
- 30:43functionalities are working or not. So
- 30:45let's say if I add a new task which I
- 30:48can add from here. Uh let's say I say
- 30:50recording
- 30:52and today work personal let it be today.
- 30:55And when I click add task, okay,
- 30:58recording task is available here. So all
- 30:59the functionalities are also working. I
- 31:01can just set the status whether it is
- 31:03open or done. So if I click uh done,
- 31:05yeah, it has not changed here also. I
- 31:07can remove my task. I can clear complete
- 31:09task like this. So perfect. I just want
- 31:11to open this on the chrome browser also
- 31:13to see how the things work there also.
- 31:15Although it will remain same exactly
- 31:17like this. But let's see how it will
- 31:19look in the chrome. So just copy this
- 31:21URL and let's go to the chrome. Okay.
- 31:24Here I need to first login with the chat
- 31:25GPD to access my website. Okay. So it
- 31:28requires some steps. Let leave it for
- 31:30now. We can review it from here itself
- 31:32only because it will look same like that
- 31:34in the browser also. So if I just expand
- 31:36it a little bit more, it is responsive.
- 31:38That's a good part. Perfect. That's what
- 31:40I want to show you that if you use a
- 31:42site plug-in then it not only build a
- 31:44website but it also generate the URL
- 31:45which you can share with others also.
- 31:47Now you can just define the project also
- 31:49where you can work on your existing
- 31:50project. You can work with your GitHub
- 31:52repository and all the things in this
- 31:53codeex app. Now let's see how we can
- 31:55open any application through codeex app
- 31:56itself using the plug-in that we have
- 31:58discussed before which is computer use
- 32:00plug-in. So if I open the new task here
- 32:02I can just type at the rate and when I
- 32:04type it will list all the plugins that I
- 32:06have installed. So I'll just write here
- 32:08the name of the plug-in which I want to
- 32:09use which is computer and I click enter.
- 32:12So this is the plug-in I want to use.
- 32:13I'll just write here let's say open
- 32:15calculator. And when I click enter, it
- 32:17will do planning. It says that I'm using
- 32:19the computer user skill here since you
- 32:22ask for the computer plug-in directly.
- 32:23And I opening the instructions before I
- 32:25operate the app. And let's see whether
- 32:27it will open my calculator app or not.
- 32:28Okay. So it's now need my permission. So
- 32:30I just say allow this conversation. And
- 32:32as you can see here it says calculator
- 32:34is open. And we are able to see the
- 32:35calculator here. So it has opened the
- 32:37calculator and we are now able to use
- 32:38it. So in this way you can open the any
- 32:40application in your Mac if you have used
- 32:41the computer any plug-in because you
- 32:43have given the entire control to this
- 32:45Mac. Now the another plug-in is also
- 32:46available. If I click on add the rate
- 32:48and then let's say if I use the browser
- 32:50plug-in or maybe the GitHub plug-in for
- 32:52the GitHub repository. So and the site
- 32:55plugin we have already seen. Let's say
- 32:56if I use the browser and let's say if I
- 32:59want to ask any questions. So I just
- 33:01click on the try now that's for the by
- 33:02default question. It says I test my
- 33:04check out flow on local host and when I
- 33:06click enter it will open and run the
- 33:08things in my local host browser which is
- 33:10the chat gypy browser itself. As you can
- 33:12see, it says I'm going to use the inapp
- 33:14browser tooling to exercise your local
- 33:15host checkout flow. And this is how this
- 33:17uh pet actually works. It will show you
- 33:19the information of the current thing
- 33:20that is running on your codeex app.
- 33:22Okay, it will take time to check out my
- 33:24flow and the local host. But the thing
- 33:26is that I want to explain you how you
- 33:27can use the different plugins for to
- 33:29work on that particular tool. Okay, it
- 33:30needs my approval. So I just click on
- 33:32allowance again. I click on allowance.
- 33:34Uh click on allowance again.
- 33:37Allowance.
- 33:39Okay, I think it will take some time to
- 33:41review the things and uh to check out my
- 33:43flow on local host. But the thing is
- 33:45that I want to just show you that how
- 33:46you can use the different plugins and
- 33:48access the particular tool from the
- 33:49codeex only. So that's all the overview
- 33:51of the Codex app. I hope you understand
- 33:52how the things work here. Install using
- 33:54it on your system and start using it and
- 33:56then see how it's work for you.
- 33:59So now let's see how we can use Codex on
- 34:01the web. Every feature will remain same
- 34:03exactly like we have seen in the Codex
- 34:05app. Only the thing is that you do not
- 34:06have to install an app to use Codex. So
- 34:08if you want to use it on the web just go
- 34:10to the chat GPD website and here you
- 34:11will see two option first one is chat
- 34:13and the second one is work. So if you
- 34:15want to do the normal chat GBD work you
- 34:17can do it in the chat option but if you
- 34:18want to assign a task to codeex then you
- 34:20can switch to work option and here you
- 34:22will see all the features like you can
- 34:23choose a project add a plugins and even
- 34:25you can open the desktop app from here
- 34:27itself and when I open the sidebar we
- 34:29are able to schedule the task from the
- 34:31schedule option from codex web itself
- 34:33and we are able to manage all the
- 34:35plugins and when I click on the more
- 34:36option site option is also available
- 34:38there that means we are able to build
- 34:40and deploy the website from codex web
- 34:41itself. Now you just need to make sure
- 34:43one thing that if you want to use the
- 34:44codex web then you must have at least a
- 34:46subscription plan because on free plan
- 34:48this will not work. So just to show you
- 34:50if I open my chat GP on free plan then
- 34:52you can see that chat and work option is
- 34:54not there and we can see here also that
- 34:56we are in the free plan and even if I
- 34:58open the sidebar that schedule option is
- 35:00not there as well as if I open the more
- 35:02that site option is also not there. It
- 35:04shows me the codeex option. So if I open
- 35:06this one, so you can see here instead of
- 35:08opening the codex web, it will redirect
- 35:10me to download the codex app because on
- 35:11free plan we cannot use it. So we need
- 35:13to keep in mind if you want to use codex
- 35:15web. Now if you go back to WordPress
- 35:16plan, then here let's say if I want to
- 35:18use a GitHub plug-in to review the
- 35:20changes in my repository. So I can just
- 35:23use here at the rate and call my GitHub
- 35:25plug-in and there I can give the task
- 35:27whatever I want to use for my
- 35:29repository. But you need to make sure
- 35:30that your GitHub account is connected to
- 35:31Codex then only it will access all your
- 35:33repository. So to make sure just go to
- 35:35your profile and open the settings and
- 35:37here you can go to the plugins and in
- 35:40the GitHub you can see that my GitHub
- 35:42account is already connected with codeex
- 35:44and if you click on this three dot it
- 35:46will shows that a reconnect and
- 35:47disconnect option this will only show if
- 35:49you have already connected your GitHub
- 35:50account and here also we can see that
- 35:52this GitHub plug-in contains some skills
- 35:53like review follow-up CI debug GitHub
- 35:56and publish changes although we will
- 35:57understand about this skills when we
- 35:59understand codeex in ID extension we'll
- 36:01create our own skills and understand it
- 36:03in detail. But just now understand that
- 36:05this plug-in contains some skills and
- 36:07based on your task it will decide that
- 36:09what skill it should use. Now when codex
- 36:11take action based on your task it will
- 36:13also look at the skills and whatever the
- 36:15skills is required at that time it will
- 36:17use that skill to execute the task. So
- 36:19if I go back here I can use the githup
- 36:21plug-in as well as any other plug-in if
- 36:23I want to use and I can assign the task
- 36:25to my codex from the web itself. So yeah
- 36:27this is all how you can use a codex on
- 36:28web. Again just make sure you have a
- 36:30subscription plan if you want to use
- 36:31codex on the web.
- 36:34So now let's see how we can use codeex
- 36:36inside your terminal which runs on your
- 36:38local machine. So whenever you want to
- 36:40use codex with just commands only then
- 36:42you can use codex cla instead of codex
- 36:45app and web. So to install codex cla on
- 36:47your local machine just go to the
- 36:49website which is again
- 36:49chajjypy.com/codex
- 36:52and here when you scroll down all the
- 36:53way down here you will find a way codex
- 36:57cla. So you can copy this command which
- 36:59just start with npm and then run this
- 37:01command on your terminal to install the
- 37:03codec cla but there are other option
- 37:05also available. If you don't want to
- 37:06install it with npm then you can go to
- 37:08the codec cla docs this one and here
- 37:11when you go to the available on section
- 37:13then you will find a codec cla option
- 37:15you can click on this and here multiple
- 37:17options available to download it. You
- 37:19can go with the Mac OS or Linux option
- 37:21or Windows npm or homebrew option. But
- 37:23if you are using the npm version then
- 37:25you need to make sure that NodeJS is
- 37:27installed in your system otherwise this
- 37:29npm will not work. By the way if you
- 37:31want to verify whether NodeJS is
- 37:32installed or not on your system then you
- 37:34can just open the terminal and here you
- 37:36can type node - version and when you
- 37:40click enter it will show you the
- 37:41version. If you are able to see this
- 37:43version on your system that means NodeJS
- 37:45is installed. If not then you need to
- 37:47install it first to use the npmware. So
- 37:49we can copy any one of the command from
- 37:50here and then we can install codeex cla
- 37:53but what I can do instead of installing
- 37:55it from here I'll install it from the
- 37:57change log because there we'll get the
- 37:59latest version of the codec cla. So I'll
- 38:01just open codeex change log and uh this
- 38:06one and here you can see we have all the
- 38:08updates. So I would also recommend you
- 38:10to always prefer to go with the codec
- 38:12change log because here you will get to
- 38:13know what is the new version is coming
- 38:15from the codec cla and all and based on
- 38:17that you can download it. So you can
- 38:19copy one of these command from here. As
- 38:20you can see in July 2026 they have
- 38:22launched a new update which is a codeex
- 38:25version 0.144.5.
- 38:28Even though the in July itself they have
- 38:29launched the different version which is
- 38:310.144.4
- 38:33but now it's different. So keep an eye
- 38:35on this and based on this only you have
- 38:36to install the version. But now I've
- 38:38already installed this uh this
- 38:40particular command 0.144.4.
- 38:43So I'll not going to install again for
- 38:45you. Even though I'll just show you how
- 38:46we can install just copy this command.
- 38:48Then again open your terminal and here
- 38:50just paste it. And the moment you paste
- 38:53it and click enter it will install on
- 38:55your system. And now once you install
- 38:57the next step is you need to use it in
- 39:00your terminal. But now how to use it?
- 39:02It's very simple. What you need to do
- 39:04whenever you want to use codex in your
- 39:06system inside your directory let's say
- 39:07inside your project or inside your
- 39:09repository you just go to your directory
- 39:11and then just type here codeex and when
- 39:14you type and click enter you are ready
- 39:17to use codeex you can see here it tells
- 39:20me to update the version as I show you
- 39:22here that uh as we can see here again
- 39:24the latest version is 0.144.5
- 39:27but before recording this video I have
- 39:28installed the 0.144.4
- 39:304 that's why it gives me an update. So
- 39:33if you have already installed then later
- 39:34on they will automatically lets you know
- 39:36that what's the latest version is coming
- 39:38right now. So you can update from your
- 39:40terminal itself only. But right now I
- 39:42don't want to update the latest version.
- 39:43Let's skip for now. And so I'll just
- 39:45click on this escape. Now see when you
- 39:47open the codex for the first time in
- 39:48your terminal it will ask you to sign
- 39:50in. Now there are three ways of signing.
- 39:52You can go with chatg or you can connect
- 39:54to another device with one time code or
- 39:56you can uh use your own API key. So I
- 39:59would prefer to go with the sign in with
- 40:00chargibility because I already have a
- 40:02plan here which is a plus plan. But if
- 40:04you are exploring a charge for the first
- 40:06time and you want to only pay for the
- 40:08money which based on how much token you
- 40:10have used then you can go with your API
- 40:12key method but let's go with the sign in
- 40:14with chubby for now. So I'll just click
- 40:16enter and when I click enter it will
- 40:18redirect me to the chat GPT. Here I have
- 40:20an option to use it. So I don't want to
- 40:23login in chat juby through this account.
- 40:25So I'll go with the account where I have
- 40:26a plus plan. So I'll just open this my
- 40:29account and here I'll just use my
- 40:32continue with Google and it says
- 40:34continue and we are signed into the
- 40:35codeex. Now we can close this window and
- 40:38here we can close this one also and now
- 40:40when we go to the terminal it says that
- 40:42you have signed in successfully and you
- 40:43can say that before you start uh decide
- 40:45how much autonomy you want codex can
- 40:47mistake. Okay these are the things no
- 40:49worries just click on this enter now and
- 40:51now once you click enter you can see we
- 40:52have a terminal UI. Now this is the
- 40:54place where you start using codex. So
- 40:56let me increase the size of the terminal
- 40:58to the full like this. And now if you
- 41:00want to use the codeex you are now ready
- 41:02to use it. Whatever the command,
- 41:04whatever the task you want to give, you
- 41:05can give it from the terminal itself.
- 41:07Now before we start discussing about
- 41:09more concepts in Codex CLI, let's talk
- 41:12about the safety and security also
- 41:14because right now you are using codeex
- 41:15cla inside your system only. So you may
- 41:18have concerned that what if I run any
- 41:20command which can access my local files
- 41:22or which can change my system
- 41:24configuration or can access my app in my
- 41:26system. We have these concerns. See the
- 41:29thing is that basically chat GPD or I
- 41:31can say that codeex takes care of this.
- 41:33How it will take care? So whenever you
- 41:35run codeex cla inside any project they
- 41:38make sure that it can go only access the
- 41:40things inside that project only. If you
- 41:43want to take access to the outside of
- 41:44project with the command then it needs
- 41:46to first take access from you that means
- 41:48approval from you. Now basically codex
- 41:50uses sandbox environment which basically
- 41:53decides some rules and policies that
- 41:55what are the things it should access
- 41:56inside that project and if you want to
- 41:58access anything outside then how much
- 42:00permission we should give it. All those
- 42:02things rules are decided inside the
- 42:04sandbox and that sandbox create a
- 42:06isolated environment inside your
- 42:08project. So each time you use codex
- 42:10inside any project that project is an
- 42:12isolated environment. So your codeex
- 42:14cannot access something which is outside
- 42:16of that project. Now this is not only
- 42:19managed in the codex level itself only.
- 42:22Your OS also takes care of this. So
- 42:24whatever the policies your codeex decide
- 42:27using sandbox environment all those
- 42:29policies are transferred to your
- 42:30operating system also. Whatever you are
- 42:32using Mac OS, Ubuntu or Window it will
- 42:36get transferred there and then operating
- 42:38system has their own tools like if you
- 42:40talk about the Mac OS they have a tool
- 42:42which is seat belt. So based on those
- 42:44tools it will make sure that whatever
- 42:46the policies the codex define inside the
- 42:48sandbox environment based on those
- 42:50policies only the codex are allowed to
- 42:52access the project or access the other
- 42:55things in your system. So this is how
- 42:57codex actually manage. Now these are the
- 42:58by default settings which is configured
- 43:00by the codeex but if you want to change
- 43:02the settings based on your requirement
- 43:04you are able to do that because they
- 43:06have their own configuration system
- 43:07where you can manipulate the things. Now
- 43:09if you remember that we have seen in the
- 43:11codex app also let me open it for you.
- 43:13If you can see here in the codex app
- 43:15when we go to the settings we have seen
- 43:17this a configuration option inside our
- 43:19personal section. So when you open this
- 43:20configuration you can see there are some
- 43:23by default settings available. As you
- 43:24can see we have an approval policy which
- 43:26is an on request. So by default it is an
- 43:29approval means if you want to take
- 43:31access of something which is outside of
- 43:33your project it will first take an
- 43:34approval from you. So we have by default
- 43:36settings set like this and we have a
- 43:37sandbox setting also like read only
- 43:40workspace write full access and same for
- 43:42the model feature as well as workspace
- 43:44dependency. So inside our app we can
- 43:46manipulate this configuration setting
- 43:48but the thing is that right now we are
- 43:50inside our codeex cla we don't have any
- 43:52user interface where we can go to this
- 43:53particular option and click on this
- 43:55particular button to change the setting.
- 43:57So how we can change it in the codeex
- 43:58cla we can change it by creating our own
- 44:01configuration file. So in codeex when
- 44:03you install it for the first time let's
- 44:04say we are using the codeex cla. So when
- 44:06you install it it will generate a system
- 44:08generated file for you inside your user
- 44:10directory or we can say that the home
- 44:12directory with the name dotcodex. So I
- 44:15can show you now. So let me open this
- 44:17finder. If you in the window then you
- 44:19can open your file explorer. So when you
- 44:21go to your home directory you can see
- 44:22these are all the folders available
- 44:24here. Now in this same home directory
- 44:27the codex folder is also being generated
- 44:29by the codeex itself but it is not
- 44:31visible like this because that's an
- 44:32hidden folder. So to see that folder
- 44:34what you can do in my quest there is a
- 44:36shortcut command which you can use
- 44:38command shift and period and when you
- 44:40enter you can see we have all the hidden
- 44:41files that are available in this home
- 44:43directory. So when you scroll down so
- 44:45you can see in this case we have this
- 44:47dotcodex file or we can say that folder
- 44:49same like that we have a dot cloud also
- 44:51because I have used the cloud code also
- 44:52before in my system that's why we have
- 44:54system generated cloud folder but if you
- 44:56look at this dotcodex folder then in
- 44:58this folder we have to create our own
- 45:00config.tml file as you can see here this
- 45:02config file is already available but in
- 45:05your case it will not available because
- 45:06I have already created before that's why
- 45:08it is showing here. I'll show you how
- 45:09you can create your own config.l file
- 45:11and how you can manipulate the settings
- 45:13there. So once you see this folder which
- 45:14is a codex folder you can go to the
- 45:16terminal inside this folder and you can
- 45:19create this file which is config.toml
- 45:21file. So what we can do uh we can open
- 45:23this folder by clicking on the right
- 45:25click and we can say that new terminal
- 45:26at folder terminal has been opened. We
- 45:29can just also check whether we are in
- 45:30the correct folder or not. So when I
- 45:31click ls we can see all the files that
- 45:33are available inside that codex folder.
- 45:36Now if I want to create my config
- 45:37dottoml file so what I can do I can just
- 45:40write here command which is touch this
- 45:41is a shell command so I can write here
- 45:43touch and then the name of my file which
- 45:45is config dottoml and when I click enter
- 45:48it will create my file. I'll not create
- 45:50it right now because it is already
- 45:51available on my system. So once you
- 45:53create it you can just go with ls
- 45:55command to see whether it is available
- 45:56or not. So when you click uh you are
- 45:58able to see this type of file in your
- 46:00system. Now once you create this file
- 46:02you can open it and do the changes
- 46:03there. So what we can do here uh we can
- 46:06open this file in our VS code and see
- 46:09what the things available here. So we
- 46:11have this VS code and we can see this is
- 46:14how file looks like. As you can now see
- 46:16here in this file there are some
- 46:17predefined settings available. As you
- 46:19can see we have a model which is a GBD
- 46:215.4. Now if you remember in terminal uh
- 46:24if you open this terminal here you can
- 46:26see when we start codex and when the
- 46:28terminal UI starts you can see it says
- 46:30that by default GBD model is 5.4 4 with
- 46:33the reasoning effort medium. We have not
- 46:35set this model. It is by default model
- 46:37and it also shows the directory that you
- 46:38are using it in the user directory right
- 46:40now. So how this model is set by by
- 46:42default it is set because it is already
- 46:45configured in our config.toml file. But
- 46:48if you want to use some other model as a
- 46:50by default model you can just change it
- 46:52in your config.tml file and also you can
- 46:54define the reasoning effort and same
- 46:56like that there are some other settings
- 46:57also available. You can read all those
- 46:59settings and get to know what are the
- 47:00things available inside config.tml toml
- 47:02file. Now I want to show you more things
- 47:03about this. Uh as you can as I told you
- 47:05before that you can change the sandbox
- 47:06setting also right that we have seen in
- 47:08the codex app also that read only or
- 47:10write workspace only. You can change all
- 47:12those settings here. Now one doubt may
- 47:15come in your mind that why we have to
- 47:17create this file that when we have
- 47:18create this file this entire
- 47:21configuration will be applicable to all
- 47:22the folders. Why? Because we have
- 47:24created this file inside our codeex
- 47:26folder which is in home directory. So
- 47:28every folder comes under that home
- 47:30directory only. So these entire settings
- 47:32will available in all the projects
- 47:34wherever you are going to use codeex.
- 47:35But you don't want this. You don't want
- 47:37that why in every project a same model
- 47:39should get used and the same settings
- 47:41should get used. I have I want my
- 47:43different settings for each project.
- 47:44Right? And that's true. You want that.
- 47:46So what you can do if you want a
- 47:48different settings inside your project,
- 47:50you can create your own config.l file
- 47:52there inside that project itself. And
- 47:54next time when use codex inside that
- 47:56project, it will override your settings
- 47:58whatever you have defined in your global
- 47:59codex folder which we have seen in this
- 48:01one in home directory. But you need to
- 48:03make one thing sure that if you're using
- 48:05inside your project as a different
- 48:07config.l file then you have to trust
- 48:09that folder inside your global file. As
- 48:11you can see here these are all the
- 48:13folders which I have already granted in
- 48:15my config.l file. So if I want to use
- 48:17codex inside this folder and want to
- 48:19create a separate configuration there
- 48:21then I have to first trust that folder
- 48:23otherwise those configuration will
- 48:25totally get ignored by codeex even
- 48:27though you have created inside your
- 48:29project. As you can see we have this
- 48:30project and we have set the property
- 48:32which is trust level with trusted here.
- 48:34So you can set your project if you want
- 48:36to use your own configuration inside
- 48:38your project. Okay. Now once we have
- 48:39seen this let's try it out also. So we
- 48:42have this GBD 5.4 and medium. So right
- 48:44now we are using codex inside our own
- 48:46terminal in our local system. But we can
- 48:48use it in the VS code terminal also
- 48:49because both are same. So I can now just
- 48:52run codeex inside this terminal. I'll
- 48:54just write here codex and when I click
- 48:56enter it will start using codex here. I
- 48:58just need to skip because I don't want
- 48:59to install the latest version. And my
- 49:01codex is started. Okay. Now for the
- 49:03better view I would like to keep this
- 49:04terminal in the side instead of bottom.
- 49:06So I just change the setting here.
- 49:08Appearance we have option I think. So
- 49:11here panel position. Yes. we go to the
- 49:14right side. Okay. Now we can see codeex
- 49:16how it actually works here better. So we
- 49:18have this terminal and we can see it is
- 49:20using GPD 5.4 media version. But now
- 49:23let's say if I change this model here uh
- 49:25let's say if I change to GPD 5.4 U mini
- 49:29this one. And even if I change the
- 49:31reasoning of it let's say from medium to
- 49:33I want it let's say high or high doesn't
- 49:36make sense here because we're using the
- 49:375.4 mini. So I think fast makes sense
- 49:39here. Fast. And when I say save this
- 49:42time, let me exit from my codeex, I'll
- 49:45use the command which is exit. And now
- 49:47when I start my codeex again by writing
- 49:49the command which is codeex enter and
- 49:53again skip. Now this time you can see
- 49:55the by default model it is using is gpt
- 49:585.4 mini with the reasoning effort as
- 50:00fast. So in this way you can define your
- 50:02own by default settings in the
- 50:04config.tml file. Now let's see one more
- 50:06thing in the security setting. Let's say
- 50:08you are working in your project and you
- 50:10want that when you are using some
- 50:12command to give some task to the codeex
- 50:14you want that that particular task
- 50:16should use a different model because you
- 50:18don't want to waste your token let's say
- 50:20you only want to change the variable
- 50:21name inside that project now just to
- 50:23change that variable name in your
- 50:24project would you use your high model
- 50:26which takes a long token let's say zt
- 50:285.5 or 5.6 Of course not. You will not
- 50:31use those model because you are just
- 50:32changing your file name. So in that case
- 50:34you can create a different profile in
- 50:36your configuration settings and whenever
- 50:38you feel like that this task requires a
- 50:40less token and less reasoning effort you
- 50:42can switch to that particular profile
- 50:44and assign that model to that particular
- 50:46task. Now how to create this profile? So
- 50:48to create that you can go to the
- 50:50terminal again uh this terminal here we
- 50:53have we are already inside our codeex
- 50:55folder. So if you want to create a
- 50:57profile, let's say I want to create a
- 50:59profile for a fast model. So those type
- 51:01of task which requires a low reasoning
- 51:03effort, I can choose that particular
- 51:04profile. So I just create the file name
- 51:06by using the command touch and then I
- 51:08can just write here fast or whatever the
- 51:10name suits for you based on your
- 51:12requirement. I'm using a fast because
- 51:14I'm creating a low reasoning effort
- 51:15model. So I'm just write here fast then
- 51:18dotconfig dot toml. Once you write this
- 51:21name and click enter, your file will
- 51:23generated inside that codeex folder. So
- 51:26I'll show you here now if you go down uh
- 51:29that folder should available here I
- 51:30think so codex this one when you go down
- 51:34yes we have our fast doconfig file now
- 51:37let's open this file inside our VS code
- 51:38and see what things available here so
- 51:40when we click enter so we can see that
- 51:42it's completely empty but if you look at
- 51:44the config file then it has some
- 51:45predefined settings because this is the
- 51:47main file and this is the file which we
- 51:49have created it's a custom file so we
- 51:50have to define all the rules by ourself
- 51:52here so now in this fastconfig file If I
- 51:55want to use the low reasoning model,
- 51:57I'll just define a model or instead of
- 51:59defining here, I'll just copy it from my
- 52:00config.ml and then I only change the
- 52:02model name and the reasoning effort. So
- 52:04I'll just copy this and paste it here.
- 52:07Now let's say I want to use a model 5.4
- 52:10mini here only for the low reasoning
- 52:11effort and I'll go with let's say I want
- 52:15it to use uh medium. Okay. And now in
- 52:19the config.ml file I'll change it to the
- 52:22previous setting where it automatically
- 52:24use 5.4 with medium or let's say I want
- 52:27to use high this one. Okay. So now we
- 52:30have two profile. First one is the
- 52:31normal which is a main file config.l and
- 52:34second one is created by us which is a
- 52:36fast.config.l.
- 52:37Now if I want to use this profile to
- 52:39delegate the task to that particular
- 52:41model. So we just write here codex then
- 52:44hyphen and then profile because we have
- 52:46created our own profile. Now whenever we
- 52:48write like hyphen profile or some other
- 52:51name after hyphen we basically call it
- 52:53as flex in codex. So there are different
- 52:55flags available in codeex based on that
- 52:57you can decide that what particular task
- 52:59should do codex. Right now I want to use
- 53:01my profile flag that's why I use a
- 53:03double hyphen and then the name which is
- 53:05profile. And now I can just give the
- 53:06name of my file which is fast. So I'll
- 53:09just write here fast. And then I can
- 53:12delegate any task to it. Let's say I
- 53:14want to say uh what's available in this
- 53:16file. So I'll just say what is available
- 53:19or instead of this I can just write here
- 53:21what this file contains and now when I
- 53:25click enter it starts working and uh it
- 53:29want to use so I will say allow as you
- 53:30can see this it asked me for the allow
- 53:32because we have discussed about the
- 53:34safety purpose also that uh it uses some
- 53:36by default settings because of that only
- 53:38it asks our approval because it is
- 53:40accessing our file which is
- 53:41fast.config.tml to read the content
- 53:44inside this. So that is what we discuss
- 53:46about the safety purpose. So now you can
- 53:48see this it says it using the GP 5.4
- 53:50mini and with the medium reasoning
- 53:52effort and I think we are able to see
- 53:54that also that which model it has used
- 53:56while doing all this effort. Uh I think
- 54:00we are able to see that okay we are not
- 54:02able to see but we are able to see that
- 54:03we use the so with profile test the main
- 54:05change is that your base default is GBD
- 54:075.4 with high reasoning are overridden
- 54:10at GBD 5.4 for mini with medium
- 54:12reasoning because we are using our flag
- 54:13which is profile. So in this way you can
- 54:15create multiple flags or multiple
- 54:18profiles and you can delegate the task
- 54:20based on how much reasoning if it
- 54:21requires. So that's all about the
- 54:23settings. Now let me show you one more
- 54:24thing about the safety that how it
- 54:26actually ask for our approval when it is
- 54:28accessing something outside of our
- 54:30project. So if I go back to the terminal
- 54:32and here so let's say if I ask that open
- 54:34a particular app from the terminal. So
- 54:37let's say if I say uh open calculator
- 54:40now you already know that this is
- 54:42outside of the project task. So when I
- 54:44say enter it will definitely ask for my
- 54:46approval because that's a by default
- 54:47settings in our sandbox environment. So
- 54:50yeah you can see it says that would you
- 54:51like to run the following command. If I
- 54:53granted yes then it will open the
- 54:55calculator and if I deny then it will
- 54:57not open. So I'll just say yes for now
- 54:59and it says calculator open. So let's
- 55:01see whether it has opened or not. So if
- 55:03I just minimize this. So yes, we are
- 55:05able to see the calculator here and this
- 55:07is our own system calculator not a
- 55:09calculator which is generated by codeex
- 55:11and all our own Mac OS calculator here.
- 55:13So in this way you can grant the
- 55:15permission if you want to accessing
- 55:17something which is outside of your
- 55:18project and you can change the setting
- 55:20also which we have seen in the config.l
- 55:22file. So that's all about safety and the
- 55:24security settings.
- 55:27So now let's see one of the most
- 55:28important thing in codex cla which is
- 55:31commands or basically we can call it as
- 55:33/ commands. Now we are not using a codex
- 55:35web or app where you can do everything
- 55:37from the buttons and all everything is
- 55:39running in your terminal. So only the
- 55:41command is the option to work with codex
- 55:43cla. Now if you remember that in
- 55:45previous videos we have talked about one
- 55:47of the command which is a / status
- 55:48command through which you can see how
- 55:50much token usage you have used and how
- 55:52much weekly limit is left. So how that
- 55:54command is actually working that's
- 55:56actually a slash command and same like
- 55:58that there are other commands also
- 56:00available in codex cla which we are
- 56:01going to see now. So if you want to use
- 56:03any of the command you just type a slash
- 56:06and when you type slash it will give you
- 56:08the list of all the slash commands that
- 56:09are available in codex. So we can just
- 56:12move down here we have model fast ID. So
- 56:15we'll discuss some of them which is
- 56:16useful. Uh so we can see we have
- 56:18permission key map vim experimental
- 56:20approve memories skills and lot more. So
- 56:24let's discuss the first one. Suppose we
- 56:26are using the /model layer and if I want
- 56:28to change the model as we can see right
- 56:30now currently it is using the GP 5.4
- 56:32with medium effort. If I want to change
- 56:34the model to something else with some
- 56:36different reasoning effort I can just
- 56:38use the command which is /mod and when I
- 56:40click enter it will ask me that which
- 56:42model would you like to use and it also
- 56:44give me the information that currently
- 56:45you are using the GPD 5.4. As we can see
- 56:48this is a current model and this is the
- 56:50default model which is GPD 5.6. So if I
- 56:53want to change, let's say I want to go
- 56:54with GPD 5.6, I just click enter. I can
- 56:58decide the reasoning effort whether low,
- 56:59medium, high. I'll go with higher. And
- 57:02when I click enter, my model has
- 57:04changed. And now currently it is using
- 57:06GPD 5.6 Luna. Now this is the one
- 57:09command. Let's use another one also.
- 57:11Suppose if I want to increase the speed
- 57:13of my model, I want to use the /fast
- 57:16command here to increase the speed to
- 57:181.5x. I can use here. But you need to
- 57:20also make sure that it will use more
- 57:22tokens compared to the previous model.
- 57:24So if you want a task which requires a
- 57:26fast and you want to complete it as soon
- 57:28as possible, you can switch to the /fast
- 57:30command. Now the another one is / id.
- 57:33When you use this command, your current
- 57:35session whatever you are running in
- 57:36codex cli will transfer to your codeex
- 57:38ID. We have not discussed about the
- 57:40codex ID section yet. But if you use the
- 57:42codex ID extension in VS code, then your
- 57:44current session and the chat will get
- 57:46transferred to that ID. Now the next
- 57:47thing is the permission. Now this is an
- 57:49important one because if you remember
- 57:51that when we talk about the safety in
- 57:52sandbox environment it always asks our
- 57:55approval when we are trying to access
- 57:57something which is outside of your
- 57:58project right so if you want to change
- 58:00the setting you can change it from the /
- 58:02command itself you can just use the /
- 58:04permission here and when you click enter
- 58:06it will ask you for three ways of using
- 58:08it either you can give it as ask for
- 58:10approval which is the default one but if
- 58:11you want to approve for the things which
- 58:13is sensitive only then you can go with
- 58:15the second option which is approve for
- 58:16me and if you want to get the full
- 58:18access to the codex you trust the codeex
- 58:19a lot you can just go with the third
- 58:21option which is full access and based on
- 58:23your requirement you can switch between
- 58:25them but I would like to keep it as ask
- 58:27for approval because I don't want to
- 58:28access any external files apart from
- 58:31this project so I'll keep it as ask for
- 58:33approval so every time it will ask for
- 58:35my approval now the next thing you can
- 58:37see here uh is we have approve which is
- 58:40exactly work same like this permission
- 58:42we have memories skills we'll discuss
- 58:44about skills later uh hooks review
- 58:47rename name new archive delete resume.
- 58:51Okay, let's talk about the resume
- 58:52command also. Now what does the resume
- 58:53command actually mean? Suppose you are
- 58:55using the codeex cli and you are working
- 58:56in any chat and now let's say you get
- 58:58exit and next day you come back again to
- 59:00the codex cli and you want to continue
- 59:02with the same chat you can continue it
- 59:04with the / resume command. So if I type
- 59:06here / resume and when I click enter it
- 59:09will say these are all your current chat
- 59:11that you are using. As you can remember
- 59:13that we are using it from the VS code
- 59:14terminal. This was the last one which we
- 59:16have used which is the open calculator
- 59:18and then we have before that we have
- 59:19used the codex profile for fast where we
- 59:22have write the content which is what
- 59:24this file contain and this previous one
- 59:26we have used without question mark. So
- 59:28all those chat you are able to see here
- 59:30with the time stamp also that when was
- 59:31the last time you have used it. You can
- 59:33switch between them and continue task
- 59:35from there itself. Okay. So with the /
- 59:37resume command you are able to do this.
- 59:39Now let's escape from here and let's see
- 59:42the another thing. Suppose if we look at
- 59:44the command which is uh let's say we
- 59:47want to use a command delete. You can
- 59:48delete the particular session. If you
- 59:50use a command delete here it will ask me
- 59:51that whether you want to keep the
- 59:53session or you want to delete and exit.
- 59:54So if you want to permanently delete you
- 59:56can use a/delete command. Now escape
- 59:58from there also I don't want to delete
- 59:59my session. Now another thing is the sub
- 1:00:01agent personality exit. Yeah this exit
- 1:00:04one is also useful. So if you want to
- 1:00:06exit from the codeex you can just type
- 1:00:07here exit and when you click enter. We
- 1:00:10have seen this in the VS code terminal
- 1:00:11also. But if you want to exit, you can
- 1:00:12just write here exit and it will make
- 1:00:15you out from your codeex cla and you can
- 1:00:17start it again by using the codeex again
- 1:00:19here and skip and our codeex will start
- 1:00:21again. Now let's look at one of the most
- 1:00:23important command which is a /init. So
- 1:00:25when you type /init command you can read
- 1:00:27the description what it says. It says
- 1:00:29that it will create an agent.md file
- 1:00:31with instruction for codex. But now what
- 1:00:34is agents.md file? We have not discussed
- 1:00:36about this anywhere in our project and
- 1:00:38it's very important file in codeex but
- 1:00:40we will not discuss about this
- 1:00:41agents.mmd file for now because I want
- 1:00:43to create a separate section for
- 1:00:44agents.md file. So when we start
- 1:00:46building a project using the codeex cla
- 1:00:49we'll discuss about the agents.md file
- 1:00:51in detail but just for now you just
- 1:00:53understand that when you use the /init
- 1:00:55command it will create agents.md file
- 1:00:57with some scaffold content inside it.
- 1:00:59Scaffold basically means by default
- 1:01:01content some rules available there. what
- 1:01:03are all those rules that we'll discuss
- 1:01:05about this and all those rules will be
- 1:01:07available in the form of markdown. So
- 1:01:09we'll see how all those things are
- 1:01:10actually work when we build our own
- 1:01:12project and there we'll create our own
- 1:01:13agents file. So these are all the SL
- 1:01:15commands. You can use any one of them
- 1:01:17based on your requirement and you can
- 1:01:19explore also by using the slash command.
- 1:01:20Now the another one you can use here is
- 1:01:22a / logout. So if you want to login with
- 1:01:24some another thing let's say you want to
- 1:01:26go with the API key now or maybe you
- 1:01:27want to connect with a different device
- 1:01:28you can use a / log out here and when I
- 1:01:31say / logout and click enter uh it will
- 1:01:33loged out me from my current chat GPD
- 1:01:35account and now if I want to see it
- 1:01:37again whether we have logged out or not
- 1:01:39so I can just write a codeex and when I
- 1:01:40click enter let's skip for now again and
- 1:01:43again it will ask me for authentication
- 1:01:44again I can go with a chatg or device
- 1:01:47code or provide my own API key to
- 1:01:49authenticate again with my codeex cla
- 1:01:52command explore by yourself also. Just
- 1:01:54type the slash here and see all the list
- 1:01:56of the codecs and based on your
- 1:01:57requirement you can use any one of them.
- 1:02:01Now imagine you have a set up a CI
- 1:02:02pipeline and every time it gets
- 1:02:04triggered your codeex start working
- 1:02:06inside it. It will review the changes,
- 1:02:08it will apply the fixes and it will push
- 1:02:10them all back automatically. Now this
- 1:02:13only possible through codec cla because
- 1:02:15you know that CI pipeline only works
- 1:02:17with commands not with the user
- 1:02:18interfaces. Now there's one command
- 1:02:21which is provided by codeex which lets
- 1:02:23you integrate all these things inside
- 1:02:25your CI pipeline and not only in the CI
- 1:02:28pipeline but all the environment which
- 1:02:30only works in headless and
- 1:02:31non-interactive mode. So if you want to
- 1:02:34see that command let's open the terminal
- 1:02:36and here let me first call my codeex to
- 1:02:39use it. So I'll just write here codeex
- 1:02:41uh let's skip and now we are inside the
- 1:02:43codeex. So if you want to use that
- 1:02:45command to execute it automatically. I
- 1:02:47can use the command which is codeex then
- 1:02:50xc. This is the exact command which we
- 1:02:52need to use to automate our task. Now we
- 1:02:54can use the alias also. So if you don't
- 1:02:56want to write xc we can write e also
- 1:02:58like this. But let's go with the xc for
- 1:03:00now. And here you can give the task. Now
- 1:03:02I want to show you how you can give
- 1:03:04actually this task inside of CI pipeline
- 1:03:06and how it will actually work. So to
- 1:03:08make it sure we need to first create a
- 1:03:09folder and then here we'll create a CI
- 1:03:11pipeline with the GitHub actions and
- 1:03:13there we'll see how this codeex actually
- 1:03:15works inside that. So let's create a
- 1:03:17folder inside the desktop. Let's say we
- 1:03:20call a folder which is review. And now
- 1:03:22we'll open this folder inside our VS
- 1:03:24code. Now we know that if we want to
- 1:03:25create a GitHub action for the CI
- 1:03:27pipeline, we have to first create a dot
- 1:03:29GitHub folder and inside that we need to
- 1:03:30create a workflow. So we'll do the same
- 1:03:33here. I'll just create a folder which is
- 1:03:35GitHub and inside this I'll create one
- 1:03:38more folder with the name workflows and
- 1:03:40inside this we need to create our yml
- 1:03:42file where we write all the commands for
- 1:03:44executing. Uh let's say we write a code
- 1:03:47review yimml. Now this is our file. Now
- 1:03:50let me zoom in a little bit. Now I've
- 1:03:52already created the entire commands.
- 1:03:53I'll just paste it here and explain you
- 1:03:55how we are actually injecting our codeex
- 1:03:58command inside this. So I'll just paste
- 1:04:00it here. Now if you look at here this is
- 1:04:02just the normal GitHub action commands
- 1:04:04where we have a name and we are writing
- 1:04:05the on command which decide that when
- 1:04:07this CI pipeline should get triggers and
- 1:04:09then we are writing our jobs. Now if you
- 1:04:11notice here with the name run codeex
- 1:04:13review. Now this is the job that we have
- 1:04:15decided in our codeex yml to run and
- 1:04:17inside this we have set an environment
- 1:04:19variables. Now this is important
- 1:04:21otherwise if you do not decide your
- 1:04:23openi API key then it will not get to
- 1:04:25know that whether you are authenticated
- 1:04:27user or not. So you need to apply your
- 1:04:30open AI key. Now if you notice here we
- 1:04:32have used the open AI key using the
- 1:04:33secret variable. Now how it will get all
- 1:04:36the secret variable it will get from the
- 1:04:37GitHub actions. I'll show you in one of
- 1:04:39my repo where I have do this. So let me
- 1:04:41open the chrome and here this is my repo
- 1:04:44and in this repo if you go to the
- 1:04:45settings then here if you go to the
- 1:04:47secret and variable options then go to
- 1:04:50the actions you can see this this is the
- 1:04:52place where you have to define all your
- 1:04:53secret variables. I've already defined
- 1:04:55some of the secret variable for this
- 1:04:56repo which is AWS access key and ID. So
- 1:04:59here if you define your open API key
- 1:05:01then the next time when that CI pipeline
- 1:05:03gets triggered it will fetch that open
- 1:05:05AI key from the secret variables. Now
- 1:05:07this is a best practice because you
- 1:05:08should not define your secret variables
- 1:05:10like open AI key or any other variable
- 1:05:12directly in your GitHub action commands
- 1:05:14which has a chance for expose. So always
- 1:05:17keep them inside your GitHub actions and
- 1:05:18then you can fetch it from there. And
- 1:05:20then we have this run command which
- 1:05:22basically run our codeex command and
- 1:05:24inside this we have given the task which
- 1:05:26it should run. We have write here like
- 1:05:28review the changes in this PR for bugs
- 1:05:30and rest of the things. So in this way
- 1:05:32you can inject codeex inside your CI
- 1:05:34pipeline or anywhere where only commands
- 1:05:36work. Now when you define this it will
- 1:05:38run this task for one time and provide
- 1:05:40the output in the standard output format
- 1:05:42and then finish the task. There's a no
- 1:05:44human interaction required because
- 1:05:45everything is running in the headless
- 1:05:47mode non-inctive mode. Now although we
- 1:05:49can run this command in our Codex
- 1:05:50terminal also but that is not the way
- 1:05:52you should write it. You should always
- 1:05:53write this codeex command where only we
- 1:05:55are working with the command line. But
- 1:05:57let me show you for the demo. So if you
- 1:05:59open the terminal here and here if we
- 1:06:02run our codeex uh do you test the
- 1:06:04content? Yes. Continue. And here if I
- 1:06:06write the command which is codeex and
- 1:06:08then let's say if I give a task uh run
- 1:06:12test and fix any issue in this file I'm
- 1:06:16going to click enter it will work for
- 1:06:18short here but as I told you before we
- 1:06:20should not use it like this here I think
- 1:06:21it will take more time because we run it
- 1:06:23directly in our home directory and
- 1:06:24inside that home directory there are
- 1:06:26multiple folders and file available so
- 1:06:28it will scan all those file and find the
- 1:06:30bugs inside this. So we can terminate it
- 1:06:32for now but you get the point that we
- 1:06:34can use this command to automate our
- 1:06:36task in the headless mode. So this is
- 1:06:37the way you can run codex in the
- 1:06:39automation mode.
- 1:06:42Now we have reached at the point where
- 1:06:43we are going to create our own fullstack
- 1:06:45application from back end to front end
- 1:06:47to integrating to our database and also
- 1:06:50deploying it on the hosting platform.
- 1:06:52And while we are doing all those things
- 1:06:54we'll understand all the important
- 1:06:55concepts of codeex there itself. Now you
- 1:06:58already know that whenever we want to
- 1:07:00deploy our project, we need to at least
- 1:07:02keep a track of all the commits in the
- 1:07:04code in a version control system. Maybe
- 1:07:06a GitHub or a bit bucket. So we'll also
- 1:07:08do the same thing. If you want to deploy
- 1:07:10our project, we need to first have it in
- 1:07:12the GitHub. So what we'll do, we'll
- 1:07:14create a project. Basically, we are
- 1:07:16going to build a URL shortener website,
- 1:07:18which is a very basic website, but there
- 1:07:21we'll understand how all the concepts of
- 1:07:23codeex actually work. So we'll start
- 1:07:25from there. We'll push our code on the
- 1:07:27GitHub and also we are not only going to
- 1:07:29push the code by ourself by writing all
- 1:07:31the git command. Instead we will take
- 1:07:33the help of codeex. Codex will only do
- 1:07:35all the things. It will create a repo
- 1:07:37for us. It will deploy it on the versel
- 1:07:39or also it will integrate the database.
- 1:07:41It will open up the request. It will
- 1:07:43also create a new branch and also it
- 1:07:45will merge it to the main. So all the
- 1:07:47things will be managed by the GitHub.
- 1:07:50But we need to make sure one thing if it
- 1:07:52is managed by the GitHub then it should
- 1:07:55get access to our GitHub account also.
- 1:07:57So the first thing is that we need to
- 1:07:58connect our GitHub account with a codeex
- 1:08:01so that it can create a repo and do the
- 1:08:02rest of the things there. So we need two
- 1:08:04things to connect it to our GitHub
- 1:08:05account. The first thing is that of
- 1:08:07course git. So what we can do we'll go
- 1:08:10here in the website and we'll search
- 1:08:11here get install
- 1:08:14and from here we'll install it. And I am
- 1:08:17assuming that you might have this in
- 1:08:19your system because if you have used git
- 1:08:21or github before this git command is
- 1:08:23already there because through this only
- 1:08:24you are able to write all the git
- 1:08:26commands. So you can install the git
- 1:08:28command based on your operating system
- 1:08:30whether you are a window or Ubuntu or
- 1:08:32Mac OS or if you want to go with the
- 1:08:34homebrew method also that also you are
- 1:08:36going to do there. Now once you install
- 1:08:38this the next thing is that you need a
- 1:08:40GH which basically means a GitHub CLI
- 1:08:42through that only it will going to
- 1:08:43authenticate with your GitHub account
- 1:08:45and do the rest of operations. So just
- 1:08:48go again and search get GH install and
- 1:08:53here you can just go this website maybe
- 1:08:58yeah this one itself and here you will
- 1:09:00get the command which is a blue install
- 1:09:02gh. So install these two things and
- 1:09:04after installing it open the terminal
- 1:09:06and verify whether you have installed it
- 1:09:07or not. So just try to get - version you
- 1:09:11are able to see the version of git that
- 1:09:13means it is installed. Same you can run
- 1:09:14for the GH also. So I'll just write gh
- 1:09:17version and we got the version of the GS
- 1:09:20also. So now after this we need to
- 1:09:23connect our GitHub account through
- 1:09:24codeex. So the thing is that we need to
- 1:09:27use a command which is a gh o login
- 1:09:29because gs is a cla which basically
- 1:09:31means a github cla. So we are able to
- 1:09:33run this command. So I'll just write
- 1:09:34here gh o login and when you enter this
- 1:09:39command it will ask you what you want to
- 1:09:41actually authenticate your github
- 1:09:42account or something else. I'll say
- 1:09:44github.com.
- 1:09:46I'll click on this. Then it will ask
- 1:09:48which protocol do you actually want to
- 1:09:50use https or ssh. So you can go with the
- 1:09:53https because it's a very simple one. So
- 1:09:55just click on this and it will ask
- 1:09:57authenticate git with your gith
- 1:09:58credential. Just say y and then click
- 1:10:00enter. Then it will ask how you actually
- 1:10:02want to login with browser or you want
- 1:10:04to paste an authentication token. So
- 1:10:06click on with browser and then it say
- 1:10:08that copy this code because this is the
- 1:10:10code we are going to use in our browser
- 1:10:11when you want to authenticate with the
- 1:10:12GitHub account. So just copy this and
- 1:10:15once you confirm that I have copied it
- 1:10:16then click on the enter. It will
- 1:10:18redirect you to the browser. Here it
- 1:10:20will ask your account that through which
- 1:10:21account you actually want to continue
- 1:10:24with the GitHub. So just click on
- 1:10:25continue and then paste the code which
- 1:10:27we have copied from the terminal and
- 1:10:29then click on continue and it will ask
- 1:10:32that if you want to continue then what
- 1:10:34are the things you want to grant it
- 1:10:36maybe create a git repo read an
- 1:10:38organization team membership and if you
- 1:10:40have connected with other organization
- 1:10:41also then you want to give access to
- 1:10:43that organization also or not you can
- 1:10:45just enable and disable all this thing
- 1:10:46from there. Then once you comfortable
- 1:10:48with this thing then click on authorize
- 1:10:50GitHub and it will say you have
- 1:10:51authenticated. Now go back to the
- 1:10:53terminal and here if you notice it says
- 1:10:55that logged in naman para which is my
- 1:10:57GitHub account and it also said that you
- 1:10:59were already logged in because I've
- 1:11:00tried this before also. Now once we
- 1:11:02connect our GitHub account the next step
- 1:11:03is creating a project. So as I told you
- 1:11:06before that we are going to build a URL
- 1:11:07shortener website. So first thing is
- 1:11:09that we need a folder. So either you can
- 1:11:12say to codex that create a folder to
- 1:11:13that particular path or you can just
- 1:11:15manually create it and then open codex
- 1:11:16inside that folder. So I'll prefer the
- 1:11:18manual way here. So just open the finder
- 1:11:21or if you are in the windows and open
- 1:11:23the file explorer and then decide where
- 1:11:25you want to create a folder. In my case
- 1:11:27I want to go with the desktop. So I'll
- 1:11:28go here and then click on new folder and
- 1:11:31then I'll write the name of my folder
- 1:11:33which will be the link forge which
- 1:11:35basically means a URL shortener. So I'll
- 1:11:37just write here link forge and when I
- 1:11:40click enter I have created my folder.
- 1:11:43Now I'll open this folder inside the VS
- 1:11:45code and there we'll use the codeex
- 1:11:47inside this folder. So just click right
- 1:11:50click actions open VS code. Okay. So now
- 1:11:53we are inside of a VS code with this
- 1:11:55particular folder. Just open the
- 1:11:56terminal and now start running the
- 1:11:59codeex here. We can use this terminal as
- 1:12:01I told you before that either you can
- 1:12:02use a VS code terminal or your computer
- 1:12:04terminal. Both are similar just only the
- 1:12:06platform change. So I'll just write here
- 1:12:08first I need to verify whether I'm in
- 1:12:09the link forge folder or not although I
- 1:12:11am but just for the shity I'll just
- 1:12:13write here pawwd and it says that you
- 1:12:15are in the users naman paharia desktop
- 1:12:17link forge. Okay now I want to run the
- 1:12:19ls command also just to show that right
- 1:12:21now this project folder is completely
- 1:12:23empty. So as you can see here now so
- 1:12:25just write the command which is codex
- 1:12:27and it says yes continue because this is
- 1:12:29the empty folder. So it just asked
- 1:12:30whether you want to trust this folder or
- 1:12:32not. So I'll just click on yes continue.
- 1:12:34And now our codeex is started in our VS
- 1:12:37code terminal. So what the first thing
- 1:12:39we need to do? First thing is that we
- 1:12:41need to create at least one file to
- 1:12:43create a GitHub repo because GitHub repo
- 1:12:45can't be empty. So at least one file is
- 1:12:46needed. So I'll maybe create a simple
- 1:12:49readme.md file and then I'll just commit
- 1:12:51that file and create my GitHub repo. So
- 1:12:53all those things we are going to do with
- 1:12:54the codeex. So I'll just say create a
- 1:12:58readme file. I'll say readme.md file for
- 1:13:02this project which is built with
- 1:13:05expressjs
- 1:13:06and reactjs. I just give the little
- 1:13:10context that what text tag we are going
- 1:13:11to use in this project so that it at
- 1:13:14least contains some relevant information
- 1:13:16about these project inside my readmi.mmd
- 1:13:18file. Just create enter. It will start
- 1:13:20creating it. We can see it in the real
- 1:13:22time also that whether the file has been
- 1:13:24created or not. As you can see it says
- 1:13:25the workspace is empty and it has
- 1:13:27created the readme file. And this is the
- 1:13:29content it contains inside it. I can
- 1:13:31open the readme file here also and we
- 1:13:32can see what are the things it contains.
- 1:13:35So it says that the link forge is a
- 1:13:36fullstack a web application built with
- 1:13:38express js on the back end and the
- 1:13:39reactjs on the front end. This is able
- 1:13:41to write here because I have given the
- 1:13:43context and the text project structure
- 1:13:46and the feature. Okay. Now the next step
- 1:13:48is we need to commit this file. So I'll
- 1:13:51just simply say create a initial commit
- 1:13:53or maybe I just say that create my
- 1:13:55public GitHub repo. So it will
- 1:13:56automatically make sure that okay if you
- 1:13:58want to create a repo it should first
- 1:13:59have a file with a commit message. So it
- 1:14:01will automatically create a commit
- 1:14:02message push our file and then create a
- 1:14:04public repo. So I'll just simply write
- 1:14:06here create a GitHub or I'll say create
- 1:14:10a public GitHub repo then click enter.
- 1:14:13It will first look in our GitHub account
- 1:14:15that whether we are authenticated or not
- 1:14:17and once it confirm it will then look at
- 1:14:19whether the same name GitHub repo is
- 1:14:20available or not in the GitHub. If it is
- 1:14:22available, it may use a different name
- 1:14:25or maybe it will tell us that this name
- 1:14:27is already available. You should choose
- 1:14:28a different name. By the way, we have
- 1:14:30not given the name of the repo. It will
- 1:14:31automatically fetch the name based on
- 1:14:33the project we have given. It will now
- 1:14:34ask, do you want to run the git in it?
- 1:14:36Yes, we want to run. So, first it will
- 1:14:38initialize the git. As I told you
- 1:14:40before, it will automatically understand
- 1:14:41that if you want to create a git repo,
- 1:14:43clear steps are required like we need to
- 1:14:45create a git in it commit and then push
- 1:14:47github and then only our repo will
- 1:14:49available. again do you want to create a
- 1:14:51branch with the main I'll say yes
- 1:14:53proceed although I can give it the
- 1:14:54permission for full access so this thing
- 1:14:56will not ask it will automatically
- 1:14:58create by itself then it says uh do you
- 1:15:00want to stage the file and commit with
- 1:15:02the message with the initial commit I'll
- 1:15:04say of course yes so all the steps it is
- 1:15:06following to create a my GitHub repo and
- 1:15:08get repo create link forge I'll say yes
- 1:15:10proceed and it says link forge already
- 1:15:12exist on a GitHub account so I'm looking
- 1:15:14up its URL and then I'll connect the
- 1:15:16local repo to that existing public
- 1:15:17repository instead of creating a
- 1:15:19duplicate Okay, so it has said that this
- 1:15:21repo is already available. I have this
- 1:15:23same repo in my GitHub account. That's
- 1:15:25why it says this. No worries. Let's
- 1:15:27click on yes, proceed and see what it
- 1:15:28does. Would you like to run the
- 1:15:30following command? Connect the local
- 1:15:31repository to the existing public
- 1:15:32repository and push the initial commit.
- 1:15:34I'll say something different. I don't
- 1:15:36want to make sure it should be available
- 1:15:38inside my existing public repository. It
- 1:15:40should be a completely new. So I'll say
- 1:15:42no and I'll say something different to
- 1:15:44the codeex. I'll say create a public
- 1:15:47GitHub repo with the name URL shortener.
- 1:15:52Okay, now I'm sure that this name is not
- 1:15:53available in my GitHub repository. So it
- 1:15:55will definitely create a new repo. Now
- 1:15:57commit is already done if I'm not wrong.
- 1:15:59Yeah, initial commit is there. I'll say
- 1:16:01yes proceed now. And now it says that it
- 1:16:03has created our repo with the name URL
- 1:16:05shortener. We can click on this URL to
- 1:16:07verify whether the repo is created or
- 1:16:09not. So just click here and it has
- 1:16:11opened the browser and we can see this
- 1:16:13it is inside my GitHub account with the
- 1:16:15name URL shortener and it has also
- 1:16:17committed my first file which is
- 1:16:18readme.md with a message initial commit
- 1:16:21and this is the exact content it
- 1:16:22contains inside it. So as you can see
- 1:16:24all the things are done with the codeex
- 1:16:25cla itself. We have not created the repo
- 1:16:27by itself by writing all the g commands.
- 1:16:30We just tell the codeex that create a
- 1:16:31github repo and it automatically create
- 1:16:33a message. It asks for the approval
- 1:16:35because you have given the permission
- 1:16:36for ask approval. But if you feel like
- 1:16:38that it will have smart enough and
- 1:16:40create the repo by itself with a good
- 1:16:42commit message and all the relevant
- 1:16:44things then you can go with the full
- 1:16:45access permission also. Although we'll
- 1:16:47use the full access permission only
- 1:16:49later because we don't want to give
- 1:16:50permission every time I believe that it
- 1:16:53will keep everything perfect and
- 1:16:54although we are here for the monitor so
- 1:16:56monitor in between if something goes
- 1:16:58wrong. So we have now done this part
- 1:16:59where we have connect our GitHub account
- 1:17:01create a public repo and also commit our
- 1:17:03first file which is admin. MD
- 1:17:07now whenever we use codex inside our
- 1:17:09project we want it to follow some
- 1:17:11instruction and rules before taking any
- 1:17:13action inside my project now let's say
- 1:17:15if I want that whenever generate any
- 1:17:17code for me it should also run npm run
- 1:17:20test command so that it can verify
- 1:17:22whatever the code it has generated we
- 1:17:24can also make a command or the
- 1:17:25instruction where I will say that before
- 1:17:27generating the code you should always
- 1:17:29take a pull request so that it will get
- 1:17:31the latest code I can give another
- 1:17:32instruction also let's say I want that
- 1:17:34whenever you are creating a variable
- 1:17:36name or the file name always follow some
- 1:17:38naming convention in short I just want
- 1:17:40to give some instruction and guidance to
- 1:17:42the codeex so that it can work inside my
- 1:17:44project based on those guidance now you
- 1:17:46can think it in this way also let's say
- 1:17:47when a junior developer gets hired in
- 1:17:49the company how manager and the senior
- 1:17:51developer explain him everything guide
- 1:17:53him with all the instructions like what
- 1:17:55tech stock we are working on how the
- 1:17:57deployment actually goes on and how we
- 1:17:59communicate on the day-to-day basis so
- 1:18:01that when this junior developer start
- 1:18:03working it follow all the guidance and
- 1:18:05the instruction and work based on that.
- 1:18:06Same like that whenever you want to
- 1:18:08guide codeex that how it should work
- 1:18:10inside my project we need to create a
- 1:18:12file and there we'll define all the
- 1:18:14instruction. So as you can see here
- 1:18:16right now we have a readme.md file and
- 1:18:19what's the role of the readme.md file to
- 1:18:21guide humans that what this repo
- 1:18:23actually contain. Whenever you open any
- 1:18:24GitHub repository, you always read the
- 1:18:26readme.md file to know what this repo
- 1:18:29actually contained, what is the
- 1:18:30description of the repo, what text tag
- 1:18:32actually use, what are the commands I
- 1:18:34need to follow to make this repo
- 1:18:36available on my system and run it
- 1:18:37locally. Same like that, we need to
- 1:18:39create an agents MD file where we write
- 1:18:42all the instruction for the codeex to
- 1:18:44follow inside my project. Now, just like
- 1:18:46this in cloud code also, if you know
- 1:18:47about the cloud code and have used it
- 1:18:49before in cloud code, we also create a
- 1:18:51instruction file. But the name of that
- 1:18:53file is claude.m MD. So every agent has
- 1:18:57their own file name but the purpose
- 1:18:58remain the same which is giving the
- 1:19:00instruction and the guidance which you
- 1:19:02want it should work inside your project.
- 1:19:04So we'll create one file here inside my
- 1:19:06link forge. Now if you remember that I
- 1:19:08have discussed about one slash command
- 1:19:10in the slash video where we have talked
- 1:19:13about /init command and you know that
- 1:19:15what does that command actually do? it
- 1:19:18create an issafold agents.md file which
- 1:19:21basically means creating an agent.mmd
- 1:19:23file with some default instruction. So
- 1:19:25if I type this command will it create my
- 1:19:27agent md file inside my project of
- 1:19:29course it will create. So let's try it
- 1:19:31out. So if I type here / init and then
- 1:19:34when I say enter it will create an agent
- 1:19:36md file. It will read my readme.md file
- 1:19:38also to get the context that what this
- 1:19:40repo actually contain and based on that
- 1:19:42it will write some by default
- 1:19:44instruction and I'll look at those
- 1:19:46instruction if I'm happy with that I can
- 1:19:48go with that or if I want to customize I
- 1:19:50can customize based on my requirement so
- 1:19:52it has created agents MD file I don't
- 1:19:54have to write the name by myself I just
- 1:19:55need to use the command slash in it and
- 1:19:58it has automatically created agents MD
- 1:20:00file so just open it and this is how it
- 1:20:02looks like everything in the markdown
- 1:20:04format because we are using the
- 1:20:05extension with MDF format. Now, as you
- 1:20:08can see, it says the repository
- 1:20:09guidelines, which we also discussed
- 1:20:10instruction. It says the project
- 1:20:12structure and the module organization.
- 1:20:14It needs a server for the backend
- 1:20:16express API, clients for the React app,
- 1:20:18test for the test.js and assets. And it
- 1:20:21also write some useful command npm
- 1:20:23install, rundev, test, run build, and
- 1:20:26the coding style, what type of style it
- 1:20:28should follow inside my project when it
- 1:20:30takes or generate any code. And also we
- 1:20:32have defined subtasks like test command,
- 1:20:34initial commit, env file. So all those
- 1:20:37things are available here. But if you
- 1:20:39want to customize it based on your
- 1:20:40requirement, you can just change this
- 1:20:42entire thing and put your own content
- 1:20:44and your instruction and then you can
- 1:20:46push it on your GitHub. So we'll do the
- 1:20:48same thing. We'll not follow this by
- 1:20:49default instruction. Although it's
- 1:20:50relevant because it has created based on
- 1:20:52our project, but I want to use something
- 1:20:54different. So I'll just select all those
- 1:20:56things and cut now and paste my content.
- 1:20:59So this is what I want inside my
- 1:21:01instruction file. You can read this. You
- 1:21:03can understand what are the things
- 1:21:04available here. I have already created
- 1:21:06before. So I know what are the things
- 1:21:07available here and it's relevant. So
- 1:21:09just read it out. Now I'll save this and
- 1:21:12I'll say now create a commit. It will
- 1:21:15automatically create my commit. Push it
- 1:21:16on the GitHub and then we'll verify
- 1:21:18whether it is pushed or not. So I just
- 1:21:21write here create a
- 1:21:24commit or I'll just say push it on
- 1:21:29GitHub.
- 1:21:31Okay, it says I'm checking the local
- 1:21:32div. It asking for my permission. I'll
- 1:21:35say yes,
- 1:21:37it has pushed. We can verify the commit
- 1:21:39also. And it says that addit contributor
- 1:21:42guide. So it's a relevant commit. It has
- 1:21:44generated by itself based on the content
- 1:21:46which we are going to push. And we can
- 1:21:48verify whether this is done or not. So
- 1:21:51just go to the browser and here when we
- 1:21:53refresh
- 1:21:54we can see the commit as well as our
- 1:21:56file which is agents.mmd file and this
- 1:21:59is the commit add contributor guide and
- 1:22:01it has done now only just open this file
- 1:22:03to verify whether it contains the same
- 1:22:04content or not and it contains. So okay
- 1:22:07so this is what we want to discuss about
- 1:22:09agents.mmd file which basically means
- 1:22:11creating our own instruction and
- 1:22:13guidance which our codeex use inside our
- 1:22:15project.
- 1:22:18Now it's time to create a functionality
- 1:22:19in our project by creating the backend
- 1:22:21files and the front end files and also
- 1:22:23the test cases. Now I can give a command
- 1:22:26to the codeex to create all those things
- 1:22:28for me and there are multiple ways to
- 1:22:30use it. So let's say if I want to create
- 1:22:32my back end and the front end, I'll just
- 1:22:34write all those things in one command to
- 1:22:36the codeex and it will generate for me.
- 1:22:38But the thing is that if I give the
- 1:22:40entire command to codeex to generate my
- 1:22:42back end and front end at one go, then
- 1:22:44it will for sure generate. But it will
- 1:22:47take a lot more time because it needs to
- 1:22:49first generate the entire back end code.
- 1:22:51It needs to run the test cases to make
- 1:22:53sure that everything working and then it
- 1:22:54will move to the front end code and then
- 1:22:56it will generate that. So I have to wait
- 1:22:58for entire thing. Now I can use the
- 1:22:59another option also. Maybe I can give a
- 1:23:01codeex a command where I'll say first
- 1:23:03create the back end code and I'll just
- 1:23:05say enter. It will create and give me
- 1:23:06the back end code. Then I'll switch to
- 1:23:08the next one which is creating a front-
- 1:23:10end code. And when it generate the front
- 1:23:11end code for me, then I'll say run the
- 1:23:13test case to verify whatever you have
- 1:23:15created is correct or not. So in this
- 1:23:17way I have divided my task into subtask
- 1:23:19and then give it one by one. But there's
- 1:23:21still a catch. I have to wait for the
- 1:23:23model to make sure that whether the
- 1:23:24first task is completed or not and then
- 1:23:26only I'm able to give the second task.
- 1:23:28Now what if I can say that we can run
- 1:23:30all these task valerly at once. I just
- 1:23:32say the codeex then run all these task
- 1:23:34at once and I can verify whether these
- 1:23:36tasks are running simultaneously or not.
- 1:23:39Now basically there's a concept in
- 1:23:40codeex which is sub aents and now the
- 1:23:43name itself says sub aent which
- 1:23:45basically means creating multiple agents
- 1:23:47for your task. So suppose if I want to
- 1:23:50create multiple agent one for the back
- 1:23:52end one for the front end and one for
- 1:23:54running the test case I can do this in
- 1:23:56my codeex. Now this is very useful
- 1:23:58because if you have a large complex task
- 1:24:00and you don't want to make the only one
- 1:24:02thread or I can say the one agent to do
- 1:24:04that entire task you can divide it into
- 1:24:06the multiple task. So your main agent
- 1:24:09can only focuses on creating a planning
- 1:24:11for you relevant all the informations
- 1:24:14creating a plan for you gathering all
- 1:24:15the relevant information and whatever
- 1:24:17the important things are required. So
- 1:24:19how the flow actually goes on let's
- 1:24:21discuss on the drawing board. If we have
- 1:24:23as a developer we basically have a main
- 1:24:25agent which is the entry point which is
- 1:24:26right now we are using where we give all
- 1:24:28the commands to the codeex or I can say
- 1:24:30that a task. Now through the main agent
- 1:24:32we give a command to the codeex that
- 1:24:35create sub aent for this particular
- 1:24:36task. I'll define the task that what
- 1:24:38should agent do for this particular task
- 1:24:40and let's say I've given the task that
- 1:24:43one agent should do search code another
- 1:24:44one should write a code and the next one
- 1:24:46should run the test case and I'll say
- 1:24:48also once these all task get executed
- 1:24:51summarize all those task do a merge
- 1:24:54result and then give me the final output
- 1:24:55so who will responsible for my final
- 1:24:57output of course my main agent because
- 1:24:59that takes care of all the agents work
- 1:25:01it will look and monitor all the things
- 1:25:03whether they have completed or not and
- 1:25:04once they completed it will merge the
- 1:25:06result and give me the final output.
- 1:25:08This is how agents actually work. So
- 1:25:10let's go to the VS code and create a sub
- 1:25:12aent. Now now one thing I also want to
- 1:25:14share that whenever you are creating a
- 1:25:15sub aent in codeex we have to create it
- 1:25:18explicitly means we have to manually
- 1:25:20call those sub aents and tell it that
- 1:25:22use the sub aent for this particular
- 1:25:23task. But in other agents like if you
- 1:25:26talk about the clot code they
- 1:25:28automatically create the sub aent based
- 1:25:29on the task you have given. So if it
- 1:25:31monitor that your task requires a long
- 1:25:33context, it is a complex task and it
- 1:25:35must be divided into the sub agent, it
- 1:25:37will automatically divide even though
- 1:25:39you didn't tell it to do. But in Codex,
- 1:25:41you have to manually manage it. So I'll
- 1:25:43just write my prompt which I have
- 1:25:44already created. I'll just paste it. And
- 1:25:47this is my prompt. I'll just say build a
- 1:25:50URL shortener project using sub aent.
- 1:25:52Split the work into independent task.
- 1:25:54One sub aent should create the front
- 1:25:56end. Another should build a back end and
- 1:25:59another should prepare test and
- 1:26:00documentation. After they finish
- 1:26:02integrate everything. So this is my
- 1:26:04prompt where I assign a task to the
- 1:26:06codeex and tell it to create sub aents
- 1:26:09for this task and at last summarize my
- 1:26:11result. So let's see how well it will
- 1:26:12generate my code with the sub aent. So
- 1:26:14let's say enter and it will look at my
- 1:26:16prompt and then delegate my task to the
- 1:26:18sub aent. So as you can see here it has
- 1:26:20spawned three sub aents. One is for the
- 1:26:23back end, one is for the front end and
- 1:26:24one is for the test and documentation.
- 1:26:26And these are the three agents running.
- 1:26:29So these are the three agents which are
- 1:26:30running parallelly. While they build,
- 1:26:32I'm staying out of their file scope. So
- 1:26:34integrating stays clean and conflict
- 1:26:36free. So this is our main agents work.
- 1:26:39But these three agents are working for
- 1:26:40backend, front end and the test case.
- 1:26:42Let's wait for the result which are
- 1:26:43running parallelly. Although we can
- 1:26:45verify the result also we can monitor
- 1:26:47those sub agent work in between. If you
- 1:26:48want to see what this back end sub aent
- 1:26:50do currently. So I can just able to do
- 1:26:52that with a command. I'll tell this
- 1:26:54command. Let's say if I just write a /
- 1:26:56agent. As you can see here when I say /
- 1:26:58agent it say switch the active agent
- 1:27:01thread. As you know right now we are
- 1:27:03running three sub aent. That means when
- 1:27:05I write this command and click enter. If
- 1:27:07you can see this these are the agent.
- 1:27:09Now if you notice the name it says
- 1:27:11Pascal Tesla and Ris total. I don't know
- 1:27:15how to pronounce it because these are
- 1:27:16very funky and the weird name. Now these
- 1:27:18names are created by the codeex itself.
- 1:27:20We don't have any permission to define
- 1:27:22how the names of the sub agent should
- 1:27:24be. When you assign the task to the
- 1:27:26codex, it will automatically assign some
- 1:27:27funky name to it which you can later
- 1:27:29identify. Okay, Pascal is for this one,
- 1:27:32Tesla for this one and the third one is
- 1:27:34for this one. So if I want to switch
- 1:27:35between any one of the task and monitor
- 1:27:37how the works going on there. I can just
- 1:27:39do up and arrow key and here I can
- 1:27:41switch between them. Uh okay, it ask me
- 1:27:43for one permission first. Let me click
- 1:27:45yes approved. And now let's say if I
- 1:27:47want to see the work of Tesla sub agent,
- 1:27:49I just go here and click enter. And this
- 1:27:51is what going on in Tesla sub agent.
- 1:27:54Okay. Now if I want to monitor someone
- 1:27:55else, I can again go to the / agent
- 1:27:57command. And here let's say go to the
- 1:27:59Pascal one. Now click enter. And this is
- 1:28:02what going inside the Pascal. Okay. So
- 1:28:04in this way we can monitor the task of
- 1:28:06sub east sub agent and let's wait for it
- 1:28:08to complete the task and let's see how
- 1:28:11the work's going on there.
- 1:28:15So as you can see here till this point
- 1:28:17my back end sub agent has completed it
- 1:28:19work and my main agent has informed me
- 1:28:21that back end is confirmed I'm waiting
- 1:28:23on the front end work next and then I'll
- 1:28:24reconcile the root manifest and run the
- 1:28:26combined checks. So now it says that
- 1:28:28waiting for the passcode which is the
- 1:28:30name of my front end sub agent. So it
- 1:28:32again ask me for the approval. I'll say
- 1:28:33yes proceed. I need to change this
- 1:28:35permission but I'll change it later. I
- 1:28:36don't want to interrupt it in between
- 1:28:38but later on I will definitely give it
- 1:28:39to the full access so I every time I
- 1:28:41don't have to give it the approval.
- 1:28:43Okay. Okay, now it says that the Pascal
- 1:28:44completed that means front end
- 1:28:45implementation is complete and verified
- 1:28:47with the production build. As you can
- 1:28:48see the front end folder here as well.
- 1:28:50So this is my front end code and this is
- 1:28:52my back end code and now what is running
- 1:28:55only I think one thing is done. No, all
- 1:28:57the thing has done. Now we can see here
- 1:28:58it says all three workers finished. I'm
- 1:29:01inspecting the produced file and then
- 1:29:02I'll integrate the two part app into a
- 1:29:04core and layout. So the root commands
- 1:29:06are consistent.
- 1:29:08Now it says that the back end test pass.
- 1:29:10I'm waiting for the front end production
- 1:29:11build to finish and then I'll commit the
- 1:29:13integrated repo state. So basically it
- 1:29:15is running the test cases front end and
- 1:29:17back end subent work has done even
- 1:29:19though test sub aent work is also done
- 1:29:21but it is doing a basic thing which we
- 1:29:24have also mentioned in the agent autom
- 1:29:26file which is running all the test
- 1:29:27command to make sure that all the code
- 1:29:29which is generated is correct or not. So
- 1:29:31now all the sub agents work has done and
- 1:29:33it takes around 7 minutes 43 seconds to
- 1:29:35complete my entire back and the front
- 1:29:36end code and I've also given the
- 1:29:38permission in between to push my code.
- 1:29:40So that's why we are able to see the
- 1:29:41commit here as well. So all the code of
- 1:29:44the back end and front end is now
- 1:29:45available on our GitHub too. So now it's
- 1:29:48time to run this project and see how the
- 1:29:50functionalities and you are actually
- 1:29:51working. So I'll just say run the
- 1:29:53project. Although I can run it by myself
- 1:29:55also by running the command npm rundev.
- 1:29:58I think it has given me the command to
- 1:29:59run in this project. It says that npm
- 1:30:02run test npm run build but I'll tell the
- 1:30:04codeex to run it by yourself. So I'll
- 1:30:06say run the project. Okay, we have made
- 1:30:08the mistake in spelling. I just write
- 1:30:10here s instead of n but it will
- 1:30:13understand. Okay, so project has been
- 1:30:15started. We can now verify by using the
- 1:30:17URL which is given for the front end. So
- 1:30:19I'll just copy this URL and here I'll
- 1:30:21paste the command and this is how our
- 1:30:23project looks like. And to be honest, at
- 1:30:25first glance, it really surprised me. In
- 1:30:28terms of UI functionality, I'm not sure.
- 1:30:31Let's verify whether it has also
- 1:30:33surprised me the functionality or not.
- 1:30:34So what we can do, we can paste any URL
- 1:30:36here. Let's say this one URL only. I'll
- 1:30:39just copy it and paste it now. And let's
- 1:30:42say shorten. Okay, it has shortened my
- 1:30:43URL. It has said that this is the
- 1:30:45original one. This is a short link. It
- 1:30:47has also given me the time stamp that I
- 1:30:49have done it on this date with this
- 1:30:51time. I can just copy it and verify
- 1:30:54whether it's working or not. So yeah,
- 1:30:56this is how it has converted. When I
- 1:30:57click enter, it actually redirect me to
- 1:30:59the original URL. So perfect. Our
- 1:31:02functionalities are also working. It has
- 1:31:03also given me the information that in
- 1:31:06terms of stats that you have generated
- 1:31:08one storage local only. So everything is
- 1:31:10running in the local but later on we'll
- 1:31:12definitely push it on the hosting
- 1:31:14database and also deploy it on the
- 1:31:15production. So let's go back here. So
- 1:31:17now we have understood how we can invoke
- 1:31:19sub agent and delegate the task for each
- 1:31:21sub aent. But what if I want to use a
- 1:31:24sub aent again for the same purpose?
- 1:31:26Let's say I want to use the same front
- 1:31:28end agent. But am I able to use that
- 1:31:30again? Of course not because that was a
- 1:31:32sub agent created by the codeex itself
- 1:31:34with a different name. So if I want to
- 1:31:36use the same agent again for the
- 1:31:38repetive task, I can create my own
- 1:31:40custom sub agent and then I can just tag
- 1:31:42or mention that sub aent in my prompt
- 1:31:44which will automatically invoke and
- 1:31:46there I'll mention all the instruction
- 1:31:48how to create a sub aent. Now let's see
- 1:31:50in this folder which is your link forge
- 1:31:53in our case here in the root we'll
- 1:31:54create a folder with the namecodex.
- 1:31:58So we'll just write here dotcodex and
- 1:32:00then inside this dotcodex we'll create a
- 1:32:03subfolder with the name agents and then
- 1:32:06click enter. Now inside this agents
- 1:32:08folder we basically create our own
- 1:32:10custom sub agent. So I'll just go inside
- 1:32:12my agents and create a file and let's
- 1:32:14say I want to create a agent for the
- 1:32:16reviewer which will review all the files
- 1:32:18of my code. So I'll just create a random
- 1:32:21just to show how custom sub aents
- 1:32:22actually work. So I'll just write here
- 1:32:24reviewer dot toml. Now basically
- 1:32:26whenever we are creating a sub agent
- 1:32:28custom sub aent we have to use the
- 1:32:30extension name toml so that we can write
- 1:32:32all the configuration inside there. So
- 1:32:34let's save this and now reduce the size
- 1:32:37of the terminal and increase the size of
- 1:32:39the file. Now in this reviewer dottoml
- 1:32:41file what are the things we need to
- 1:32:43mention? The first thing is required
- 1:32:46name of the agent. Although we have
- 1:32:47given the name in the file but we need
- 1:32:49to mention inside the file also. So that
- 1:32:51whenever we want to invoke that file or
- 1:32:53invoke that sub aent, we can invoke it
- 1:32:55by its name. So I'll just write here
- 1:32:57name and I'll say the name of this sub
- 1:32:59aent is reviewer. And once we define the
- 1:33:01name, the next thing is defining the
- 1:33:03description which will let the codeex
- 1:33:05know what is this sub agent for. So I'll
- 1:33:08just write a description and here I'll
- 1:33:10say review my files in this project and
- 1:33:16report me any potential bug. Now the
- 1:33:19next thing is require a developer
- 1:33:21instruction. Basically you define all
- 1:33:23the instruction which is required for
- 1:33:25this sub aent. We have created only the
- 1:33:27description which tell what this sub
- 1:33:29aent for. But what it actually do you
- 1:33:32have to define it inside a developer
- 1:33:34instruction. So I'll just write here
- 1:33:36developer instructions. And now here
- 1:33:39I'll basically use a three quote because
- 1:33:41I want to write everything inside a
- 1:33:43multi-line. So I'll just use here three
- 1:33:46quote and I'll close it with the through
- 1:33:48quote again and inside these quotes I'll
- 1:33:51write my all the developer instructions.
- 1:33:53So this is my developer instruction
- 1:33:54where I have write the review code like
- 1:33:56an honor prioritize correctness security
- 1:33:59behavior regression and missing test
- 1:34:01coverage and rest of the things. Now we
- 1:34:02can mention another thing also right now
- 1:34:04we have name description and the
- 1:34:05developer instruction which are required
- 1:34:07field. So if I want to show you it on
- 1:34:09the sub agent documentation also you can
- 1:34:12see here these are the required field
- 1:34:13which we have mentioned in our file also
- 1:34:15name description and developer
- 1:34:18instruction but we can mention other
- 1:34:20thing also for example you want to
- 1:34:22mention that which model this sub aent
- 1:34:24should use maybe you want to use a
- 1:34:25custom model for this one so you can
- 1:34:26just write here model let's say this sub
- 1:34:29aent should use the model GPD 5.5 with
- 1:34:31the medium effort so I'll just say GPD
- 1:34:355.5 and make sure it is inside inside a
- 1:34:37double inverted comma because we in the
- 1:34:39terminal file so every value should be
- 1:34:40inside a double inverted comma. Now I
- 1:34:42can define the model reasoning effort
- 1:34:43also model reasoning
- 1:34:47effort and here I'll say it should run
- 1:34:49on medium. So in this way this
- 1:34:51particular agent will run with this
- 1:34:52custom model although I can define a
- 1:34:54sandbox property also if you remember we
- 1:34:56have discussed about this in the safety
- 1:34:58lecture also. Basically the sandbox if I
- 1:35:00just want to repeat it again it decides
- 1:35:02all the rules and policies that how it
- 1:35:05should run inside that project and how
- 1:35:07much permission you want to give to the
- 1:35:08codeex inside that project. If I write
- 1:35:10here sandbox mode and here if I say read
- 1:35:13only. Now in this way what I'm doing
- 1:35:15when I say a sandbox mode should be read
- 1:35:16only it will only able to read my files
- 1:35:19outside of this project but not able to
- 1:35:21access it and even not able to do any
- 1:35:23edit there because right now it is
- 1:35:25running in the read only. But if you
- 1:35:27want to give it a permission to write
- 1:35:28those file do some edit then you can
- 1:35:30change it from read only to write also.
- 1:35:32So in this way you can define a
- 1:35:34particular policies and rule for this
- 1:35:35particular sub aent and based on that it
- 1:35:38will ask for permission for you. Now
- 1:35:39let's test whether this sub agent is
- 1:35:41actually working or not in our codeex.
- 1:35:42So just save this file and here first
- 1:35:46thing I want to verify whether this sub
- 1:35:47aent is available or not. So I'll just
- 1:35:49say is there any sub agent or I'll say
- 1:35:53just agent because at the end it is an
- 1:35:55agent only. Is there any agent available
- 1:35:57in my folder? And it says yes, there's
- 1:36:01an agent.mmd file in this folder. But
- 1:36:03this is not we are asking. I'm asking
- 1:36:04about there's also agents directory in
- 1:36:06the repo metadata. But the main repo
- 1:36:08level agent guide is agents md file.
- 1:36:10Okay. So I think it just misunderstood
- 1:36:11our command basically to understand
- 1:36:13about the agent MD file not the sub
- 1:36:15aent. So I'll just write here sub agent
- 1:36:17instead of agent now. So just use the
- 1:36:19upper arrow key for the history prompt.
- 1:36:23And here instead of agent I'll use here
- 1:36:25as sub agent. So I just basically love
- 1:36:27this also feature in the CLI command.
- 1:36:29You can just move from different prompt
- 1:36:31to prompt because everything is in the
- 1:36:33CLI. So you have a history of every
- 1:36:35prompt. So I'll just write here as sub
- 1:36:37agent
- 1:36:38and I'll say enter now. Okay. It says it
- 1:36:42has sub agent. If you mean can this
- 1:36:44workspace use sub agent? And it says yes
- 1:36:47I was able to spawn sub agent for the
- 1:36:48task. If you mean is there sub aent
- 1:36:50config file? So I think it is not able
- 1:36:52to catch my file which is available in
- 1:36:53my folder for the agent because I think
- 1:36:56we are running in the same session. So I
- 1:36:58think I need to first exit from the
- 1:36:59codeex and then rerun it again to make
- 1:37:01sure whether it is able to get the
- 1:37:03latest file of my folder or not. So I'll
- 1:37:05just write a /exit
- 1:37:08and here I'll clear first and now again
- 1:37:10I'll run the codeex and now let's ask it
- 1:37:13again. So if I say is there any sub aent
- 1:37:16available in my folder when I say enter
- 1:37:18let's increase the size of the terminal
- 1:37:19also. And now it is checking and now you
- 1:37:22can say it has said that I found a
- 1:37:24codeex/ aents. So I'm reading its
- 1:37:27content now to confirm what sub aents
- 1:37:28are actually defined and it has now able
- 1:37:30to get our sub aent which is recomml
- 1:37:33file. So the issue is that we are
- 1:37:35running the same session that's why it
- 1:37:36is not able to get the file which we
- 1:37:37have created. But now when we rerun it
- 1:37:39again it is able to find the file in our
- 1:37:41folder. So it says yes in this workspace
- 1:37:44I found one sub aent definition name
- 1:37:46reviewer purpose review files in this
- 1:37:48project and the report potential bug.
- 1:37:49This is the description which we have
- 1:37:50defined in our file and mode read only.
- 1:37:53This is a sandbox property. So this is
- 1:37:55the only sub aent to use here. Now if I
- 1:37:57want to use this custom sub aent, I can
- 1:37:59just write the command just a normal
- 1:38:01English command. I'll just say use
- 1:38:03reviewer sub agent to review my files.
- 1:38:09And now when I say enter it will look at
- 1:38:11my folder, use my reviewer toml file and
- 1:38:14whatever the instruction I have given
- 1:38:16there based on that it will run my sub
- 1:38:18aent. It says I'm locating the available
- 1:38:19sub agent tooling and then I'll run the
- 1:38:21re agent against the repository
- 1:38:23searching the web spawn this GBD 5.5
- 1:38:27medium as you can see we have defined
- 1:38:28the model also that's why it is using
- 1:38:30the custom model which is a GBD 5.5
- 1:38:32medium because this is the model with
- 1:38:34the reasoning effort we have defined
- 1:38:35inside the sub aent so the review is
- 1:38:37running I'll wait for this and finding
- 1:38:39and then summarize the result so as you
- 1:38:40can see here it has completed the review
- 1:38:42sub aent and it says the reviewer sub
- 1:38:43agent completed a review and findings
- 1:38:45these are the findings it does it says
- 1:38:47that unbounded in memory storage front
- 1:38:49end is still loading backend test. So
- 1:38:51whatever the review it has done based on
- 1:38:54that it has given us the result. Okay.
- 1:38:56So this is what our review sub agent
- 1:38:58actually do and this is how you can
- 1:38:59actually invoke in your prompt. So this
- 1:39:01is all about the sub agent. If I want to
- 1:39:03recap it once again you want to keep the
- 1:39:05main agent only for the relevant
- 1:39:06information then you can delegate your
- 1:39:08task into the sub agent. Now there are
- 1:39:10two ways of using the sub agent. First
- 1:39:12way you can use it directly from the
- 1:39:14prompt. You can invoke sub agent how
- 1:39:15many you want and the second way you can
- 1:39:18create a custom sub aent if you feel
- 1:39:19like that you want to use that sub aent
- 1:39:21in future also. So that's all about sub
- 1:39:24agents.
- 1:39:27Now the next concept that we are going
- 1:39:28to understand is about skills and this
- 1:39:31feature of codeex will definitely help
- 1:39:33you to save lot of your time because
- 1:39:35whenever you are working with a
- 1:39:36repetitive task you have to define
- 1:39:38everything to the codeex again and again
- 1:39:40in your prompt. For example, suppose you
- 1:39:43have created one feature using codeex
- 1:39:45and now if you want to create a similar
- 1:39:47feature again sometime in future you
- 1:39:50have to explain everything to the codeex
- 1:39:52once again in the prompt you have to
- 1:39:54explain so that it makes sure that it
- 1:39:56follows the same pattern and created the
- 1:39:58task or the feature similar like to the
- 1:40:01previous one. So this is what you have
- 1:40:02to do every time whenever you want to
- 1:40:04create or work with the same task or the
- 1:40:06same feature. Now how does the skills
- 1:40:08help here? See whenever you are working
- 1:40:10with a repeated task instead of writing
- 1:40:12all the things every time in the prompt
- 1:40:14you can create a skill for that
- 1:40:16particular task and define all the
- 1:40:19necessary instruction only at once in
- 1:40:21that skill file and later on whenever
- 1:40:24you want to work with the same task you
- 1:40:25can just call that skill where you
- 1:40:27define all the instruction just like we
- 1:40:30have imported our custom subvision file
- 1:40:32if you have remember in the previous
- 1:40:33lecture where we have created our own
- 1:40:35custom file and every time we want to
- 1:40:37use that we just call that custom agent
- 1:40:39in our prompt. Same like that if you
- 1:40:42want to work with the same task. So
- 1:40:43instead of explaining every time in your
- 1:40:46prompt you can call your custom skill
- 1:40:48where you have defined everything. So in
- 1:40:50our project right now you can see we
- 1:40:53have our backend code. So if I open src
- 1:40:56folder uh we have our different
- 1:40:58different files. If you go to the
- 1:41:00server.js this is where our server is
- 1:41:02running. If you go to the services, this
- 1:41:05is the services. And if you go to the
- 1:41:07routes, these are all the routes, URL
- 1:41:09routes and the health routes. So if I
- 1:41:11open the URL route, let me reduce the
- 1:41:14size of the terminal for now. And here,
- 1:41:15if you look at here, we have only two
- 1:41:17route which is get route as well as post
- 1:41:21route. Perfect. But what if I want to
- 1:41:23create one more route which is a delete
- 1:41:24route. So if I want to create a delete
- 1:41:26route I have to explain everything to
- 1:41:28the codeex just to make sure that the
- 1:41:30next route which is a delete route it
- 1:41:32will create it will create exactly like
- 1:41:35the same it has created my get and post
- 1:41:37route but instead of explaining it in my
- 1:41:40prompt I can create a skill for that
- 1:41:42route and next time I just call that a
- 1:41:44skill and it will create a delete route
- 1:41:46with the same pattern the way it has
- 1:41:48created my get and post route. But why
- 1:41:50I'm creating a skill only for the delete
- 1:41:52route. See I am creating here because
- 1:41:55this is not the only route I want in my
- 1:41:57project. Let's say in future I want to
- 1:41:58create a more route. Let's say one for
- 1:42:00update route or maybe I want to create a
- 1:42:01more get route or the post route. So
- 1:42:03will I explain everything again to the
- 1:42:05prompt? Of course not. I'll use that
- 1:42:07skill where I already defined the
- 1:42:09pattern how my API or the route should
- 1:42:11be created and based on that my every
- 1:42:14route will get created by the codeex. So
- 1:42:16now to create an skill just like we have
- 1:42:18created a custom agent inside agents
- 1:42:20folder same we have to create our
- 1:42:23skills. So inside our dot codex folder
- 1:42:25we have an agent folder and inside this
- 1:42:28agent folder we have to create one more
- 1:42:30folder which is skills and now inside
- 1:42:34this skills folder we have to define the
- 1:42:37name of our skill. So in my case I want
- 1:42:40to create a skill for the API endpoint.
- 1:42:42So I'll just write here API/
- 1:42:45endpoint.
- 1:42:47So this is the name of my skill and
- 1:42:49after this I have to create one file.
- 1:42:52Although this API/ endpoint is a name of
- 1:42:54my skill folder. So inside this only we
- 1:42:57have our main file or skill file. So
- 1:43:00I'll just create this one. And now
- 1:43:03inside this I'll write the name which is
- 1:43:06skill.
- 1:43:08MD. And now I can click enter. So
- 1:43:11basically whenever you want to create an
- 1:43:12skills inside your folder you have to
- 1:43:14follow the same pattern. You have to go
- 1:43:16inside dotcodex folder then you have to
- 1:43:18create a skills folder inside that you
- 1:43:21have to write the name of your skill in
- 1:43:23the form of folder in our case which is
- 1:43:25AP endpoint and then you have to define
- 1:43:27the name which is skill.md. So this name
- 1:43:30will remain same for every skill only
- 1:43:32the name which is the skill name you
- 1:43:34have to write here which is different.
- 1:43:36Now inside this skill.md file what are
- 1:43:39the things we need to define? The first
- 1:43:41thing is that you need to define the
- 1:43:42name of the skill so that we can call it
- 1:43:45in our prompt. So I can just write a
- 1:43:47name and I'll give it a name which is a
- 1:43:50a endpoint. Same name or I can use a
- 1:43:52custom name also. Doesn't matter that
- 1:43:54you have to use the same name which you
- 1:43:55have used in the folder also but in our
- 1:43:57case let it be same. The next thing we
- 1:43:59need to define a description. So I just
- 1:44:01write here add a new
- 1:44:05express route in project or in this
- 1:44:10project following our convention. So
- 1:44:13these two things are required which is a
- 1:44:15name and description so that it can
- 1:44:17understand that we need to call this
- 1:44:19skill. Now the syntax of writing the
- 1:44:22skill is not like that. Whenever you
- 1:44:23write a name and description these two
- 1:44:25things should be available inside a
- 1:44:27front matter. So you have to write
- 1:44:29something like this. You have to mention
- 1:44:31three hyphens just like this and you
- 1:44:34need to close this with the three
- 1:44:35hyphens again just like this. So
- 1:44:37basically this three hyphen called as
- 1:44:39front matter or we can call it as front
- 1:44:41load and inside that we have to define
- 1:44:43the name and description. Now as I told
- 1:44:45you before that we need to define the
- 1:44:47convention also just like we have
- 1:44:48defined the developer instruction inside
- 1:44:50our custom sub agent. Same like that in
- 1:44:53a skill file we have to define the steps
- 1:44:55or the convention that what this skill
- 1:44:57should actually do when we call this
- 1:44:59skill in our prompt. So I'll just write
- 1:45:01a steps just a heading it should follow
- 1:45:03the space and then I'll paste my skills.
- 1:45:06So these are the skill it should follow.
- 1:45:08I'll just say that add the route to src
- 1:45:10server.js and follow the existing
- 1:45:13response shape. So if I just want to
- 1:45:15show you that how the shape actually
- 1:45:16looks like of my API route. So we can go
- 1:45:19to the services here. It should be
- 1:45:23available in our controller URL
- 1:45:26controller. And here we can see this.
- 1:45:28This is the way it created our API
- 1:45:30route. It has the error message as well
- 1:45:32as the status code for the success
- 1:45:34route. So we follow the same pattern. We
- 1:45:36say that whenever you're creating a new
- 1:45:38route, make sure that you have a data on
- 1:45:40success and error on failure and also
- 1:45:43matching the storage logic which is
- 1:45:45available in our store.js JS and all the
- 1:45:47relevant instructions or the necessary
- 1:45:49conventions which I want it to follow
- 1:45:51inside this skill I have mentioned here.
- 1:45:53Now just save this file. Now if I want
- 1:45:55to use this I can use just by say use
- 1:45:59which is the name API endpoint skill to
- 1:46:03create a delete route and in this way it
- 1:46:06will use my API endpoint. But before
- 1:46:08writing this prompt I want to first show
- 1:46:10or verify that whether this skill is
- 1:46:12available in our folder or not. So just
- 1:46:14remove this command for now. I want to
- 1:46:16first test it using the skill because we
- 1:46:18have this skills command. So let's see
- 1:46:20whether it is available using the skills
- 1:46:22command or we need to manually write the
- 1:46:23prompt to ask whether this skill is
- 1:46:25available or not. So let's say skills
- 1:46:28list skills and it says these are the
- 1:46:31skills available. These are my plugins
- 1:46:32as well as skills whether my custom
- 1:46:35skill is available or not. I may type it
- 1:46:36by manually. I'll say API endpoint and
- 1:46:40yes this skill is available. We can see
- 1:46:43this. It says that in the inside the
- 1:46:45codeex agent skills API endpoint skill
- 1:46:47is available. So we can use this skill.
- 1:46:49I'll just say use API/
- 1:46:53endpoint to create a delete route and it
- 1:46:57has read my skill. As you can see it say
- 1:46:59that explore readkll.md and it has
- 1:47:02searched my skill and it says that I
- 1:47:03found the skill and now I'm reading the
- 1:47:05content that is available in that skill
- 1:47:07and based on that it will create my
- 1:47:08delete route. So this is very useful.
- 1:47:10You don't have to explain everything in
- 1:47:12the prompt. If you are working with a
- 1:47:14repetitive task, you can just create a
- 1:47:15skill once and then you can just use
- 1:47:17that skill in your prompt. Now it says
- 1:47:19that the endpoint is implemented. I'm
- 1:47:21running a test command and this is what
- 1:47:23it has done. And now it has done with
- 1:47:24our task. It says that I have added the
- 1:47:27delete endpoint and what are the things
- 1:47:29it has changed and what is the behavior
- 1:47:32and it has completed the entire task in
- 1:47:331 minute 16 second and we can verify it
- 1:47:36URL controller also whether delete
- 1:47:38controller has been added or not. So
- 1:47:41yeah we have an delete short code and it
- 1:47:43follows the same pattern. Perfect. So
- 1:47:46this is what skills actually do. Now you
- 1:47:49can call this skills in two ways. Either
- 1:47:51you can call it explicitly just like we
- 1:47:54have called it right now or you can call
- 1:47:56it implicitly which mean if you do not
- 1:47:58mention the name of the skill then also
- 1:48:01it will understand whether this skill
- 1:48:03should be used in this task or not. So
- 1:48:05let's say if I just say that create a
- 1:48:06delete route. So what it will do it will
- 1:48:08just match my task with my skills that
- 1:48:10are available in my folder and it will
- 1:48:12look like whether is there any skill
- 1:48:14available in my folder which matches the
- 1:48:16task requirement and if it is available
- 1:48:18it will automatically inject that skill
- 1:48:21to that particular task and based on the
- 1:48:23instructions I have given in that skill
- 1:48:25it will use that to execute my task and
- 1:48:27why it is possible because we have
- 1:48:29defined the description in our skill.md
- 1:48:31file. This description basically help
- 1:48:33Codex to know whether this skill is
- 1:48:35useful for that particular task or not.
- 1:48:37So yes in this way you can use the
- 1:48:39skills create your own skill whenever
- 1:48:41you feel like that you have a repetitive
- 1:48:43task.
- 1:48:45So till this point we have learned about
- 1:48:47how we can create skills how we can
- 1:48:49create sub aents and also how we can
- 1:48:52connect any external application through
- 1:48:54plugins. But now what if you want to
- 1:48:56connect any application which is not
- 1:48:58available in plug-in. Let's say your own
- 1:49:00application. Now whenever you want to
- 1:49:02connect any custom application which is
- 1:49:04not a part of plug-in, we basically use
- 1:49:07MCP which stands for model context
- 1:49:10protocol. So in the past whenever any AI
- 1:49:13application wants to connect with any
- 1:49:16external application for the
- 1:49:17communication and for performing every
- 1:49:19action they basically follow the
- 1:49:21standard way of connection which is MCP.
- 1:49:24again model context protocol but now we
- 1:49:26have this plug-in option and all so we
- 1:49:28just click on one button and our MCP or
- 1:49:31I can say that app is able to connect
- 1:49:33with the codeex so here we'll see how we
- 1:49:36can connect our own application or maybe
- 1:49:38some different application using MCP but
- 1:49:41before that I want to give you a short
- 1:49:42overview of MCP also what it actually
- 1:49:44mean and what the main purpose of it so
- 1:49:47the main purpose you already understand
- 1:49:49that it actually help to connect with
- 1:49:50external application but MCP actually
- 1:49:54stands for model context protocol. So
- 1:49:56here model basically means a tool which
- 1:49:59we are currently using. Maybe it can be
- 1:50:01codeex, cloud code, copilot or any tool
- 1:50:04through which we are able to communicate
- 1:50:06or connect with our external
- 1:50:08application. The second term which is
- 1:50:10context. Now what does it actually mean?
- 1:50:13Whenever we are using any model and want
- 1:50:15to connect with any external
- 1:50:17application, we want to give a resource
- 1:50:19or context. what are the things it needs
- 1:50:21to perform inside that application. So
- 1:50:24all those context is a part of model
- 1:50:26context itself. Now the third term which
- 1:50:29is protocol. Now protocol basically
- 1:50:31means some set of rules and instructions
- 1:50:33which you define how it gets connected
- 1:50:35to that external application. So with
- 1:50:37this let's see how we can connect it.
- 1:50:39Now if I want to tell you also that till
- 1:50:41this point we have already seen the MCP
- 1:50:43although we have not discussed about it
- 1:50:45but somehow we have seen it. For
- 1:50:47example, if you remember that when we
- 1:50:48install any new plug-in that under the
- 1:50:50hood that plug-in or the application is
- 1:50:53actually behaving as an MCP. So for
- 1:50:55example, let me show you in the codeex
- 1:50:57app. If you go to the plug-in, you can
- 1:50:58see this I have this Figma plug-in which
- 1:51:00I have installed from here itself. Now
- 1:51:02if I show you that this Figma plug-in is
- 1:51:04actually a part of MCP. So I can go to
- 1:51:07the new chat and here I'll use the slash
- 1:51:09command which is /mcp
- 1:51:12and when I click enter it listed all my
- 1:51:14mcps that are available inside my codeex
- 1:51:17and you can see here Figma also listed
- 1:51:19under my MCP although it's a plug-in
- 1:51:21because plug-in is actually under the
- 1:51:23hood working as an MCP mcp the main role
- 1:51:26is to connect with an external
- 1:51:27application. So that's why Figma is
- 1:51:29available here and it is authenticated
- 1:51:31with oath and we are able to use Figma
- 1:51:33through our codeex. Now let's say if I
- 1:51:35want to connect any another application
- 1:51:37and for example if you want to connect
- 1:51:40my notion app so what I can do I can
- 1:51:42just go to the browser and search notion
- 1:51:44MCP and whatever the things it provide
- 1:51:46us to connect with that application we
- 1:51:48will follow all those step so let's go
- 1:51:50to the browser and here we'll just type
- 1:51:52notion MCP server and here it has
- 1:51:55already provided MCP so I can just click
- 1:51:57on this one it gives us overview I want
- 1:51:59to connect so I'll go with the
- 1:52:00connecting to notion MCP and here you
- 1:52:02can see it provides all the way to
- 1:52:04connect with MCP with different model.
- 1:52:06If you are using cloud code, you can go
- 1:52:08with this one. Cursor for this VS code
- 1:52:10cloud desktop winds surf GPD and this is
- 1:52:14for codeex. So if you want to use MCP of
- 1:52:16notion, we basically needs to paste this
- 1:52:19command which is MCP server notions and
- 1:52:21this is the URL. Now this is an URL. If
- 1:52:24you notice here, it follows HTTPS
- 1:52:26protocol because this is a remote
- 1:52:28access. So that's why we basically use
- 1:52:30this URL to connect this application.
- 1:52:32Now copy this. Once you copy this, you
- 1:52:34need to paste it inside your config.tml
- 1:52:36file. As you can see here, it also says
- 1:52:38that you need to paste inside your
- 1:52:40config.l file. So if you paste this
- 1:52:44insideex/config.ml
- 1:52:46file, your all project and codeex get
- 1:52:48access to that particular tool or I can
- 1:52:50say that notion app. But if you want
- 1:52:52that particular notion app inside a
- 1:52:54particular project only, then you can
- 1:52:57just create a config.l terminal file
- 1:52:59inside that project directory and there
- 1:53:01only you can mention this MCP server so
- 1:53:03that project can only access that notion
- 1:53:05app so but we'll focus only in the
- 1:53:07global ones we'll put this inside our
- 1:53:08configt file so just open your finder
- 1:53:11and here inside your user folder or I
- 1:53:14can say that home directory just open
- 1:53:16the hidden files and in this you can go
- 1:53:18to the docex folder and here we have
- 1:53:20configurl file just open this and here
- 1:53:23anywhere you can paste the MCP server as
- 1:53:25you can see here we have some MCP server
- 1:53:27also which we have seen in uh NCP list
- 1:53:29which is a node ripple as well as this
- 1:53:31Figma is also added here. So now just
- 1:53:34add this. I'll just paste it here as
- 1:53:36well like this. And now notion is added
- 1:53:39with this command. Just save this. The
- 1:53:42next step is we need to authenticate it.
- 1:53:44If you remember when we are adding the
- 1:53:46plug-in of GitHub, we basically use the
- 1:53:48gh login command to authenticate with
- 1:53:51our GitHub application. Same like that
- 1:53:54whenever you start using notion for the
- 1:53:56first time it will automatically prompt
- 1:53:58you to authenticate it with your notion
- 1:54:00app but you can also do this step before
- 1:54:03also so that it can automatically start
- 1:54:05doing your task. So very simple we can
- 1:54:08do in the VS code itself just open the
- 1:54:10new terminal and here we can see the
- 1:54:11step how we can authenticate. So go back
- 1:54:13to the browser and here it can says that
- 1:54:16you can install using Codex MCP login
- 1:54:18notion. So just copy this and paste it
- 1:54:21in your terminal. Now enter. It will
- 1:54:23authenticate us to the notion app. It
- 1:54:25will redirect to the notion browser. It
- 1:54:27says do you want to authenticate? I say
- 1:54:28yeah I recognize and trust this URL and
- 1:54:31click continue. And it says
- 1:54:32authentication complete. When we go back
- 1:54:34to the VS code we are now successfully
- 1:54:36logged in with the notion app. Now we
- 1:54:37can use this notion app through our
- 1:54:39codeex. We just give a simple prompt
- 1:54:40like create a new page for this
- 1:54:42particular notion app. It will able to
- 1:54:44create it. Let's try it out. So if I go
- 1:54:46just inside codeex terminal UI and I'll
- 1:54:48skip the update for now. And here let's
- 1:54:50say if I say create a page for NCP
- 1:54:54server nodes in notion. Now this is just
- 1:54:57a normal natural language prompt I have
- 1:54:59given to codeex and let's see whether it
- 1:55:01is able to authenticate with my notion
- 1:55:03application and able to create my page
- 1:55:05there or not. So just click enter and
- 1:55:07now it says I'll create a practical MCP
- 1:55:10server nodes and it has called my notion
- 1:55:12MCP server and it says that it has
- 1:55:14created just open this. Let's see how
- 1:55:16things work here. So let's click on this
- 1:55:18one open and we can see this it has
- 1:55:20created inside my own notion app with a
- 1:55:23proper structured manner in the table
- 1:55:25with examples all things are mentioned
- 1:55:28here with just one prompt and how this
- 1:55:29is possible because we have connected
- 1:55:31with MCP. So this is how you can connect
- 1:55:34any external application. Now if you
- 1:55:36notice here we have done this through
- 1:55:38config.tml file but there are other ways
- 1:55:40also to connect with the MCP server. For
- 1:55:42example, you can create it with the user
- 1:55:43interface inside a Codex desktop app or
- 1:55:46you want to go with the command, then
- 1:55:47you can go with the Codex CLI method
- 1:55:49also. So let's quickly see those two
- 1:55:50method also. So go back here and now
- 1:55:53suppose I want to connect a new
- 1:55:55application. So let's say if I want to
- 1:55:56connect this same application through
- 1:55:58CEX app then what I can do I just open
- 1:56:00my CEX and here you can just go to the
- 1:56:02settings or you can just even click on
- 1:56:04the from plugins here also and then from
- 1:56:06here you can also click on the setting
- 1:56:08button. So just click here. Now if you
- 1:56:09notice here in this we have these three
- 1:56:11MCPS right now this notion one also
- 1:56:13which we have added right now and this
- 1:56:15is from the plugins. So if I want to
- 1:56:17create a new plug-in through codeex
- 1:56:18desktop app I can just click on add
- 1:56:20server here. You can just define the
- 1:56:22name of your server. In our case I want
- 1:56:23to create a notion. So I'll just write
- 1:56:25here notion although we have notion
- 1:56:26server but I just want to show you how
- 1:56:28you can create from the app itself. Now
- 1:56:29once you define the notion here you need
- 1:56:31to paste the URL. But right now if you
- 1:56:34notice we have this two option which is
- 1:56:36stddio IO and the streamable HTTP. Now
- 1:56:39what does it actually mean? See stddio
- 1:56:41IO is basically used whenever you want
- 1:56:43to work with MCP in your local computer
- 1:56:45itself where things will not get hosted.
- 1:56:47Everything will remain inside your
- 1:56:49computer itself. In short in local
- 1:56:51environment but if you want to connect
- 1:56:53with the remote access like this notion
- 1:56:55app then you need to use streamable HTTP
- 1:56:58method. So just click on this option.
- 1:57:00Here you will find the URL option. just
- 1:57:02paste the URL. So again go back to the
- 1:57:04browser copy this URL. This one itself
- 1:57:06you don't need to copy the entire
- 1:57:07command and paste this inside URL
- 1:57:09option. Now if you notice here once you
- 1:57:11paste this it asks for the another thing
- 1:57:13also like barrier token headers and
- 1:57:15headers from environment variables. But
- 1:57:17right now you need to leave all these
- 1:57:18things empty because if you remember
- 1:57:21this notion app actually follows oath
- 1:57:24connection which basically means you
- 1:57:25don't have any token or the API key to
- 1:57:28put it here. You just use the URL and
- 1:57:30just click on save. It will
- 1:57:32automatically connect an MCP server.
- 1:57:34This barrier token and all things are
- 1:57:35required when you are actually having
- 1:57:37your own token. For example, if you have
- 1:57:39created your own spring boot application
- 1:57:41where you have JWT token and all and you
- 1:57:43have configured MCP server for your
- 1:57:45application at that time you have to
- 1:57:47configure those JWT token inside this
- 1:57:50barrier token. At that time it is only
- 1:57:52required. But I'll show you some
- 1:57:53application example also where this
- 1:57:55token is required. For example, if I
- 1:57:57want to connect the GitHub MCP, I'll
- 1:57:59just search here GitHub MCP server. And
- 1:58:02yeah, let's go to the first URL. And
- 1:58:04here, if you go to the readme file, we
- 1:58:06have an option for codeex. Just go on
- 1:58:08this one. And here you can see this. If
- 1:58:10you want to install or connect a GitHub
- 1:58:12MCP server, this is the prerequisite.
- 1:58:14You need to have a OpenAI codeex, which
- 1:58:17we are currently using. And the second
- 1:58:18thing, you need a access token, which is
- 1:58:20a personal access token from GitHub. And
- 1:58:22once you have these two things, you can
- 1:58:24just write this in your config.tml TML
- 1:58:26file as well as you have to config your
- 1:58:28barrier token environment variable. Now
- 1:58:30you don't have to put it directly inside
- 1:58:32your this config.ml file. Instead you
- 1:58:34can just put it inside your env file
- 1:58:36which you can later ignore using getit
- 1:58:38ignore. And now if you want to know how
- 1:58:40you can create your own personal token
- 1:58:41just click on this link. It will
- 1:58:43redirect you to this page. Here you can
- 1:58:45just define the token name and the
- 1:58:47description if you want to give for
- 1:58:48future reference and then whether it
- 1:58:50should be public all or only select
- 1:58:52repository. And then you can click on
- 1:58:53generate token. In this way you can
- 1:58:55create a token which you can just put it
- 1:58:56here back. If you just go back you can
- 1:58:59put that token here and then you are
- 1:59:01able to connect GitHub MCP server as
- 1:59:03well. So in this way these are two ways
- 1:59:05through which you can connect the MCP
- 1:59:06server. If I want to show you one more
- 1:59:08example. So I don't know how many of you
- 1:59:10know about this application which is
- 1:59:12Excel. This application which is
- 1:59:13basically used to create illustration or
- 1:59:16the diagram to explain the concept. So
- 1:59:18this application also have their own MCP
- 1:59:21server. So if you want to connect just
- 1:59:23click on this Excel draw MCP and here
- 1:59:25you'll get this MCP URL which you can
- 1:59:26just copy and paste it in your MCP and
- 1:59:29it also requires an API key. As you can
- 1:59:31see it says create an Excel draw plus
- 1:59:33API key. So you basically need Excel
- 1:59:36draw subscription which is a plus then
- 1:59:38only you are able to create an API key.
- 1:59:40But I just want to show you that Excel
- 1:59:41draw also supports a API method. So here
- 1:59:45if you want to install the API you need
- 1:59:47to first use that API here. Then only
- 1:59:49you are able to use Excel draw MCP
- 1:59:51server and after once you install Excel
- 1:59:54MCP you can just skip the prompt it will
- 1:59:56connect with Excel draw app and able to
- 1:59:59draw whatever you have defined in your
- 2:00:00prompt. Now let's see the another way of
- 2:00:02also creating an MCP server. We have
- 2:00:03seen the codeex app as well as from the
- 2:00:05config toml. But if you are working only
- 2:00:07with the codex cla then you can just
- 2:00:09open the codeex cla here. Here here as
- 2:00:11we are already open it in our VS code.
- 2:00:13Just write a command which is codex
- 2:00:15mcpad. If you just go back to the
- 2:00:16browser and look at the GitHub one, you
- 2:00:18can see this, it also supports to
- 2:00:20install GitHub MCP through Codex CLI.
- 2:00:23Just write the command this one codex
- 2:00:24mcp and then the name of the MCP in our
- 2:00:28case it is GitHub and then you use the
- 2:00:30flag which is - URL and then paste the
- 2:00:33MCP URL this one and then you need to
- 2:00:35paste the token which is a barrier token
- 2:00:37in our case. So I just copy this command
- 2:00:40and paste it here and I just replace my
- 2:00:42token with this one and we are able to
- 2:00:44use the GitHub MCP. So this is all about
- 2:00:46MCP through which you can connect any
- 2:00:47external application in your codeex.
- 2:00:51Now imagine in your project you have a
- 2:00:53multiple branches and you want to work
- 2:00:55all of your branches simultaneously.
- 2:00:58Well you are able to work with them.
- 2:01:00There are hactics. The first one is that
- 2:01:03you need to switch the branch multiple
- 2:01:05times by using the command get checkout.
- 2:01:07This is also okay. But the another thing
- 2:01:09is that if you want to switch to the
- 2:01:12next branch, you need to make sure that
- 2:01:14your current branch code is committed.
- 2:01:16If you have not committed it and try to
- 2:01:18switch, you might have seen the code or
- 2:01:20error in your terminal which says you
- 2:01:22need to first commit the code or stretch
- 2:01:25them before switching the branch. So
- 2:01:26these are the basic issues or the
- 2:01:28hectics you need to go through if you
- 2:01:30are working with multiple branches
- 2:01:32altogether. But what if I can say you
- 2:01:35you can work with all branches
- 2:01:37simultaneously even though you have not
- 2:01:39committed the code in your current
- 2:01:40branch. Now this is going to be possible
- 2:01:43through get work tree. What does the
- 2:01:45work tree actually mean by the way? See
- 2:01:47whenever you are working with work tree
- 2:01:49you are having multiple branches in each
- 2:01:52work tree and every work tree you can
- 2:01:54run simultaneously and you can switch
- 2:01:56the branch between them. Now to make it
- 2:01:58more clear let's go to the drawing board
- 2:02:00and understand with an example. Suppose
- 2:02:02I have one directory in my desktop
- 2:02:04folder which is a link forge. I want to
- 2:02:07show you on the desktop also just to
- 2:02:08make you verify. So in desktop we have
- 2:02:11only one work tree which is link forge
- 2:02:14and inside that work tree we have three
- 2:02:17branches. Let's assume we have a three
- 2:02:18branch which is a main which is a by
- 2:02:20default branch. The two branches are
- 2:02:23feature one Google and the second branch
- 2:02:25is feature two github. Now these two
- 2:02:28branches I have created because I want
- 2:02:30to work with these two branches
- 2:02:31simultaneously and look at the changes
- 2:02:33and all the things there. I'm not able
- 2:02:35to do this but I need to do the check
- 2:02:37out as I told you before. So how can I
- 2:02:39use a work tree here? When I use a work
- 2:02:42tree this will what happen inside my
- 2:02:45desktop I can create a multiple
- 2:02:47directories and each directory will have
- 2:02:49their own separate branch. So I have a
- 2:02:52link forge which is our main directory
- 2:02:54and it contains only one branch which is
- 2:02:56main and then I have created one
- 2:02:58separate directory. Now that directory
- 2:03:00is in my root folder which is in the
- 2:03:02desktop not inside my main directory
- 2:03:04folder. Remember this this is very
- 2:03:06important. So we have created a link
- 2:03:08forge one directory or we can say that
- 2:03:11work tree where it has only one branch
- 2:03:13which is feature 1/ Google and same I
- 2:03:16have created one more directory which is
- 2:03:18link forge 2 and it contains feature 2/
- 2:03:21gitaboth and now I can switch between
- 2:03:23these branches or directories without
- 2:03:26committing the code in one of the
- 2:03:27branch. So let's look at the practical
- 2:03:30way also. So go to the VS code now and
- 2:03:32here I'll open the terminal first and in
- 2:03:34this fresh terminal I first see where I
- 2:03:36am right now. So I'll just do ls. I have
- 2:03:39these files inside this folder. I need
- 2:03:40to know the directory also. So I'll say
- 2:03:42pwd. Okay. So when I run the command pwd
- 2:03:44we are inside our link forge folder. Now
- 2:03:46in this folder itself we will create a
- 2:03:49different folder or we can say that work
- 2:03:51tree. So to create a work tree we have
- 2:03:53to write a git command manually because
- 2:03:55in CLI it's not kind of possible.
- 2:03:58There's a no particular command is
- 2:04:00available in CLI. If I just want to show
- 2:04:02you if you go here let's say if I type a
- 2:04:04slash and want to show you then there is
- 2:04:06no work tree command is available
- 2:04:08through which you can create a work tree
- 2:04:09through codex cla. So you have to create
- 2:04:11it manually with the git commands and
- 2:04:14then you have to use codeex inside that
- 2:04:16particular directory. Although we'll
- 2:04:17look at the better way also how you can
- 2:04:19create the directory through the user
- 2:04:20interface but just now if you're using
- 2:04:22it in the CLI then you have to follow
- 2:04:24the git command. So where to create a
- 2:04:25git work tree? You have to write a
- 2:04:27command get work tree then add and then
- 2:04:32you have to define a path. So I want my
- 2:04:35work tree inside my desktop folder not
- 2:04:37inside my link forge. So I'll just use
- 2:04:40the path dot dot and slash. In this way
- 2:04:43I'm making sure that I'm creating inside
- 2:04:45a desktop folder. And here I'll define
- 2:04:47the name of my work tree whatever the
- 2:04:49name I want to give. So in my case I
- 2:04:51just call it as link forge one. And
- 2:04:54inside this I have to define the name of
- 2:04:56my branch. But one minute right now I
- 2:04:58don't have any branch. How will I define
- 2:05:00the name here? You have a two ways. Now
- 2:05:02here either you can create a branch
- 2:05:04first and then you can mention the name
- 2:05:05here or you can create the branch
- 2:05:07simultaneously along with your work
- 2:05:09tree. So you can do one thing here if
- 2:05:11you want to create you don't have to use
- 2:05:13this command. This command is only
- 2:05:14useful when you have existing branch and
- 2:05:16you only want to mention it. But to
- 2:05:18create a new branch along with a new
- 2:05:19work tree, you have to write the command
- 2:05:21add - b and then you have to mention the
- 2:05:24name of your new branch. So what I want
- 2:05:27now here so for my this project I want
- 2:05:30to create a branch for the delete route
- 2:05:32because if you remember we have created
- 2:05:33a delete route with functionality but
- 2:05:36that functionality is not used in the UI
- 2:05:38till now. So if I just want to show you
- 2:05:40on the UI you can see this here we have
- 2:05:43a copy button but the delete button is
- 2:05:45not available here. Although we have a
- 2:05:46backend code for this but it is not used
- 2:05:49till now in the UI. So we'll go here and
- 2:05:52I'll create a new branch and there I'll
- 2:05:54add that feature and later on I will
- 2:05:55merge it to the main branch. So I'll
- 2:05:57just write the name of my branch. I want
- 2:05:59it for the delete UI. So I'll just say
- 2:06:01delete
- 2:06:04or / UI just like this and then I'll
- 2:06:08define the name of my work tree. So as
- 2:06:10you know we have to define the path. So
- 2:06:11I'll just say dot dot slash. So it will
- 2:06:14create inside my desktop and now I'll
- 2:06:16say link forge one and when I click
- 2:06:19enter it says that preparing work tree
- 2:06:21and head is now at this particular
- 2:06:23commit hash id bind dev server to local
- 2:06:25host. Okay so we have created a work
- 2:06:27tree just verify whether this work tree
- 2:06:29available in my desktop or not. So open
- 2:06:31the finder and here yes this link for is
- 2:06:34available and when you open it we have
- 2:06:36all the code that is available in my
- 2:06:38main branch because we have created the
- 2:06:40new work tree from main branch itself
- 2:06:42that's why all code is available here.
- 2:06:43So okay so now we have created the work
- 2:06:45tree let's open this work tree in the
- 2:06:47new terminal and there we'll see whether
- 2:06:49that branch is available or not. So I'll
- 2:06:51open a new terminal and here first I'll
- 2:06:53see the directory I'm inside the link
- 2:06:55force. I need to go one directory back
- 2:06:57so that I can access my both directory.
- 2:07:00cd and ls we have now two directory so
- 2:07:04I'll now just say cd link forge one
- 2:07:08enter ls we are now inside the link
- 2:07:11forge one I can again try pwd just for
- 2:07:13verification and we are inside the link
- 2:07:15forge one directory so now in the two
- 2:07:18different terminal we are running two
- 2:07:19different branches one terminal is
- 2:07:21running for our main branch and the
- 2:07:23another terminal is running our link
- 2:07:26forge one branch or I can say that
- 2:07:28directory if I want to verify whether
- 2:07:29whether we have two branches or not. So
- 2:07:31I can just run a command which is get
- 2:07:33branch and it says we have two branch
- 2:07:36delete UI and main and you can see this
- 2:07:38delete UI is the current branch because
- 2:07:40in this terminal we are inside the link
- 2:07:42forge but if I run the same command in
- 2:07:44the new terminal and here if I go to the
- 2:07:47link forge we are in the link forge
- 2:07:48right now by the way and here if I just
- 2:07:50do get branch here it can say that you
- 2:07:53are in the main branch currently so
- 2:07:54that's also confirm that every work tree
- 2:07:56has their own separate branch link forge
- 2:07:58one contains delete branch and our link
- 2:08:01Forge which is the main directory
- 2:08:02contains our main branch. Now I can work
- 2:08:04with them simultaneously. I can just
- 2:08:06switch the terminal. I can run the
- 2:08:07different codecs inside them and I can
- 2:08:09delegate my work and then I can use it
- 2:08:12and push it on my GitHub without
- 2:08:14committing the branch code before
- 2:08:15switching it to the next branch. But as
- 2:08:18I told you before, we will see the
- 2:08:19better way also how we can create the
- 2:08:21work tree directly from the UI. Now to
- 2:08:23create it from the UI, we need to use a
- 2:08:25CEX app. So you can get a user
- 2:08:27interface. So let's go to the Codex app
- 2:08:29and see the better way of it. Now in
- 2:08:31this codeex app we need to first use our
- 2:08:33project which we have created from the
- 2:08:34codex cla. So I'll just click on choose
- 2:08:37project and this one this one I'll say
- 2:08:40new project. I want to create or upload.
- 2:08:43I'll say upload and desktop and I want
- 2:08:46my link forge. So I'll click on this
- 2:08:49open. So we have now this link forge.
- 2:08:51I'll say create project and my link
- 2:08:54forge folder is created. This is not the
- 2:08:56new project. It is a project which is
- 2:08:57already available in our system. So what
- 2:09:00we can do? We can create a work tree
- 2:09:02from here itself which is a link forge
- 2:09:04one. But one thing we need to do before
- 2:09:06that if I want to create a same work
- 2:09:08tree name I need to first remove it from
- 2:09:10here from my finder. This one I need to
- 2:09:12first remove this. So to remove this
- 2:09:15work tree you can run the command which
- 2:09:16is a get work tree remove. So I can just
- 2:09:19write a get work tree remove and then
- 2:09:22the name of the work tree which I want
- 2:09:24to remove. Although I can look at the
- 2:09:26list also before deleting. If I don't
- 2:09:28know the name of the work tree and I
- 2:09:29want to know how many work trees are
- 2:09:31available in my folder or in my
- 2:09:33directory I can just run a get work tree
- 2:09:35list and enter. It will source all the
- 2:09:38list of the work tree. Right now we have
- 2:09:39only two link forge and the link forge
- 2:09:41one. I want to delete the link forge
- 2:09:43one. I again run the command which is
- 2:09:44get work tree remove link forge one. And
- 2:09:49when I say enter it has removed. Let's
- 2:09:51verify it on the finder also. So you can
- 2:09:53see this now we don't have link forge
- 2:09:55one directory and even though we can
- 2:09:56verify by running the command again
- 2:09:58which is a get work tree list and it
- 2:10:00says unable to read current work
- 2:10:01directory no such file or directory
- 2:10:03available let me verify in which branch
- 2:10:05are we right now okay we are in the link
- 2:10:06forge but that directory is not
- 2:10:08available that's why it says so okay so
- 2:10:10I need to go one back and now I'll go
- 2:10:13inside link forge and here if I run the
- 2:10:16get work list again it shows only one
- 2:10:19workry directory which is a link forge
- 2:10:20one so in this way you can delete the
- 2:10:22directory also if their work has been
- 2:10:24done. So now let's get the same work
- 2:10:26directory from the codeex app also. So
- 2:10:28go back here. Here we are in the link
- 2:10:30forge and this is running on the local.
- 2:10:33So if you want to create a work tree
- 2:10:35from your link forge which has a main
- 2:10:37branch what you can do you can start the
- 2:10:39new chat all the way in the new chat
- 2:10:41right now. But if your session is
- 2:10:42running then you can click on the new
- 2:10:44chat to start the new chat and then you
- 2:10:46need to make sure you are inside your
- 2:10:47link forge folder as we are right now.
- 2:10:49And after that you need to click on this
- 2:10:51local. Right now everything running in
- 2:10:53the local. So you need to click on this
- 2:10:55local. And here you can see we get an
- 2:10:57option which is a new work tree. So this
- 2:10:59is what I'm talking about. By just using
- 2:11:01the user interface you can create a new
- 2:11:03work tree. So I'll say create a new work
- 2:11:05tree. And here I can set the environment
- 2:11:08also because when we are creating a new
- 2:11:09work tree all the dependencies and the
- 2:11:11required environment variables are not
- 2:11:13available by default. You need to set
- 2:11:15it. But in Codex app if you want to set
- 2:11:17it you can click on this no environment
- 2:11:19section because right now we don't have
- 2:11:21you can go to the environment setting
- 2:11:22from here itself or you can go from
- 2:11:24profile settings and here itself
- 2:11:28environments so these are the places
- 2:11:30where you can create an environment for
- 2:11:31your project. So next time when you
- 2:11:33create a work from that project it will
- 2:11:35fetch all the necessary environment the
- 2:11:37dependencies the all the API keys
- 2:11:39whatever you have inserted in your env
- 2:11:41files all the environment variables will
- 2:11:43get fetched to that work tree. Right now
- 2:11:45we don't have one so it will not ask any
- 2:11:47permission for us. I'll say let it be no
- 2:11:49work tree. It will get a new work tree
- 2:11:51from the main branch. So let it be
- 2:11:52mainly and we are in the new work tree.
- 2:11:54So now what I'll do I'll assign a task
- 2:11:56to the codeex to have a delete
- 2:11:58functionality on the UI based on my
- 2:11:59delete route. So I'll say create a
- 2:12:02delete button or maybe I'll say add a
- 2:12:06delete functionality on UI also and I
- 2:12:10have given it a full access permission
- 2:12:11so it will not ask me for any approval.
- 2:12:14Now when I say enter it says the work
- 2:12:16tree created and this is my work tree.
- 2:12:18Right now we have not defined the branch
- 2:12:20and when we are writing the get work
- 2:12:22tree there we get an option to define
- 2:12:24the branch at the same time. But in this
- 2:12:26the branch option will only come when
- 2:12:28you execute your task. So when we run
- 2:12:30this task it says create a branch. I'll
- 2:12:33create it once this code has been done.
- 2:12:34It has read my all the code. It says
- 2:12:36that the back end already support delete
- 2:12:37API. It is able to read because we have
- 2:12:40given the permission of our existing
- 2:12:41folder. That's why it is able to access
- 2:12:43all the code. Maybe I can access the
- 2:12:45file from here itself. If I go to the
- 2:12:46files, yeah, we have all the files. This
- 2:12:49is our folder. We have seen all this
- 2:12:51file in the VS code also. We can see it
- 2:12:53in the code example as well. Now, it has
- 2:12:55completed the task. It has done the
- 2:12:57thing. I can review it before pushing my
- 2:12:59code. So, I can just look at the
- 2:13:01changes. These are the all the changes
- 2:13:03it has done. As I can see in the
- 2:13:05app.jsx, this is the handle leader
- 2:13:07function. That means functionality has
- 2:13:09been added on UI and it has made some
- 2:13:11changes in the styling also and these
- 2:13:13are all the changes. Now I need to first
- 2:13:16create a branch for this particular work
- 2:13:19tree. So I'll just click on this create
- 2:13:20branch and here I'll define it has
- 2:13:23already given me the suggestion that
- 2:13:25which says add UI delete functionality.
- 2:13:27So this makes sense. I'll go with this
- 2:13:29particular branch name. Although if you
- 2:13:31notice that it has also created a prefix
- 2:13:33with the name codeex which let us know
- 2:13:35that this particular work tree and the
- 2:13:37branch is created by the codeex. So I
- 2:13:39just say create and it will create a
- 2:13:41branch and we can see this is my branch
- 2:13:43name. Now I can commit and push this
- 2:13:45changes. So I'll say yeah commit and
- 2:13:48push. So it is generating the message
- 2:13:49for me basically commit message and
- 2:13:52pushing changes and the commit has been
- 2:13:54pushed. Let's verify it on the browser
- 2:13:56also. So here if you go and you can see
- 2:13:59it says a codeex/ adduid delete
- 2:14:01functionality had recent posess 4
- 2:14:03seconds ago. So if I refresh the page
- 2:14:06and main we have now two branches. So
- 2:14:09from the codex app also we can able to
- 2:14:10push the branch and we can able to see
- 2:14:13the code also. Now once this work has
- 2:14:15been done I have done with this work
- 2:14:17tree. The next step is I need to
- 2:14:18deattach this work tree which we are
- 2:14:20able to do from the get command also. We
- 2:14:22have seen the get work tree remove
- 2:14:23command through which we can remove the
- 2:14:25work tree. But in the codeex app if you
- 2:14:27want to remove the work tree you need to
- 2:14:29first shift your branch to your main
- 2:14:31directory which is a link forge where
- 2:14:33your main branch is already available.
- 2:14:35So what we can do here if you look at
- 2:14:37this work tree option I'll just click on
- 2:14:39this it says a local checkout. So when I
- 2:14:42click this on local checkout it says
- 2:14:44where you want this branch should go.
- 2:14:46Right now it is in the link forge one
- 2:14:49directory but from that directory it
- 2:14:51will shift to the link forge directory
- 2:14:53which is my main directory and it also
- 2:14:55contain my main branch. So I'll say hand
- 2:14:57off my this branch to the link forge. So
- 2:14:59I'll say hand off and now it has hand
- 2:15:01off my work. So if I go back here you
- 2:15:04can see this we are in my main branch.
- 2:15:06If you look at here this is my main
- 2:15:08branch. This is my codeex add UI delete
- 2:15:11functionality and this is the delete UI.
- 2:15:12This is one I think we have created from
- 2:15:14the get command. That's why it shows but
- 2:15:16this one doesn't exist I know. So now we
- 2:15:19have this branch in our main directory
- 2:15:20along with the main branch. The next
- 2:15:22step is we need to merge this branch to
- 2:15:25the main branch code and then we need to
- 2:15:27delete this branch. This is the actual
- 2:15:29flow goes on with the GitHub. First step
- 2:15:31if I want to repeat we need to create a
- 2:15:33separate work tree from your main
- 2:15:35directory from your main branch itself
- 2:15:37and there you can do your work and once
- 2:15:40your work has been done to that work
- 2:15:41tree you deattach your branch from that
- 2:15:43work tree and push that branch code to
- 2:15:46your main directory where your main
- 2:15:48branch is also available. So as you can
- 2:15:49see here we have now two branches. The
- 2:15:51next step is create a pull request for
- 2:15:53this branch and merge that code to the
- 2:15:55main branch. So we can have a option
- 2:15:57here which is a create pull request. I
- 2:15:58just simply click on this. It says
- 2:16:00create a PR. I say okay create it. It
- 2:16:02will generate a meaningful message and
- 2:16:04it has created a PR for my branch which
- 2:16:06is add UI delete functionality. Let's go
- 2:16:08back here and here if you go to the pull
- 2:16:11request we can see this we have a branch
- 2:16:13name and it is open pull request. Now we
- 2:16:16can close it from ourself manually from
- 2:16:18here itself. But I'll do it by codeex.
- 2:16:21So go to the codeex app. We don't have
- 2:16:23any user interface option to merge the
- 2:16:25branch. So I can just simply type a
- 2:16:27prompt here. I'll say merge a PR.
- 2:16:29Although practically we do not directly
- 2:16:30merge a branch. We need to first review
- 2:16:32the changes and after that all the
- 2:16:34changes or test cases pass then only we
- 2:16:36merge the branch. But right now we
- 2:16:37believe that Codex has done everything
- 2:16:39perfect. So we can directly merge it
- 2:16:40without review. I'll say merge appear
- 2:16:43and perfect it has merged our PR to the
- 2:16:46main. We can verify it now the browser
- 2:16:48also. So just go here and here when we
- 2:16:51go to the code we can see this a commit
- 2:16:53message which says merge pull request.
- 2:16:55And even though if you go back to the
- 2:16:56pull request, we can see this no one has
- 2:16:58opened. Now we can see this our current
- 2:17:00pull request has been closed now. And
- 2:17:02even though it has also deleted my
- 2:17:04branch because that work has been done,
- 2:17:05we have merged it to the main now. So if
- 2:17:07you go to the code, we click on the
- 2:17:08main, we can see this now only one
- 2:17:10branch is available. Even though we
- 2:17:11click on the view all branches, only one
- 2:17:13branch is available. The delete
- 2:17:15functionality branch has been deleted
- 2:17:16because we have merged it to the main.
- 2:17:18So in this way work tree actually work.
- 2:17:20You can work it simultaneously. You have
- 2:17:22a different branch in the different work
- 2:17:24tree. So without committing the code in
- 2:17:25your current branch, you can switch the
- 2:17:27branch and work simultaneously. So I
- 2:17:29hope this makes you understand how it
- 2:17:31actually works and how you can create
- 2:17:33your own work tree for your project.
- 2:17:37Now we are almost done with all the
- 2:17:39concepts of codeex. Only few things are
- 2:17:41left which is integrating this into a
- 2:17:44production database and also deploying
- 2:17:46it on the hosting platform. So first
- 2:17:48we'll go with the integrating where
- 2:17:50we'll integrate our database. So
- 2:17:52basically we are going to use neon
- 2:17:54database where we have a serverless post
- 2:17:56gray and we'll host our database there.
- 2:17:58Now we can do this with the codex
- 2:18:00itself. We have to just install a
- 2:18:02plug-in which is a neon plug-in. Now
- 2:18:04from the codex cla you can't able to
- 2:18:06install a plug-in for your requirement.
- 2:18:09But you can go to the chat jp account on
- 2:18:11the browser. Then there you can select a
- 2:18:12plug-in which you want to use and you
- 2:18:14can install it. And if you have a codex
- 2:18:15app you can install from your codex app
- 2:18:17itself. Just go to the plugins option
- 2:18:19and here you can search the plug-in
- 2:18:21based on your requirement and you can
- 2:18:22install it. So as you can see I have
- 2:18:24already installed the neon postgrade
- 2:18:26because this is what we are going to use
- 2:18:27to integrate our database and host it
- 2:18:30there. So now instead of doing all the
- 2:18:32things from codeex app we'll go back to
- 2:18:35the codeex cla code and from there we'll
- 2:18:37integrate our database. So now we are
- 2:18:40already running with the codeex.
- 2:18:41Although before integrating to the
- 2:18:43database, I want to also show you that
- 2:18:44we have a delete functionality on the UI
- 2:18:46which we have done in the previous
- 2:18:47lecture. So if I go back to the UI, you
- 2:18:50can see this we have now delete button
- 2:18:51and it's working perfectly. If I just
- 2:18:53click on this delete, it will delete my
- 2:18:55URL. And if I paste it again and shorten
- 2:18:58my URL is added, I can again delete it.
- 2:19:00So now let's use a plug-in which is a
- 2:19:02neon DB to integrate the database. So we
- 2:19:04can see that we are storing everything
- 2:19:05inside our inmemory. So we need to now
- 2:19:07shift it to the production database. So
- 2:19:09I can just call the plug-in. I'll just
- 2:19:11say add the rate neon and this is my
- 2:19:14plug-in. I'll say neon postgrade and
- 2:19:16here I'll say
- 2:19:18shift my inmemory database to neon
- 2:19:22serverless postg gray. And now I just
- 2:19:25click enter. Now I'm able to use this
- 2:19:27neon postgrip plug-in because I have
- 2:19:28already installed it as I told you
- 2:19:30before. But when you install it, it will
- 2:19:32first ask for the authentication. It is
- 2:19:34not only about using the plug-in by just
- 2:19:36installing it. You need to also connect
- 2:19:37it with the codeex just like we have
- 2:19:39done for the GitHub where we
- 2:19:40authenticate our account. Same like that
- 2:19:42you need to authenticate your neon app
- 2:19:44so that it can run your and communicate
- 2:19:46with your application flawlessly. So we
- 2:19:48have already done this that's why I'm
- 2:19:50able to use it. I'll just say enter. It
- 2:19:52will start running. It will create
- 2:19:53automatically project or the database
- 2:19:55inside my neon dashboard and where it
- 2:19:57will also create a table and all the
- 2:19:59records whatever we are going to do in
- 2:20:01our UI. So at the time it is doing
- 2:20:04changes in our code. We can just go to
- 2:20:05the neon dashboard from UI and see how
- 2:20:07the things are going on there. So this
- 2:20:09is my neon console. I'll just open it
- 2:20:11here. Okay. So these are the project.
- 2:20:14These are my previous project. We have
- 2:20:15link forge link web I'm testing. I have
- 2:20:17done this for practice purpose. As you
- 2:20:19can see the timeline also 2 days ago.
- 2:20:21It's not current one. So we'll have to
- 2:20:23wait before it get a new project and
- 2:20:25then we are able to see that project
- 2:20:27here itself. So let's go to the VS code
- 2:20:29back and see how it's working. Okay.
- 2:20:31It's need an approval. I'll say yes.
- 2:20:37Okay. So, it has done with the task. It
- 2:20:39takes around 2 minute 55 seconds to
- 2:20:41complete. And I think everything has
- 2:20:43been done. Let's see how the things goes
- 2:20:45on there. So, if you go here and now if
- 2:20:48you refresh the page,
- 2:20:50yes, we are able to see a project which
- 2:20:52has created a minute ago. We can open
- 2:20:54this project. We can look at the tables
- 2:20:56also whether it has created a one or
- 2:20:58not. And right now it says zero tables
- 2:21:00in public schema. So let's see whether
- 2:21:03it has created or not. Create the short
- 2:21:05URL table in neon. Okay, it says that
- 2:21:07you have to create it manually. But I
- 2:21:09don't want to do anything manual by
- 2:21:10myself. I'll go with the codeex itself.
- 2:21:12So I'll say create a table also. Create
- 2:21:16a table also. Okay. Now it is creating a
- 2:21:19short URL table. Allow. Okay. So it has
- 2:21:22created the short URL. Let's go back
- 2:21:23here and refresh. Yes, now short URL
- 2:21:28table is available. We can go to the
- 2:21:29columns to see. Yeah, these are the
- 2:21:31columns available. Code, original URL,
- 2:21:33short URL and created at perfect. So now
- 2:21:36table has been done. Database is also
- 2:21:38set if I'm not wrong. If I go to the
- 2:21:40env. Yes, database URL, base URL, host
- 2:21:43and port. Everything is set here.
- 2:21:45Perfect. Now it's time to test whether
- 2:21:47things are actually getting saved in our
- 2:21:48production database or not. So here
- 2:21:50we'll add one link. Now let's say this
- 2:21:52one. And when I say shorten all that is
- 2:21:54still shows store is local only but
- 2:21:56right now it's running a production
- 2:21:58database. Okay. So it has now converted.
- 2:22:00We have this original and the shorten
- 2:22:01link. Now let's see whether it is
- 2:22:03available in our database or not. So
- 2:22:05let's go here. And now if you refresh
- 2:22:07the table. Yes, we are able to get the
- 2:22:09records in our table. And it is now
- 2:22:11remain here even though we'll close the
- 2:22:13server because right now our database is
- 2:22:16available in hosted platform. Now if I
- 2:22:19delete it from here, let's see whether
- 2:22:20the database get deleted or not. So if I
- 2:22:22delete and now if you go back here and
- 2:22:24if you refresh the table. Okay. So data
- 2:22:26has been deleted successfully from here
- 2:22:28itself. So in this way we have
- 2:22:29integrated our database only from the
- 2:22:31codeex cla itself. You just need to
- 2:22:33install the plug-in and authenticate it
- 2:22:35with your neon dashboard and you are
- 2:22:37ready to go to integrate your database
- 2:22:39from codeex cla itself.
- 2:22:42Now only one last thing is left which is
- 2:22:44deploying this application so that we
- 2:22:46can share with anyone. So let's go to
- 2:22:49the codeex cli back and see how we can
- 2:22:51do it from there itself. Now just like
- 2:22:53we have integrated our database using
- 2:22:55the neon postgrip plug-in same like that
- 2:22:57we will use versel plug-in. So as I told
- 2:22:59you before that if you want to install a
- 2:23:01plug-in either go to the chat GPD
- 2:23:03browser and from there you can install
- 2:23:04the plug-in or if you have a codex app
- 2:23:06from there also you can install the
- 2:23:08plug-in. So I'll just show you how the
- 2:23:09plug-in looks like. If you go here you
- 2:23:11can see this is overell plug-in just
- 2:23:13install it and now once you install it
- 2:23:15will ask you for the authentication. Now
- 2:23:17it will not just like a neon database
- 2:23:19where you just install the plug-in and
- 2:23:21it will authenticate by just through
- 2:23:23app. If you want to authenticate your
- 2:23:24versel account you need cla so that it
- 2:23:27can authenticate your account using
- 2:23:29commands. So go to the browser and here
- 2:23:32search
- 2:23:34and here just click on this you will get
- 2:23:38this command which is pnpm i - gel. If
- 2:23:42you are using the npm version only then
- 2:23:44only copy the command till here because
- 2:23:46we are not using the pnpm. So just copy
- 2:23:49this paste it on the terminal and you
- 2:23:51are able to use versel cla. So just open
- 2:23:53the terminal and here I have already
- 2:23:55installed it. So I just verify whether
- 2:23:56versel is available or not and it says
- 2:23:58that cla is available with the version
- 2:24:0056.5.0.
- 2:24:02So once you install the versel cla then
- 2:24:04install the versel plug-in also and then
- 2:24:06it will authenticate you through versel
- 2:24:08cla. Now I just use a plug-in now which
- 2:24:11is versel. I'll say add the date to
- 2:24:13versel and I'll say deploy this
- 2:24:15application and just say enter. At the
- 2:24:17time it is deploying. Let's open the
- 2:24:18versel on the browser also. So this is
- 2:24:20my versel account and here we'll able to
- 2:24:22see our versel project which is created
- 2:24:24by codeex. So let's go back here and see
- 2:24:27the progress. It has given me some
- 2:24:28error. It says I can't deploy this app
- 2:24:30to versel without changing the back end
- 2:24:32shape. Why? The front end is v react is
- 2:24:34deployable. The back end is standalone
- 2:24:35express. I convert the back end to
- 2:24:37versel compatible. I deploy only the
- 2:24:39front end to version and point it to the
- 2:24:41separately. I keep the current
- 2:24:43architecture and deploy it somewhere. I
- 2:24:45think the problem is that we have not
- 2:24:46committed all those codes. So that's why
- 2:24:48not able to fetch the latest one. So I
- 2:24:50need to first commit this. I'll say push
- 2:24:52my code on GitHub. Okay, it has now
- 2:24:55pushed. Let's go back to the versel
- 2:24:57command. And now let's try to deploy
- 2:24:59again.
- 2:25:01Okay, still the problem. It says I
- 2:25:03convert the back end to versa serverless
- 2:25:04functions and deploy the full
- 2:25:06application. Okay, that's what I want.
- 2:25:08So I'll say deploy my full application.
- 2:25:16Okay, so it has done with the task. It
- 2:25:18has deployed my application on Versel.
- 2:25:20And this is the URL for the Versel. But
- 2:25:22before opening this URL, I want to
- 2:25:23verify it on the UI also in Versel
- 2:25:26dashboard. So here if you go to the
- 2:25:28deployment, yes, we can see this. This
- 2:25:30is a current deployment done by a
- 2:25:32versel. It has done the multiple
- 2:25:33deployments uh 14 seconds 12 seconds
- 2:25:36back. So it done the multiple iteration
- 2:25:38just to verify whether things work or
- 2:25:39not and it has after multiple iteration
- 2:25:42created a URL for us and it's time to
- 2:25:44verify it. So just copy this and paste
- 2:25:47it on the browser. Okay, our application
- 2:25:49has opened. Let's try it out. Let's
- 2:25:51paste this shorten. So it has shortened
- 2:25:54the URL. The thing is that it is still
- 2:25:56using a local URL when it convert into a
- 2:25:59short URL. So we need to change this so
- 2:26:01that it can actually deploy it on the
- 2:26:02versel live URL instead of a local host.
- 2:26:05So I'll just say here in the prompt it
- 2:26:08convert the URL or I'll say shorten the
- 2:26:10URL with local host instead of versal
- 2:26:15URL.
- 2:26:20Okay. So I think it has now fixed the
- 2:26:22issue. Let's go back to the UI. So let's
- 2:26:24paste the URL here. Shorten. And it has
- 2:26:26now shortened it. And now it is in the
- 2:26:28versal UI. So if I just click on this
- 2:26:30short link, it should redirect me. But
- 2:26:32it is not redirecting me. Let me do the
- 2:26:35console. What's the issue? If we click
- 2:26:37on this. Okay, it opens in the new tab
- 2:26:39but with the same one. Let me try the
- 2:26:41delete functionality also. Okay, delete
- 2:26:43is also not working. Let's inspect it.
- 2:26:45Okay, delete method not allowed. Okay,
- 2:26:48so this is the issue. Let's try it out
- 2:26:49with the codeex. I'll just copy this
- 2:26:51issue to codeex and say why it's not
- 2:26:53working. I'll also explain that when I
- 2:26:56click on shorten URL, it's not working.
- 2:27:00So now let's test it out whether things
- 2:27:02are working or not. So here we already
- 2:27:04have these two recent links. So first
- 2:27:05we'll delete this and then we'll paste a
- 2:27:07new one. So delete this one and delete
- 2:27:09this one as well. And now let's paste a
- 2:27:12new one. I'll go with this GitHub
- 2:27:14shorten. Okay, we have now this one. And
- 2:27:16if you paste the Excel draw one, we have
- 2:27:18now these two. And even though if you
- 2:27:20open this shorten URL, it works perfect.
- 2:27:23If you open the second one, this one is
- 2:27:24also working. So our functionality is
- 2:27:26working. The only thing is that we need
- 2:27:27to check whether these data are
- 2:27:29available on our database or not. So
- 2:27:30just go to the neon console and here if
- 2:27:33we refresh, this is our old data I
- 2:27:35think. So if you refresh, yes, we have
- 2:27:37now new data as you can see this code
- 2:27:39has also changed if you notice at the
- 2:27:41time of refresh. Although you can verify
- 2:27:42it once again by deleting it. So let's
- 2:27:44delete this one. And now if you go back
- 2:27:47refresh yeah it has deleted. Delete the
- 2:27:49this one also. And now go back again and
- 2:27:51refresh. And this one is also deleted.
- 2:27:53Perfect. So all the things are working.
- 2:27:55We have deployed it on the versel. We
- 2:27:57got the URL also from the versel. And
- 2:27:59also we have connected our database.
- 2:28:01It's working fine. We are able to delete
- 2:28:03the records. So in our application is
- 2:28:06working fine which we have created
- 2:28:07through codeex only. So that's all about
- 2:28:10this entire codeex series. I hope you
- 2:28:12enjoyed it. How it actually works. We
- 2:28:14get to know about many more things like
- 2:28:16skills, agents.mmd file, work tree and a
- 2:28:19lot more. Try it out by yourself. see
- 2:28:21which one is working perfect for you.
- 2:28:22Although I want to show you one more
- 2:28:24thing whether how we can use it in the
- 2:28:26ID also because we have not discussed
- 2:28:28it. Everything will remain same in ID as
- 2:28:29well just like we have discussed in the
- 2:28:31codeex CLI only the interface will get
- 2:28:33changed. So in whatever the interface
- 2:28:34you are comfortable you can just go with
- 2:28:36them. I'll just give you the quick
- 2:28:38overview of the codeex ID extension. So
- 2:28:41if you can look at here when you go to
- 2:28:42this section here you can install a
- 2:28:44codeex ID. As you can see this one when
- 2:28:47you click on this install it and when
- 2:28:49you install you will get this option in
- 2:28:50the sidebar just click on this and this
- 2:28:53is how you can able to use ID extension
- 2:28:56of codeex in your ID itself just give a
- 2:28:58file whatever you want to give just open
- 2:29:00this you can just attach a file use a
- 2:29:02plug-in just like we have done in the
- 2:29:04codex cli and the codex app everything
- 2:29:06will remain same so based on your
- 2:29:07preference you can use any one of the
- 2:29:09interface and go with that so that's all
- 2:29:11about the codeex bye
About this transcript
This page contains the full transcript of OpenAI Codex Complete Tutorial by Telusko, generated from the public captions YouTube serves with the video. The transcript has 33,289 words across 4,434 segments, with the original timestamps preserved so you can click any line to jump to that moment in the embedded player.
What you can do with it
Use the transcript to take notes, quote the speaker, build a study guide, generate a summary with ChatGPT or Claude via the YouTube Summary tool, or export it as a timed subtitle file with YouTube to SRT. You can also re-open it in the transcriber to choose a caption track available on the video.
Free YouTube transcript tool
YouTube2Text is a free YouTube transcript generator — no signup, no daily limit. Paste any YouTube link and get the full transcript instantly, with timestamps, click-to-jump, caption language selection, AI prompts for ChatGPT, Claude, and Gemini, and exports to TXT, SRT, VTT, or Markdown.