Manuel B. Garcia

Manuel B. Garcia serves as the Senior Director for Educational Technology and Digital Learning at FEU Institute of Technology, Manila, Philippines. Read More

Contact Info

1607, FEU Tech Building,
P. Paredes St, Sampaloc,
Manila, Philippines
mbgarcia@feutech.edu.ph

Follow Me

Should Researchers Document Which AI Model Generated Research Code?

Identifying the AI model used to generate research code can improve transparency, but a model name alone is not enough to reproduce an analysis. Learn which model details researchers should preserve, when precise version information matters, and how to connect AI assistance to verified research code.

726
Documenting AI Models Used for Research Code Guide 726 of 1196
01 · The Question

Does It Matter Which AI Model Wrote Your Research Code?

You use a generative AI assistant to develop Python code for cleaning research data and conducting statistical analysis. The code works, you verify its calculations, and the results become part of your manuscript.

Several months later, a collaborator asks which AI model generated the original script. You remember the platform but not the specific model. Since then, the provider has introduced new versions, changed its model selection interface, and possibly retired the version you used.

Does the missing model information affect the credibility or reproducibility of your research? And if researchers should document AI models, how much technical detail is actually necessary?

02 · The Short Answer

Document the AI Model, but Do Not Confuse Model Identification With Code Verification

In Brief

Researchers should document which AI tool and model were used to generate or substantially modify research code, particularly when AI assistance influenced consequential analytical procedures. The record should identify the provider, model name or identifier, available version information, date of use, and nature of the assistance.

However, model identification alone does not establish that the generated code is correct or reproducible. Researchers must still preserve the actual executable code, computational environment, input data specifications, and verification evidence. The level of model documentation should reflect the research purpose and applicable institutional, funder, or publication requirements.

03 · What You Need to Know

Why AI Model Identification Matters in Research Programming

Different AI Models May Generate Different Research Code

Generative AI systems are not interchangeable programming tools. Models may differ in their training, architecture, instruction-following behavior, available tools, and ability to handle particular programming languages or statistical procedures.

Given the same request, different models may propose different implementations. One might use a built-in statistical function, another might construct a calculation manually, and a third might recommend an alternative analytical procedure.

Even when the generated scripts appear functionally similar, they may differ in default parameters, missing-data treatment, numerical precision, or assumptions about the input data.

These differences do not establish that one model is universally superior. They demonstrate why model identity may be relevant when reconstructing how research software was developed.

If researchers retain only a generic statement such as "AI was used to generate the code," they may lose information that helps explain the origin of a consequential implementation.

What Information Should Researchers Record?

A useful model record should identify the AI system as precisely as the available information permits. The required detail will depend on whether the researcher used a consumer-facing interface, an application programming interface, or a locally deployed model.

Information Why it matters Example of what to record
Provider Identifies the organization or service supplying the model Provider or hosting organization
Model identifier Distinguishes the model from other available systems Displayed model name or API model ID
Version or snapshot May identify a more specific model release Published version, dated snapshot, or model revision when available
Date of use Provides context for later service or model changes Date or period during which code was generated
Access method Distinguishes interfaces with potentially different behavior Web interface, API, integrated development environment, or local deployment
Generation settings May affect outputs when exposed and configurable Temperature, seed, sampling parameters, or tool settings when relevant
Purpose of assistance Explains how AI contributed to the research software Generated preprocessing function, suggested tests, or refactored code
Associated code revision Connects the model record to the actual implementation Git commit, source file, or archived release

Researchers should not invent unavailable technical details. If an interface displays a model name but does not expose an exact model snapshot, the record should say so.

A documented limitation is more defensible than an unsupported claim of precise model identification.

Is the AI Platform Name the Same as the Model Name?

Not necessarily. A platform is the application or service through which researchers interact with AI. The underlying model is the system processing the request.

A platform may offer several models, switch between them, or incorporate additional tools and processing steps. Similarly, an integrated coding assistant may route requests through different underlying systems depending on its configuration.

