<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: Nicolai Thomsen</title>
    <description>The latest articles on Forem by Nicolai Thomsen (@nthomsencph).</description>
    <link>https://forem.com/nthomsencph</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F970333%2F0a6d4046-73a0-4683-8f2d-2cb0099cfaed.jpeg</url>
      <title>Forem: Nicolai Thomsen</title>
      <link>https://forem.com/nthomsencph</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/nthomsencph"/>
    <language>en</language>
    <item>
      <title>Why creative AI matters more than we think</title>
      <dc:creator>Nicolai Thomsen</dc:creator>
      <pubDate>Mon, 21 Nov 2022 17:53:19 +0000</pubDate>
      <link>https://forem.com/nthomsencph/why-creative-ai-matters-more-than-we-think-5ak8</link>
      <guid>https://forem.com/nthomsencph/why-creative-ai-matters-more-than-we-think-5ak8</guid>
      <description>&lt;p&gt;&lt;strong&gt;tl;dr:&lt;/strong&gt; &lt;em&gt;Generative models pulls AI out from behind the scenes and make the power of the technology tangible. This is the first time in history that non-techy humans and AI can interact directly with one another, which may propel curiosity and adoption for generations. It also happens to raise fundamental questions about how "human" creativity really is.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;The recent breakthroughs in generative AI have left the whole world dumbfounded. It seems as if everyone and their dog have made or seen a piece of AI art in the last six months. Images like the ones shown in this article. Advances in generative pre-trained transformers and, more recently, diffusion architectures, have truly catapulted us into a new era of creative expression. Neat, right? AI art and literature are, indeed, brilliant in themselves, but I'd argue that the societal implications may stretch far beyond. Let's dive into it. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--1PsmxM-4--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/n5f2aqij3qki25zsts4r.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--1PsmxM-4--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/n5f2aqij3qki25zsts4r.png" alt="surfs up" width="880" height="486"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Who really cares about AI?
&lt;/h3&gt;

&lt;p&gt;Outside of the tech echo chamber, the answer is no one. Sure, the average person cares about relevant search results, autonomous vehicles and auto-correct on their phones. But how it happens is not really important. AI or 5 billion if/else statements - It's all the same. If anything, AI may be a bit scary to most people. Damn Skynet.&lt;/p&gt;

&lt;p&gt;As data scientists, we often find ourselves evangelising the gospel of AI, but, let's face it, it often falls on deaf ears outside of our labs and conferences. Or it did until recently. With the emergence of creative AI, the power of the technology has been made tangible and apparent. Creative AI is &lt;em&gt;immediately impressive&lt;/em&gt; and not just another "&lt;em&gt;think of what this could lead to&lt;/em&gt;" act. This changes the value proposition, and, consequently, the societal narrative of artificial intelligence. Effectively, it draws AI out from behind the scenes, into the limelight, as a stand-alone wonder - and not just another cog in the machine.&lt;/p&gt;

&lt;p&gt;"&lt;em&gt;I could do that&lt;/em&gt;", is a justified response to many AI models. A dog breed classifier, for example, is not likely to be more accurate at its task than a human would be. The fact that the model is factors more (cost-)efficient, doesn't really make it any more magical to a consumer. Creative AI, on the other hand, is as close to magic as it gets, and definitively shows how the capabilities of AI stretch far beyond (average) human ability.  &lt;/p&gt;

&lt;h3&gt;
  
  
  Hi robot, hello human
&lt;/h3&gt;

&lt;p&gt;Text-to-image, image-to-music, X-to-Y. We can think of these conversions as approximations of idiomatic dialogue. To humans, a "&lt;em&gt;blue world&lt;/em&gt;" means something sad, a "&lt;em&gt;burning heart&lt;/em&gt;" means passion, and "&lt;em&gt;angry, orange man&lt;/em&gt;" could mean Donald Trump. Meaning, subtext and idioms are intuitive to us, but harder to learn for language models. In part, this is due to emotive interpretation. In the image below, do you see a single bird on a branch in the rain, or do you see a sad bird?&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--WfzhNRFo--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0syqyesnjnpgfqlewt50.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--WfzhNRFo--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/0syqyesnjnpgfqlewt50.png" alt="sad birb" width="880" height="431"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;With the recent advancements, we may be significantly closer to closing the idiomatic gap in interactions with AI systems. That is, systems that understand what we mean, not what we say. &lt;/p&gt;

