In-Class Assignment: Revisiting Generative AI and Project Planning#

Day 17#

CMSE 202#

Agenda for today’s class#

  1. Using and citing generative AI

  2. Setting up a GitHub repository

  3. Effective Collaboration and Communication

  4. Project Planning

  5. Project work time

Put your name here

#

✅ Put your group member names here

#


1. Getting more practice with Generative AI and being intentional about how you use and cite it#

As we’ve done previously, we’re going to spend a bit of time thinking about how we might use generative AI as a tool to assist and accelerate our computational work. There are many ways that generative AI tools like ChatGPT and Claude can assist you when you run into expected struggles in your computational work and it can be really good at some things, while struggling with others. Of course, it is also important that we are transparent about how and went we use these tools and that we cite them appropriately.

Before we dive in, let’s look at how one of these tools defines itself.

The following text is generated from:

[1] OpenAI ChatGPT-3.5. Accessed on Sept 15, 2023 from https://chat.openai.com/. Prompt chain:{‘What is GPT-3’}

GPT-3, or Generative Pre-trained Transformer 3, is a state-of-the-art natural language processing (NLP) model developed by OpenAI. It’s the third iteration in the GPT series of models and is known for its remarkable ability to understand and generate human-like text. Here are some key characteristics and features of GPT-3:

  1. Scale: GPT-3 is one of the largest language models, containing 175 billion parameters. The large scale of the model contributes to its impressive language understanding and generation capabilities.

  2. Pre-training: Like its predecessors, GPT-3 is pre-trained on a massive corpus of text from the internet. During pre-training, the model learns to predict the next word in a sentence, gaining a deep understanding of grammar, context, and semantics.

  3. Fine-tuning: GPT-3 can be fine-tuned on specific tasks or domains. This means it can be adapted for a wide range of NLP tasks, such as text generation, translation, summarization, question-answering, and more.

  4. Human-like text generation: GPT-3 is known for its ability to generate coherent and contextually relevant text. It can answer questions, write essays, create conversational agents, and perform various language-related tasks.

  5. Zero-shot and few-shot learning: GPT-3 can perform tasks with minimal examples or instructions, making it highly versatile. It can understand and execute tasks even when provided with very limited context.

  6. Ethical considerations: GPT-3 has sparked discussions about its potential for misuse, including generating misleading information, disinformation, or deepfakes. OpenAI has implemented ethical guidelines and usage policies to address these concerns.

GPT-3 has been widely used in a variety of applications, from chatbots and virtual assistants to content generation, language translation, and more. It has the potential to revolutionize the field of natural language processing and human-computer interaction.

1.1 Citing Generative AI in your code and work#

Before we experiment with this tools again, we want to reiterate our expectations for how you should use and cite these tools. We’ve talked about this before, but it’s worth repeating.

Citing sources in your work is necessary for several important reasons:

  1. Giving Credit: When you use someone else’s ideas, research, or words in your work, it’s essential to give proper credit to the original source. Citing acknowledges the intellectual property of others and shows respect for their contributions.

  2. Avoiding Plagiarism: Failure to cite sources can lead to plagiarism, which is a serious academic and ethical violation. Plagiarism occurs when you present someone else’s work as your own. Proper citations help you avoid this.

  3. Providing Evidence and Authority: Citing reputable sources adds credibility and authority to your work. It demonstrates that your ideas are supported by existing research or expert opinions.

  4. Allowing Verification: Readers should be able to verify the claims and evidence you present in your work. By citing your sources, you allow others to find and review the same information.

  5. Showing Your Research Process: Proper citations demonstrate that you’ve done your research and have considered various perspectives and sources. It adds depth and reliability to your work.

  6. Avoiding Legal Issues: In some cases, failing to cite sources can lead to legal issues, especially if you use copyrighted material without permission.

These points are adapted from:

[2] OpenAI ChatGPT-3.5. Accessed on Sept 15, 2023 from https://chat.openai.com/. Prompt chain:{‘why is it necessary to cite a sources in work’}

Citation Requirements for this course#