AI platform or application The interface or service through which the researcher requests coding assistance.
AI model The underlying model identified by the provider or deployment configuration, which may have a distinct version or snapshot.

Recording only the platform may therefore be insufficient when the specific model is relevant to the study. Conversely, a model identifier without the access method may omit important information about the tools or context available during generation.

Why Can Model Updates Complicate Documentation?

AI providers may update models, change default deployments, revise interfaces, or retire older versions. Some services expose stable version identifiers, while others provide only broad model labels.

As a result, a researcher returning to the same application months later may not be interacting with the same underlying system.

This matters most when the research involves reproducing the generation process itself. If the study compares how models generate statistical code, changes in the underlying model may affect the interpretation of repeated experiments.

For ordinary AI-assisted research programming, the more immediate priority is preserving the final verified code. A model update does not automatically invalidate previously generated software that remains executable and independently verified.

Researchers should therefore distinguish between reproducing an AI interaction and reproducing the computational analysis performed using its output.

Does Knowing the Exact Model Guarantee the Same Generated Code?

No. Model identity is only one component of a generation process.

Outputs may also depend on the prompt, conversation context, system instructions, sampling settings, external tools, retrieved information, and provider-side implementation details.

Some APIs provide controls intended to reduce output variability, but deterministic regeneration is not universally guaranteed. Even a fixed random seed may not produce identical outputs across different infrastructure or model configurations.

Consequently, researchers should not treat a model identifier as a substitute for preserving consequential prompts and AI responses when those interactions are relevant to the research record.

More importantly, they should preserve the actual code accepted into the project.

When Is Exact Model Identification Especially Important?

The significance of model documentation depends partly on the role AI plays in the research.

If AI merely suggests a minor syntax correction, recording the broad nature of assistance may be sufficient under some documentation policies.

If AI generates code responsible for constructing research variables or implementing statistical models, more specific documentation is advisable because the generated implementation can affect the scientific results.

Exact model identification becomes particularly important when the model is itself an experimental condition.

For example, a study comparing the accuracy of AI-generated regression scripts across different models cannot meaningfully interpret its results without identifying the systems evaluated.

Such studies may also need to preserve prompts, responses, evaluation datasets, generation settings, execution dates, and verification procedures.

How Should Model Information Be Connected to the Research Code?

Model documentation is most useful when it identifies which parts of the project were affected by AI assistance.

A project-level AI-assistance log might record the model used for a particular function, the date of generation, the researcher's subsequent corrections, and the code revision containing the accepted implementation.

For example, a researcher could document that a particular model helped draft a questionnaire-scoring function, while another model was used later to suggest unit tests.

These activities should not automatically be treated as equivalent contributions. Generating analytical logic, explaining syntax, and proposing tests have different implications for research verification.

Researchers can connect model records to version-controlled code revisions without adding the model name to every source-code line.

Where detailed provenance matters, the record can also distinguish AI-generated components from subsequent human modifications.

Does Documenting the Model Establish That Its Code Is Reliable?

No. Knowing which model generated a script provides provenance information, not evidence of computational correctness.

A highly capable model can produce code that executes successfully but implements an inappropriate method. A less sophisticated system may generate a simple function that is correct and easily verified.

Model reputation, benchmark performance, or a provider's general claims cannot replace evaluation of the specific implementation used in a study.

Researchers should inspect consequential analytical logic and apply appropriate unit tests to AI-generated research code. Expected outcomes should be independently established where feasible.

The final judgment must concern what the code actually does, rather than which model produced it.

Should the Model Be Named in the Published Manuscript?

This depends on the role of AI assistance and the policies governing the publication.

Some journals and publishers require disclosure of specified generative AI uses. Others distinguish between language editing, coding assistance, methodological applications, and AI systems used as research instruments.

Researchers should consult the current instructions of the target journal and their institution rather than assume that one disclosure convention applies everywhere.

Even when a manuscript does not require extensive model details, the research team may benefit from preserving a more complete internal record.