&lt;p&gt;As AI systems learn to decode us, we also learn to decode them. Prompt engineering - The ability to identify which inputs to generative AI systems yield which results - is already a sought-after skill. &lt;a href="https://www.linkedin.com/jobs/view/ai-prompt-engineer-at-addition-3248992905/"&gt;This&lt;/a&gt; job posting for an AI Prompt Engineer, for example, requires &lt;em&gt;"1+ Year of Experience Prompt Engineering for Large Language Models"&lt;/em&gt;. Figuring out how to &lt;em&gt;tame&lt;/em&gt; generative models will be essential in a future with creative AI.&lt;/p&gt;

&lt;h3&gt;
  
  
  But creativity is for humans!
&lt;/h3&gt;

&lt;p&gt;A curious thing about our relationship with automatons and artificial intelligence is that we tend to &lt;a href="https://link.springer.com/chapter/10.1007/978-3-030-64269-3_11"&gt;move the goalpost&lt;/a&gt; for what it means to be "&lt;em&gt;intelligent&lt;/em&gt;". While we have (begrudgingly) ceded territory after territory, one area remains a shining bastion of humanism in the eyes of the public: Creativity. The new capabilities of creative AI seem to bulldoze this notion.. Or does it?&lt;/p&gt;

&lt;p&gt;&lt;a href="https://openai.com/dall-e-2/"&gt;DALL-E 2&lt;/a&gt; from &lt;a href="https://openai.com/"&gt;OpenAI&lt;/a&gt;, possibly the best text-to-image model around, is trained on hundreds of millions of captioned images, sourced from publicly available and licensed datasets. DALL-E 2 has learned the relationship between these images and their captions remarkably well. So well, in fact, that it can extrapolate across thematics, styles and motives to create completely new visuals. Arguably, however, is it not just regurgitating and combining human creativity? One answer is: "&lt;em&gt;Yes, but so are we&lt;/em&gt;". &lt;br&gt;
Our brains have been pre-trained by millions of years of evolution, and are then fine-tuned during our lifetime. Just like DALL-E, we regurgitate and combine what we have seen before. So, is creativity inherently human? Art is said to be a reflection of ourselves, and this may hold true for AI as well.&lt;/p&gt;

</description>
      <category>machinelearning</category>
      <category>ai</category>
      <category>datascience</category>
      <category>discuss</category>
    </item>
    <item>
      <title>On estimating data science projects</title>
      <dc:creator>Nicolai Thomsen</dc:creator>
      <pubDate>Tue, 15 Nov 2022 20:26:58 +0000</pubDate>
      <link>https://forem.com/nthomsencph/on-estimating-data-science-projects-6o7</link>
      <guid>https://forem.com/nthomsencph/on-estimating-data-science-projects-6o7</guid>
      <description>&lt;p&gt;&lt;strong&gt;Estimates for data science projects can be tough. Here are a few tips to hopefully make your life easier.&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Ah, the estimate! Easily given, mostly regretted. &lt;/p&gt;

&lt;p&gt;A product owner corners you, in a meeting room or, worse, at the coffee machine. After a few pleasantries, the PO asks you for an estimate for a new venture: Project AI. &lt;/p&gt;

&lt;p&gt;What do you answer? You haven't done something like Project AI before, and, frankly, you don’t really know what it would require. Yet, it's about AI and you are a data scientist, after all, so you should be able to pull a figure out of your sleeve.. Right?&lt;/p&gt;

&lt;h3&gt;
  
  
  1. "I will get back to you"
&lt;/h3&gt;

&lt;p&gt;An instant estimate is a surefire way to regret it later - Even if you are an experienced developer. First, you fit to the available data. There's no shame in putting time and thought into the estimate first. Communicate that, arguably, it's a disservice to both you and the proverbial PO not to do so. &lt;/p&gt;

&lt;h4&gt;
  
  
  What do we want to know?
&lt;/h4&gt;

&lt;p&gt;Particularly, you will need to understand the context of project AI first, so, before you leave the meeting room, ask all the questions you need. Be mindful of the phrase "&lt;em&gt;a ballpark estimate&lt;/em&gt;" as well. Too often, ballpark estimates end up being taken as qualified, once they switch hands a couple of times.    &lt;/p&gt;

&lt;p&gt;You may want to be mindful of your own expertise too. It would feel wonderful to says "&lt;em&gt;I could have it done by Tuesday!&lt;/em&gt;" and surely your PO would be impressed. Until Tuesday that is. Consider what learning curve you would face in Project AI, and let this influence your estimate. Don’t put future you in a difficult position by ignoring this factor. &lt;/p&gt;

