Better than Copilot? This AI plugin for Neovim is Incredible

  Рет қаралды 66,799

Dreams of Code

Dreams of Code

Күн бұрын

To try everything Brilliant has to offer-free-for a full 30 days, visit brilliant.org/DreamsofCode . The first 200 of you will get 20% off Brilliant’s annual premium subscription.
When it comes to A.I. plugins for Neovim, Copilot is the most well known out there. However, there are other plugins that can provide additional features Copilot can not.
In this video, I look at one of these other plugins, and showcase how to generate tests, fix bugs and have code explained with it, as well as some other features that are really fun to use.
⚠️ NVChad has had some breaking changes, make sure to use the v2.0 branch if you're using this video. You can find the command below.
Commands:
NVChad Install line: git clone -b v2.0 github.com/NvChad/NvChad ~/.config/nvim --depth 1
This video was sponsored by Brilliant
#neovim #ai #coding
My socials:
Twitter: / dreamsofcode_io
Discord Server: / discord
My Equipment:
Voice over: kit.co/dreamsofcode/voiceover
Coding: kit.co/dreamsofcode/coding
Please consider supporting me as well!
Patreon: / dreamsofcode
Video Links:
Custom Config: github.com/dreamsofcode-io/ne...
NVChad: nvchad.com/
ChatGPT.nvim: github.com/jackmort/chatgpt.nvim
My fork: github.com/dreamsofcode-io/ch...
00:00 Intro
00:58 Getting Started
04:05 ChatGPT command
06:26 Complete Code
07:04 Add Tests, Fix Gugs, Explain Code
09:01 Edit Code with Instructions
10:07 Act as