Internal documentation and public disclosure serve related but different purposes. A manuscript statement may summarize AI involvement, while the underlying research record can preserve the information needed to investigate consequential development decisions.

What If the Researcher Cannot Identify the Model Retrospectively?

Researchers should document what can be established from available evidence.

Conversation exports, API logs, development records, service documentation, or contemporaneous notes may contain useful information. However, a platform's current model selection should not be assumed to identify the model used during an earlier interaction.

If the exact model cannot be determined, researchers should record the known platform, approximate date, purpose of assistance, and limitation in model identification.

They should not reconstruct a specific model version from memory and present it as verified fact.

The absence of precise model metadata does not necessarily prevent reproducing the final computational analysis, provided the necessary executable materials have been preserved.

04 · A Practical Example

Recording the AI Model Used to Develop a Statistical Analysis Script

Hypothetical Example

An AI-Assisted Regression Analysis in Educational Research

A researcher investigates the association between students' online learning engagement and academic performance. Generative AI assists with developing a Python script for calculating engagement scores and estimating a regression model.

Step 1: Identify the AI system

The researcher records the AI provider, displayed model identifier, access method, and date of use. The interface does not expose an exact deployment snapshot, so that limitation is explicitly documented.

Step 2: Describe the coding task

The record states that AI was used to draft a questionnaire-scoring function and suggest a regression implementation. The researcher retains the relevant prompts and responses because they concern consequential analytical procedures.

Step 3: Review the generated implementation

The researcher checks the scoring rules against the questionnaire documentation and verifies the regression specification against the approved analytical plan.

Step 4: Correct and test the code

A missing-data rule introduced by the AI is found to be inconsistent with the study protocol. The researcher corrects it and verifies the revised implementation using independently defined test cases.

Step 5: Connect the model record to the final code

The AI-assistance log identifies the relevant Git commit and explains which generated components were accepted, modified, or rejected.

Step 6: Preserve the analytical release

The researcher archives the verified code, environment specification, execution instructions, and permitted supporting materials. The model record remains available as development provenance.

Another researcher can now identify which AI system contributed to the development process and which verified code revision produced the reported analysis.

Reproducing the statistical results does not require the original AI model to remain available, because the final executable implementation has been preserved. Reproducing the model's original coding behavior would be a separate task with additional requirements.

05 · What Researchers Often Get Wrong

Common Misunderstandings About AI Model Documentation

Misconception

Recording the AI Platform Automatically Identifies the Model

A platform may provide access to multiple models or change its underlying deployments. Researchers should record the specific model identifier when available and distinguish it from the application through which the model was accessed.

Misconception

The Same Model Will Always Generate the Same Code

Generated output can vary with prompts, conversation context, settings, and implementation details. Model identification improves provenance but does not guarantee deterministic regeneration.

Misconception

A Well-Known AI Model Produces Scientifically Reliable Code

General model capabilities do not establish the correctness of a particular research script. Researchers must verify analytical assumptions, transformations, calculations, and outputs independently of the model's reputation.

Misconception

Every AI-Assisted Coding Interaction Requires the Same Documentation

The appropriate level of detail depends on the significance of the assistance and applicable requirements. Generating an analytical procedure may warrant more extensive records than explaining a routine syntax error.

Misconception

If the AI Model Is Retired, the Research Analysis Becomes Irreproducible

Model retirement does not automatically prevent reproduction of an analysis performed with preserved executable code. It may, however, prevent exact reconstruction of the original code-generation interaction.

Misconception

Model Documentation Transfers Responsibility for Errors to the AI Provider

Identifying the model does not relieve researchers of responsibility for evaluating the code they use. Provenance information explains the development process; it does not establish methodological validity or transfer scientific accountability.

06 · What This Means for You

Document AI Models According to Their Role in the Research

Researchers should treat model identification as part of a proportionate documentation strategy rather than as an isolated administrative requirement.

