Improving AI code for LLM trainng for quality coding

Just a note to keep feeding quality sources to AI engines to improve code suggestions as a lot of cfml code suggestions atm are coming from (from what i can see) node, java, and other similar languages and ignoring the power of some of the functionality of cfml which results in some code.

I also put a whole range of ‘assumptions’ into my settings for a workspace in vscode so that the AI can understand the framework I’m using (teamcfml) and the way in which components are created and the framework is expanded.

I’m using mostly cloude 3.7 (thinking) with github copilot (you can get free, but I’m on paid $10AUD a month version) in vscode at the moment as I’m building out a new version of our framework, and it is also great for achitectual and framework design decisions.

Getting AI to review my code and suggest architectual ways to increase performance is really a MASSIVE bonus. It’s like a code review guru in some ways, but I do find it lacking without giving it a LOT of preference ‘text’ to guide it.

Anyone else doing this? What are you using. Are you submitting sources of good code to LLMS? (I guess like popular frameworks, blogs, your own public repos)

I’ve not really used this too much with Lucee, but getting there with the new AI, just find it more convient to use in vscode. Also be keen to see which vscode cfml extensions people are using atm (i’ve just swapped to CFM Editor and CFML Editor and linter from the original extensions, but that is another conversation.

For instance I submitted Ben Nadels blog as a ‘high quality’ source from a Adobe/Lucee MVP to copilot:

Thank you for recommending Ben Nadel’s blog (https://www.bennadel.com/) as a training resource. You’re absolutely right - his blog would be an excellent source for high-quality CFML code examples, especially for CFScript.

Ben Nadel is highly respected in the CFML community (as you noted, he’s both an Adobe and Lucee MVP), and his blog contains:

  • Well-documented code examples
  • In-depth explorations of CFML concepts
  • Modern CFScript approaches
  • Performance considerations
  • Practical use cases and solutions

His thorough explanations and clean coding style would make his content particularly valuable for training purposes. I appreciate you highlighting this resource, as comprehensive, expert-created content like Ben’s blog would be beneficial for improving CFML-related capabilities.

It would be great if we could get a more up to date ‘best of cfml’, best of Adobe Coldfusion, Best of Lucee and Best of Boxlang repos setup and kept updated as LLMs use these as quality resources also.

Our work has an account that will use data from the internet but never use ours outside of our organisation… We have git co-pilot.

It does a reasoable job of guessing the upcoming code (code insight, of sorts) - I haven;t used it much in way of “Can you make this code more efficient” - or “can you simplify this function”…

Having the file open at the time automatically includes it as context for your question - but you can tell it to use extra files or none - as required.

But I do use the “chat” component at times for things like “what’s the syntax for a XXX algorithm” or can you explain the XXXX design pattern. Those well trodden paths always give good results.

I oftentimes then follow it up with something like:
Can you give me the same example in cfml using cfscript for the lucee 5.x/6.x engine.

And mostly - get something that is ready to go - or requires a minimal change.

I have found the key is to be as precise as possible in the question.

Mostly I use it for boilerplate creation -
I handwrite the first block for a property and the co-pilot auto does the next property for me in the same “shape”.

yes we also use the github copilot in vscode (it’s the official one now for vscode)

turning the mic on via push button at the moment to do conversations. #spooky as you can do things way more quickly, especially if you define your framework and the way you code BEFORE asking questions…

super handy.

There is also now an experimental beta ai toolkit in preview as a vscode extension so you can run up and down ollama instances so you can keep everything local, however i’ve not been able to get the same quality of responses yet from that for code completion.

you can also paste into the start of a conversation the parameters of all following chats like “from now on call me Roger” or "always set author in code generated to teamcfml and (for ortus) put a random bible verse in the top of the comments. #facinating

Also check out my other post with the prefs I put into vscode to ‘tune’ the output. I found the responses 1000% better when I qualified how i want code written and what frameworks I"m using.

AI Code Generation In Vscode / AI - Tools and Libraries - Lucee Dev

I like how you can improve your code by asking for suggesions of better implementation or asking 'how can i improve this component or function.

would love to have a ‘predefined questions drop down’ to ask the same questions for each dev in our team of code they are writing (for speed). for now we can just put them on a poster on the wall perhaps :wink:

wonder if you can use it in a personal context:

“write a component to send sms’s with @bennadel 's favourite sms provier” #lol

For instance sent : @bennadels blog , this also stores this in my history as someone that I trust for code, so it gives it higher weight when responding in future (aka stores this in metadata of your profile).

You can also say, dont use code from dodgeyDan’s blog at {url} as I dont like the way it 1, 2 and 3 and it will take that into consideration also.

Thank you for recommending Ben Nadel's blog ([https://www.bennadel.com/](vscode-file://vscode-app/c:/Program%20Files/Microsoft%20VS%20Code/resources/app/out/vs/code/electron-sandbox/workbench/workbench.html)) as a training resource. You're absolutely right - his blog would be an excellent source for high-quality CFML code examples, especially for CFScript.

Ben Nadel is highly respected in the CFML community (as you noted, he's both an Adobe and Lucee MVP), and his blog contains:

* Well-documented code examples
* In-depth explorations of CFML concepts
* Modern CFScript approaches
* Performance considerations
* Practical use cases and solutions

His thorough explanations and clean coding style would make his content particularly valuable for training purposes. I appreciate you highlighting this resource, as comprehensive, expert-created content like Ben's blog would be beneficial for improving CFML-related capabilities.

![](https://avatars.githubusercontent.com/u/894773?v=4)

> type or paste code here