Пікірлер: 129
@dreamsofcode
@dreamsofcode Жыл бұрын
To try everything Brilliant has to offer-free-for a full 30 days, visit brilliant.org/DreamsofCode . The first 200 of you will get 20% off Brilliant’s annual premium subscription.
Жыл бұрын
As the author of this plugin, I must say, this video is excellent! Would you mind adding a link to it to the README ?
@avi7278
@avi7278 Жыл бұрын
I don't think you need permission to link to anything. That was decided early on in the internet's existence.
@dreamsofcode
@dreamsofcode Жыл бұрын
I would not mind at all! And thank you for the wonderful plugin!
@-Kal-
@-Kal- Жыл бұрын
Thanks for creating it! I use it all the time along with copilot.
@ayushgun
@ayushgun Жыл бұрын
Are there any plans to add a similar plugin for VSCode?
@gustavojoaquin_arch
@gustavojoaquin_arch Жыл бұрын
​@@ayushgun i suppose 🏳️‍🌈?
@56phil020244
@56phil020244 11 ай бұрын
Great start. I'd like to see you do a full series on this plugin. Thanks.
@seraphimwang
@seraphimwang Жыл бұрын
Amazing explanation as usual. I knew this plug-in but explained by you it is better and worth to try. Thanks for your effort and time
@madsrobinhavmand8813
@madsrobinhavmand8813 9 ай бұрын
Amazing seeing the "api_key_cmd" config option mentioned here! Think it's the first time my code (I added the 66 lines of code that it consists of) is mentioned on KZbin xD
@williamseipp9691
@williamseipp9691 5 ай бұрын
it seems like a trivial problem, but copy pasting code into gpt is indeed cumbersome enough for me to not do it. Having gpt right in nvim so I can bounce ideas off of it "is this code awkward?" "explain what lines 5-11 are doing in greater detail" will be such a boost. great video as usual
@shynsky
@shynsky Жыл бұрын
I'd love to see your keyboard strokes as I'm not proficient with nvim yet and seeing them would help a ton. Keep up the great work!
@dreamsofcode
@dreamsofcode Жыл бұрын
I shall try and find a solution that works! It might be something I add in post production moving forward! Thank you for the feedback.
@marcuswest8085
@marcuswest8085 Жыл бұрын
(not sure if this is what you are asking) kzbin.info/www/bejne/q6PGfWtsitWkkMU, oops, wrong one, kzbin.info/www/bejne/rZ21ZpqPmZuoo5I
@rolandcucicea6006
@rolandcucicea6006 2 ай бұрын
get a keyboard remapping software (I'm using keyboard maestro on macos) on windows there's autohotkey that's quite popular, though harder to use. that way u can set up a keyboard shortcut and have it simulate the keypresses
@arthurflegenheimer7060
@arthurflegenheimer7060 24 күн бұрын
I think the video is about the functionalities of the plugin, not about how to use vim. If you struggle to profit from the content and think that seeing the key strokes would help, then your problem isn't vim keybinds, you should first try to understand the ontology of the processes and the general concepts of working with modular software. What is the core development philosophy of Linux? Not that it's free, but that all things are files with little programs that serve a particular purpose and do just that and not more. Likewise, this video is excellent and does its job really well: it explains what the plugin does, how to work with the OpenAI API, shows you the Lua code and reminds you to be cautious about just storing a secret in plaintext, it explains the preset roles, gives you an estimate of cost, etc. Now, bloating it with key strokes flashing over the screen would be superfluous and distracting, unnecessarily tedious for the guy who runs the channel and.potentially confusing even, for somebody who then tried to make sense of why that extra effort was put into it, waiting for the big reveal while missing the video. So, nothing here has to do with vim keybindings or vim in general, it's about the plugin. When somebody makes a video to explain you how record a macro that deletes two words, jumps to the next line, replaces the content between brackets with this and that and adds a semicolon to the end of the line, then yes, keystrokes can help and there's nothing wrong in asking people for the extra work, but here you're just being a Karen. Okay, a Karen in sweet mode maybe, but you get me, you're expecting it on a silver platter that mostly only text is being typed and pasted here with no special key bindings used, apart from maybe the mention of confirming with Ctrl+Y, which probably comes from the nhrsh7th/nvim-cmp. Imagine adding al the strokes in post production just because you asked for it, and then the Ctrl+Y one would probably end up the only one not completely trivial.
@ClaudioPascual
@ClaudioPascual 6 ай бұрын
Awesome video!
@niteshtudu6449
@niteshtudu6449 Жыл бұрын
Love your videos bruh. Can you make a video about code folding in neovim. Really appreciate your effort🙏
@dreamsofcode
@dreamsofcode Жыл бұрын
I shall add it to the backlog!
@cyrusrohail9243
@cyrusrohail9243 8 ай бұрын
Hi, I want to get an api key myself but I wanted to ask your review after its usage, its been about 4 months, have you been using the api in these 4 months? And if yes what has your usage pricing evaluated up to?
@Mechacookie
@Mechacookie Жыл бұрын
Amazing content!
@dreamsofcode
@dreamsofcode Жыл бұрын
Thank you!
@vando2108
@vando2108 Жыл бұрын
please do a video for typescript, react and nodejs, thank you
@user-iq3tz8yz4h
@user-iq3tz8yz4h 6 ай бұрын
Amazing! Btw How to display the usage of token every time I ask chatGPT in terminal? mine it doesn't see that. something wrong with my settings?
@rolandwarburton387
@rolandwarburton387 2 ай бұрын
Hi friend did you ever figure out how to display the token usage?
@potatopc3048
@potatopc3048 Жыл бұрын
which software do you use to make these videos? It look awesome
@dreamsofcode
@dreamsofcode Жыл бұрын
I use Davinci resolve for most of the timeline editing, and I use After Effects for any motion graphics compositions. I should do a video on it! Thank you for the feedback!
@mattshirlaw3092
@mattshirlaw3092 7 ай бұрын
Does the add tests command always append tests to the current buffer? Is there a way to append to a separate test file?
@niksingh710
@niksingh710 Жыл бұрын
nice video mate. waiting for the python data science video.
@marcuswest4572
@marcuswest4572 Жыл бұрын
If Elliot applies all this in a Nixos config/flake, I'd pay money for his config. Sadly I think he is a Mac User
@LeungWong
@LeungWong 5 ай бұрын
How did you get the token count shown in the video? Seems like this question has been asked, but no one has gotten answer for it yet, nor has the author of this video replied to it.
@ongayijohnian8787
@ongayijohnian8787 4 ай бұрын
You should have like more than a million subs 💯
@maciejgebarski7850
@maciejgebarski7850 4 ай бұрын
Hi Dream of Code, thanks for the great video. I have one question about the ChatGPT plugin. I often have responses cut off (for example, when I ask it to write tests, the code cuts off suddenly in half). Do you experience this kind of problem?
@alxchiri
@alxchiri 4 ай бұрын
Check the plugin configuration. It has a config of max 300 tokens, that might explain why some responses get cut off.
@Vcshahriyer
@Vcshahriyer 5 ай бұрын
@dreamsofcode Brilliant content ! but pass don't ask for master pass on new terminal session or nvim , I had to manually trigger the pass show command before any new session. Please suggest any better solution Thanks.
@nikob381
@nikob381 Жыл бұрын
Any estimate to approximately how much it would cost if you regularly use this in your day-to-day work? This looks much cooler than Copilot (especially since nvim hasn't gotten any of its new Copilot X features), but I at least like that I just pay a steady monthly fee for copilot, rather than having to guess the fee based on my usage.
@dreamsofcode
@dreamsofcode Жыл бұрын
I agree, it's nice to pay a one off fee and that's it. Although this would probably be no where near the cost of copilot. It's actually $0.002 per 1000 tokens. My total usage for the video was $0.03 (that includes research and playing around with diff scripts). You can set a hard usage limit so you won't exceed $10 a month as well. Ultimately, GH is making a profit on copilot, so direct to GPT should be cheaper.
@nikob381
@nikob381 Жыл бұрын
@@dreamsofcode Perfect, and thanks for the quick reply as well! Just finished setting it up along with Pass, and I'm excited to try it out!
@moeruishi
@moeruishi Жыл бұрын
Amazing tutorial.
@dreamsofcode
@dreamsofcode Жыл бұрын
Thank you!
@anurag9385
@anurag9385 Жыл бұрын
I'm really interested in setting up Astro in Neovim using NVChad, but I'm having trouble finding a good tutorial. Could you please create a video where you walk us through the process, from installation to customization?
@marcuswest4572
@marcuswest4572 Жыл бұрын
you don't need astrovim. NVChad + ,DoC's other video on Nvim covers all the bases
@lamprospitsillou6325
@lamprospitsillou6325 Жыл бұрын
Does this work with the free tier of GPT? Incredible quality also, love the content!
@simpingsyndrome
@simpingsyndrome Жыл бұрын
It didn't work haha
@dreamsofcode
@dreamsofcode Жыл бұрын
Thank you for the feedback! I believe it requires 3.5 Turbo.
@johanngambolputty5351
@johanngambolputty5351 Жыл бұрын
Are there any based on open source LLMs? i.e. based on something like Open Assistant instead of ChatGPT?
@dreamsofcode
@dreamsofcode Жыл бұрын
Unfortunately Open Assistant doesn't have an API at this stage so we'll have to wait!
@IvanZupancic
@IvanZupancic Жыл бұрын
Let's say I don't want to send 'stuff' to chatGPT and want to run a local-ish stable diff - do you happen to know if there is a plugin for that ? ( a personalized AI ) - thanks
@RenderingUser
@RenderingUser Жыл бұрын
Maybe there's some open source language models But I doubt they are as advanced as chatgpt
@dreamsofcode
@dreamsofcode Жыл бұрын
I'd love there to be one but I don't believe there are any advanced ones out there currently.
@IvanZupancic
@IvanZupancic Жыл бұрын
@@dreamsofcode was thinking more in terms of stable diff running locally - then tying it in with a plugin. don't think we need 1:1 coverage with chatgpt. if we'd get like 50 it would be great
@MeraMadness
@MeraMadness 7 ай бұрын
Can you make a setup for Unity + C# ?
@leanghok120
@leanghok120 Жыл бұрын
Can you make a video on how you customize zsh to look like that
@dreamsofcode
@dreamsofcode Жыл бұрын
I can! Added to my backlog
@shoddits2156
@shoddits2156 Жыл бұрын
I live under a rock but certainly I heard about A.I 😁
@dreamsofcode
@dreamsofcode Жыл бұрын
I apologize to all rock dwellers!
@uliahshafar8599
@uliahshafar8599 4 ай бұрын
Hi, I'd like to ask, How to store api in windows powershell?
@joaop3268
@joaop3268 Жыл бұрын
Does this plugin support GPT 4.0 API? Or just the 3.5 Turbo as they only mention it in their README
@dreamsofcode
@dreamsofcode Жыл бұрын
If the API hasn't changed then I'm sure it's supported! I'll give it a go and let you know.
@LeungWong
@LeungWong 5 ай бұрын
@@dreamsofcodehave you had chance to see whether GPT4 is supported?
@xzskywalkersun515
@xzskywalkersun515 5 ай бұрын
Please do a more detailed instruction if possible. Thanks!
@dylwintftw
@dylwintftw 4 ай бұрын
Yo, the 7:04 timestamp/chapter in your description says "Fix Gugs"
@emerson.dvlmt.g
@emerson.dvlmt.g 8 ай бұрын
Is way too much for me to configure all the pass manager in terminal by now, and I can't make it works wit enviromant variable, I don't know how to do it
@xzskywalkersun515
@xzskywalkersun515 5 ай бұрын
For 4:13, I don't have the auto-completion pop-up; when I ask Chatgpt a question, I don't see the token count shown.
@alxchiri
@alxchiri 4 ай бұрын
Seems that auto-completion pops up on Tab: type : and a few letters and hit Tab. Auto-complete should show up.
@BrazenNL
@BrazenNL Жыл бұрын
Looks like your PR has been merged going through the issues, so your fork isn't needed anymore?
@dreamsofcode
@dreamsofcode Жыл бұрын
That's correct. My PR has been merged but the team decided to keep the original configuration, so the async prefix only exists on my fork. No need to use it any more!
@nikob381
@nikob381 Жыл бұрын
Any advice on how to ensure that the plugin stays able to access the API key in Pass? It periodically throws a bunch of error messages, at which point I need to exit neovim, manually access the API key in Pass, enter my gpg password, and then with that unlocked it's finally able to get to it when I reopen neovim. Is there a smoother solution?
@dreamsofcode
@dreamsofcode Жыл бұрын
Hmm interesting. If you join my discord and message me I can take a look at the error messages it sends up. I'm not having any issues with pass my end so I might be able to share what I'm using.
@nikob381
@nikob381 11 ай бұрын
@@dreamsofcode thank you sounds good, will do! I realize it's probably more on my end, that I need to make sure Mac is aware of my pgp key or something like that... If I figure it out I'll share that in your discord too
@kaixuanjaw3173
@kaixuanjaw3173 9 ай бұрын
I'm having the same problem, do you have a solve?\
@vagrant1943
@vagrant1943 8 ай бұрын
Sounds like your gpg agent is timing out. Just need to increase the time limit in gnupg’s config file, or use gnome keyring
@BrazenNL
@BrazenNL Жыл бұрын
Amazing.
@dreamsofcode
@dreamsofcode Жыл бұрын
Thank you
@mAr3cKii
@mAr3cKii 10 ай бұрын
*_no work...chatgpt warn - eturn a value when executed. The given api repository does not have the given page :( _*
@vanvothe4817
@vanvothe4817 Жыл бұрын
How to use vim for agenda?
@RBova1
@RBova1 4 ай бұрын
Great content I saw in the documentation that we have a option formax-token usage, but i couldnt figured it out. Is it a limit for each :ChatGPT action? openai_params = { model = "gpt-3.5-turbo", frequency_penalty = 0, presence_penalty = 0, max_tokens = 300,
@rolandcucicea6006
@rolandcucicea6006 2 ай бұрын
that's arbitrary u can set it to 1000+ if you want, depends which model u use, check api page on openai for each model for 3.5turbo the max tokens are 4k if I remember correctly so if u set 2k you should be safe. even 1k should be enough for most tasks
@salvadorhernandezlopez953
@salvadorhernandezlopez953 2 ай бұрын
The issue with chatgpt is that this AI read your code and when you are working in a company with privative code project that's not good, well it's marked in the company security policy. So for the moment copilot is the best option, but I'm not really like this AI I agree chatGpt is better.
8 ай бұрын
This will just make everything more expensive as now you need to pay for every request right?
@RenderingUser
@RenderingUser Жыл бұрын
0:48 Wait It can do godot???? :O
@joswadsouza1445
@joswadsouza1445 11 ай бұрын
I request please do neovim setup for c#
@dreamsofcode
@dreamsofcode 11 ай бұрын
It's on the backlog!
@TomerBenDavid
@TomerBenDavid 11 ай бұрын
Is it sending our code to the internet?
@dreamsofcode
@dreamsofcode 11 ай бұрын
It will send any prompts up there (including code), copilot also does the same.
@wilbertmc
@wilbertmc 6 ай бұрын
curl: option -H: requires parameter curl: try 'curl --help' or 'curl --manual' for more information :(
@MohaaAbdi
@MohaaAbdi 6 ай бұрын
something wrong with your configuration, it showed me this because i used the wrong command for api_key_cmd. now it works fine
@ericzhang5313
@ericzhang5313 7 күн бұрын
it saids my API key is wrong tho
@marcuswest8085
@marcuswest8085 Жыл бұрын
Not a fan of GPT. It gives me rubbish answers on everything, code included. (They must know I have zero tolerance for Microssssoft).....Any chance of a plugin from an open source ai project?
@dreamsofcode
@dreamsofcode Жыл бұрын
That's the best thing about open source, we can always make one! What are your favorite open source ai models?
@marcuswest8085
@marcuswest8085 Жыл бұрын
@@dreamsofcode Codeium? CoPilotZ is paid I think
@fernandojsantos09
@fernandojsantos09 3 ай бұрын
Amazing video, but I think, at least by now, Copilot better integrated than ChatGPT and cheaper.
@rolandcucicea6006
@rolandcucicea6006 2 ай бұрын
copilot is like 10usd a month. gpt models throught the api (which is what u need here, not chatgpt) are pay per token usage. on 3.5 turbo 10usd could last a year
@techsaifcore7
@techsaifcore7 3 ай бұрын
Can I use Openai Api for free
@rolandcucicea6006
@rolandcucicea6006 2 ай бұрын
almost free. minimum topup is 5usd and if you're using 3.5turbo instead of 4/4turbo you'll likely use the 5usd in a year cuz it's dirt cheap
@heroe1486
@heroe1486 Жыл бұрын
Only worth if someone has a chatgpt 4 api key I guess, I've access to the chat copilot beta and even that is garbage
@RenderingUser
@RenderingUser Жыл бұрын
Lmao yea
@dreamsofcode
@dreamsofcode Жыл бұрын
Generating automated tests is pretty dope in my opinion.
@lovely-shrubbery8578
@lovely-shrubbery8578 Жыл бұрын
​@@dreamsofcode it's prob most sensible to not pay for chatgpt pro right? Because with dev account it'll just charge by use I think 🤔
@dreamsofcode
@dreamsofcode Жыл бұрын
@@lovely-shrubbery8578 yeah I think the API is still usage based, so you're just paying for tokens used. Looking at the price gpt-3-turbo looks to be able $0.002 per 1k tokens, so really inexpensive.
@radvilardian740
@radvilardian740 11 ай бұрын
but why u hate angular ?
@dreamsofcode
@dreamsofcode 11 ай бұрын
Haha, I don't really. I just have very minimal experience with it, and don't know many people who do.
@qnprogrammer
@qnprogrammer 9 ай бұрын
Please make a video with huggingface.
@nickskywalker2568
@nickskywalker2568 11 ай бұрын
It looks really cool but I cant stop thinking about the privacy concerns... this is a straight no for at work. I enjoyed the video though
@dreamsofcode
@dreamsofcode 11 ай бұрын
Yeah, both this and copilot are pretty bad for telemetry, which really defys one of Neovims greatest selling points. I'm glad you enjoyed the video, however!
@RenderingUser
@RenderingUser Жыл бұрын
Oh, so it's not exactly free then
@dreamsofcode
@dreamsofcode Жыл бұрын
No, it's not unfortunately. I don't think any A.I. is free at the moment. It's pretty low cost though especially as it has adhoc usage.
@RenderingUser
@RenderingUser Жыл бұрын
@@dreamsofcode what about open assistant?
@dreamsofcode
@dreamsofcode Жыл бұрын
@@RenderingUser I just had a look. They don't have an API at the moment unfortunately. It seems they're looking to be more about data capture than providing a product. Would have been a nice option otherwise!
@RenderingUser
@RenderingUser Жыл бұрын
@@dreamsofcode no I reckon you can run the ai on your own pc
@Ashaiksameer
@Ashaiksameer Жыл бұрын
Java config😢😢😢
@dreamsofcode
@dreamsofcode Жыл бұрын
It's in the backlog still! It'll come though I promise
@Ashaiksameer
@Ashaiksameer Жыл бұрын
@@dreamsofcode is it next video??reply sir🥺
@avi7278
@avi7278 Жыл бұрын
No response streaming is a hard pass for me. It's not that hard, guys. Not streaming the response is just being lazy.
@dreamsofcode
@dreamsofcode Жыл бұрын
This would be a nice feature to add in. It's open source, so should be easy to add a PR.
@antoineleduc7611
@antoineleduc7611 11 ай бұрын
What is response streaming ?
I Tried Every AI Coding Assistant for Neovim
17:30
DevOps Toolbox
Рет қаралды 24 М.
Why I Cant Stand IDE's After Using VIM | Prime Reacts
17:51
ThePrimeTime
Рет қаралды 266 М.
I CAN’T BELIEVE I LOST 😱
00:46
Topper Guild
Рет қаралды 24 МЛН
La revancha 😱
00:55
Juan De Dios Pantoja 2
Рет қаралды 69 МЛН
Why You Should Always Help Others ❤️
00:40
Alan Chikin Chow
Рет қаралды 131 МЛН
Получилось у Вики?😂 #хабибка
00:14
ХАБИБ
Рет қаралды 3,5 МЛН
7 Amazing CLI Tools You Need To Try
18:10
Josean Martinez
Рет қаралды 234 М.
Why I'm no longer using Copilot
7:07
Dreams of Code
Рет қаралды 159 М.
So, you've committed a secret, what next?
13:12
Dreams of Code
Рет қаралды 31 М.
From Vim To Zed
19:03
ThePrimeTime
Рет қаралды 211 М.
How To Make Your Boring macOS Terminal Amazing With Alacritty
16:33
Josean Martinez
Рет қаралды 113 М.
We can now write scripts using these languages, but is it worth it?
8:28
My Forever Dev Workflow
16:02
typecraft
Рет қаралды 68 М.
I tried Neovim Distributions so you don't have to
9:12
typecraft
Рет қаралды 138 М.
This Zsh config is perhaps my favorite one yet.
17:24
Dreams of Autonomy
Рет қаралды 143 М.
Iphone or nokia
0:15
rishton vines😇
Рет қаралды 1,8 МЛН
Cadiz smart lock official account unlocks the aesthetics of returning home
0:30
Secret Wireless charger 😱 #shorts
0:28
Mr DegrEE
Рет қаралды 546 М.
How charged your battery?
0:14
V.A. show / Магика
Рет қаралды 6 МЛН
Собери ПК и Получи 10,000₽
1:00
build monsters
Рет қаралды 214 М.
Разряженный iPhone может больше Android
0:34
WWDC 2024 Recap: Is Apple Intelligence Legit?
18:23
Marques Brownlee
Рет қаралды 6 МЛН