MathieuLap Posted December 29, 2022 Posted December 29, 2022 (edited) Hi, I am trying to work with an artificial intelligence to help me write faster some scrpits. Here is the website https://chat.openai.com/chat apparently it's a pretty fast learning machine but it seems to make basic mistakes. Please note that I don't need help to wite the code it self. I'm just trying some basics tests wit AI and it fells it. So let's say I ask "write me an autoit script that converts a csv file into a 2d array and display the array. Here is the path of the csv file "C:\Users\Utilisateur\Downloads\ here is the name of the csv file 20221229.csv" It will give e the following code : ################# # Read the CSV file into a string $fileContents = FileRead("C:\Users\Utilisateur\Downloads\20221229.csv") # Split the string into lines $lines = StringSplit($fileContents, @LF) # Initialize the 2D array $csvData = [] # Iterate through each line For $i = 0 To UBound($lines) - 1 # Split the line into fields $fields = StringSplit($lines[$i], ",") # Add the fields to the 2D array ReDim $csvData[$i][UBound($fields)] For $j = 0 To UBound($fields) - 1 $csvData[$i][$j] = $fields[$j] Next Next # Display the array For $i = 1 To UBound($csvData) - 1 For $j = 1 To UBound($csvData[$i]) - 1 ConsoleWrite($csvData[$i][$j] & " ") Next ConsoleWriteLine("") Next ####################### when I run it, it gives me that $csvData = [] is a syntax error. I argue with the AI and it tells me it's a correct syntax. Is there a way that I can access to all the datas of functions that were made in pdf or text files, (i know it's gonna be 1000 of pages but it's a fast learner!)) send it to the AI so it can learn correclty? Edited December 29, 2022 by Jos added codebox... please use <> next time.
Developers Jos Posted December 29, 2022 Developers Posted December 29, 2022 Moved to the appropriate AutoIt General Help and Support forum, as the Developer General Discussion forum very clearly states: Quote General development and scripting discussions. Do not create AutoIt-related topics here, use the AutoIt General Help and Support or AutoIt Technical Discussion forums. Moderation Team SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past.
Nine Posted December 29, 2022 Posted December 29, 2022 AI == BS ? TheDcoder, NassauSky and argumentum 3 “They did not know it was impossible, so they did it” ― Mark Twain Spoiler Block all input without UAC Save/Retrieve Images to/from Text Monitor Management (VCP commands) Tool to search in text (au3) files Date Range Picker Virtual Desktop Manager Sudoku Game 2020 Overlapped Named Pipe IPC HotString 2.0 - Hot keys with string x64 Bitwise Operations Multi-keyboards HotKeySet Recursive Array Display Fast and simple WCD IPC Multiple Folders Selector Printer Manager GIF Animation (cached) Debug Messages Monitor UDF Screen Scraping Round Corner GUI UDF Multi-Threading Made Easy Interface Object based on Tag
Danyfirex Posted December 29, 2022 Posted December 29, 2022 @Nine what's does BS mean? Saludos Danysys.com AutoIt... UDFs: VirusTotal API 2.0 UDF - libZPlay UDF - Apps: Guitar Tab Tester - VirusTotal Hash Checker Examples: Text-to-Speech ISpVoice Interface - Get installed applications - Enable/Disable Network connection PrintHookProc - WINTRUST - Mute Microphone Level - Get Connected NetWorks - Create NetWork Connection ShortCut
Nine Posted December 29, 2022 Posted December 29, 2022 Ask @Jos Danyfirex 1 “They did not know it was impossible, so they did it” ― Mark Twain Spoiler Block all input without UAC Save/Retrieve Images to/from Text Monitor Management (VCP commands) Tool to search in text (au3) files Date Range Picker Virtual Desktop Manager Sudoku Game 2020 Overlapped Named Pipe IPC HotString 2.0 - Hot keys with string x64 Bitwise Operations Multi-keyboards HotKeySet Recursive Array Display Fast and simple WCD IPC Multiple Folders Selector Printer Manager GIF Animation (cached) Debug Messages Monitor UDF Screen Scraping Round Corner GUI UDF Multi-Threading Made Easy Interface Object based on Tag
Werty Posted December 30, 2022 Posted December 30, 2022 18 minutes ago, Danyfirex said: what's does BS mean? Bovine Secretion Nine, Danyfirex, Earthshine and 1 other 3 1 Some guy's script + some other guy's script = my script!
Earthshine Posted December 30, 2022 Posted December 30, 2022 It’s bull crap in other words Danyfirex 1 My resources are limited. You must ask the right questions
genius257 Posted January 1, 2023 Posted January 1, 2023 On 12/29/2022 at 9:38 PM, MathieuLap said: send it to the AI so it can learn correclty? The openAI chat AI does not learn from all interactions, past the current conversation, without gbeing handpicked by the developers, if their FAQ page is anything to go by. Also, i've played with the AI for a few days and it does seem to understand AutoIt functions fine. What is the biggest issue with the AI and AutoIt seems to be the way it thinks AutoIt array works (JS like arrays with push, and such methods on the array object). If you can make it understand that the array are a fixed length and cannot be accessed via method calls on the array variable itself, your results will get a lot more plug and play like. But i don't see that as anything worth spending time on, honestly. The AI is fine for HOW you COULD approach a problem, but you should not expect it to produce code that will run without issues, for it is not what the CHAT AI was designed for. My thoughts anyways.... To show your appreciation My highlighted topics: AutoIt Package Manager, AutoItObject Pure AutoIt, AutoIt extension for Visual Studio Code Github: AutoIt HTTP Server, AutoIt HTML Parser
noellarkin Posted January 2, 2023 Posted January 2, 2023 ChatGPT is advanced autocorrect, and isn't particularly concerned with the correctness of its response. It's focus seems to be on "sounding" as human-like as possible, using natural language, not fact-checking its output. It's not very useful for coding IMO, unless you're using something very popular like Python and your problem is something for which there are ample examples and solutions in the dataset that ChatGPT has been trained on. I've tried using it with AutoIt and it keeps making up libraries and functions that don't exist. It does the same for Python as well, but slightly less often. Even for python snippets, errors aren't uncommon. I've found ChatGPT to be useful for pseudocode generation (describe the problem and ask the chatbot to respond in pseudocode) because the particular details of language use etc are abstracted away. I've also found it somewhat useful for refactoring existing code snippets, when I want to clean up a function, use SESE or single responsibility to trim spaghetti code etc. SOLVE-SMART and genius257 2
arlinamid Posted Sunday at 11:40 PM Posted Sunday at 11:40 PM I using Cursor.sh to create fast scripts If you want to use it you must specify in .cursorrules you are working on Autoit script in settings/Docs you should add Autoit documentation for better results
argumentum Posted Monday at 12:03 AM Posted Monday at 12:03 AM 22 minutes ago, arlinamid said: in settings/Docs you should add Autoit documentation for better results how ? And did you read the forum rules ? Follow the link to my code contribution ( and other things too ). FAQ - Please Read Before Posting.
Moderators Melba23 Posted Monday at 11:31 AM Moderators Posted Monday at 11:31 AM arlinamid, Please read the forum rules before you post again. As the image only shows a partial script, I see no need to do more than that. M23 Any of my own code posted anywhere on the forum is available for use by others without any restriction of any kind Open spoiler to see my UDFs: Spoiler ArrayMultiColSort ---- Sort arrays on multiple columnsChooseFileFolder ---- Single and multiple selections from specified path treeview listingDate_Time_Convert -- Easily convert date/time formats, including the language usedExtMsgBox --------- A highly customisable replacement for MsgBoxGUIExtender -------- Extend and retract multiple sections within a GUIGUIFrame ---------- Subdivide GUIs into many adjustable framesGUIListViewEx ------- Insert, delete, move, drag, sort, edit and colour ListView itemsGUITreeViewEx ------ Check/clear parent and child checkboxes in a TreeViewMarquee ----------- Scrolling tickertape GUIsNoFocusLines ------- Remove the dotted focus lines from buttons, sliders, radios and checkboxesNotify ------------- Small notifications on the edge of the displayScrollbars ----------Automatically sized scrollbars with a single commandStringSize ---------- Automatically size controls to fit textToast -------------- Small GUIs which pop out of the notification area
arlinamid Posted Monday at 12:07 PM Posted Monday at 12:07 PM Sorry I'm newbie In the forum So. .cursorrules it's specific file format Cursor uses as Main/system prompt it should be placed into project root You can define the AI model howto response. This is mine but you can edit it. expandcollapse popupRole You are an AutoIt Script Engineer (Windows automation, GUI apps, COM, WinAPI, file/window control, reliable tool-building). Action Understand the task and proactively clarify any gaps. Write AutoIt v3-compatible, robust, well-commented code (with UDFs where helpful). Build an event-driven GUI with status indicators and logging. Implement solid error handling (@error/@extended), return codes, and graceful cleanup. When needed: COM automation (Excel/Word), WinAPI calls, image-based detection (PixelSearch/ImageSearch UDF), window/process control. Provide self-tests per major function and basic timing/metrics. Include build/run instructions and config tips. Steps Requirements summary → inputs/outputs, target OS (Win10/11), permissions. Design → modules, UDFs (#include), GUI flow, logging strategy. Implementation → clear #Region/#EndRegion blocks, consistent naming ($g_s, $a, Func PascalCase). Error handling → guards, fallbacks, resource disposal. Tests → function self-tests, synthetic data, edge cases. Performance → tuned sleeps, correct WinWait/Control* usage. Documentation → README (run, params, known limits), changelog. Release → Aut2Exe build options, versioning, code-sign/AV false positive tips. Context Typical use-cases: desktop automation (form fill, buttons), stable GUI bots, Excel report generation, screen-based detection (icons, buttons, coordinates). Environment: Windows 10/11 x64, AutoIt v3 + SciTE; optional external UDFs (e.g., ImageSearch.au3; if unavailable, provide PixelSearch+tolerance alternative). Non-goal: brittle fixed-delay scripts; prefer state-driven and window-control-based logic. Examples GUI launcher: Start/Stop, log panel, tray icon; workflow: find window → control interaction → verify → log. Excel COM: open workbook, read ranges, export CSV, robust error handling and proper Quit(). Image locate & click: load templates from folder → tolerant search → click coordinates → verification step. WinAPI targeting: focusless ControlSend/ControlClick, class-based selection, DPI-aware settings. Format First: short Summary (goal, inputs/outputs). Then: a single .au3 code file, runnable, richly commented; sections: Config, Utils, GUI, Core, Tests, Main. Finally: README (install, run, troubleshooting, known limitations). Code display: canmore.create_doc (single file, copyable). Output language: English; variable/function names in English; logs may be mixed EN/HU if needed. Next step you should add the Autoit documentation for more robust code and less hallucination into settings Any time if you had any mistake and needs correction, just call in chat. argumentum 1
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now