For this course (and recommended for anytime you use generative AI for the foreseeable future), you are expected to cite every time you use any form of generative AI. Your citation must include the following key items:

  1. Author: usually the company the created the AI system or the name of the AI; Or the Author and specific AI model. For example: Open AI GPT-3.5

  2. Access Date: Date the content was generated (for example: Sept 15, 2023)

  3. Access Interface: Include how the system was accessed, typically using a web URL. Include the URL of the tool or other access such as an extension in a development enviroment (for example: Accessed from https://chat.openai.com/ or Assisted by extension in VS code)

  4. Prompts: Provide the prompts or a summary of the prompts that generated the content (for example: Prompt chain:{'how many licks does it take to get to the middle of a tootsie roll; please shorten that; can you write it in limerick form})

For examples, see citations [1] and [2] above.

1.2 Using multiple AI prompts to generate python code#

Practice using ChatGPT (or Claude or something else you prefer more) to generate python code to accomplish the following task. You can access Chat GPT-3.5 for free with a free account at: https://chat.openai.com/ (you can create an account and access Claude at: https://claude.ai/)

Question 1.1: Generate a bar graph to display the undergraduate enrollment at MSU for years 2019 through 2023. Include a green color pallete to make it MSU colors. A code cell to generate the data is provide, make sure you run that cell before running your AI-generated code. Also, make sure to include a citation following the rules above.

import pandas as pd
# MSU Undergraduate Enrollment Data
data = {
    'Year': [2019, 2020, 2021, 2022, 2023],
    'Undergrad_Enrollment': [39176, 38491,38574, 39201, 40483]
}

# Create a pandas DataFrame
df = pd.DataFrame(data)
# Put your code for here; Include a citation for your code source

Question 1.2: Using this data and a generative AI tool, try to prompt the AI to generate a linear regression model to predict the enrollment in 2025. Be sure to use the fitting package that we used in class (statsmodel). What will be the enrollment in 2025 based on this model? Make sure to include a citation following the rules above.

# Put your code and citation here

Question 1.3: Using the AI tool, try to prompt it to generate a bar graph similar to what you see below. You do not necessarily need to have the same predictions, but try to match the y-axis range, the ability to make predictions for the future years below, and ability to distinguish between the provided enrollment data and the predicted enrollment. Make sure to include a citation following the rules above.

# Paste your code and citation here

Question 1.4: Reflect on your experience with using a generative AI tool to complete these tasks:

  1. What worked well?

  2. What didn’t?

  3. How do you decide when you trust the AI’s solutions versus when you don’t? What criteria are you using to make these sorts of judgement calls?

  4. In what ways do you think this sort of tool could help to advance your semester project work?

Discuss these questions with your group and record your answers in the cell below

Record your answers to the above questions here.


2. Setting up a GitHub repository for your project#

To make sure you have a GitHub repository set up for your semester project, we’re gonna start that process in this section of today’s assignment!

Before you leave class today, you need to make sure you’ve done the following:

  1. Set up a new private GitHub repository for your project.

  2. Make sure all group members are collaborators on the repository.

  3. Add your instructor and TA as collaborators on the repository.

  4. Make sure all group members have cloned the repository to their local machines or JupyterHub to confirm that they have access.

  5. Make the following updates/additions to the README.md file in the primary directory of your repository (only one person needs to add this information, commit the changes, and push the changes):

    • Add your project group name (this can be your project idea/topic)

    • Add the names of all group members

  6. Create another Markdown document (with the .md extension) in the primary directory of your repo called “ProjectDiscussionAndPlanning.md”, add this to your repo, and commit it. As you work through Parts 3 and 4 of this assignment, you’ll add the following information to it, commit those changes, and push them to the repo at the end of class (only one person needs to add this information, commit the changes, and push the changes, but you can take turns doing this to get some practice!):

    • Add your plans for creating effective collaboration and communication within your project group (based on your discussion in the Part 3 and the answers to those questions)

    • Add your project roles and who is taking on each role based on your discussion in Part 4 and the answers to those questions

    • Add the short-term project goals you identified in the Part 4 and the deadlines for each goal

    • Add the day, time, and location of your first group meeting, as determined in Part 4 as well


3. Fostering effective collaboration and communication in your project group#

Do This: As a group, discuss the responses you had in your pre-class assignment to the following questions regarding a previous group work experience:

  • What worked well in this group effort? What did you do that helped the group work well together? What did other people do that helped the group work well together? Can you identify aspects of the group work that made the project successful? If the project wasn’t successful, still try to identify parts of the group work that went well.

  • What challenges did you face in this group effort? What strategies did you use to overcome these challenges? What did other people do to overcome these challenges? Can you identify aspects of the group work that made the project challenging? What could you do differently on future group efforts to avoid these challenges?

Make sure everyone gets a chance to share their experiences.

Take any notes that seem important here:

Do This: Now that you’ve talked about your previous group work experiences, discuss the following questions:

  1. What form of communication will work best for all of your when you need to discuss your project and make decisions? For example, will you use Slack, Discord, text messages, email, in-person meetings etc.?

Make sure your group’s answer is recorded in the ProjectDiscussionAndPlanning.md file in your repo, but feel free to drop any important notes here as well, if that would be helpful.

  1. How often do you think you should meet as a group to discuss your project? How long should these meetings be? What should you do if you can’t make a meeting?

Make sure your group’s answer is recorded in the ProjectDiscussionAndPlanning.md file in your repo, but feel free to drop any important notes here as well, if that would be helpful.

  1. What are some strategies you can use to make sure everyone is contributing to the project? How will you make sure everyone is on the same page? How will you hold each other accountable?

Make sure your group’s answer is recorded in the ProjectDiscussionAndPlanning.md file in your repo, but feel free to drop any important notes here as well, if that would be helpful.

  1. As a group, what are you overall goals for the project? What strategies will you use to make sure you meet these goals?

Make sure your group’s answer is recorded in the ProjectDiscussionAndPlanning.md file in your repo, but feel free to drop any important notes here as well, if that would be helpful.


4. Project Planning#

Now that you’ve had a chance to think about how you will work together as a group, it’s time to start thinking about how you will plan your project to make sure you meet your project goals.

Do This: To start, spend some time thinking about the various roles that might be needed in order for your project to meet its goals. For example, you might want:

  • someone to be in charge of sending our reminders for group meetings and reserving a space to meet or setting up a zoom room

  • someone to periodically test your project code to ensure that it is still working as intended and reporting issues as they arise (GitHub has an issue tracking feature!)

  • someone to take the lead in developing the project presentation slides (e.g. setting up a shared slide deck, building an outline, indicating who is responsible for which part, etc.)

  • and so on… (you should take these as suggestions and come up with the list of roles that make sense to you and your group!)

You may find it useful to review the project requirements page on tue course website to make sure you all know what’s expected of you and it might help with identifying important roles to have within your group: https://msu-cmse-courses.github.io/cmse202-S24-jb/course_materials/CMSE202_FinalProjectRequirementsAndGradingRubric.html

If someone is missing from your group, its OK to assign them a role during this class session, but make sure to make contact with them to ensure that they are OK with taking on this role or if they think they would be an asset to the group in another way.

Record the project roles you’ve identified for your group and who is going to take on that role in the ProjectDiscussionAndPlanning.md file in your repo, but feel free to drop any important notes here as well, if that would be helpful.

Do This: Now that you’ve determined the role(s) each of you will take in supporting your project, you’re going to try to identify some short-term project goals that you can use to help you stay on track. For example, you might want to:

  • Have usable data or a chosen model you’re going to use (or both) by next week

  • Have a working proof-of-concept by end of March.

  • Have first-draft versions of key data visualizations by April 5th.

  • and so on… (again, these are just random suggestions, you should choose things that align with your overall project goals and map to a realistic timeline)

You may want to revisit the project requirements and grading rubric and, as a reminder, you’re expected to give a project progress update presentation during the Day 23 class session. For reference, the course schedule is here: https://msu-cmse-courses.github.io/cmse202-S24-jb/course_materials/CMSE202_Calendar.html

It would be really great to have a complete project draft by Day 23!

Record at least three short-term project goals with target deadlines in the markdown cell below. You may also wish to include who in the group will be working on each goal.

Record the project goals and corresponding deadlines that you’ve identified for your group and who is going to work on each goal in the ProjectDiscussionAndPlanning.md file in your repo, but feel free to drop any important notes here as well, if that would be helpful.

Do This: Finally, before moving on to set up your project repository, set a day, time, and (if possible) as location for your first group project meeting (you can always just use Zoom for this).

Make sure everyone in the group is available at this time and that you have a way to contact each if something comes up. If you can’t find a time that works for everyone, try to find a time that works for most people and then make sure to record the meeting or take detailed notes so that anyone who can’t make it can still get caught up.

Record the day, time, and location of your first group meeting in the ProjectDiscussionAndPlanning.md file in your repo, but feel free to drop any important notes here as well, if that would be helpful.


5. Project work time#

With any time still remaining, you are strongly encouraged to start using it to make some forward progress on your project.

Good luck!


Congratulations, we’re done!#

Now, you just need to submit this assignment by uploading it to the course Desire2Learn web page for today’s submission folder (Don’t forget to add your names in the first cell).

© Copyright 2023, Department of Computational Mathematics, Science and Engineering at Michigan State University