<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Dr Clemens Jarnach ⚡️ on Medium]]></title>
        <description><![CDATA[Stories by Dr Clemens Jarnach ⚡️ on Medium]]></description>
        <link>https://medium.com/@clemensjarnach?source=rss-83addca999c7------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*7UzqbasqM5OcBXvKe_xxNA.png</url>
            <title>Stories by Dr Clemens Jarnach ⚡️ on Medium</title>
            <link>https://medium.com/@clemensjarnach?source=rss-83addca999c7------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 21 Nov 2026 18:04:16 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@clemensjarnach/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Find Invisible Unicode Characters aka “AI Watermarks”]]></title>
            <link>https://levelup.gitconnected.com/find-invisible-unicode-characters-aka-ai-watermarks-4dd7acf7deca?source=rss-83addca999c7------2</link>
            <guid isPermaLink="false">https://medium.com/p/4dd7acf7deca</guid>
            <category><![CDATA[unicode]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[python]]></category>
            <dc:creator><![CDATA[Dr Clemens Jarnach ⚡️]]></dc:creator>
            <pubDate>Mon, 28 Apr 2025 14:37:23 GMT</pubDate>
            <atom:updated>2025-04-28T14:37:23.835Z</atom:updated>
            <content:encoded><![CDATA[<h4>Clean Up Your Text and Uncover AI Traces: A Tool for Finding and Removing Hidden Unicode</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*bPu9D3Efa0ezyT5G" /><figcaption>Photo by <a href="https://unsplash.com/@googledeepmind?utm_source=medium&amp;utm_medium=referral">Google DeepMind</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>Have you ever faced accusations of using ChatGPT to write your essays? Or maybe you’ve stared at code or data that <em>looked</em> flawless yet stubbornly refused to cooperate? The underlying cause might be something invisible to the naked eye: Unicode characters that don’t render visually, now sometimes referred to as “AI watermarks.”</p><blockquote>But there’s a way to find them! Keep reading to learn how.</blockquote><p>It’s becoming increasingly apparent that Large Language Models (LLMs) like ChatGPT frequently incorporate these invisible Unicode characters into their output, inadvertently creating spacing and formatting anomalies. This prevalence has led some to dub them “AI watermarks.” While not a definitive method for detecting AI-generated text, the presence of these obscure Unicode characters can be a strong indicator. Finding them embedded in a student’s essay or a colleague’s email raises a significant likelihood of AI involvement, as these are not characters typically introduced through manual typing.</p><p>For example, the text you copied from ChatGPT might <em>appear</em> like this:</p><pre>Hello world! This is an example text with some invisible characters. <br>Can you find non-printable spaces between or be​hind  words?</pre><p>However, if you were able to reveal the underlying Unicode characters, the same text might actually look like this:</p><pre>Hello&#39;U+A0&#39;world! This is an example&#39;U+A0&#39;text with some invisible characters. <br>Can you find non-printable spaces between or be&#39;​U+200B&#39;hind&#39;U+FEFF&#39; words?</pre><p>Notice theU+A0, U+FEFF and U+200B elements? These are the invisible Unicode characters that can make a developer’s life difficult or expose the use of AI in a piece of writing.</p><p>This is because LLMs, like ChatGPT, seemed to have picked up on the fact that those invisible Unicode characters are a great way to create spaces and other formatting in their outputs. Hence, ChatGPT and other AI generated text is full of them. Of course, this is still not a bullet-proof way of detecting AI-generated text, but it comes pretty close. If you find these invisible Unicode characters in your student’s essay, or your boss’s email, chances are it has been processed with AI in some way, because you would not normally enter them yourself when writing a text.</p><p>While their exact purpose isn’t always clear — it could be an artifact of the generation process, or even a subtle, unintentional fingerprint — their presence can cause significant headaches for developers and data scientists.</p><p>Let’s take a closer look at what these characters are and how you can identify and eliminate them.</p><h3>Understanding These “Invisible” Characters</h3><p>These are subtle Unicode characters that, while <strong>visually undetectable</strong>, can significantly disrupt:</p><ul><li>String matching</li><li>Text rendering</li><li>Database searching and indexing</li><li>Machine learning pipelines</li></ul><p>Beyond these technical issues, some tech-savvy individuals are also exploring the presence of these subtle characters as a potential, albeit not foolproof, way to identify AI-generated text.</p><p>Common offenders include:</p><ul><li>U+00A0 — <strong>Non-breaking space</strong>: While it looks like a standard space, it behaves differently.</li><li>U+200B — <strong>Zero-width space</strong>: A character with no visual width.</li><li>U+200C / U+200D — <strong>Zero-width joiners</strong>: Used for complex script rendering but can be problematic in plain text.</li><li>U+FEFF — <strong>Byte Order Mark (BOM)</strong>: Often found at the beginning of files and can interfere with processing.</li></ul><p>These characters frequently infiltrate your workflows through sources like:</p><ul><li>Copy-pasted content</li><li>AI-generated text</li><li>User-submitted forms</li><li>Exports from PDF or Word documents</li><li>Server responses</li></ul><h3>Here Is How To Find Unicode And Clean Your Text</h3><p>One option is to find a website that does the job for you. Another is to run a script yourself. To detect and clean text from non-printable Unicode characters, I wrote a small Python script designed to <strong>highlight and clean</strong> these invisible Unicode characters from .txt files.</p><h4>Here’s What the Script Does</h4><ul><li>Highlights hidden characters in the console, providing details such as type, Unicode value, line number, and column number.</li><li>Replaces problematic space-like characters with standard spaces.</li><li>Removes other non-printing characters.</li><li>Generates a cleaned output file named yourfilename.txt.clean.txt</li></ul><h4>Here’s How to Use the Script</h4><p>1. <strong>Download the script</strong> from my GitHub repo (you’ll find it under `highlight_and_clean_unicode.py`).<br>2. <strong>Save it</strong> anywhere on your machine.<br>3. Then, run the following line in your terminal:</p><pre>python3 highlight_and_clean_unicode.py yourfile.txt</pre><p>And the script will provide output similar to this, highlighting the problematic characters:</p><pre>Line 1, Col 6: [NBSP] U+00A0<br>Line 1, Col 32: [NBSP] U+00A0<br>&gt;&gt; Hello[NBSP]world! This is an example[NBSP]text with some invisible characters.<br><br>Line 2, Col 48: [ZWSP] U+200B<br>&gt;&gt; Can you find non-printable spaces between or be[ZWSP]hind  words?</pre><p>In this output:</p><ul><li>[NBSP] indicates a Non-Breaking Space (U+00A0).</li><li>[ZWSP] indicates a Zero-Width Space (U+200B).</li><li>The &gt;&gt; prefix shows the line of text where the invisible character was found, with [NBSP] or [ZWSP] inserted to make it visible in the output. The &quot;Col&quot; number indicates the character&#39;s position on that line.</li></ul><h3>Open Source</h3><p>This script is open-source, lightweight, and distributed under the MIT license. You are welcome to fork the repository, contribute improvements, or integrate it into your existing data pipelines. Here is my GitHub link:</p><blockquote><em>GitHub link: </em><a href="https://github.com/clemensjarnach/highlight_and_clean_unicode">https://github.com/clemensjarnach/highlight_and_clean_unicode</a></blockquote><pre>Let&#39;s Connect:<br><br><a href="https://clemensjarnach.github.io/">Cemens Jarnach</a> | <a href="https://github.com/clemensjarnach">GitHub</a> | <a href="https://bsky.app/profile/clemensjarnach.bsky.social">BlueSky</a> | <a href="https://twitter.com/ClemensJarnach">Twitter</a> | <a href="https://www.linkedin.com/in/clemensjarnach/">LinkedIn</a></pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4dd7acf7deca" width="1" height="1" alt=""><hr><p><a href="https://levelup.gitconnected.com/find-invisible-unicode-characters-aka-ai-watermarks-4dd7acf7deca">Find Invisible Unicode Characters aka “AI Watermarks”</a> was originally published in <a href="https://levelup.gitconnected.com/">Level Up Coding</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Slow and Steady: Welfare and the Tortoise’s Thoughtful Decision-Making in Turbulent Times]]></title>
            <link>https://medium.com/@clemensjarnach/slow-and-steady-welfare-and-the-tortoises-thoughtful-decision-making-in-turbulent-times-2253be122118?source=rss-83addca999c7------2</link>
            <guid isPermaLink="false">https://medium.com/p/2253be122118</guid>
            <category><![CDATA[welfare]]></category>
            <category><![CDATA[elections]]></category>
            <category><![CDATA[politics]]></category>
            <category><![CDATA[decision-making]]></category>
            <dc:creator><![CDATA[Dr Clemens Jarnach ⚡️]]></dc:creator>
            <pubDate>Sun, 16 Feb 2025 18:34:54 GMT</pubDate>
            <atom:updated>2025-02-16T18:41:53.837Z</atom:updated>
            <content:encoded><![CDATA[<h4>In turbulent times, slow, deliberate decisions matter.</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*hbX96OuExoCognhO" /><figcaption>Photo by <a href="https://unsplash.com/@karlibri?utm_source=medium&amp;utm_medium=referral">Karl Ibri</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>A car drives into a union rally crowd in Munich on February 13th, one day before the Munich Security Conference, ten days before Germany’s federal election. This attack is yet another addition to a series of violent incidents that have shaken Germany. As world leaders, including Volodymyr Zelensky and U.S. Vice President JD Vance, gather for the Munich Security Conference — a leading forum for debating international security policy and addressing the world’s most pressing security concerns — the conference opens under the shadow of the latest attack, in which at least 30 people were severely injured.</p><p>In today’s political landscape, concerns about the rise of populist right-wing movements, nationalism, radicalism, and frequent acts of violence contribute to a growing sense of instability. Many individuals find themselves standing at a political crossroads, uncertain of which path to take or what kind of creation of new paths they are willing to support. In such times, it is essential to engage in critical reflection on one’s social and political beliefs, questioning what one personally believes in, stands for, and considers acceptable.</p><p>One particularly crucial topic for consideration is one’s attitude toward <strong>welfare and wealth redistribution</strong>. This article does not seek to impose a particular viewpoint but rather aims to encourage readers to engage in introspection regarding their stance on this one issue, one important issue of many.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TQfRzNNQGXvhNONHzYsAgA.png" /></figure><p>Imagine a <strong>tortoise carrying a box labelled “Redistribution”</strong> on its back. As the tortoise arrives at a crossroads, it must decide which pathway to take. Different roads represent different methods of redistribution. One possible route leads through government intervention, involving taxation, social security, and policies such as universal basic income. Another path follows religious institutions, where redistribution occurs through faith-based charity and welfare programs. A third option involves charitable organizations and philanthropic donations, while yet another relies on direct individual action, encompassing personal giving and community-led initiatives. The choice of pathway is influenced by a range of factors that shape an individual’s attitude toward welfare and redistribution, from personal experiences to broader societal influences.</p><p>The image of a tortoise stands for the slow, deliberate process of decision-making, particularly when it comes to complex issues like redistribution. The tortoise’s steady, careful pace contrasts with the potential for hasty or rash decisions, emphasising the importance of thoughtful reflection and consideration before making choices. Careful movement implies the long-term nature of these decisions, suggesting that choices around welfare and redistribution should be approached with patience and long-term thinking, rather than reacting impulsively.</p><p>Crucial questions on this topic remain <strong>worth everyone’s reflection</strong>:</p><ul><li>Why do some people, or why do I, prefer giving to charity over supporting government-led redistribution through taxation? Is there an inherent difference in moral perception between voluntary giving and state-enforced redistribution?</li><li>Why do many people feel more compelled to donate to local causes — such as their church, school, or community centre — rather than to large-scale organizations that may have a greater global impact, such as those fighting malaria or extreme poverty?</li><li>What psychological or ideological factors lead some individuals to support extensive welfare policies while others resist them? Is opposition to redistribution rooted in economic self-interest, cultural values, or trust (or lack thereof) in institutions?</li><li>How does trust in government, charities, or religious institutions influence one’s willingness to support redistribution? Does declining trust in government institutions erode support for welfare policies?</li><li>Is redistribution perceived as an issue of fairness or an encroachment on individual autonomy? How do different perspectives on meritocracy influence attitudes toward welfare?</li><li>Some argue that redistribution through taxation is coercive, while voluntary giving through charity preserves individual freedom. Others contend that taxation is a fair and necessary mechanism to ensure social justice. Where should the balance lie between personal choice and collective responsibility in redistributive policies?</li><li>How do stereotypes about welfare recipients shape public support for redistribution? Do narratives of “deserving” and “undeserving” poor influence political attitudes toward welfare programs?</li><li>Are my attitudes towards welfare based on rationality? Max Weber distinguishes between different types of social action, including instrumental-rational action (goal-oriented behaviour) and value-rational action (guided by ethical or moral beliefs). When people decide whether to support redistribution through taxation, charity, or other means, are they primarily acting out of rational self-interest, or are they guided by deeply held values and social norms?</li><li>Is support for redistribution primarily situational, or are there underlying cultural and political structures that sustain long-term differences in welfare attitudes?</li><li>Many religious traditions emphasize charity, yet religious individuals often have divergent views on government-led redistribution. Why might some religious groups advocate for private charity over state welfare programs?</li><li>Do people’s views on redistribution align with their broader social identity? Are attitudes toward welfare and redistribution shaped more by economic class, political ideology, or cultural belonging?</li></ul><h3>Individual-Level Factors</h3><p>A person’s background and life experiences significantly shape their stance on redistribution. Socioeconomic status, education, and upbringing all contribute to one’s perspective on welfare policies. Political ideology further influences attitudes, as views on government intervention and individual responsibility often differ between those with liberal and conservative orientations. Additionally, religious beliefs play a role, with some traditions emphasizing charity and social responsibility, while others prioritize self-reliance and individual initiative.</p><p>Beyond ideology and belief systems, trust in institutions also affects attitudes toward redistribution. Individuals who have confidence in the government, NGOs, or religious organizations are more likely to support welfare policies administered by these institutions, whereas skepticism toward these bodies may lead to a preference for alternative forms of assistance. Personal experiences, such as direct exposure to poverty or personal benefit from welfare programs, also shape perspectives on redistribution. These experiences influence one’s perception of fairness, particularly whether one believes in meritocracy or the necessity of social safety nets. Psychological factors, including empathy, moral duty, and a sense of justice, further contribute to how individuals assess the legitimacy of redistribution policies.</p><h3>Macro-Level Context</h3><p>In addition to individual factors, broader societal and historical influences also shape attitudes toward redistribution. Cultural norms play a fundamental role in determining whether a society leans toward collectivism or individualism, which in turn influences support for welfare systems. Historical experiences with past welfare policies and economic crises further affect trust in redistribution mechanisms. If a country has experienced successful welfare programs, its citizens may be more inclined to support similar initiatives in the future, whereas negative historical experiences may lead to scepticism</p><p>The perceived transparency and fairness of welfare systems also contribute to attitudes toward redistribution. When individuals believe that resources are distributed equitably and without corruption, they are more likely to support welfare policies. Economic conditions similarly play a role; during periods of economic downturn, public support for redistribution often increases, whereas prosperity may lead to greater resistance. Another crucial factor is proximity to those in need. Living in urban areas or having direct exposure to poverty often increases awareness of social inequalities, whereas those with limited contact with disadvantaged populations may underestimate the necessity of welfare programs. Public perception of the effectiveness of welfare policies also determines support. If welfare policies are seen as successfully reducing inequality and improving social mobility, they are more likely to be accepted.</p><p>The manner in which redistribution is implemented also influences public attitudes. Government programs remain one of the most widely recognized forms of redistribution, often carried out through taxation, social security, and direct welfare initiatives. However, religious and charitable institutions have historically played a significant role in providing aid, with many individuals preferring to contribute through faith-based or independent charities rather than relying on state intervention. In addition, direct individual action, such as personal donations, mutual aid networks, and community-led initiatives, represents another approach to redistribution that many people consider preferable.</p><h3>Final Remarks</h3><p>Attitudes toward welfare and redistribution are shaped by a complex interplay of personal, cultural, economic, and political factors. By critically reflecting on these influences, one can develop a deeper understanding of one’s own beliefs and contribute to more informed discussions on social justice and economic fairness. Just as the tortoise at the crossroads must decide which path to take, society as a whole faces a similar choice regarding redistribution. The fundamental question remains: which road do we choose, and what principles guide that decision?</p><p>In light of recent turbulent events, personal reflection and active engagement with party programs and campaign materials are essential for making informed decisions in (upcoming) elections. As Germany grapples with the implications of this latest attack, voters must remain vigilant, critically assess political narratives, and avoid reactionary choices that could further destabilize an already tense political landscape.</p><pre>Let&#39;s Connect:<br><br><a href="https://clemensjarnach.github.io/">Cemens Jarnach</a> | <a href="https://www.linkedin.com/in/clemensjarnach/">LinkedIn</a> | <a href="https://bsky.app/profile/clemensjarnach.bsky.social">Bluesky</a></pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2253be122118" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Did TV make you go to the ballot?]]></title>
            <link>https://medium.com/@clemensjarnach/did-tv-make-you-go-to-the-ballot-2949b8fe56bb?source=rss-83addca999c7------2</link>
            <guid isPermaLink="false">https://medium.com/p/2949b8fe56bb</guid>
            <category><![CDATA[elections]]></category>
            <category><![CDATA[brexit]]></category>
            <category><![CDATA[voter-turnout]]></category>
            <dc:creator><![CDATA[Dr Clemens Jarnach ⚡️]]></dc:creator>
            <pubDate>Thu, 18 Jul 2024 14:29:32 GMT</pubDate>
            <atom:updated>2024-07-18T14:29:32.013Z</atom:updated>
            <content:encoded><![CDATA[<h4>Exploring Television’s Impact on Voter Turnout in the 2016 EU Referendum</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*C5ZZ5WSsIliQnaf2" /><figcaption>Photo by <a href="https://unsplash.com/@stevehb?utm_source=medium&amp;utm_medium=referral">Steve Houghton-Burnett</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>While working on my PhD thesis, I found myself intrigued this morning by whether individuals who consumed specific news sources were more inclined to turnout and vote in the 2016 EU Referendum. Therefore, I conducted a brief analysis comparing the impact of television, internet (excluding online newspapers), newspapers, and radio news consumption on the likelihood of individuals who initially expressed low likelihood of voting in the EU Referendum actually casting their vote.</p><p>The question of whether information sources affect voter turnout is certainly not new. Cheng-Matsuno et al. (2023) conducted an experiment in the UK, demonstrating that text messages sent by a local authority successfully increased voter registration and contributed to a notable increase in turnout. Gerber et al. (2009) found evidence that newspaper exposure can affect voting turnout rates. Gentzkow (2006) examined the introduction of television in the 1950s in the US, finding a significantly negative effect on voter turnout. However, as far as I know, no one has specifically examined the impact of media exposure on turnout in the EU referendum.</p><p>To investigate this, I categorized the aforementioned news sources into binary variables: 0 indicating non-use for following news about politics or current affairs during the campaign period, and 1 indicating use of the medium for following news during the referendum campaign.</p><p>For this analysis, I used survey data from the British Election Study (BES) Internet Panel conducted by YouGov. The data spans from Wave 7 (April 14, 2016, to May 4, 2016) through Wave 9 (June 24, 2016, to July 4, 2016), encompassing the period immediately before and after the EU Referendum held on June 23, 2016.</p><p>To estimate a causal relationship, I employed a quasi-experimental research design. I used pre-referendum survey data to ascertain voter turnout intentions, measured news media consumption during the campaign period, and then examined the actual turnout post-referendum. This chronological separation ensures clarity in establishing cause and effect. This approach allows for a robust analysis of whether and how different news media influenced voter turnout during a pivotal referendum, shedding light on the dynamics between media consumption and political participation.</p><p>To examine the influence of news consumption from various media sources on participants’ voting behaviour, I conducted logistic regressions to model turnout. Table 1 presents the findings from two logistic regression models: Model 1 predicts turnout in the referendum without considering pre-campaign intentions, while Model 2 assesses the likelihood of voting while controlling for initial turnout intentions. Both models include age and educational attainment as key control variables.¹</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/562/1*ZMMoNG1Cm0UR_w41eKE7fw.png" /></figure><p>The results from Model 2 indicate that among all four media types, only television consumption shows a statistically significant effect. Hence, the results suggest that using television news during the campaign period increased the likelihood of voting in the Brexit referendum, even among those who initially did not intend to vote, suggesting a mobilizing effect of television on turnout—an interesting conclusion that should be validated and further investigated by future research. However, it is important to note that although the coefficient for television is statistically significant, the effect size and the predicted marginal effects are relatively small.</p><p>Figure 1 displays the coefficients of Model 2 for all four news sources, accompanied by their respective 95% confidence intervals.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/400/1*uXKC392H3gbTmtNQQWQjhw.png" /><figcaption>Figure 1: Coefficients of Logistic Regression Model 2</figcaption></figure><p>All media types have positive estimates, however, none of the other news sources exhibit a statistically significant effect on turnout. The control variables, though not the focus of this analysis, demonstrate expected results: older age and higher levels of education increase the likelihood of voter turnout in the referendum.</p><p>Please note that this analysis is intended as a preliminary investigation to determine if there are larger implications worth exploring. Further research in this field would be necessary to draw conclusive answers. It’s also important to acknowledge the limitations of this study, particularly the relatively small percentage of BES survey respondents who indicated they were unlikely to vote in the referendum compared to those who stated they intended to vote. Therefore, employing a small events model may be an appropriate model for robustness and could be undertaken to validate the initial findings presented above.</p><h4>Conclusion</h4><p>This study uncovered insights into the relationship between news consumption and voter turnout during the 2016 EU Referendum. Specifically, television news consumption significantly increased voter participation, including among those initially disinclined to vote, indicating a mobilizing effect of television during electoral campaigns. In conclusion, while this analysis offers initial evidence of television’s role in mobilizing voter turnout, continued exploration is essential to fully understand the broader implications and mechanisms at play in electoral behaviour.</p><h3>Footnotes</h3><p>[1]: It’s important to note that future research should aim to validate these results using more comprehensive models with additional controls.</p><h3>References</h3><p>Cheng-Matsuno, V., Foos, F., John, P., &amp; Unan, A. (2023). Do text messages increase voter registration? Evidence from RCTs with a local authority and an advocacy organisation in the UK. _Electoral Studies_, _81_, 102572-. <a href="https://doi.org/10.1016/j.electstud.2022.102572">https://doi.org/10.1016/j.electstud.2022.102572</a></p><p>Gentzkow (2006) examined the introduction of television in the 1950s in the US to determine its impact on voter turnout, finding a significantly negative effect.</p><p>Gerber, A. S., Karlan, D., &amp; Bergan, D. (2009). Does the Media Matter? A Field Experiment Measuring the Effect of Newspapers on Voting Behavior and Political Opinions. _American Economic Journal. Applied Economics_, _1_(2), 35–52. <a href="https://doi.org/10.1257/app.1.2.35">https://doi.org/10.1257/app.1.2.35</a></p><pre>Let&#39;s Connect:<br><br><a href="https://clemensjarnach.github.io/">Cemens Jarnach</a> | <a href="https://twitter.com/ClemensJarnach">Twitter</a> | <a href="https://www.linkedin.com/in/clemensjarnach/">LinkedIn</a></pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2949b8fe56bb" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Mermaid Diagrams for Obsidian Note-Taking]]></title>
            <link>https://levelup.gitconnected.com/mermaid-diagrams-for-obsidian-note-taking-b022b570e01c?source=rss-83addca999c7------2</link>
            <guid isPermaLink="false">https://medium.com/p/b022b570e01c</guid>
            <category><![CDATA[mermaid]]></category>
            <category><![CDATA[obsidian]]></category>
            <category><![CDATA[markdown]]></category>
            <dc:creator><![CDATA[Dr Clemens Jarnach ⚡️]]></dc:creator>
            <pubDate>Wed, 24 Apr 2024 17:37:33 GMT</pubDate>
            <atom:updated>2024-04-24T17:37:33.831Z</atom:updated>
            <content:encoded><![CDATA[<h4>A Guide to Using Mermaid Syntax to Add Diagrams to Your Markdown Documents</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pBZ-dJ2jdv0RYKfMF938lQ.png" /></figure><p>If you’re anything like me, you love organizing your notes by creating lists, internal links, and footnotes. For this purpose, I love using Markdown and Obsidian. Perhaps you’re already familiar with Obsidian or another Markdown-based note-taking tool. One standout feature of Obsidian that I haven’t touched on yet is the ability to create diagrams, timelines, flowcharts, and more using Mermaid. As a researcher and data scientist, clear and concise note-taking, along with planning research designs and machine learning models, are crucial aspects of my work. Working with Obsidian and Mermaid has made it incredibly easy to plan my research in a structured and tidy manner. So let’s delve into it.</p><h3>What is Mermaid and Why Use It?</h3><p>Mermaid is a powerful tool for creating diagrams and visualizations using simple text and code. It is a JavaScript-based diagramming and charting tool with the ability to render Markdown-inspired text definitions into dynamic diagrams and charts.</p><p>Mermaid simplifies the process of creating complex diagrams by allowing users to describe them using a simple and intuitive syntax. This makes it ideal for generating various types of diagrams, including flowcharts, sequence diagrams, and Gantt charts, directly within Obsidian.</p><p>Mermaid diagrams offer a significant boost to the visual appeal of your content, making the planning of sequences, statistical or machine learning models much more intuitive and visually engaging.</p><p>Of course, Mermaid’s versatility extends beyond these applications. It can be effectively employed for any type of sequence diagram, allowing you to vividly depict relationships between elements. Additionally, Mermaid is ideal for creating DAC (Directed Acyclic Graph) diagrams and many other types of visual representations, providing a comprehensive toolkit for organizing and presenting complex information.</p><h3>Examples of Mermaid Flowchart in Obsidian</h3><p>Let’s explore some practical examples of how Mermaid can be utilized within Obsidian to enhance your note-taking and visualization capabilities:</p><p>Use Mermaid to create flowcharts illustrating the steps in a process or workflow. Whether it’s outlining the steps of a research methodology or visualizing the stages of a project, flowcharts provide a clear and structured representation of sequential tasks.</p><pre>```mermaid<br>flowchart TB<br>    start_sequence((Start)) --&gt; gather_ingredients{Gather Ingredients}<br>    gather_ingredients --&gt; bread[Do I have Bread?]<br>    bread --&gt;|No| get_bread{Get Bread}<br>    bread --&gt;|Yes| do_i_peanut_butter[Do I have Peanut Butter?]<br>    get_bread --&gt;   do_i_peanut_butter<br>    do_i_peanut_butter --&gt;|No| get_peanut_butter{Get Peanut Butter}<br>    do_i_peanut_butter --&gt;|Yes| assemble{Assemble Sandwich}<br>    get_peanut_butter --&gt; assemble{Assemble Sandwich}<br>    assemble --&gt; end_sequence((END))<br>```</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/975/1*0ygaHs0FDuZPusiFCqUxRw.png" /></figure><h3>Simple Guide to Mermaid Syntax</h3><p>Let’s start with the simple syntax. First things first, you will need a `mermaid` code block and within it, an initial command with the type of diagram you would like, such as a simple flowchart with some of the basic shapes available:</p><pre>```mermaid<br><br>flowchart <br> box_id[Text in a box] <br> squircle_id(Text in a squircle)<br> circle_id((Circle))<br> database_id[(Database)]<br> diamond_id{Diamond}<br><br>```</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/966/1*03lEcXtbFNPLD7bsV7SGxg.png" /></figure><p>You can see that different types of brackets or bracket combinations create different shapes.</p><p>Now let’s add arrows between them:</p><pre>```mermaid<br><br>flowchart LR<br> box_id[Text in a box] → squircle_id(Text in a squircle)<br><br>```</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/396/1*ABDv2W2BDLqGk4eRxDHRew.png" /></figure><p>Also, notice how you can change the orientation of your diagram with two letters after the flowchart command, with either LR for left to right or TB for top to bottom.</p><pre>```mermaid<br><br>flowchart TB<br> box_id[Text in a box] --&gt; squircle_id(Text in a squircle)<br><br>```</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/200/1*4X7uC7qr_hJEAHjTyciVKA.png" /></figure><p>You can change the tie from a nondirectional tie --- to a unidirectional tie --&gt; or a reciprocal tie &lt;--&gt;</p><pre>```mermaid<br><br>flowchart LR<br> A --- B<br> C --&gt; D<br> F &lt;--&gt; E<br><br>```</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/200/1*7KVK3H1vbDO1E2e0lp47sw.png" /></figure><p>If you have two nodes tied to another node, you can simplify the code with an `&amp;`. See in the two code blocks below how two different syntaxes result in the same visualization.</p><pre>```mermaid<br><br>flowchart LR<br> A --&gt; C<br> B --&gt; C<br>```<br><br>```mermaid<br><br>flowchart LR<br> A &amp; B --&gt; C<br><br>```</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/174/1*OrMhz4vm15CjM89Lrg_bpQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/174/1*OrMhz4vm15CjM89Lrg_bpQ.png" /></figure><h3>To Sum Up</h3><p>Mermaid stands as a valuable asset for Obsidian users, enabling the rapid and intuitive creation of flowcharts and various diagrams. Its seamless integration makes it an indispensable tool for visual clarity and organization in note-taking and knowledge management workflows.</p><p>There are, of course, many more variations and applications, but this is a simple introduction to get people interested in using Mermaid for their Obsidian note-taking. For much more detailed documentation and a full overview of what is possible with Mermaid, please refer to the official Mermaid website (<a href="https://mermaid.js.org/">https://mermaid.js.org/</a>).</p><h3>Before you leave</h3><ul><li>📰 Subscribe for more posts like this: <a href="https://medium.com/@clemensjarnach/subscribe">Clemens Jarnach ⚡️</a></li><li>👉👈 Please follow me: <a href="https://t.co/D0Ndbkjld9">Medium</a> | <a href="https://twitter.com/ClemensJarnach">Twitter</a> | <a href="https://www.linkedin.com/in/clemensjarnach/">LinkedIn</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b022b570e01c" width="1" height="1" alt=""><hr><p><a href="https://levelup.gitconnected.com/mermaid-diagrams-for-obsidian-note-taking-b022b570e01c">Mermaid Diagrams for Obsidian Note-Taking</a> was originally published in <a href="https://levelup.gitconnected.com/">Level Up Coding</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Rounding Numbers: Are you doing it wrong?]]></title>
            <link>https://levelup.gitconnected.com/rounding-numbers-are-you-doing-it-wrong-29bae9f6b610?source=rss-83addca999c7------2</link>
            <guid isPermaLink="false">https://medium.com/p/29bae9f6b610</guid>
            <category><![CDATA[python]]></category>
            <category><![CDATA[computing]]></category>
            <category><![CDATA[computer-science]]></category>
            <dc:creator><![CDATA[Dr Clemens Jarnach ⚡️]]></dc:creator>
            <pubDate>Wed, 07 Jun 2023 09:08:31 GMT</pubDate>
            <atom:updated>2023-06-11T22:59:38.079Z</atom:updated>
            <content:encoded><![CDATA[<h4>Navigating Rounding Bias in Computer Science: Choosing the Optimal Rounding Method for Your Needs</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*mh_nDoLEj5vESZkz" /><figcaption>Photo by <a href="https://unsplash.com/@loomydoons?utm_source=medium&amp;utm_medium=referral">Myles Bloomfield</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>Rounding numbers is a common practice that helps us simplify and make sense of numerical values. However, have you ever considered the potential bias introduced by traditional rounding methods? In this blog post, we will explore the concept of rounding bias and delve into Python 3’s approach, known as “round half to even” or “banker’s rounding,” which seeks to address this bias.</p><p>Rounding numbers is not as straightforward as it may seem. The traditional approach most of us are familiar with involves rounding up, where any fractional part greater than or equal to 0.5 is rounded up to the next whole number. While this method may seem intuitive, it introduces a bias towards higher values, potentially leading to inaccuracies and skewed results in certain scenarios.</p><p>Consider a situation where you are tasked with calculating the average income of a group of individuals. If you always round up when dealing with decimal values, you may inadvertently inflate the average income, giving a distorted representation of the actual data. Rounding bias can have far-reaching consequences in various applications, from financial forecasting to scientific research.</p><h3>Rounding numbers in computing</h3><p>Another important application of rounding numbers arises from the fact that computers cannot precisely represent all real numbers. Think about it — we consider computers to be incredibly powerful and more capable of difficult calculations than humans, yet we often forget their limitations, and most computers use a finite representation system called floating-point arithmetic, which can only approximate real numbers within a limited range and precision. Humans have the ability to comprehend and reason about real numbers in a more abstract and intuitive manner compared to computers. We can perform mental calculations, estimate values, and compare real numbers based on our innate sense of quantity.<br>Floating-point arithmetic is a numerical method used to represent real numbers with an approximation, using an integer called the significand, which has a fixed precision. This format allows a wide range of numbers to be displayed, but has limitations in terms of precision.</p><p>Here is an example: let’s consider the number π (pi), which is an irrational number, which means it has an infinite number of decimal places and cannot be expressed as a finite fraction or a terminating decimal. Thus the number π (pi) cannot be represented exactly on a computer with finite precision. Computers use a finite number of bits to store and manipulate numbers, which means that they can only represent an approximation of π. When representing π in a computer, rounding or truncation is necessary to limit the number of decimal places or bits used to store the approximation. This introduces some degree of error, as the true value of π cannot be fully captured. The number of decimal places or bits used to represent π determines the level of accuracy in the approximation.</p><p>Ok, let’s illustrate: the binary single-precision (32-bit) floating-point representation where p = 24, indicating that the significand consists of a sequence of 24 bits; you can think of p = 24 as saying: I want the number with a `precision` of 24 bits. E.g. look at the first 33 bits of the number π: 11001001000011111101101010100010001</p><p>You can get this output in Python by converting the decimal representation of π into a binary string:</p><pre>import math<br><br>pi = math.pi<br>print(pi) <br>&gt; 3.141592653589793<br><br>binary_pi = format(int(pi * (2**33)), &#39;033b&#39;)<br>print(binary_pi)<br>&gt; 11001001000011111101101010100010001<br></pre><p>You multiply π by 2 raised to the power of 33 to scale it up and convert it to an integer. Then, using the format() function, we convert the integer into a binary string with a width of 33 bits, indicated by the 033b format specifier.</p><p>Let’s summarise everything so far. Due to the finite number of bits available, there are some real numbers that cannot be accurately represented in binary floating-point format. For example, numbers that have infinitely repeating decimal expansions, such as 1/3 (0.3333…), cannot be represented exactly. The computer can only store an approximation of these numbers. As a result, computations involving real numbers can sometimes suffer from round-off errors and precision limitations. It’s important to be aware of these limitations when performing numerical calculations and consider appropriate techniques, such as using higher precision libraries or implementing error analysis and mitigation strategies, when necessary.</p><p>In the following sections, we will explore an alternative approach to the most common rounding method.</p><h3>Round Half to Even (Banker’s Rounding)</h3><p>“Round to Even”, also called “Banker’s Rounding” method is an approach that aims to mitigate the bias introduced by always rounding up, providing a fairer and more accurate representation of the data. And this is also the method Python 3’s round() function uses. So let’s see the rationale behind this method, its advantages, and how it handles cases where the number to be rounded falls exactly between two integers.</p><p>Python 3 introduces an innovative approach to rounding called “round half to even” or “banker’s rounding.” This method aims to address the bias introduced by always rounding up and provides a more balanced and statistically sound approach to rounding numbers.</p><p>The rationale behind “round half to even” is to minimize the overall rounding error and maintain fairness in rounding. Unlike always rounding up, this method considers the digits following the rounding position and rounds to the nearest even number when the fractional part is exactly 0.5. This approach ensures that half of the numbers are rounded up, while the other half is rounded down, resulting in a more balanced distribution. This choice helps maintain statistical fairness and minimizes the bias introduced by always rounding up.</p><p>To better understand Python 3’s rounding behaviour, let’s consider some code examples. In traditional rounding, the number 3.5 would be rounded up to 4, as it exceeds the threshold of 0.5. However, in Python 3’s “round half to even” method, the number 3.5 is rounded down to 3 since both 3 and 4 are equidistant from it, and the rule favours rounding to the nearest even number.</p><p>Here’s an example demonstrating Python 3’s rounding method:</p><pre># Rounding using Python 3&#39;s &quot;round half to even&quot; method<br>num1 = 3.5<br>num2 = 4.5<br><br>rounded1 = round(num1)<br>rounded2 = round(num2)<br><br>print(rounded1)  # Output: 4<br>print(rounded2)  # Output: 4<br><br>&gt; 4<br>&gt; 4</pre><p>In this example, both 3.5 and 4.5 are rounded down to 4 according to Python 3’s rounding rules. This behaviour ensures a balanced distribution of rounding results, reducing bias and maintaining statistical accuracy.</p><p>Now, let’s compare this with the traditional rounding method:</p><pre># Traditional rounding<br>import math<br><br>num1 = 3.5<br>num2 = 4.5<br><br>rounded1 = math.ceil(num1)<br>rounded2 = math.ceil(num2)<br><br>print(rounded1)  # Output: 4<br>print(rounded2)  # Output: 5<br><br>&gt;4<br>&gt;5</pre><p>In the traditional rounding approach, the number 3.5 is rounded up to 4, while 4.5 is rounded up to 5. This highlights the bias introduced by always rounding up and the difference in behaviour compared to Python 3’s “round half to even” method.</p><p>By adopting Python 3’s rounding approach, we can mitigate bias, maintain statistical fairness, and achieve more accurate results in rounding calculations.</p><p>Banker’s rounding plays a crucial role in statistical calculations and data aggregation. When dealing with large datasets, rounding bias can have a significant impact on the summary statistics and overall analysis. By employing banker’s rounding, we can ensure fairness in aggregating data and avoid skewed results. For instance, when calculating the mean or average of a dataset, banker’s rounding minimizes the distortion caused by rounding bias, resulting in a more representative and reliable estimate. However, it is important to note that banker’s rounding may not be suitable for every situation. In certain contexts, alternative rounding methods may be more appropriate. For example, when dealing with financial transactions or pricing, rounding methods that always round up may align better with industry standards or legal requirements. Similarly, specific analytical techniques or mathematical models may necessitate the use of alternative rounding methods tailored to their unique requirements.</p><h3>The “Round Randomly” Method</h3><p>In addition to banker’s rounding, another alternative rounding method worth considering is the “round randomly” approach. As the name suggests, this method involves rounding numbers randomly when they fall exactly between two integers. Let’s explore the pros and cons of this approach and see how it can be implemented in Python.</p><h4>Pros</h4><ol><li>Balanced Distribution: Similar to banker’s rounding, the “round randomly” method achieves a balanced distribution of rounded values. It avoids the systematic bias introduced by always rounding up and provides a fair representation of the data.</li><li>Statistical Neutrality: By rounding numbers randomly, this method does not favour rounding up or down, ensuring statistical neutrality in calculations and data analysis.</li><li>Minimized Impact of Bias: Rounding numbers randomly can help mitigate the potential impact of rounding bias and its consequences on various calculations.</li></ol><h4>Cons</h4><ol><li>Lack of Determinism: The random nature of this method means that the rounding results will vary each time the calculation is performed. This lack of determinism can make it challenging to replicate and verify results consistently.</li><li>Unpredictability: Rounding numbers randomly can introduce unpredictability into calculations, making it harder to anticipate and understand the rounding outcomes.</li><li>Potential Loss of Precision: In some cases, rounding numbers randomly may lead to a loss of precision compared to other rounding methods. This can affect the accuracy of calculations, particularly when high precision is required.</li></ol><p>In Python, we can implement the “round randomly” method by utilizing the random module. The random.uniform(a,b) function generates a random floating-point number between a and b. We can round our original number by adding a random offset within the range [-0.5, 0.5] to introduce randomness.</p><p>Here’s an example of implementing the “round randomly” method in Python:</p><pre>import random<br><br>def round_randomly(number):<br>    return round(number + random.uniform(-0.5, 0.5))<br><br># Example usage<br>num = 3.5<br>rounded = round_randomly(num)<br><br>print(rounded)  # Output: Either 3 or 4 (randomly rounded)</pre><p>Each time the function is called, it will generate a random offset within the range [-0.5, 0.5] and add it to the number, resulting in a rounded value that can be either 3 or 4.</p><p>By understanding the pros and cons of both “banker’s rounding” and the “round randomly” method, we can choose the most appropriate rounding approach for our specific needs, considering factors such as fairness, accuracy, and the nature of the data being rounded.</p><h3>List of Python functions for rounding numbers</h3><ol><li>round(x,ndigits=0): Rounds the value of x to the specified number of decimal places (ndigits). If ndigits is not provided, it defaults to 0, which rounds to the nearest integer. round(x,ndigits=0)</li><li>math.ceil(x): Rounds the value of x up to the nearest integer greater than or equal to x.</li><li>math.floor(x): Rounds the value of x down to the nearest integer less than or equal to x.</li><li>math.trunc(x): Truncates (cuts off) the decimal places from the value of x, returning the integer part without rounding.</li></ol><h3>Conclusion</h3><p>Rounding numbers is a common practice that simplifies numerical values, but traditional rounding methods can introduce bias towards higher values. Moreover, rounding numbers is a common task in many programming applications, and understanding the rounding methods available in Python can lead to more accurate and fair calculations. Python 3’s “round half to even” method, also known as banker’s rounding, offers a balanced distribution by rounding half the numbers up and half down. This approach minimizes bias and maintains statistical accuracy, especially when numbers fall exactly between two integers. By contrast, traditional rounding methods always round up, which can introduce a bias toward higher values. Banker’s rounding is particularly valuable in scenarios where precision and fairness are important, such as financial calculations, scientific experiments, or surveys. However, it’s essential to consider alternative rounding methods based on specific needs and contexts. The “round randomly” method offers a balanced distribution and statistical neutrality by rounding numbers randomly when they fall between two integers. While it mitigates bias, it introduces unpredictability and lacks determinism. The choice of rounding method should consider factors such as fairness, accuracy, the nature of the data being rounded, and industry standards or legal requirements.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=29bae9f6b610" width="1" height="1" alt=""><hr><p><a href="https://levelup.gitconnected.com/rounding-numbers-are-you-doing-it-wrong-29bae9f6b610">Rounding Numbers: Are you doing it wrong?</a> was originally published in <a href="https://levelup.gitconnected.com/">Level Up Coding</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Google I/O 2023 – Five Key Takeaways]]></title>
            <link>https://medium.com/@clemensjarnach/google-i-o-2023-five-key-takeaways-375e7be54dde?source=rss-83addca999c7------2</link>
            <guid isPermaLink="false">https://medium.com/p/375e7be54dde</guid>
            <category><![CDATA[technology-news]]></category>
            <category><![CDATA[google]]></category>
            <category><![CDATA[ethics]]></category>
            <category><![CDATA[tech]]></category>
            <category><![CDATA[artificial-intelligence]]></category>
            <dc:creator><![CDATA[Dr Clemens Jarnach ⚡️]]></dc:creator>
            <pubDate>Fri, 12 May 2023 15:21:05 GMT</pubDate>
            <atom:updated>2023-05-12T15:21:05.600Z</atom:updated>
            <content:encoded><![CDATA[<h4>An Executive Summary of the Google I/O Presentation with Expert Commentary</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0E6AJ3FE0MB6EfXRKJdaVQ.png" /></figure><p>Google I/O, the annual developer conference held yesterday (May 10, 2023), was a platform where Google showcased its latest developer solutions, products, and groundbreaking technology. The CEO of Google, Sundar Pichai, took the stage to address the company’s approach to AI development and its commitment to responsibility. In a carefully choreographed presentation, the CEO discussed Google’s efforts to build AI tools that can identify AI-generated content and showcased a live demo featuring generative AI. In this blog post, I will provide you with an executive summary of the key highlights from the event, offering you a comprehensive overview of the significant points shared during the Google I/O presentation.</p><h4>1. Bard is now open to everyone!</h4><p>Google has made an exciting announcement that its AI-powered chatbot, Bard, is now open to all users without the need for a waitlist. This development opens up opportunities for a broader audience to engage with Bard’s advanced conversational capabilities. Furthermore, Google is enhancing the chatbot’s functionality by introducing new features. Users can now enjoy Bard’s support for Japanese and Korean languages, expanding its reach and potential impact. Additionally, Google has streamlined the process of exporting the generated text to popular platforms like Google Docs and Gmail, making it more convenient for users to utilize the content generated by Bard. These updates reflect Google’s commitment to continuously improving and expanding the capabilities of its AI chatbot, empowering users with enhanced conversational experiences and increased productivity.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*I35hSnkk-emgRke3" /><figcaption>Photo by <a href="https://unsplash.com/it/@2hmedia?utm_source=medium&amp;utm_medium=referral">2H Media</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><h4>2. Responsibility Takes Centre Stage</h4><p>Throughout the presentation, the CEO highlighted the importance of responsibility in AI development. Pichai acknowledged the need for caution in adopting AI and mentioned the company’s ongoing efforts to create tools such as watermarking and other techniques to identify AI-generated content. By focusing on responsible practices, Google aims to address the concerns surrounding the potential misuse of AI.</p><h4>3. Carefully Choreographed Presentation of Generative AI</h4><p>While some critics argue that Google’s AI events are often meticulously scripted, the recent presentation did include one live demonstration. The demonstration showcased Google Workspace, utilising generative AI to write a children’s short story. By allowing the AI model to read the text and generate a story, Google presented a safe and controlled live demo, emphasising the potential benefits of AI in creative tasks. Yet, this might not have been the most exciting or most difficult of tasks for a strong generative AI model.</p><h4>4. Google’s Position on the Platform Shift</h4><p>As the presentation progressed, the question arose of how Google might lead in the massive platform shift towards generative AI without jeopardising its core products. This is a significant challenge for the company. While it remains unclear who has the most reliable technology in terms of information quality, Google is cautious in its approach to AI. This approach, while perhaps less exciting for investors looking for immediate results, positions Google as a potential leader in AI because of its careful and thoughtful methodology. Of course, we don’t know what’s going on behind the scenes and have to rely on their carefully crafted public statements. Is this just a clever way of explaining why Google is lagging behind its competitors?</p><h4>5. The Role of Large Language Models</h4><p>During the discussion, the CEO mentioned the use of large language models like ChatGPT and Bard. While both models have their merits, Pichai acknowledged that caution is necessary when relying on these systems. While they may sound accurate and provide seemingly correct answers, it is crucial to consider the sourcing and evaluate the information critically.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*TVn9BsAS1hWk70xG" /><figcaption>Photo by <a href="https://unsplash.com/@minimalsayan?utm_source=medium&amp;utm_medium=referral">Sayan Majhi</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><h4>Conclusion</h4><p>Google’s CEO has given a speech emphasising responsibility in AI development, outlining the company’s commitment to developing AI tools and technologies thoughtfully and carefully. While their approach may not be as flashy as that of their competitors, Google’s commitment to responsible practices positions them as a potential leader in the rapidly evolving world of generative AI. However, it’s important to remember that Google, like any for-profit company, strives to appear superior and forward-thinking to investors and stakeholders. It is therefore prudent to take statements from presentations such as this with a pinch of salt and maintain a critical perspective on the company’s motives and actions. As technology continues to advance, it is vital that ethical considerations remain at the forefront, and any claims made by tech giants like Google should be scrutinised. I would prefer to see some hard, transparent evidence to back up Google’s bold claims.</p><h3>Before you leave</h3><ul><li>📰 Subscribe for more posts like this: <a href="https://medium.com/@clemensjarnach/subscribe">Clemens Jarnach ⚡️</a></li><li>👉👈 Please follow me: <a href="https://t.co/D0Ndbkjld9">Medium</a> | <a href="https://twitter.com/ClemensJarnach">Twitter</a> | <a href="https://www.linkedin.com/in/clemensjarnach/">LinkedIn</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=375e7be54dde" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Add Colour to Your Markdown Text]]></title>
            <link>https://levelup.gitconnected.com/add-colour-to-your-markdown-text-9fc9f0628f48?source=rss-83addca999c7------2</link>
            <guid isPermaLink="false">https://medium.com/p/9fc9f0628f48</guid>
            <category><![CDATA[markdown]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[productivity]]></category>
            <dc:creator><![CDATA[Dr Clemens Jarnach ⚡️]]></dc:creator>
            <pubDate>Tue, 02 May 2023 17:09:58 GMT</pubDate>
            <atom:updated>2023-05-03T09:32:55.203Z</atom:updated>
            <content:encoded><![CDATA[<h4>A Guide to Using HTML and LaTeX Syntax to Add Coloured Text to Your Markdown Documents</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*4u5tZ_q4DePEa7G9" /><figcaption>Photo by <a href="https://unsplash.com/@rumpf?utm_source=medium&amp;utm_medium=referral">Christina Rumpf</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>If you’re a fan of Markdown syntax, you may have noticed that it doesn’t offer a built-in way to change the colour of your text. However, fear not! There are a few workarounds you can use to add some 🌈-colour to your text.</p><p>One pretty universal option is to use HTML syntax. You can wrap your text in a &lt;span&gt; tag and then set the colour with CSS. For example, if you want your text to be red, you can use the following code:</p><pre>&lt;span style=&quot;color:red;&quot;&gt;your text here&lt;/span&gt;</pre><h4>R Markdown</h4><p>If you use R Markdown, another option is to use LaTeX syntax. You can use the \textcolor{}{} command to change the colour of your text. Note that this method requires the LaTeX `xcolor` package, which is included in Pandoc’s default LaTeX template. Here’s an example of how to use this syntax in your markdown file:</p><pre>---<br>output: pdf_document<br>---<br>Roses are \textcolor{red}{red}, violets are \textcolor{blue}{blue}.</pre><p>In this example, the first set of curly braces contains the desired text colour, and the second set of curly braces contains the text to which this colour should be applied.</p><p>It’s worth noting that if you want to use these methods in an R Markdown document that will be exported to multiple output formats, you should avoid embedding raw HTML or LaTeX code in your document. This is because these elements will be ignored in output formats that don’t support them. Instead, you can use a couple of different methods to handle this issue.</p><p>One approach is to create custom CSS or LaTeX files for each output format. You can then reference these files in your R Markdown document using the appropriate YAML header. For example, if you want to use a custom CSS file for HTML output, you can include the following YAML header:</p><pre>---<br>title: &quot;My Document&quot;<br>output:<br> html_document:<br> css: custom.css<br>---</pre><p>Another approach is to use conditional code blocks to include HTML or LaTeX code only in specific output formats. For example, you can use the following code to include HTML code only in HTML output:</p><pre>&lt;! - html_preserve →<br>&lt;span style=&quot;color: red;&quot;&gt;your text here&lt;/span&gt;<br>&lt;! - /html_preserve →</pre><p>Similarly, you can use the following code to include LaTeX code only in PDF output:</p><pre>```{=latex}<br>\textcolor{red}{your text here}<br>``` <br></pre><p>With these methods, you can add some colour to your Markdown documents without worrying about compatibility issues across different output formats.</p><h4>Obsidian</h4><p>If you’re an Obsidian user, you may be wondering how to add coloured text to your notes. Fortunately, the solution is the same as for Markdown in general. You can use HTML syntax to wrap your text in a&lt;span&gt;tag and set the colour with CSS. For example, if you want to make your text red, you can use the following code:</p><pre>&lt;span style=&quot;color:red;&quot;&gt;your text here in red&lt;/span&gt;, <br>&lt;span style=&quot;color:#520099;&quot;&gt;or make it blue&lt;/span&gt;</pre><p>Simply add this code to your Obsidian note and you’ll have coloured text in no time. It’s a simple and effective way to add some visual interest to your notes and make certain information stand out.</p><h4>Hex colour code</h4><p>It’s worth noting that in addition to using colour names like “red” or “blue,” you can also use hex codes to specify colours in HTML and Obsidian. This gives you even more options for customising the colour of your text.</p><pre>&lt;span style=&quot;color: #FF69B4;&quot;&gt;Why did the tomato turn red?&lt;/span&gt;<br>&lt;span style=&quot;color: #00FFFF;&quot;&gt;Because it saw the salad dressing!&lt;/span&gt;</pre><p>In this example, we’ve used the hex codes #FF69B4 for pink and #00FFFF for turquoise to make the joke stand out. Of course, you can use any hex code you like.</p><h3>Summary</h3><p>In summary, Markdown syntax doesn’t provide a built-in way to change the colour of your text. However, you can use HTML or LaTeX syntax to achieve this. HTML syntax involves wrapping the text in a &lt;span&gt; tag and setting the colour with CSS, while LaTeX syntax requires the use of the \textcolor{}{} command.</p><p>With these tips, you can add some colourful flair to your Markdown documents and ensure they look great across all output formats.</p><h3>Before you leave</h3><ul><li>📰 Subscribe for more posts like this: <a href="https://medium.com/@clemensjarnach/subscribe">Clemens Jarnach ⚡️</a></li><li>👉👈 Please follow me: <a href="https://t.co/D0Ndbkjld9">Medium</a> | <a href="https://twitter.com/ClemensJarnach">Twitter</a> | <a href="https://www.linkedin.com/in/clemensjarnach/">LinkedIn</a></li></ul><h3>Level Up Coding</h3><p>Thanks for being a part of our community! Before you go:</p><ul><li>👏 Clap for the story and follow the author 👉</li><li>📰 View more content in the <a href="https://levelup.gitconnected.com/?utm_source=pub&amp;utm_medium=post">Level Up Coding publication</a></li><li>💰 Free coding interview course ⇒ <a href="https://skilled.dev/?utm_source=luc&amp;utm_medium=article">View Course</a></li><li>🔔 Follow us: <a href="https://twitter.com/gitconnected">Twitter</a> | <a href="https://www.linkedin.com/company/gitconnected">LinkedIn</a> | <a href="https://newsletter.levelup.dev/">Newsletter</a></li></ul><p>🚀👉 <a href="https://jobs.levelup.dev/talent/welcome?referral=true"><strong>Join the Level Up talent collective and find an amazing job</strong></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9fc9f0628f48" width="1" height="1" alt=""><hr><p><a href="https://levelup.gitconnected.com/add-colour-to-your-markdown-text-9fc9f0628f48">Add Colour to Your Markdown Text</a> was originally published in <a href="https://levelup.gitconnected.com/">Level Up Coding</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The Rise of Artificial Intelligence in Chess]]></title>
            <link>https://pub.towardsai.net/the-rise-of-artificial-intelligence-in-chess-9a7f59c453bf?source=rss-83addca999c7------2</link>
            <guid isPermaLink="false">https://medium.com/p/9a7f59c453bf</guid>
            <category><![CDATA[chess]]></category>
            <category><![CDATA[artificial-intelligence]]></category>
            <category><![CDATA[technology]]></category>
            <dc:creator><![CDATA[Dr Clemens Jarnach ⚡️]]></dc:creator>
            <pubDate>Fri, 21 Apr 2023 22:02:13 GMT</pubDate>
            <atom:updated>2023-04-24T08:21:54.957Z</atom:updated>
            <content:encoded><![CDATA[<h4>And The Epic Battle of Kasparov vs. Deep Blue</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*jln3sc2ZaPQtvhfO" /><figcaption>Photo by <a href="https://unsplash.com/@warrenumoh?utm_source=medium&amp;utm_medium=referral">Warren Umoh</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>Chess has been one of the world’s most popular board games for centuries, and for centuries humans have reigned supreme as the most formidable chess players on the planet. In the 1980s, the idea of a computer beating the best human players was laughable. But in 1997, the impossible happened — a computer beat the world champion.</p><p>One of the fascinating developments in the history of chess has been the rise of computer chess engines, which use artificial intelligence algorithms to analyze positions and make moves. With all the buzz surrounding modern AI applications such as ChatGPT, it’s easy to forget the rich history of chess engines and their impact on the game and the development of artificial intelligence more generally. In this article, I’ll take a closer look at the evolution of chess engines, from the earliest mechanical devices to the cutting-edge software programs of today.</p><p>The birth of modern artificial intelligence (AI) models for computers began in the 1950s. The term “artificial intelligence” was first coined in 1956 at the Dartmouth Conference, where a group of scientists came together to discuss the possibility of creating machines that could simulate human intelligence. This led to the development of some of the earliest AI models and some of the first applications were chess engines.</p><p>A chess engine is a computer program that uses artificial intelligence (AI) algorithms to play chess. These programs are designed to analyze chess positions, calculate possible moves and their consequences, and choose the best move based on a set of evaluation criteria.</p><p>The game of chess has always been regarded as the ultimate test of strategic thinking and decision-making. It requires a keen understanding of the nuances of the game and the ability to think several moves ahead. For centuries, humans were the undisputed masters of the game. But as technology progressed and computers became more advanced, the possibility of a machine beating the best human players became a topic of discussion. As well as being an interesting battle between man and machine, or a great marketing stunt for IBM, chess provided the perfect playground for artificial intelligence engineers to test and develop their models.</p><blockquote>As with pretty much everything in modern computing, Alan Turing and Claude Shannon laid the foundations for chess engines.</blockquote><p>Alan Turing and Claude Shannon are two prominent figures in the history of computing and information theory. Alan Turing was a British mathematician and computer scientist who was instrumental in breaking the German Enigma code during the Second World War. He is also known for his work on the concept of a universal machine, which laid the foundations for modern computing. Claude Shannon was an American mathematician and electrical engineer who is considered the father of modern digital circuit design theory and information theory.</p><p>Shannon (1950) published a paper describing a program that could potentially play chess against a human. A year later, Turing created the first computer chess algorithm, but the hardware available at the time was not powerful enough to run it effectively. Soon after, Dietrich Prinz, a colleague of Turing’s, succeeded in creating a basic chess algorithm that was implemented on the Ferranti Mark 1, the first commercially available computer. Although the computer did not have the power to play a full game of chess, it served as a proof of concept for chess computing.</p><p>From these more theoretically motivated developments, the beginning of computer chess engines really blossomed in practical application in the late 50s and 60s, with dramatic software and hardware innovations enabling more powerful machines.</p><p>But in 1997, the impossible happened. IBM’s Deep Blue chess computer defeated world champion Garry Kasparov in a six-game match. Deep Blue was a supercomputer developed by IBM that was specifically designed to play chess at a high level, with a sophisticated algorithm and powerful processing system. Deep Blue was the culmination of years of research and development, and its victory over Kasparov was a major milestone in the field of artificial intelligence.</p><p>Garry Kasparov is a Russian chess grandmaster and former World Chess Champion. He became the youngest-ever undisputed World Chess Champion at the age of 22 and held the title for over a decade. Kasparov is widely regarded as one of the greatest chess players of all time, and his matches against computers such as Deep Blue have become legendary in the history of the game.</p><p>The 1997 showdown between Garry Kasparov, the reigning world chess champion, and Deep Blue, a supercomputer developed by IBM, was a momentous occasion in the history of artificial intelligence. The match was watched by millions around the world, who held their breath as the two competitors battled it out.</p><p>In the end, Deep Blue emerged victorious, defeating Kasparov in six games out of a possible 12. The victory was a watershed moment for AI, showing that machines were capable of outsmarting even the best human players in complex games like chess.</p><p>The basic structure of chess can be viewed as a search tree problem, where each state represents a particular configuration of chess pieces on the board, and the allowed actions correspond to the legal moves that the current player can make in that particular configuration.</p><p>The Deep Blue system, consisting of an IBM RS/6000 SP computer with 30 nodes (or 30 processors) and 480 individual chess search engines, was designed to perform parallel processing and chess tree searches. On average, Deep Blue was able to evaluate about 100 million positions per second. Deep Blue used several concepts used in earlier chess programs, such as quiescent search, iterative deepening, transposition tables and NegaScout (Campbell et al, 2022).</p><p>Today chess engines are indispensable tools for chess players, who use them to analyze their games and improve their strategies. But the memory of that fateful match in 1997 still lingers, a testament to the power of technology. Of course, the urge to develop even better chess engines has not ceased since then, and IBM’s success with Deep Blue has not settled the debate but has fuelled the race for better and more sophisticated computer models.</p><p>The current best chess computer is generally considered to be Stockfish, an open-source chess engine developed by a team of programmers from around the world. Stockfish has been consistently at the top of computer chess rating lists for several years and has won numerous computer chess championships and tournaments. One of the reasons for Stockfish’s success is its highly efficient search algorithm, which allows it to analyze millions of moves per second and make highly accurate predictions about the best moves to make in any given position. Other top chess engines include Leela Chess Zero, Komodo and Houdini.</p><h3>Conclusion</h3><p>The evolution of chess engines began with the earliest mechanical devices and has progressed to the cutting-edge software programs of today. Alan Turing and Claude Shannon laid the foundations for chess engines, with Shannon publishing a paper describing a program that could potentially play chess against a human. In 1997, the impossible happened: a computer beat world chess champion Garry Kasparov.</p><p>IBM’s Deep Blue chess computer defeated world champion Garry Kasparov in a six-game match. The victory was celebrated as a triumph of machine over man, and Deep Blue’s victory demonstrated the rise of artificial intelligence. Chess was used to test the computational capabilities of computers and to advance computer science by developing the ability of computers to perform the complex calculations needed to discover new drugs, perform comprehensive financial modeling, search large databases and perform massive computations in various fields of science. Deep Blue had a significant impact on computing in several industries, and its architecture was applied to financial modelling, data mining and molecular dynamics.</p><p>Today, chess engines are indispensable tools for chess players, who use them to analyze their games and improve their strategies — just one example of how artificial intelligence is being used in almost every aspect of our technology-filled lives.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*BNbjmLp2K9mH387vrFLT_A.png" /></figure><h3>Before you leave</h3><ul><li>👏 Clap for the story</li><li>📰 Subscribe for more posts like this: <a href="https://medium.com/@clemensjarnach/subscribe">Clemens Jarnach ⚡️</a></li><li>👉👈 Please follow me: <a href="https://t.co/D0Ndbkjld9">Medium</a> | <a href="https://twitter.com/ClemensJarnach">Twitter</a> | <a href="https://www.linkedin.com/in/clemensjarnach/">LinkedIn</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9a7f59c453bf" width="1" height="1" alt=""><hr><p><a href="https://pub.towardsai.net/the-rise-of-artificial-intelligence-in-chess-9a7f59c453bf">The Rise of Artificial Intelligence in Chess</a> was originally published in <a href="https://pub.towardsai.net/">Towards AI</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Setting a default location for images and other attachments in Obsidian]]></title>
            <link>https://levelup.gitconnected.com/setting-a-default-location-for-images-and-other-attachments-in-obsidian-f6480fd007a9?source=rss-83addca999c7------2</link>
            <guid isPermaLink="false">https://medium.com/p/f6480fd007a9</guid>
            <category><![CDATA[obsidian]]></category>
            <category><![CDATA[notetaking]]></category>
            <category><![CDATA[productivity]]></category>
            <dc:creator><![CDATA[Dr Clemens Jarnach ⚡️]]></dc:creator>
            <pubDate>Tue, 04 Apr 2023 17:10:18 GMT</pubDate>
            <atom:updated>2023-04-04T17:10:18.613Z</atom:updated>
            <content:encoded><![CDATA[<h4>How do I set up a default location for attachments in Obsidian to make my vault less cluttered?</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eYzPhPKF9Az7V0RGNx0jvg.png" /><figcaption>Image by Clemens Jarnach</figcaption></figure><p>Here are all the steps you need in a condensed “click path” format:</p><pre>Settings &gt; Files &amp; Links &gt; Default location for new attachments &gt; <br>In the folder specified below &gt; Attachment folder path &gt; <br>(enter folder path e.g.) `Archive/Attachment`</pre><h4>But if that is not clear, let me walk you through it</h4><p>In Obsidian, you can set a default location for pictures and other attachments by configuring the “Attachment folder” option in the settings. Here are the steps to follow:</p><ol><li>Open Obsidian and click on the “<em>Settings</em>” icon in the left sidebar</li><li>In the Settings menu, click on “<em>Files &amp; Links</em>” in the left sidebar.</li><li>Scroll down to the “<em>Default location for new attachments</em>” option.</li><li>By default, the option is set to “<em>Vault folder</em>”. If you want to set a default location for your attachments, click on the drop-down menu and select “<em>In the folder specified below</em>”.</li><li>In the “<em>Attachment folder path</em>” tab, click on the “<em>Choose folder</em>” button to select the folder where you want to store your attachments.</li><li>Once you have selected the folder, you are done and you can exit “<em>Settings”</em>.</li></ol><p>For my personal setup, I have an <em>`Archive`</em> folder in my Vault to store notes and documents that I don’t need on a regular basis but don’t want to get rid of. Within the <em>`Archive`</em> folder, you can have another folder structure to separate file types, e.g. you could have an <em>`Attachments`</em> folder or a <em>`Media`</em> folder. In my case, the default location for pictures and other attachments is <em>`Archive/Attachment`</em>.</p><h4>Why should you bother?</h4><p>Setting a default location for media, images and other attachments in Obsidian (or any other directory) can be useful for a number of reasons:</p><ol><li><strong>Organisation:</strong> By setting a default attachment folder, you can keep all your attachments in one place, making it easier to find and manage them. This can be especially useful if you work with a lot of attachments across multiple notes.</li><li><strong>Backup:</strong> By storing your attachments in a separate folder, you can back up your attachments separately from your notes. This can be useful if you want to create a backup of your attachments without backing up your entire Obsidian vault.</li><li><strong>Collaboration:</strong> If you’re collaborating with others and sharing your Obsidian vault, setting a default attachment folder can ensure that everyone is saving attachments to the same location. This can help avoid confusion and make it easier to share and access attachments.</li><li><strong>Convenience: </strong>If you frequently attach files to your notes, setting a default attachment folder can save you time and make the process more convenient. You won’t have to navigate to the folder where you want to save the attachment every time you add a file to a note.</li></ol><p>Hope this helped!</p><h3>Before you leave:</h3><ul><li>👏 Clap for the story</li><li>📰 Subscribe for more posts like this <a href="https://medium.com/@clemensjarnach/subscribe">Clemens Jarnach ⚡️</a></li><li>👉👈 Please follow me: <a href="https://t.co/D0Ndbkjld9">Medium</a> | <a href="https://twitter.com/ClemensJarnach">Twitter</a> | <a href="https://www.linkedin.com/in/clemensjarnach/">LinkedIn</a></li></ul><h3>Level Up Coding</h3><p>Thanks for being a part of our community! Before you go:</p><ul><li>👏 Clap for the story and follow the author 👉</li><li>📰 View more content in the <a href="https://levelup.gitconnected.com/?utm_source=pub&amp;utm_medium=post">Level Up Coding publication</a></li><li>💰 Free coding interview course ⇒ <a href="https://skilled.dev/?utm_source=luc&amp;utm_medium=article">View Course</a></li><li>🔔 Follow us: <a href="https://twitter.com/gitconnected">Twitter</a> | <a href="https://www.linkedin.com/company/gitconnected">LinkedIn</a> | <a href="https://newsletter.levelup.dev/">Newsletter</a></li></ul><p>🚀👉 <a href="https://jobs.levelup.dev/talent/welcome?referral=true"><strong>Join the Level Up talent collective and find an amazing job</strong></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f6480fd007a9" width="1" height="1" alt=""><hr><p><a href="https://levelup.gitconnected.com/setting-a-default-location-for-images-and-other-attachments-in-obsidian-f6480fd007a9">Setting a default location for images and other attachments in Obsidian</a> was originally published in <a href="https://levelup.gitconnected.com/">Level Up Coding</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Chain-of-Thought Reasoning]]></title>
            <link>https://pub.towardsai.net/chain-of-thought-reasoning-a3d531aa8054?source=rss-83addca999c7------2</link>
            <guid isPermaLink="false">https://medium.com/p/a3d531aa8054</guid>
            <category><![CDATA[artificial-intelligence]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[data-science]]></category>
            <dc:creator><![CDATA[Dr Clemens Jarnach ⚡️]]></dc:creator>
            <pubDate>Mon, 27 Mar 2023 16:01:44 GMT</pubDate>
            <atom:updated>2023-03-27T16:01:44.608Z</atom:updated>
            <content:encoded><![CDATA[<h4>How Multimodal Chain-of-Thought Reasoning Can Improve Large Language Models and your ChatGPT prompting too</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*QSbtxVRiLpCZ5prR" /><figcaption>Photo by <a href="https://unsplash.com/fr/@deepmind?utm_source=medium&amp;utm_medium=referral">DeepMind</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>The Generative Pre-trained Transformer (GPT) model, which is currently used by ChatGPT, has become one of the most dominant language models available, boasting unprecedented accuracy and fluency in natural language generation. But, there is always a way to do things better.</p><p>OpenAI has pushed the boundaries of natural language processing and artificial intelligence communication technology by introducing ChatGPT, a language model that used GPT-3 to generate human-like responses and engage in fluid dialogue with users. With their recent release of <a href="https://openai.com/product/gpt-4">GPT-4</a>, an even better model, everyone is on the edge of their seats. Despite the success of GPT models, recent research has identified room for improvement. Recent developments in Large Language Models (LLMs) have made impressive progress in complex reasoning tasks. One particularly encouraging method is the use of Chain-of-Thought (CoT) prompts. CoT prompting involves generating intermediate reasoning chains to deduce an answer. Whereas previous studies have focused on language modality only, a new research paper by Zhang et al. (2023) introduces a novel approach called Multimodal-CoT, which incorporates both text and image modalities into a two-stage framework. This new approach shows promising performance improvements over the current state-of-the-art GPT-3 model. Will GPT-4 solve such problems, and how can you use this prompt technique?</p><p>In this blog post, I will provide an overview of Zhang et al.’s (2023) research and explore how Multimodal-CoT can improve reasoning and answer inference in large language models.</p><h3>What is CoT?</h3><p>Chain-of-Thought (CoT) prompting is a type of language prompting technique used in natural language processing (NLP) that involves the generation and refinement of chains of reasoning to facilitate better language understanding and generation. In CoT prompting, a language model (e.g., a neural network-based model such as GPT-3) is presented with a prompt to perform a given task (e.g., answer a question). The model is then given a set of rationales (or reasons) for why a given word or phrase might be the correct answer. The model can then use these rationales to generate a more accurate and contextually appropriate response. CoT prompting has been proven to be effective in improving the performance of language models in a variety of tasks.</p><p>Chain-of-Thought prompting is like playing a game of “Twenty Questions”. You think of an object, and your friend has to ask you questions to figure out what it is. When your friend asks a question, you give them a reason why the answer to the question might help them guess the object. For example, if your friend asks “Is it a vegetable?”, you might say “Yes, because it grows in the ground.” Your friend can then use this reason to make a better guess. CoT prompting works in a similar way. A computer program is given a prompt to perform a task, like answering a question. It is then given a set of reasons why a certain answer might be correct. The program can use these reasons to come up with a better answer. This technique has been shown to improve the performance of computer programs that process language in a variety of tasks. Theoretically, a pretty straightforward and convincing model, wouldn’t you agree? Give it a try next time you use ChatGPT and see if the answers improve in accuracy and desirability.</p><p>On the more practical side, CoT prompting can be computationally expensive, especially when dealing with large datasets and complex reasoning tasks. The process involves generating and refining chains of reasoning, which can require significant computing resources. Additionally, creating the set of rationales to present to the language model may require manual annotation, which can be time-consuming and costly. However, the benefits of using CoT prompting, such as improved performance in language tasks, may outweigh the computational cost for certain applications. Moreover, advancements in hardware and software technologies, as well as the development of more efficient algorithms, may help to reduce the computational cost of CoT prompting in the future.</p><h3>Multimodal-CoT: A Two-Step Framework</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*XC_vyiAd2Q5-h8mK" /><figcaption>Photo by <a href="https://unsplash.com/@fakurian?utm_source=medium&amp;utm_medium=referral">Milad Fakurian</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>The Multimodal CoT framework, as proposed by Zhang et al. (2023), consists of two distinct stages. The first stage involves the generation of rationales, which is achieved by feeding the model with both speech and vision inputs. The second stage then focuses on response inference, where they combine the initial speech input with the rationale generated in the first stage. The updated language input, along with the original vision input, is then fed into the model to infer the answer (Zhang et al., 2023).<br>By combining speech and visual input in this way, Multimodal CoT allows for a more comprehensive understanding of the task at hand, resulting in more accurate and informative responses. Zhang et al. (2023) believe that this framework has the potential to revolutionize the field of multimodal learning, and I am excited to see where it goes from here.</p><p>Zhang et al. evaluated their method using the “ScienceQA” benchmark dataset (Lu et al., 2022), which is a large-scale multimodal science question dataset that annotates answers with detailed lectures and explanations. The dataset contains 21k multimodal multiple-choice questions with rich diversity across subjects, topics, categories, and skills. Zhang et al.’s (2023) most sophisticated model (i.e., Multimodal-CoT_Large) outperformed the previous state-of-the-art LLM GPT-3.5 by an average of 17 percentage points, achieving an accuracy rate of 92%, and even surpassed human performance on the “ScienceQA” benchmark. Overall, the results confirm the effectiveness of multimodality and the potential for high accuracy through the use of CoT and a two-step framework as proposed by Zhang et al. (2023).</p><h3>Conclusion</h3><p>In summary, Chain-of-Thought (CoT) prompting is a technique that can be used to improve the reasoning and accuracy performance of large language models<strong> </strong>(LLM) by providing rationales for a given the word or phrase. The method shows strong capabilities to be effective in improving the performance of language models in various tasks. In addition, research by Zhang et al. presents an exciting new approach to Chain-of-Thought reasoning by incorporating both language and vision modalities into a two-step framework that separates reasoning generation and response inference. Their proposed method achieves high accuracy, outperforming existing LLMs and human-level performance. This type of research opens up promising avenues for future studies and AI applications. In addition, the concept behind CoT prompting can also help users of LLMs, such as ChatGPT, to improve their prompting and achieve better, more accurate results. I believe we will see much more of this approach in the near future, and iterations of this model will push the already very impressive capabilities of current large language models even further.</p><h4>References</h4><p>Lu, P., Mishra, S., Xia, T., Qiu, L., Chang, K.-W., Zhu, S.-C., Tafjord, O., Clark, P., and Kalyan. A. (2022). Learn to explain: Multimodal reasoning via thought chains for science question answering. <em>ArXiv preprint</em>, <a href="https://arxiv.org/pdf/2209.09513.pdf">arXiv:2209.09513v2</a>.</p><p>Zhang, Zhuosheng, Zhang, Aston, Li, Mu, Zhao, Hai, Karypis, George, &amp; Smola, Alex. (2023). Multimodal Chain-of-Thought Reasoning in Language Models. <a href="https://arxiv.org/pdf/2302.00923.pdf">arXiv:2302.00923v4</a>.</p><pre><strong>Let&#39;s Connect:</strong><br><br><a href="https://clemensjarnach.github.io/">Cemens Jarnach</a> | <a href="https://twitter.com/ClemensJarnach">Twitter</a> | <a href="https://www.linkedin.com/in/clemensjarnach/">LinkedIn</a></pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a3d531aa8054" width="1" height="1" alt=""><hr><p><a href="https://pub.towardsai.net/chain-of-thought-reasoning-a3d531aa8054">Chain-of-Thought Reasoning</a> was originally published in <a href="https://pub.towardsai.net/">Towards AI</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>