&lt;h3&gt;
  
  
  2. How data ruins everything
&lt;/h3&gt;

&lt;p&gt;Any software development venture has risks. Data scientific ones have those too, but with an added dimension. One that is often overlooked by PMs, POs and clients: Data signals. &lt;/p&gt;

&lt;p&gt;Even for the most brilliant architecture, success hinges on generalizable signals in your data. Say Project AI is a dog breed image classifier (because, why not). We may hypothesize that we can differentiate breeds, but what happens to the project if there are no significant signals for your models to fit to? how long will it take you to procure and/or annotate new data? These are the additional risks that govern data science projects. And they must be accounted for in any reasonable estimate as well as communicated clearly to your stakeholders. What is your contingency plan? Try not to scare them too much. &lt;/p&gt;

&lt;h3&gt;
  
  
  3. Explore the jungle
&lt;/h3&gt;

&lt;p&gt;"&lt;em&gt;well..&lt;/em&gt;", you start and mumble something about uncertainty. Instead of treading water, diminish that uncertainty a bit by exploring the domain jungle. How? By asking questions. A lot of questions. We know by now that we don't make instant estimates, so the next step is about (A) learning what you can, and (B) delimiting your eventual estimate. "&lt;em&gt;Can we realistically assume that we will have quality data handed?&lt;/em&gt;" and "&lt;em&gt;what specifically would the end deliverable look like?&lt;/em&gt;" are good places to start. Mix in your expertise (&lt;em&gt;"If that's so, we could do Y instead of X, to achieve Z"&lt;/em&gt;), when applicable.&lt;/p&gt;

&lt;p&gt;As you traverse the jungle, one of two things are likely to happen: Either you will learn most of what you need to, or your PO will become keenly aware that you can't be expected to make a realistic guess based on such sparse information, much less a qualified estimate. Once you have squeezed the jungle fruit for information, return to civilization and crunch the numbers in peace.  &lt;/p&gt;

&lt;h3&gt;
  
  
  4. Break it down
&lt;/h3&gt;

