Install ChatGPT File Uploader, I use it for the Edge browser.
Once installed, go to start a new chat in ChatGPT.
After the green button to upload the file appears on the screen, upload each file individually. Wait a few minutes between uploads to avoid network errors.
After all four text files are uploaded, the installation process is complete.
You can now start asking it questions regarding modification of Doom with DECORATE and ACS.
Here are the pages from the ACS and Decorate wiki pages copied to notepad; pruned of text that would confuse the AI, and divided into individual pages and folders.
how can I train AI to become an expert at coding zdoom DECORATE?
ChatGPT4:
DECORATE is a scripting language used in the ZDoom engine for creating and modifying game objects, such as weapons, monsters, and other entities. To train an AI to become an expert at coding ZDoom DECORATE, follow these steps:
Gather data:
Collect a large dataset of DECORATE scripts and examples, including both simple and complex objects, as well as tutorials and explanations. You can find these resources in ZDoom forums, GitHub repositories, and modding communities.
Preprocess the data:
Clean and organize the data by removing irrelevant information and structuring it in a consistent format. You may want to tokenize the code, which means breaking it down into smaller units like keywords, variables, and symbols.
Choose an AI model:
Select an appropriate AI model for your task. Given that you want the AI to be an expert in coding, a large-scale language model like OpenAI's GPT architecture would be suitable.
Fine-tune the model:
Fine-tune the chosen AI model on your preprocessed DECORATE dataset. This process will help the AI understand the syntax, structure, and common patterns in DECORATE scripts. The more data and variety you provide, the better the model will become at understanding and generating DECORATE code.
Evaluate and iterate:
Test the AI model's performance by giving it tasks related to DECORATE scripting, such as generating new objects, modifying existing ones, or fixing errors. Analyze the results and iterate on the model by fine-tuning it further or adjusting the training data if needed.
Create a user interface:
Develop a user interface (UI) that allows users to interact with the AI and request tasks related to DECORATE coding. This could be a web application, a command-line interface, or an integration with popular code editors.
Continuous learning:
Keep updating the AI model with new DECORATE scripts, examples, and resources as they become available. This will help the AI stay up-to-date with the latest developments and best practices in the ZDoom modding community.
Remember that AI training can be time-consuming and resource-intensive. Make sure you have access to the necessary computational power and be prepared to iterate on your model to achieve the best results.
Last edited by Kontra Kommando on Wed May 17, 2023 3:46 am, edited 7 times in total.
I think once plugins allow for ChatGPT Plus to create file structures, and allows you to upload documents like PDF, you could probably create this.
You would just need the data organized and cleaned up correctly.
I wonder if it would be sufficient to take all of the information in the wikis including all of the meta data like tutorials, examples, etc. put it all in a single text file organized clearly.
A while back someone jumped onto a Discord asking for help getting some code they "wrote" working correctly and it was an AI generated slurry of DECORATE, ACS and Unity C#. That was very funny and I fully encourage more people to expose themselves like that.
I've endeavored to compile the data from the zdoom wiki to be used as sources for training AI to be an expert at scripting DECORATE for zdoom. I'm also pruning out all of the text that could potentially confuse the AI.
I will share the files with the community once it is completed.
Theoretically, you should just be able to upload it into an AI-software prioritized for coding, and it should work.
I suppose this all depends on whether you have access to a large-scale AI language model that allows fine-tuning. So far as I'm aware, GPT doesn't allow you to do that yet?
If you're just building a training dataset, then the good news is that there's a LOT of valid code out there. It's just not well-represented on the open internet, which is why GPT currently struggles with this specific task (while doing better at other more well-known languages like C or Python where there's a glut of examples on like, StackExchange). It would probably be good to ask mod authors if you're allowed to use their code, but if they do then chances are you can just feed the entire DECORATE code into the training model.
That said, I think ZScript would be a better choice. It's more programming-language-like, so GPT's inbuilt "knowledge" would help. Also it's more future-proof and flexible, and relies much less on other-language shims (such as how DECORATE is often mixed with ACS). Plus it'd be easier to pre-process as most mods put the majority of their code in a zscript/ folder. If you can "counter-train" the model, then stuff to put in for "bad" data would be other control lumps like MAPINFO or GLDEFS, just so the model doesn't get confused.
Thus far I have transcribed all of the information for the Action Functions for DECORATE into notepad format, and pruned out all of the text that would confuse the AI. I am currently half-way done with the Doom Classes. I would like to see this out to competition out of the sear curiosity of if it would work.
But I would gladly like to collaborate with anyone that could provide me the raw coding, as that would be optimal for feeding the AI information.
I am currently making individual notepad files curated into dedicated folders, and sub-folders.
I was also considering making a PDF version of all of the files.
Additionally, I was curious as to if putting it all into one file would be better. I could easily combine all of them in adobe acrobat.
I could probably make it in those various formats to test which is best.
I was also thinking if Slade had some guides I could also include.
Maybe if people were willing to contribute their own coding as well as examples for the AI too. This could be a great project for multiple participates.
I also would like to endeavor to do the Zscript version as well. I think it would probably be necessary to separate the zscript files from the DECORATE files, because I could see it confusing the AI. Hopefully, there will be a way to control which folders can be selected to be analyzed.
I also think the Hexen, Heretic, etc. games need to be separated, and be focused specifically on a single game at a time.
I think this would hone the AI's data to yield the best results.
Last edited by Kontra Kommando on Mon Apr 17, 2023 11:03 am, edited 2 times in total.
Once The Code Interpreter Plugin is available for Chat GPT, I am hoping it will be able to do the kind of functions necessary for testing this project. I think we may be able to see if it could analyze these files, and become an expert at coding in DECORATE.
The Code Interpreter Plugin:
The Code Interpreter plugin is a game-changer for both seasoned programmers and coding enthusiasts. It enables ChatGPT to understand and interpret code in a variety of programming languages. This means that users can now simply input code snippets, and the plugin will interpret, debug, or explain the code to them. It’s like having your very own personal coding assistant!
Key Features:
Language Support: The Code Interpreter plugin offers support for multiple programming languages, such as Python, JavaScript, and Java. This broad support ensures that users with diverse coding backgrounds can benefit from its features.
Code Explanation: The plugin helps users understand the functionality of a given code snippet by breaking it down into simpler terms. This is particularly useful for beginners who are still learning the ropes of programming.
Debugging Assistance: Another fantastic feature of the Code Interpreter plugin is its ability to identify errors in your code and offer suggestions for fixing them. This can save a great deal of time and effort, especially for developers working on large projects.
Code Optimization: The plugin also provides guidance on how to optimize your code for better performance and readability. This can be invaluable for seasoned developers seeking to improve their code quality and maintainability.
Real-time Collaboration: The Code Interpreter plugin facilitates real-time collaboration among team members, allowing multiple users to work on the same code simultaneously. This feature can enhance productivity and streamline the development process.
Me: could the code interpreter plug in be a good AI to use for a project like this?
Chat GPT4:
A code interpreter plugin could be a useful starting point for a project like this. However, it's important to understand that a code interpreter is designed to read and execute code, while your goal is to create an AI that can understand and generate code related to ZDoom.
To achieve your goal, you may want to consider the following steps:
Choose an AI model suitable for natural language processing and code generation tasks, such as GPT-based models or similar architectures.
Train the chosen AI model with your pruned ZDoom-related programming dataset. This process will require fine-tuning the model to make it more effective at understanding and generating ZDoom-related code.
Develop a plugin or a standalone application that integrates the trained AI model with ZDoom, allowing the AI to interact with the ZDoom engine and provide code generation support.
Test and iterate on your solution to improve its effectiveness and ensure it meets the needs of ZDoom developers.
To conclude, while a code interpreter plugin can be helpful, it's not the best choice for creating an AI that can generate ZDoom-related code. Instead, you should consider using an AI model specifically designed for natural language processing and code generation tasks, and then train it using a curated dataset. Developing a plugin or an application to integrate the AI with ZDoom will be an essential part of the process.
(Bolded is really not necessary, you could just copy and paste it. Ulimately, it is suggesting a natural language processing and code generation tasks, such as GPT-based models that can examine solely the files necessary)
Me: Maybe an AI plugin integrated with Slade prioritized for DECORATE, zscript, etc would make more sense.
Chat GPT4:
Integrating the AI model with SLADE (a Doom map editor) could indeed be a more effective approach if your primary goal is to assist users in creating and editing ZDoom-related content, such as DECORATE scripts, custom monsters, and other game elements.
To integrate the AI with SLADE and prioritize it for DECORATE, ZDoom, and other related components, consider the following steps:
Choose an AI model suitable for natural language processing and code generation tasks, such as GPT-based models or similar architectures.
Train the chosen AI model with your pruned ZDoom-related programming dataset, focusing on DECORATE, ZDoom, and other relevant components.
Develop a plugin or an extension for SLADE that integrates the trained AI model, allowing it to interact with the editor and provide suggestions, auto-completion, and code generation support.
Test and iterate on your solution to improve its effectiveness and ensure it meets the needs of SLADE users working on ZDoom-related content.
By integrating the AI with SLADE, you can offer a more seamless user experience for content creators working on ZDoom projects, as they would be able to access the AI's code generation capabilities directly within the editor they are already using. This could help improve the efficiency of creating and editing ZDoom-related content, making it a valuable addition to the SLADE ecosystem.
I think it would be really interesting to see if including literature in addition to the scripting data, and asking it to create custom character values based on the characters in the literature.
For example, including the Iliad, and asking it to create a custom character similar to Achilles, or Ajax.
Me: If I curated all the pages to look similar to the following. Individually saved as notepad files, would that be optimal for feeding the AI information, by uploading those notepad files?:
Baron of Hell plasma
Actor type: Explosive
Game: Doom
DoomEd Number: None
Class Name: BaronBall
Spawn ID: 154
Identifier:T_BARONBALL
Classes: BaronBall
The green energy projectile fired from a Baron of Hell or a Hell Knight.
ChatGPT4: Curating and formatting the pages to resemble the example you provided can make it easier for the AI to understand and learn from the data. Saving them as individual plain text files (e.g., Notepad files) can be an acceptable format for feeding the AI information. However, you might need to preprocess the data further to optimize it for training.
Here are some recommendations for preparing the data:
Consistent formatting: Ensure that all the files have a consistent format, using the same structure and terminology. This will help the AI model identify patterns and learn more effectively.
Tokenization: Break down the content into smaller pieces called tokens. These tokens can be words, characters, or other units, depending on the AI model you're using. Tokenization helps the model process the data efficiently.
Encoding: Convert the tokenized text into numerical representations that can be fed into the AI model. This usually involves mapping each token to a unique integer or vector.
Splitting the data: Divide your dataset into training, validation, and test sets. The training set is used to train the AI model, the validation set is used to fine-tune it, and the test set is used to evaluate its performance.
Data augmentation (optional): Generate additional training examples by slightly modifying the existing ones, for example, by rephrasing sentences, changing the order of lines, or introducing synonyms. This can help the AI model generalize better and improve its performance.
Once you have prepared the data, you can feed it into an AI model suitable for natural language processing and code generation tasks, such as a GPT-based model. Remember that the model will need to be fine-tuned using your dataset to become effective at understanding and generating ZDoom-related code.
Here are the pages from the ACS and Decorate wiki pages copied to notepad; pruned of text that would confuse the AI, and divided into individual pages and folders.