Oregon State University|blogs.oregonstate.edu
Blog Owner
Blogger Name

Archives: November, 2023

My First Foray into the Wilderness

  November 22nd, 2023

The last two months of speed-running learning how to utilize AI coding tools for app development have been an adventure and a half, to say the least. I came into the course without any experience, and I was absolutely terrified of whether I would even be able to get off the ground. Even with this being the case, however, my greatest breakthrough surprisingly lies outside the realm of AI. I had zero experience with app deployment, and all of my previous coursework had been carried by the university offering servers and solutions for everything. The capstone was a huge eye-opener and learning experience for me in terms of the difficulties and accumulated costs of setting things up on my own.

It was our second week together as a group. We had selected our project of utilizing AI tools to create an app which connected humans to animals, and we had even done a bit of brainstorming on solutions for optimally researching and developing our individual apps. The problem, however, was that we had all been so accustomed to being given rights to both host our apps as well as deploy our database backends through the university’s servers that we failed to even realize we would have to venture out on our own to find solutions to these fundamental issues for our capstone project.

How hard could it be to find web hosting anyway? My line of thinking may have been a bit naive in hindsight, but it also held true. It felt like there were infinite options, as long as I was willing to pay the right price. I started with GitHub pages and Google Cloud, but they both only offered hosting solutions for static webpages, at least if I wanted to keep things free or relatively cheap. My application would need to not only be dynamic but also connected to a database. This led me to Amazon Web Services. Amazon offered not only web hosting of dynamic web applications, but also options for SQL databases to serve as my backend. It came at a bit of a price, but it seemed much more affordable than the potentially hundreds of dollars it felt like Google was asking of me. Surely it would be smooth sailing now, right? I had everything at my fingertips, and it was all on a single platform even.

Not quite, or at least not quite yet. It started simple enough. I created a free-tier AWS account, and I went through about half an hour of tutorials on setting up user identities and MFA. This eventually led to me being given temporary keys through which I could connect to AWS remotely. I set up the AWS CLI to access AWS through Git Bash/Powershell, and after another hour or so of tinkering, it seemed like things were finally looking up. It was, however, only the beginning. I could connect to AWS, but what good did that do me exactly? I wanted to deploy a Flask app, but it wasn’t like I could just upload my code somewhere and have AWS know what to do with it.

This issue inevitably led me down a huge rabbit hole of installing Docker to create containers, configuring Lightsail to deploy containers through the AWS CLI, creating NoSQL tables through Amazon DynamoDB, and learning how to connect my web app to all of them. It took me an entire day to get things set up, and by the end of it all it felt like I had accomplished something spectacular, except that it was really just a basic task of deploying a web app online somewhere via a paid service. It was, however, just the breakthrough my group needed. I was the first to succeed, and I felt it motivated others to either follow my lead or pursue similar avenues with renewed vigor. It put our minds at ease and allowed us to begin our journey in earnest, as much of our web app was not even configurable without a functional backend.

The journey taught me a lot about myself as well as about the reality of my work. I learned I should never take anything for granted, even within a heavily controlled environment such as academia, and I came to realize there was a lot I still had to learn even at a most fundamental level. I also learned, however, that the answers were always at my fingertips, and that I simply had to put in the time and effort to find them. This has felt more true in computer science than any other facet of my life. I also, of course, learned quite a bit about hosting solutions themselves and how I could utilize them in my future endeavors. There are a lot of choices, and AWS might not always be the best one for my needs, but my experiences will undoubtedly impact my ability to make informed choices in the future as well as streamline and expedite my process of doing so.

Read the post...


A Newbie’s AI Coding Journey

  November 3rd, 2023

Talk about throwing yourself into the deep end! AI Coder was in my top 3 for capstone projects, but I honestly wasn’t expecting to end up with it. I had exactly zero experience heading into things, and it seemed like much of my group was a bit more advanced than me. We selected a “dating app” to be our final deliverable, and our goal was to utilize various AI tools as best as we could in order to plan and develop a web app tailored to matching humans to prospective animal friends. This is the story of my journey for the last few weeks.

We each picked our favorite AI tool to compare and contrast our experiences in web development utilizing them. What even was my favorite AI tool? I didn’t even know any AI tools to begin with, aside from vaguely understanding ChatGPT existed. I ended up selecting GitHub Copilot. I felt relatively confident about building a web application, so having something more hands on felt like the right call. Copilot plugs right into my favorite IDE: VS Code, and all it really takes to get going is a few comments from which it attempts to generate code. It should be pretty simple, right?

Honestly, it really is pretty simple, but also kind of not very simple at all. I can get it to do almost anything I want, but only to a certain extent. I’m making a Flask app for the dating app. I turned Copilot on and decided to start with something simple. I asked it to import Flask. It succeeded, but it also imported more things than I ever would have needed to complete my basic tasks. It doesn’t particularly hurt to have them, but I decided it wasn’t quite what I wanted, so I refined my comments a bit further to be more explicit. With the correct guidance, it was able to import only that which I desired, but at this point I would’ve been better off simply writing the line myself. What was even the point?

I suppose it was a little amusing to me later when I found out I actually did need a handful of the things it had imported, and I had written off as useless. It was just a matter of adding a few extra words at the top of my Python file, but that was beside the point. Humans are far from perfect, and AI will likely never be perfect as well, but it had still presented me with a helpful suggestion which at worst could have served as a convenient reminder and at best could have saved me a lot of grief if I had been working with something a little more unfamiliar to me. It doesn’t always give suggestions I want, and it doesn’t even always give suggestions that are correct in the sense of creating functional code that will actually run, but it does serve as a convenient primer to have along. I occasionally forgot an exact syntax or ran into a simple problem I’ve seen numerous times before, and these were instances in which Copilot managed to take care of me in an efficient manner. I still had to look over its work, but this both removed at least some of the repetitiveness of my work and served as a refresher on little nuances I may have slightly forgotten.

Overall, I would say I have had a relatively positive experience with GitHub Copilot. If I knew nothing, Copilot was not very helpful. It would make an attempt, of course, unless I provided it with too much information at least, but this was still not very useful to me in the long run, as I would neither be able to verify the code’s usability nor build upon it without relying further on AI. It’s a bit interesting. Knowing more about exactly what I needed and how to go about making it made having AI around a bit more convenient. It could help me learn a bit more about a language, help me avoid a bit of repetitiveness in my work, or even write some comments for my code for me. It noticed my approaches to problems and provided my own solutions back to me when I encountered similar problems later on in my work. It’s not something I’d always use, but at this point I at least enjoy having it around, and that’s honestly not something I would’ve been able to say even a few weeks earlier.

Read the post...