&lt;p&gt;There are multiple ways to build an estimate, and people much cleverer than I have written extensively about them elsewhere. One example is the simple approach explained in the &lt;a href="https://pragprog.com/titles/tpp20/the-pragmatic-programmer-20th-anniversary-edition/"&gt;The Pragmatic Programmer&lt;/a&gt; by David Thomas and Andrew Hunt (2020, 2nd edition, pp. 65-71). My interpretation is as follows:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Sketch a solution architecture&lt;/strong&gt;: This is the fun part. Visualize the elements involved (Backend, frontend, APIs, DB) and the data flows between them. I use MS PowerPoint for this, although some devs consider it a sin. Here's a simple outline.&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--tz6glbqO--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/wn2twf58sp8lygmc0hoi.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--tz6glbqO--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/wn2twf58sp8lygmc0hoi.png" alt="Image description" width="880" height="722"&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Break each part down into components&lt;/strong&gt;: Create a tabular overview of the components of each element. I prefer the following format.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Element&lt;/th&gt;
&lt;th&gt;Component&lt;/th&gt;
&lt;th&gt;Functionality&lt;/th&gt;
&lt;th&gt;Conditions&lt;/th&gt;
&lt;th&gt;Est. days&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;Comp. Aa
&lt;/td&gt;
&lt;td&gt;&amp;lt; Functions to cover &amp;gt;&lt;/td&gt;
&lt;td&gt;e.g., 'Specified data schema respected' or 'Client documentation available'&lt;/td&gt;
&lt;td&gt;4&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Serv. A&lt;/td&gt;
&lt;td&gt;Comp. Ab
&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;10&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;Comp. Ac
&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;&lt;/td&gt;
&lt;td&gt;7&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;3. Identify the risky components&lt;/strong&gt;: Be mindful of which components are likely to deviate from your estimate. You will want to pay extra attention to these. After project kick-off you may want to start off with these elements, particularly if they are in the &lt;a href="https://hbr.org/1963/09/the-abcs-of-the-critical-path-method"&gt;critical path&lt;/a&gt; of your timeline. (Critical path is another great tool that I'd like to cover in a later post).&lt;/p&gt;

&lt;p&gt;Alternatively, &lt;a href="https://www.linkedin.com/pulse/what-pert-how-can-we-use-dave-fourie-pmp-prince2-/"&gt;PERT&lt;/a&gt; is a great option, particularly if you have sparse information to go on. &lt;/p&gt;

&lt;p&gt;Lastly, consider using a use case model for crystal clarity of what the deliverables should be able to do. In the case of our brilliant dog breed classification service, it could look like the following. Consider the use case with the prefix "&lt;em&gt;A user wants to&lt;/em&gt;".&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;Use case&lt;/strong&gt;: Upload a photo and receive back a predicted dog breed and a confidence score.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Requirements:&lt;/strong&gt; [Quick response]&lt;br&gt;
&lt;strong&gt;Solution:&lt;/strong&gt; A RESTful API exposing a multi-class classifier with high inference speed, trained on (image, label) pairs of dogs their respective breeds. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;On error&lt;/strong&gt;: Return instructions for use of the API.&lt;/p&gt;




&lt;h3&gt;
  
  
  5. Ask around
&lt;/h3&gt;

&lt;p&gt;More important than sitting down with the estimate alone, is to ask the people around you. Perhaps someone in your team or the community has dealt with something akin or tangential to project AI already. Likewise, consider reaching out to others in your space with more experience. If nothing else, they can likely point you in the right direction. Importantly, do not ask the client. "&lt;em&gt;What's a realistic estimate for the client?&lt;/em&gt;" is not a relevant question in your position (although it's highly relevant for your PO).&lt;/p&gt;

&lt;h3&gt;
  
  
  6. Are you often late?
&lt;/h3&gt;

&lt;p&gt;I once worked with a PM who took any estimate we gave her and multiplied it by pi (3.14). Seems high? Her intuition was that she consistently saw underestimation from data scientists. You could call it human curve-fitting. The underlying point here is important: You may be consistently under- or overestimating your projects. &lt;/p&gt;

&lt;p&gt;Look outside work. Are you a time optimist? Perhaps this means that you are inclined to underestimate your travel time. It may be worthwhile to consider your own biases and whether they translate into your estimates on data science projects. &lt;/p&gt;

&lt;h3&gt;
  
  
  7. Keep score
&lt;/h3&gt;

&lt;p&gt;Project estimation is a skill. Hard-won at times. In order to improve, you may want to log your performance. Take note of your estimation accuracy across projects or even individual tasks. &lt;/p&gt;

&lt;p&gt;When the estimates are off, ask yourself what caused it. Maybe your model was wrong. Maybe you estimated data gathering to be more time-consuming than it turned out to be.   Although all projects vary, you are likely to uncover some patterns to learn from. &lt;/p&gt;

&lt;h3&gt;
  
  
  8. Communicate continuously
&lt;/h3&gt;

&lt;p&gt;Your initial estimates will be skewed once the project actually starts. That is almost inevitable. What matters is that you communicate why and, more importantly, &lt;em&gt;how to adjust&lt;/em&gt; to your stakeholders continuously throughout the project. Estimation doesn't stop when the project starts. It's something worthwhile to include in stand-ups and checkpoint meetings. To quote &lt;a href="https://www.linkedin.com/in/gergelyorosz"&gt;Gergely Orosz&lt;/a&gt; in his &lt;a href="https://blog.pragmaticengineer.com/yes-you-should-estimate/"&gt;awesome post&lt;/a&gt; on estimation in software projects: "&lt;em&gt;Good communication is more important than good estimation&lt;/em&gt;". Make sure to pipe up when things change!&lt;/p&gt;

&lt;h3&gt;
  
  
  9. Putting it all together
&lt;/h3&gt;

&lt;p&gt;We've covered a few tips in this post. Here's a neat list of them, tagged with the corresponding sections.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Avoid instant estimation. (1)&lt;/li&gt;
&lt;li&gt;Be mindful of the learning curve. (1)&lt;/li&gt;
&lt;li&gt;Account for the risk of data signals. (2)&lt;/li&gt;
&lt;li&gt;Listen and learn first. (1, 3)&lt;/li&gt;
&lt;li&gt;Break it down. (4)&lt;/li&gt;
&lt;li&gt;Ask around for pointers. (5)&lt;/li&gt;
&lt;li&gt;Consider your own biases. (6)&lt;/li&gt;
&lt;li&gt;Keep score of your estimation prowess. (7)&lt;/li&gt;
&lt;li&gt;Good communication is more important than good estimation. (8)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I hope these tips will help you with your future estimates. Good luck with your projects!&lt;/p&gt;

</description>
      <category>datascience</category>
      <category>methodology</category>
      <category>productivity</category>
    </item>
  </channel>
</rss>
