<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>AI &#8211; My Shitty Code</title>
	<atom:link href="https://myshittycode.com/ai/feed/" rel="self" type="application/rss+xml" />
	<link>https://myshittycode.com</link>
	<description>Embracing the Messiness in Search of Epic Solutions</description>
	<lastBuildDate>Tue, 05 Sep 2023 16:33:22 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.1</generator>

<image>
	<url>https://myshittycode.com/wp-content/uploads/2022/04/cropped-icon-32x32.png</url>
	<title>AI &#8211; My Shitty Code</title>
	<link>https://myshittycode.com</link>
	<width>32</width>
	<height>32</height>
</image> 
<site xmlns="com-wordpress:feed-additions:1">205304208</site>	<item>
		<title>GitHub Copilot: 10+ Ways to Increase Productivity</title>
		<link>https://myshittycode.com/2023/09/02/github-copilot-10-plus-ways-to-increase-productivity/</link>
					<comments>https://myshittycode.com/2023/09/02/github-copilot-10-plus-ways-to-increase-productivity/#respond</comments>
		
		<dc:creator><![CDATA[Shitty Author]]></dc:creator>
		<pubDate>Sat, 02 Sep 2023 16:08:18 +0000</pubDate>
				<category><![CDATA[AI]]></category>
		<category><![CDATA[Development Tools]]></category>
		<category><![CDATA[Programming Language]]></category>
		<category><![CDATA[GitHub Copilot]]></category>
		<category><![CDATA[VS Code]]></category>
		<guid isPermaLink="false">https://myshittycode.com/?p=2432</guid>

					<description><![CDATA[<p>What is GitHub Copilot GitHub Copilot is dubbed &#8220;an AI pair programmer&#8221; to help us write code faster, using a generative AI model developed through a collaboration between GitHub, OpenAI, and Microsoft Azure AI. These days, there are nothing short of AI-powered tools that can do similar things in this space. For example, Tabnine, Google&#8217;s [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://myshittycode.com/2023/09/02/github-copilot-10-plus-ways-to-increase-productivity/">GitHub Copilot: 10+ Ways to Increase Productivity</a> appeared first on <a rel="nofollow" href="https://myshittycode.com">My Shitty Code</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<div class="wp-block-rank-math-toc-block" id="rank-math-toc"><h2>Table of Contents</h2><nav><ul><li><a href="#what-is-git-hub-copilot">What is GitHub Copilot</a></li><li><a href="#prerequisites">Prerequisites</a></li><li><a href="#tips-tricks">Tips &amp; Tricks</a><ul><li><a href="#type-descriptive-code">Type Descriptive Code</a></li><li><a href="#type-comments-first">Type Comments First</a></li><li><a href="#view-multiple-suggestions">View Multiple Suggestions</a></li><li><a href="#generate-test-cases">Generate Test Cases</a></li><li><a href="#internationalization">Internationalization</a></li><li><a href="#generate-realistic-test-data">Generate Realistic Test Data</a></li><li><a href="#learn-id-es-shortcut-keys">Learn IDE&#8217;s Shortcut Keys</a></li><li><a href="#converse-with-q-and-a">Converse with &#8220;q: &#8221; and &#8220;a: &#8221; </a></li><li><a href="#fix-bug">Fix Bug</a></li><li><a href="#list-steps">List Steps</a></li><li><a href="#explain-code">Explain Code</a></li><li><a href="#translate-codebase-to-another-programming-language">Translate Codebase to Another Programming Language</a></li></ul></li><li><a href="#copilot-labs-settings">Copilot Labs Settings</a><ul><li><a href="#show-brushes-lenses">Show Brushes Lenses</a></li><li><a href="#show-test-generation-lenses">Show Test Generation Lenses</a></li></ul></li><li><a href="#what-else">What Else</a></li></ul></nav></div>



<h2 class="wp-block-heading" id="what-is-git-hub-copilot">What is GitHub Copilot</h2>



<p>GitHub Copilot is dubbed &#8220;an AI pair programmer&#8221; to help us write code faster, using a generative AI model developed through a collaboration between GitHub, OpenAI, and Microsoft Azure AI.</p>



<p>These days, there are nothing short of AI-powered tools that can do similar things in this space. For example, <a href="https://www.tabnine.com/" target="_blank" rel="noopener">Tabnine</a>, <a href="https://cloud.google.com/blog/products/application-development/introducing-duet-ai-for-developers" target="_blank" rel="noopener">Google&#8217;s Duet AI</a>, <a href="https://arxiv.org/abs/2305.12050" target="_blank" rel="noopener">Meta&#8217;s CodeCompose</a> (currently used internally at Meta), and <a href="https://about.fb.com/news/2023/08/code-llama-ai-for-coding/#:~:text=Code%20Llama%20is%20a%20code,Llama%20features%20enhanced%20coding%20capabilities." target="_blank" rel="noopener">Code Llama</a>.</p>



<h2 class="wp-block-heading" id="prerequisites">Prerequisites</h2>



<p>You need to <a href="https://github.com/features/copilot#pricing" target="_blank" rel="noopener">obtain a paid license</a> before you can use GitHub Copilot.</p>



<p>Then, install the <strong>GitHub Copilot</strong> extension in your favorite IDE. In this post, I&#8217;m using VS Code because GitHub also created <strong>the GitHub Copilot Labs</strong> extension that is not available in JetBrains IDEs (e.g., IntelliJ, PyCharm, etc.).</p>



<figure class="wp-block-image size-full is-resized"><img decoding="async" src="https://myshittycode.com/wp-content/uploads/2023/09/extensions.png?x45560" alt="github copilot" class="wp-image-2450" style="width:640px" width="640" srcset="https://myshittycode.com/wp-content/uploads/2023/09/extensions.png 1062w, https://myshittycode.com/wp-content/uploads/2023/09/extensions-300x101.png 300w, https://myshittycode.com/wp-content/uploads/2023/09/extensions-1024x343.png 1024w, https://myshittycode.com/wp-content/uploads/2023/09/extensions-768x257.png 768w" sizes="(max-width: 1062px) 100vw, 1062px" /></figure>



<h2 class="wp-block-heading" id="tips-tricks">Tips &amp; Tricks</h2>



<p>Below is a compilation of cool tricks you can do with GitHub Copilot using VS Code.</p>



<h3 class="wp-block-heading" id="type-descriptive-code">Type Descriptive Code</h3>



<p>The easiest way to get started is to continue with your typical coding. If you type descriptive variables or function names, GitHub Copilot can provide better code suggestions. </p>



<p>You can also cycle through the inline suggestions using <a href="https://docs.github.com/en/copilot/configuring-github-copilot/configuring-github-copilot-in-your-environment?tool=vscode" target="_blank" rel="noopener">shortcut keys</a> in your favorite IDE.</p>



<figure class="wp-block-image size-full"><img fetchpriority="high" decoding="async" width="640" height="480" src="https://myshittycode.com/wp-content/uploads/2023/09/by-descriptive-code.gif?x45560" alt="" class="wp-image-2434"/></figure>



<h3 class="wp-block-heading" id="type-comments-first">Type Comments First</h3>



<p>The challenge of typing very descriptive variables or function names is they get very lengthy, and you risk having your favorite code format tool complaining about the line length. </p>



<p>So, it helps to write them as comments first before you write your code. You can comment above the function you want to create or even at the top of the file.</p>



<p>The most significant advantage of this approach is if your multline comments are clear and precise, it sets proper guardrails for GitHub Copilot to provide better code suggestions based on the context you define (i.e., less hallucination).</p>



<figure class="wp-block-image size-full"><img decoding="async" width="640" height="480" src="https://myshittycode.com/wp-content/uploads/2023/09/by-comments.gif?x45560" alt="" class="wp-image-2433"/></figure>



<h3 class="wp-block-heading" id="view-multiple-suggestions">View Multiple Suggestions</h3>



<p>Sometimes, you want to browse all suggestions all at once. </p>



<p>In that case, identify the shortcut key listed under <strong>github.copilot.generate</strong> first.</p>



<figure class="wp-block-image size-large"><img decoding="async" width="1024" height="594" src="https://myshittycode.com/wp-content/uploads/2023/09/open-completions-panel-1024x594.png?x45560" alt="" class="wp-image-2497" srcset="https://myshittycode.com/wp-content/uploads/2023/09/open-completions-panel-1024x594.png 1024w, https://myshittycode.com/wp-content/uploads/2023/09/open-completions-panel-300x174.png 300w, https://myshittycode.com/wp-content/uploads/2023/09/open-completions-panel-768x446.png 768w, https://myshittycode.com/wp-content/uploads/2023/09/open-completions-panel-1536x891.png 1536w, https://myshittycode.com/wp-content/uploads/2023/09/open-completions-panel.png 1858w" sizes="(max-width: 1024px) 100vw, 1024px" /></figure>



<p>Then, type the comment and press the shortcut key in the next new line to open up the suggestions in a new tab. You can browse the suggestions and accept the one you like.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="1072" height="708" src="https://myshittycode.com/wp-content/uploads/2023/09/show-all-suggestions.gif?x45560" alt="" class="wp-image-2496"/></figure>



<h3 class="wp-block-heading" id="generate-test-cases">Generate Test Cases</h3>



<p>One of the best uses of GitHub Copilot is the ability to create test cases, especially if your function has excellent documentation. </p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="640" height="480" src="https://myshittycode.com/wp-content/uploads/2023/09/generate-test-single.gif?x45560" alt="" class="wp-image-2439"/></figure>



<p>Here&#8217;s another example where you want to generate multiple assertions.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="640" height="480" src="https://myshittycode.com/wp-content/uploads/2023/09/generate-test-multiple-assertions.gif?x45560" alt="" class="wp-image-2438"/></figure>



<p>Perhaps you don&#8217;t want to lump multiple assertions into one test case because if one of the assertions fails, the entire test case fails.</p>



<p>In this example, I&#8217;m using the <a href="https://docs.pytest.org/" target="_blank" rel="noopener">pytest</a> framework, which has a decorator that allows the parameterization of the test function&#8217;s argument(s). To refactor the existing test case, GitHub Copilot Labs&#8217; custom brush converts a single test case into 5 test cases.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="1130" height="656" src="https://myshittycode.com/wp-content/uploads/2023/09/lab-brush-custom-parameterize-1.gif?x45560" alt="" class="wp-image-2442" style="object-fit:cover"/></figure>



<h3 class="wp-block-heading" id="internationalization">Internationalization</h3>



<p>If you are building an app that users worldwide will use and want to serve the text based on regions, you can easily convert the text to different spoken languages.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="640" height="480" src="https://myshittycode.com/wp-content/uploads/2023/09/context-recognition.gif?x45560" alt="" class="wp-image-2435"/></figure>



<p>A faster way to perform language conversion is to use GitHub Copilot Labs&#8217; custom brush to convert multiple lines simultaneously.</p>



<h3 class="wp-block-heading" id="generate-realistic-test-data"><figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="1106" height="348" class="wp-image-2440" style="object-fit:cover" src="https://myshittycode.com/wp-content/uploads/2023/09/lab-brush-custom-i18n.gif?x45560" alt=""></figure>Generate Realistic Test Data</h3>



<p>Sometimes, you want to generate realistic data for your program or test cases.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="640" height="480" src="https://myshittycode.com/wp-content/uploads/2023/09/data-generation-1.gif?x45560" alt="" class="wp-image-2436"/></figure>



<p>You can also define the preferred data structure.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="640" height="480" src="https://myshittycode.com/wp-content/uploads/2023/09/data-generation-2.gif?x45560" alt="" class="wp-image-2437"/></figure>



<p>Perhaps you want to know what world leaders like to eat. As you can see, GitHub Copilot can determine the country leaders and associate the dishes relevant to that country.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="640" height="480" src="https://myshittycode.com/wp-content/uploads/2023/09/data-generation-3.gif?x45560" alt="" class="wp-image-2456"/></figure>



<h3 class="wp-block-heading" id="learn-id-es-shortcut-keys">Learn IDE&#8217;s Shortcut Keys</h3>



<p>I have used IntelliJ IDEA as my primary IDE for almost 20 years. My brain is fully wired with that particular IDE&#8217;s shortcut keys. To my disappointment, GitHub doesn&#8217;t create the <strong>GitHub Copilot Labs</strong> extension for JetBrains products.</p>



<p>To challenge myself, I want to learn similar shortcut keys for VS Code. While I can search the web for it, the easiest way is to do it directly in the code editor so that it doesn&#8217;t take my attention away during code development.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="640" height="200" src="https://myshittycode.com/wp-content/uploads/2023/09/search-engine-vscode-shortcuts.gif?x45560" alt="" class="wp-image-2449"/></figure>



<h3 class="wp-block-heading" id="converse-with-q-and-a">Converse with &#8220;q: &#8221; and &#8220;a: &#8221; </h3>



<p> You can ask GitHub Copilot anything using the <strong>q:</strong> and <strong>a:</strong> construct, even though it&#8217;s unrelated to your codebase.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="640" height="200" src="https://myshittycode.com/wp-content/uploads/2023/09/q-a-search-engine.gif?x45560" alt="" class="wp-image-2448"/></figure>



<p>You can use the same construct to ask GitHub Copilot to explain the codebase.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="640" height="480" src="https://myshittycode.com/wp-content/uploads/2023/09/q-a-explain.gif?x45560" alt="" class="wp-image-2447"/></figure>



<p>You can even argue with GitHub Copilot and defend Chuck Norris&#8217; honor!</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="640" height="480" src="https://myshittycode.com/wp-content/uploads/2023/09/q-a-converse.gif?x45560" alt="" class="wp-image-2469"/></figure>



<h3 class="wp-block-heading" id="fix-bug">Fix Bug</h3>



<p>You can attempt to fix unobvious bugs. This feature is far from perfect., but it&#8217;s worth trying out.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="1168" height="586" src="https://myshittycode.com/wp-content/uploads/2023/09/lab-brush-fix-bug.gif?x45560" alt="" class="wp-image-2443" style="object-fit:cover"/></figure>



<h3 class="wp-block-heading" id="list-steps">List Steps</h3>



<p>Perhaps you inherited a project from a previous team and struggled to understand the written code. In this case, you can list the steps in the codebase.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="1246" height="590" src="https://myshittycode.com/wp-content/uploads/2023/09/lab-brush-list-steps.gif?x45560" alt="" class="wp-image-2444" style="object-fit:cover"/></figure>



<h3 class="wp-block-heading" id="explain-code">Explain Code</h3>



<p>Maybe you don&#8217;t want to clutter the existing codebase with unnecessary comments because you don&#8217;t own the codebase. In this case, you can use GitHub Copilot to explain the code instead.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="1246" height="590" src="https://myshittycode.com/wp-content/uploads/2023/09/lab-explain.gif?x45560" alt="" class="wp-image-2445" style="object-fit:cover"/></figure>



<h3 class="wp-block-heading" id="translate-codebase-to-another-programming-language">Translate Codebase to Another Programming Language</h3>



<p>You can also translate a block of highlighted code to another programming language.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="1246" height="590" src="https://myshittycode.com/wp-content/uploads/2023/09/lab-translate.gif?x45560" alt="" class="wp-image-2446" style="object-fit:cover"/></figure>



<h2 class="wp-block-heading" id="copilot-labs-settings">Copilot Labs Settings</h2>



<p>If you often use the Copilot Labs features, there are 2 settings worth enabling to provide quick access to them.</p>



<figure class="wp-block-image size-large"><img loading="lazy" decoding="async" width="1024" height="394" src="https://myshittycode.com/wp-content/uploads/2023/09/copilot-lab-settings-1024x394.png?x45560" alt="" class="wp-image-2491" srcset="https://myshittycode.com/wp-content/uploads/2023/09/copilot-lab-settings-1024x394.png 1024w, https://myshittycode.com/wp-content/uploads/2023/09/copilot-lab-settings-300x115.png 300w, https://myshittycode.com/wp-content/uploads/2023/09/copilot-lab-settings-768x296.png 768w, https://myshittycode.com/wp-content/uploads/2023/09/copilot-lab-settings-1536x591.png 1536w, https://myshittycode.com/wp-content/uploads/2023/09/copilot-lab-settings.png 1798w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<h3 class="wp-block-heading" id="show-brushes-lenses">Show Brushes Lenses</h3>



<p>When enabled, all brush functions (fix bug, list steps, custom, etc.) are made available when you move your cursor within the function or highlight the code.</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="640" height="480" src="https://myshittycode.com/wp-content/uploads/2023/09/labs-settings-brush.gif?x45560" alt="" class="wp-image-2492"/></figure>



<h3 class="wp-block-heading" id="show-test-generation-lenses">Show Test Generation Lenses</h3>



<p>When enabled, it displays &#8220;Suggest test&#8221; on the function that quickly brings you to the Copilot Labs&#8217; Test Generation section.</p>



<p>Please note the Copilot Labs&#8217; Test Generation currently works with Javascript and Typescript (as of 2023-09-03).</p>



<figure class="wp-block-image size-full"><img loading="lazy" decoding="async" width="1104" height="772" src="https://myshittycode.com/wp-content/uploads/2023/09/labs-settings-test-generation.gif?x45560" alt="" class="wp-image-2493"/></figure>



<h2 class="wp-block-heading" id="what-else">What Else</h2>



<p>Do you know other cool tricks that are not listed here? If so, drop your comments below. I&#8217;m interested to learn from you.</p>
<p>The post <a rel="nofollow" href="https://myshittycode.com/2023/09/02/github-copilot-10-plus-ways-to-increase-productivity/">GitHub Copilot: 10+ Ways to Increase Productivity</a> appeared first on <a rel="nofollow" href="https://myshittycode.com">My Shitty Code</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://myshittycode.com/2023/09/02/github-copilot-10-plus-ways-to-increase-productivity/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">2432</post-id>	</item>
		<item>
		<title>Vertex AI PaLM: Intro to text-bison</title>
		<link>https://myshittycode.com/2023/08/01/vertex-ai-palm-intro-to-text-bison/</link>
					<comments>https://myshittycode.com/2023/08/01/vertex-ai-palm-intro-to-text-bison/#respond</comments>
		
		<dc:creator><![CDATA[Shitty Author]]></dc:creator>
		<pubDate>Tue, 01 Aug 2023 17:58:06 +0000</pubDate>
				<category><![CDATA[AI]]></category>
		<category><![CDATA[Cloud]]></category>
		<category><![CDATA[Generative AI Studio]]></category>
		<category><![CDATA[Google Cloud Platform]]></category>
		<category><![CDATA[PaLM 2]]></category>
		<category><![CDATA[Vertex AI]]></category>
		<guid isPermaLink="false">https://myshittycode.com/?p=2314</guid>

					<description><![CDATA[<p>What is text-bison Google&#8217;s PaLM 2 for text (text-bison) is recently GA&#8217;d. This foundation model is optimized for natural language tasks and it comes in 4 sizes (gecko, otter, bison, and unicorn). To date, unicorn doesn&#8217;t exist yet, no pun intended&#8230; unless one decides to stick an ice cream cone on a pony&#8217;s forehead at [&#8230;]</p>
<p>The post <a rel="nofollow" href="https://myshittycode.com/2023/08/01/vertex-ai-palm-intro-to-text-bison/">Vertex AI PaLM: Intro to text-bison</a> appeared first on <a rel="nofollow" href="https://myshittycode.com">My Shitty Code</a>.</p>
]]></description>
										<content:encoded><![CDATA[
<div class="wp-block-rank-math-toc-block" id="rank-math-toc"><h2>Table of Contents</h2><nav><ul><li><a href="#what-is-text-bison">What is text-bison</a></li><li><a href="#getting-started">Getting Started</a><ul><li><a href="#freeform-form">Freeform Form</a></li><li><a href="#structured-form">Structured Form</a></li><li><a href="#export-code">Export Code</a></li></ul></li></ul></nav></div>



<h2 class="wp-block-heading" id="what-is-text-bison">What is text-bison</h2>



<p>Google&#8217;s PaLM 2 for text (<a href="https://cloud.google.com/vertex-ai/docs/generative-ai/model-reference/text" target="_blank" rel="noopener">text-bison</a>) is recently GA&#8217;d. This foundation model is optimized for natural language tasks and it comes in 4 sizes (gecko, otter, bison, and unicorn). To date, unicorn doesn&#8217;t exist yet, no pun intended&#8230; unless one decides to stick an ice cream cone on a pony&#8217;s forehead at a county fair right now. If you know how to use OpenAI&#8217;s ChatGPT or Google Bard, you already know how to use text-bison.</p>



<h2 class="wp-block-heading" id="getting-started">Getting Started</h2>



<p>The fastest way to explore text-bison is to leverage <a href="https://cloud.google.com/vertex-ai/docs/generative-ai/learn/generative-ai-studio" target="_blank" rel="noopener">Generative AI Studio</a>, select the model to use, and get going with prompt design with absolutely no code. The pricing is listed <a href="https://cloud.google.com/vertex-ai/pricing" target="_blank" rel="noopener">here</a>. For text-bison, you can either use freeform or structured form.</p>



<h3 class="wp-block-heading" id="freeform-form">Freeform Form</h3>



<p>The freeform form is basically a giant text area for you to write anything you want. In this example, I want to put AI to good use&#8230; by analyzing one of Bruno Mars&#8217; lyrics.</p>



<figure class="wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio"><div class="wp-block-embed__wrapper">
<iframe loading="lazy" title="Bruno Mars - When I Was Your Man (Official Music Video)" width="500" height="281" src="https://www.youtube.com/embed/ekzHIouo8Q4?feature=oembed" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" referrerpolicy="strict-origin-when-cross-origin" allowfullscreen></iframe>
</div></figure>



<p>By providing concise instructions and the lyric snippet, the AI model accurately describes what Bruno&#8217;s trying to tell us, how he feels, and ways for him to improve his personal relationship.</p>



<figure class="wp-block-image aligncenter size-large is-resized"><img loading="lazy" decoding="async" src="https://myshittycode.com/wp-content/uploads/2023/08/text-bison-freeform-1024x586.png?x45560" alt="" class="wp-image-2316" width="1024" height="586" srcset="https://myshittycode.com/wp-content/uploads/2023/08/text-bison-freeform-1024x586.png 1024w, https://myshittycode.com/wp-content/uploads/2023/08/text-bison-freeform-300x172.png 300w, https://myshittycode.com/wp-content/uploads/2023/08/text-bison-freeform-768x440.png 768w, https://myshittycode.com/wp-content/uploads/2023/08/text-bison-freeform-1536x879.png 1536w, https://myshittycode.com/wp-content/uploads/2023/08/text-bison-freeform-2048x1172.png 2048w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<h3 class="wp-block-heading" id="structured-form">Structured Form</h3>



<p>The structured form leverages the few-shot prompt technique to assist the model to provide a more specific response. In this case, you provide some context and a few examples of how the model should respond. Then, you test it by providing an input for the model to generate an output.</p>



<figure class="wp-block-image aligncenter size-large is-resized"><img loading="lazy" decoding="async" src="https://myshittycode.com/wp-content/uploads/2023/08/text-bison-structured-1024x629.png?x45560" alt="" class="wp-image-2317" width="1024" height="629" srcset="https://myshittycode.com/wp-content/uploads/2023/08/text-bison-structured-1024x629.png 1024w, https://myshittycode.com/wp-content/uploads/2023/08/text-bison-structured-300x184.png 300w, https://myshittycode.com/wp-content/uploads/2023/08/text-bison-structured-768x471.png 768w, https://myshittycode.com/wp-content/uploads/2023/08/text-bison-structured-1536x943.png 1536w, https://myshittycode.com/wp-content/uploads/2023/08/text-bison-structured-2048x1257.png 2048w" sizes="auto, (max-width: 1024px) 100vw, 1024px" /></figure>



<h3 class="wp-block-heading" id="export-code">Export Code</h3>



<p>In either freeform or structured form, once you are pleased with your designed prompt, you can export it to code by clicking on the <strong>&lt;&gt; VIEW CODE</strong> link on the top right. </p>



<figure class="wp-block-image aligncenter size-large is-resized"><img loading="lazy" decoding="async" src="https://myshittycode.com/wp-content/uploads/2023/08/text-bison-code-1-1024x970.png?x45560" alt="" class="wp-image-2327" width="768" height="728" srcset="https://myshittycode.com/wp-content/uploads/2023/08/text-bison-code-1-1024x970.png 1024w, https://myshittycode.com/wp-content/uploads/2023/08/text-bison-code-1-300x284.png 300w, https://myshittycode.com/wp-content/uploads/2023/08/text-bison-code-1-768x728.png 768w, https://myshittycode.com/wp-content/uploads/2023/08/text-bison-code-1-1536x1456.png 1536w, https://myshittycode.com/wp-content/uploads/2023/08/text-bison-code-1.png 1566w" sizes="auto, (max-width: 768px) 100vw, 768px" /></figure>
<p>The post <a rel="nofollow" href="https://myshittycode.com/2023/08/01/vertex-ai-palm-intro-to-text-bison/">Vertex AI PaLM: Intro to text-bison</a> appeared first on <a rel="nofollow" href="https://myshittycode.com">My Shitty Code</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://myshittycode.com/2023/08/01/vertex-ai-palm-intro-to-text-bison/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">2314</post-id>	</item>
	</channel>
</rss>

<!--
Performance optimized by W3 Total Cache. Learn more: https://www.boldgrid.com/w3-total-cache/?utm_source=w3tc&utm_medium=footer_comment&utm_campaign=free_plugin

Page Caching using Disk: Enhanced 
Lazy Loading (feed)
Database Caching 58/78 queries in 0.036 seconds using Disk

Served from: myshittycode.com @ 2026-02-19 05:03:08 by W3 Total Cache
-->