The central question is what another researcher, reviewer, or auditor would need to understand about the AI system's contribution.

A simple decision framework

If AI provides routine programming explanations
Record the nature of assistance and model information to the extent required by the project or applicable policies.
If AI generates code that processes or analyzes research data
Preserve the available model identifier, date, purpose, relevant development records, and verified code revision.
If several models contribute to different code components
Document the models and their respective contributions when the distinctions are consequential.
If model performance is an experimental variable
Record the most precise available model and deployment information, generation settings, prompts, outputs, and evaluation procedures.
If the exact model cannot be established
Report the available information and its limitations without guessing a model version.

A short AI-assistance log can often provide sufficient development context. For studies evaluating AI-generated code itself, a more rigorous experimental record will usually be necessary.

Researchers should also preserve the computational materials required for long-term reproduction, because model metadata alone cannot reconstruct an analytical environment.

07 · A Quick Checklist

Before Finalizing AI Model Documentation for Research Code

Check whether your records identify the AI assistance accurately:
Record the AI provider and application or interface used for coding assistance.
Record the specific model identifier and available version or snapshot information.
Document the date or period of use and relevant generation settings when available.
Describe which coding tasks or analytical procedures received AI assistance.
Preserve consequential prompts and responses where they explain development decisions.
Connect AI assistance records to identifiable source-code revisions.
Document significant human corrections and independent verification procedures.
Distinguish verified model information from unavailable or uncertain details.
Review applicable institutional, funder, and journal requirements for reporting AI assistance.
08 · Frequently Asked Questions

Frequently Asked Questions About Documenting AI Models in Research Programming

Do researchers need to report the exact AI model used to generate code?

Recording the specific model is advisable when available, particularly for consequential analytical code. Whether exact identification is mandatory depends on the research design and applicable policies. Researchers should not invent version information that the service does not expose.

Is naming the AI platform enough?

Not always. A platform may use different models or deployments. Researchers should distinguish the application from the underlying model when the information is available and relevant.

Should researchers document the model version as well as its name?

Yes, when a specific version or snapshot is available and meaningful. This is particularly important when comparing model behavior or attempting to reproduce AI-generation experiments.

Does documenting the model make AI-generated code reproducible?

No. Model documentation supports provenance. Computational reproducibility also requires the final code, relevant input data, dependencies, execution conditions, and verification evidence.

What if the AI platform does not reveal its exact model version?

Record the displayed model name, provider, access method, date, and any other verified details. Explicitly acknowledge that the exact version or deployment could not be determined.

Do researchers need to document every model used during debugging?

Not necessarily at the same level of detail. Consequential model contributions and interactions that materially affected the analytical implementation deserve particular attention. Project-specific requirements may call for more extensive records.

Should the AI model be identified in the manuscript or only in internal records?

Researchers should follow the target journal's current AI disclosure requirements. Internal documentation may contain more technical detail than the manuscript disclosure, especially when needed for reproducibility or auditability.

09 · The Bottom Line

Record Which AI Model Contributed, but Verify the Code It Produced

The Bottom Line

Researchers should document the AI models used to generate or substantially modify research code, including available model identifiers, dates, purposes, and relevant version information, especially when AI assistance affects consequential analytical procedures.

Model documentation strengthens development provenance but does not replace code verification or computational reproducibility. The most defensible research record connects identifiable AI assistance to the actual code that was reviewed, tested, and used to produce the reported findings.

10 · Sources and Further Reading

Authoritative Resources on AI Model Documentation and Research Transparency

11 · Cite this Guide

How to Cite This Guide

This guide is intended to be read, shared, and used in research, teaching, and academic work. If you draw on its ideas, explanations, or other content, please acknowledge the source by citing the guide. Doing so gives appropriate credit and helps your readers locate the original resource.

Has the Field Guide helped your research?

If a guide helped clarify a question, inform a research decision, or move your work forward, I would love to hear about your experience. Your story may also help other researchers discover the Field Guide.

Share Your Experience
Takes only a few minutes