<?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 Piram Singh on Medium]]></title>
        <description><![CDATA[Stories by Piram Singh on Medium]]></description>
        <link>https://medium.com/@piram.singh?source=rss-37e444058d76------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*YYqnKsE-6E2chL3XirjfNg.jpeg</url>
            <title>Stories by Piram Singh on Medium</title>
            <link>https://medium.com/@piram.singh?source=rss-37e444058d76------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 21 Nov 2026 18:21:54 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@piram.singh/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[Piram’s 2024 Update]]></title>
            <link>https://medium.com/@piram.singh/pirams-2024-update-4735074eaf0f?source=rss-37e444058d76------2</link>
            <guid isPermaLink="false">https://medium.com/p/4735074eaf0f</guid>
            <category><![CDATA[new-year]]></category>
            <category><![CDATA[growth]]></category>
            <category><![CDATA[reflections]]></category>
            <dc:creator><![CDATA[Piram Singh]]></dc:creator>
            <pubDate>Wed, 08 Jan 2025 00:51:31 GMT</pubDate>
            <atom:updated>2025-01-08T01:15:53.675Z</atom:updated>
            <content:encoded><![CDATA[<h4><em>a recollection of a transitional year of learning &amp; reflecting</em></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*IfeE4Im42saTwe9G" /><figcaption>family trip to tiburon, CA 🌁</figcaption></figure><p>Hello there 👋,</p><p>2024 was a transitional year for me — a year of building, learning new tools and skills, and preparing myself to find my next role as a designer.</p><p>Alongside progressing in my professional journey, I learned more about myself, made new friends, and had some fun along the way. In this year’s letter, I’ll go over the following:</p><p>1. <strong>Project Highlight:</strong> SpatialTranslate project showcase</p><p>2. <strong>Quick Updates:</strong> UX bootcamp &amp; Building my brand</p><p>3. <strong>Personal Learning:</strong> 4 lessons from projects, people, and myself</p><p>4. <strong>Cooking Review:</strong> Top 5 meals I made or ate last year!</p><h4>Project Highlight — SpatialTranslate</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*WS7cL9IU0_vpZzdV.jpeg" /></figure><p>One of my most significant projects this summer was <strong>SpatialTranslate</strong>. The project explored the future of communication and how mixed reality could create more seamless and immersive ways to connect. Throughout the process, I learned how to pivot toward more efficient strategies in development, as well as build design systems, style guides, and other essential components for XR. You can find the project article <a href="https://medium.com/@piram.singh/building-a-translator-app-for-apple-vision-pro-cd4482e143a7">here</a>, and the design case study <a href="https://piramsingh.com/projects/spatial-translate">here</a>.</p><h4><strong>Quick Updates:</strong> UX bootcamp &amp; Building my brand</h4><p>1️⃣<strong> General Assembly’s UX Bootcamp</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*WW9w7jodkcbc2PEEGg7oMg.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eVl1Waed8EouS7fphpgPIw.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QJRyhtgMPzC-804jklEMSQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SNzxs2pMERI_4ZqA-E6zuA.png" /><figcaption>bootcamp artfiacts + meetups w/ the sf cohort 🌊</figcaption></figure><p>As I wrapped up my SpatialTranslate project, my next step was to start searching for jobs, but the XR market is still nascent and to land any job, I needed to learn the fundamentals.</p><p>In August 2024, I decided to take a 12-week bootcamp to learn the fundamentals as a supplement to help me land my next role in the 6 months! I built out 4 projects alongside 15 other members and 3 instructors. Here are my key moments from the bootcamp:</p><ul><li><strong>Doing 10-15 interviews in 1 week as user research sprints</strong></li><li><strong>Building lo-fi solutions as plausible solution rather than going fully hi — fi</strong></li><li><strong>Designing complex user-flows</strong></li><li><strong>Learning advanced Figma tactics</strong></li><li><strong>Managing 2 of the 4 projects with global teams</strong></li></ul><p>2️⃣ <strong>Building my Brand</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/960/1*X73KocZTuauvEeGRuYpYvg.gif" /><figcaption>quick walkthrough of my portfolio website</figcaption></figure><p>As the bootcamp wrapped up, I had five solid projects under my belt that needed to be shown to the world. The next step was figuring out how to show them off through my portfolio site. Turns out, that wasn’t as easy as I thought — I decided to take the long road and use Framer (which has a pretty steep learning curve) instead of just posting on Dribbble or Behance. Here are a few things I learned along the way:</p><ol><li><strong>HTML Design ≠ Figma Design: </strong>Working within constrained boxes in HTML posed the biggest learning curve, as it required a different mindset compared to Figma’s free-form design.</li><li><strong>Filtering Down:</strong> I wrote over 4,000 words about design and development across three Vision Pro projects. One of the biggest lessons I learned was how to cut all that down into clear, focused case studies that actually highlight the key design takeaways.</li><li><strong>Template &gt; Scratch:</strong> When I started learning HTML design, I quickly realized how important responsive design is — especially when working within the constraints of relative containers. Initially, I thought building everything from scratch was the way to go, but using a template and iterating proved to be much more efficient. This site is still a work in progress — always evolving and improving!</li></ol><h4><strong>4 Lessons from Projects, People, and Myself</strong></h4><p><strong>building + reflecting = growth</strong></p><p>This year, as I worked on my website and AVP projects, I leaned on the insights and support of others. Each experience pushed me to expand my mindset and grow. Here are a few key lessons that continue to guide me forward.</p><ol><li><strong>🧠 Research is damn hard: </strong>I thought building was the toughest part, but I was wrong. Deep research flips everything — turning assumptions into empathy. The hardest habit to unlearn? Skipping straight to solutions.</li><li><strong>🤝 Big Connections Start Small : </strong>Networking doesn’t start with a pitch. The most valuable connections I’ve made happened by leaning into randomness — whether it’s a side chat in line or laughing over a shared awkward moment.</li><li><strong>⛓️‍💥 Embrace Non-Linearity : </strong>In my first client project, we abandoned “best practices” and validated raw ideas from scratch. The result? A product that stood out because it wasn’t shaped by pre-existing frameworks. Linear paths rarely lead to standout results</li><li>✨ <strong>Simplicity Wins: </strong>A PM at Apple told me this: great management is more about cutting than creating. The power of filtering — saying no to 90% of ideas — forces the remaining 10% to shine. Minimalism isn’t a design choice; it’s a strategy.</li></ol><h4>4. Food Review</h4><p>In 2023 — I watched tons of movies, spending lots of time at AMC. In my free time last year I was either at a restaurant or in the kitchen cooking something good. Here are my top 5 dishes</p><p><strong>5. Monty’s Burger — (Score 7.8/10) — — 📍 Los Angeles, CA</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/768/1*GW_0Wfyo7Njzyx42YlSmFA.jpeg" /></figure><p><strong>4. Home-made Bagel Sandwich (8.0/10) — — 📍 Irvine, CA</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OdxXtU_I6EYs0fuWNqnT6Q.jpeg" /></figure><p>3.<strong> Home-made Pink Pasta (Score: 8.4/10) — — 📍Fremont, CA</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/768/1*Iv2EGbL7NVhmbLT2AB8fEw.jpeg" /></figure><p><strong>2. Joe’s Pizza (Score: 8.7/10) — — 📍NYC, NY</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/360/1*B59u6P46D5Y9DggJ6FR2jA.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/360/1*jc5kq-FG4AM-fjM_vPyEpg.jpeg" /></figure><ol><li><strong>L’industrie (9.4/10) — — 📍Brooklyn, NY</strong></li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/768/1*JFt0Z0JYjviwxQOHslhZPQ.jpeg" /></figure><h3>What’s next for me in 2025 …</h3><p>2025 is the year I really take what I have built over the past 2 years and bring it out in to the world for everyone to see:</p><ul><li><strong>📂 Iterate on my portfolio — I just got started on my personal brand. There’s more to come</strong></li><li><strong>💼 Keep searching for that meaningful job + start getting experience</strong></li><li>💪<strong> Being Healthy — </strong>Increasing the amount of times I go to the gym and being in nature more often. Taking more breaks to explore the world more</li><li>👥 <strong>Building in Public</strong> <strong>—</strong> I felt that last year I was in a cave working away. It’s time to get out of the building and show everyone. I’ll be at networking events 1x/week + posting more design content on Linkedin!</li><li>🪯<strong> Growing SSA Sounds —</strong> For those who know me personally, <em>kirtan</em> — sikh classical music — has been a big part of my life. Giving back to Sikh Student associations through <a href="https://soundcloud.com/ssasounds">ssa_sounds</a> in more ways is always the goal.</li></ul><p><em>👋Hey, I’m Piram and I’m an aspiring UI/UX designer, exploring how AI is changing the design world. Connect with me on </em><a href="https://www.linkedin.com/in/piramsingh/"><em>LinkedIn</em></a><em> to follow me on this journey!</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4735074eaf0f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Building a Translator App for Apple Vision Pro!]]></title>
            <link>https://medium.com/@piram.singh/building-a-translator-app-for-apple-vision-pro-cd4482e143a7?source=rss-37e444058d76------2</link>
            <guid isPermaLink="false">https://medium.com/p/cd4482e143a7</guid>
            <category><![CDATA[translation]]></category>
            <category><![CDATA[xr]]></category>
            <category><![CDATA[speech-to-text-api]]></category>
            <category><![CDATA[google]]></category>
            <category><![CDATA[voices]]></category>
            <dc:creator><![CDATA[Piram Singh]]></dc:creator>
            <pubDate>Fri, 02 Aug 2024 01:22:42 GMT</pubDate>
            <atom:updated>2024-08-02T01:54:05.080Z</atom:updated>
            <content:encoded><![CDATA[<h4>Building Translator App for Vision Pro with Google Cloud Speech To Text (STT) and Translate APIs</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QG25P6aihG21Fmc6LPig9A.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QTY0JtkWVw9NXrDlxyojPQ.gif" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/700/1*xIsRaH7SUR8X0VVD3Y4rmw.gif" /><figcaption>design + web app for spatial translate</figcaption></figure><p>My app, SpatialTranslate builds off of the idea of how we can better<strong> interact, communicate, </strong>and<strong> engage</strong> with the world in a more immersive and customizable way with the power of XR! It all stems from creating an app</p><blockquote>that makes it 10x better to travel from the comfort of your home.</blockquote><p>To illustrate this, let me take you on a journey 👇</p><p>For the past couple of months, i’ve been going to SF for founder’s meetups at many incubator houses — so let’s say hypothetically a founder from Mexico just got founding for his new startup from Founder’s Inc and wants to visit the offices in SF instantly.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/900/0*eMKgaPrkwLfpLaSB.jpg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/900/0*Qii2BHpbFUlVBG7M.jpg" /><figcaption>founders inc offices in sf</figcaption></figure><p>Now the thing is for founders, <strong>time</strong> is the most valuable resource for them as you want to ship fast and iterate quickly — so flying to SFO and back just to visit is not a good usage of time or money — that’s where this founder would put on their vision pro on and transport themselves to the founder’s inc office and have an immersive conversation with other founder’s w/ built — in translations</p><p>Now just from this quick scenario, you saw a quick glance of what travel could look like, but there’s a <em>bigger reason</em> why this app is a preview of the future of <em>communication</em> and <em>engagement</em>.</p><p>Currently, if we want to engage with content online, there’s no real-time, personal feedback loop that we can actually experience — here’s what we have to do right now 👇</p><p>🏑 Imagine your a Punjabi speaker from India whose really interested in the current ongoing olympics in Paris who is a big field hockey fan and would like to experience the feeling that athletes — you would have to go through the following steps:</p><ol><li>📺 If the channel exists and a similar language is being streamed, watch the stream in a different language and try to understand the commentary that commentators are illustrating</li><li>💬 Hours later, you would go onto twitter or other social media and find a specific section of the platform that are Punjabi speakers are on to understand the entirety of the event within the intricacies of the language — the current status of this type of communication has so much to room to grow and innovate more in this space!</li></ol><p>That’s why the future of creating <em>immersive experiences </em>where you can have <strong>real-time translations</strong>, <strong>dubbing </strong>and interacting with real people is going to be a game changer for XR.</p><p>Now creating something like this from the ground up is hard from the get-go, however after months of doing r&amp;d — creating a web-app powered by google speech to text and translate apis was the best course of action!</p><p>Coming up, i’ll break-down how I built this real-time translation application into four main steps:</p><h4>(1)<strong> 🛠️ Setting Up Coding Environments</strong></h4><h4>(2)<strong> 💬 Connecting Google Cloud APIs</strong></h4><h4>(3) <strong>💻 Coding Breakdown</strong></h4><h4>(4)<strong>🪞 Designing native UI/UX for visionOS</strong></h4><h3>🛠️ Setting Up Coding Environments</h3><p>To get started building this project, we need to set up our dev environments and install the necessary libraries to get started coding. Some prerequisites here : <strong>have a IDE like VS Code</strong> &amp; the <strong>latest version of Python</strong></p><p>Let’s get started 👇</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/766/1*6dtp1lB8lFgEI-xe3_7t5A.png" /><figcaption>VisionProWebApp in finder</figcaption></figure><p>The first thing we are going to do is create a directory on our machine so that we can make modifications in VS Code</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/614/1*qR6SXFjpiC6nVprHpgVM5w.png" /></figure><p>Once the directory is made on our machine, let’s open it up in VSCode and create three main folders: <strong>templates, venv, </strong>&amp;<strong> app2.py</strong></p><ul><li><strong>templates </strong>— this will hold our client side code in html (index.html) → think of this is as where the front-end of our code will live.</li><li><strong>venv —</strong> this is the <strong>virtual environment </strong>which will hold all of the important libraries we need so we can access the web app<strong>. </strong>You’ll run the app from this environment only.</li><li><strong>app2.py —</strong> this is where the server-side code will live. In this case we are using python which will help us access google API’s and run the app’s back-end.</li></ul><p>Once the basic file structure has been created, we need to identify the various different libraries &amp; download the necessary ones to create the application, here are the libraries that we are going to need:</p><p>(1)<strong> 💻 Flask </strong>— this is a web application framework to create the web server and manage the web app.</p><p>(2) 🗣️ <strong>Flask-SocketIO — </strong>this module allows for bi-directional audio communication between client and servers.</p><p>(3) 🎤 <strong>pyAudio — </strong>this module allows for audio to be captured from the system’s microphone</p><p>(4) 🗂️ <strong>queue </strong>— this module allows for audio to be chunked and sent to the google APIs</p><p>(5) 📝 <strong>logging — </strong>this was used for logging messages and used for debugging the application</p><p>For numbers 1–3, you’ll need to CD into venv file from the command line and use pip (or any other package manager) and install those libraries. Here are the respective commands 👇</p><pre>pip install flask</pre><pre>pip install flask-socketio</pre><pre>pip install pyaudio</pre><p>once those libraries are installed, the last step in setting up the dev environment is creating the README.md file. You can use the README to put extra instructions for yourself or if you’d like to put it on github — it can be a guide on how to use your application.</p><p>We’ll get to setting up the requirements.txt once we connect the Speech To Text (STT) and Translate APIs from Google.</p><h3>💬 Connecting Google Cloud APIs</h3><p>To connect the Google Cloud APIs to your project, there are three main steps we need to take:</p><ol><li><strong>Setting Up the Google Cloud Project</strong></li><li><strong>Creating the Service Account &amp; JSON Key</strong></li><li><strong>Setting Environment Variables on the command line</strong></li></ol><h4><strong>Setting Up the Google Cloud Project</strong></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*JMhW6SzjkbCSzLDg0B4orQ.png" /></figure><ol><li>Go to <a href="https://cloud.google.com/?hl=en">https://cloud.google.com/?hl=en</a> and sign-in by using your google account and enter the console.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*f2HLwDPxKWGmKqBFPCtxIw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SQ9-s80FRDgcEs7sgzku6Q.png" /><figcaption>creating a new project in the GCP</figcaption></figure><p>2. You’ll then want to click on New Project in the top right-hand side and then fill in the corresponding information</p><p>3. Click Create once information is filled out</p><p>Once the project is created, lets enable the STT and Translate APIs!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*M7kriMeqduobs8ud3XjijA.png" /><figcaption>API Library</figcaption></figure><p>4. From the console go to APIs and Services &gt; Library</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GfV4BjVRKf-hCSjGmDMzIw.png" /><figcaption>STT API</figcaption></figure><p>5. Enable the <strong>Google Cloud Speech to Text API</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Axvs2sVv-5leQwZCW9hjLg.png" /><figcaption>Translate APIs</figcaption></figure><p>6. Enable the <strong>Google Cloud Translation API</strong></p><p>Once the project is created and we have enabled our APIs, we need a way for our computer to recognize the APIs via the Cloud Project we created — For that we’ll need to generate json keys that we will have to put them locally on your machine</p><h4><strong>Creating the Service Account &amp; JSON Key</strong></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*E2tyROcXjsgS27rcPeFS8w.png" /></figure><ol><li>From the console, click through the following: IAM &amp; Admin &gt; Service Account</li><li>Hit “Create Service Account” at the top and enter a name and description for the service account</li><li>Click “Create and Continue”</li><li>You want to grant the account “Editor” status</li><li>Click “Continue” and “Done”</li></ol><p>Once the account is created, we can generate the JSON key</p><p>6. Find the service account you created</p><p>7. Click on the three dots to the right and click “Manage Keys”</p><p>8. Click on “Add Key” &gt; “Create New Key”</p><p>9. Select JSON and click “Create”</p><p>10. Download the JSON File and place it in a secure location</p><h4><strong>Setting Environment Variables on the command line</strong></h4><p>The last step to making sure your code will work is putting the JSON Key on your path of your machine!<br>From the command line, do the following:</p><ol><li>Open your shell configuration file (i.e. ~/.bashrc, ~/.bash_profile, ~/.zshrc,)</li><li>Once added add the following line in the shell configuration file:</li></ol><pre>export GOOGLE_APPLICATION_CREDENTIALS=&quot;/path/to/your/credentials.json&quot;</pre><p>3. Save the file and reload the configuration by running one of the following lines of code based on your machine:</p><pre>source ~/.bashrc<br># or<br>source ~/.bash_profile<br># or<br>source ~/.zshrc</pre><p>Now that you’ve connected the APIs an stored the JSON key securely, we can start coding the web app</p><h3>💻 Coding Breakdown</h3><p>With our Project set-up and Google Cloud API’s connected, the next step is we can start coding and testing the web app with two main files that we are going to build: <strong>index.html</strong> and <strong>app2.py. </strong>These are our front-end and back-end respectively</p><h4>🌐 Front-End : index.html</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kKjyy77YVN1vNZC8O2ns-w.png" /></figure><pre>&lt;!DOCTYPE html&gt;<br>&lt;html&gt;<br>&lt;head&gt;<br>    &lt;title&gt;Real-Time Translation&lt;/title&gt;<br>    &lt;style&gt;<br>        @font-face {<br>            font-family: &#39;SF Pro Display&#39;;<br>            src: url(https://medium.com/&#39;https://developer.apple.com/fonts/SFProDisplay-Regular.woff2&#39;) format(&#39;woff2&#39;),<br>                 url(https://medium.com/&#39;https://developer.apple.com/fonts/SFProDisplay-Regular.woff&#39;) format(&#39;woff&#39;);<br>            font-weight: normal;<br>            font-style: normal;<br>        }</pre><p>Let’s get started with building out this with the Web UI — we’ll start this like a normal HTML file structure — this part of the code initializes the Title of the website — <em>Real Time Translation —</em> by using official fonts from Apple as the source</p><pre><br>        body {<br>            font-family: &#39;SF Pro Display&#39;, Arial, sans-serif;<br>            background-color: #F2F2F7; /* Light gray background */<br>            margin: 0;<br>            padding: 20px;<br>        }<br><br>        h1 {<br>            color: #1D1D1F; /* Dark text color */<br>            text-align: center;<br>            font-size: 24px;<br>        }<br><br>        #controls {<br>            text-align: center;<br>            margin-bottom: 20px;<br>        }</pre><p>This next chunk of the code then goes into the body section which formats the text with parameters like the background-color, margin, and padding . This part of the code creates the light gray background for the text, initializes the text colors for the webpage, and then intializes the formatting to be centered with the controls id.</p><pre>#language-select, #startButton, #stopButton {<br>            font-size: 16px;<br>            padding: 10px;<br>            border: none;<br>            border-radius: 8px;<br>            box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);<br>            margin: 5px;<br>        }<br><br>        #language-select {<br>            background-color: #FFFFFF;<br>            color: #1D1D1F;<br>        }<br><br>        #startButton {<br>            background-color: #007AFF; /* Apple blue */<br>            color: #FFFFFF;<br>        }<br><br>        #stopButton {<br>            background-color: #FF3B30; /* Apple red */<br>            color: #FFFFFF;<br>        }<br><br>        #stopButton:disabled {<br>            background-color: #FF3B30;<br>            color: #FFFFFF;<br>            opacity: 0.5;<br>        }</pre><p>The next chunk of code formats the shape and color for the langauage selection drop-down, start button, stop button, and the disabled state for the stop button. The important thing to note here is that we are using exact hex codes from Apple design documentation.</p><pre><br><br>        .container {<br>            display: flex;<br>            justify-content: space-around;<br>        }<br><br>        .column {<br>            background-color: #FFFFFF;<br>            padding: 20px;<br>            border-radius: 8px;<br>            box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);<br>            width: 45%;<br>        }<br><br>        .column h2 {<br>            text-align: center;<br>            color: #1D1D1F;<br>        }</pre><p>This chunk of code does the following:</p><ul><li>.container sets the display to use the flexbox layout which makes it more responsive and flexible to layout child elements within the container element and distribute them with space around</li><li>.column styles the appearance of the column elements which include parameters like background color, padding, border radius, box-shadow, and the width</li><li>.column h2 centers the text and sets the appearance of h2 elements within the column elements of the webpage</li></ul><pre> #englishText, #translatedText {<br>            font-size: 18px;<br>            color: #1D1D1F;<br>            white-space: pre-wrap; /* Preserve whitespace */<br>            height: 400px; /* Fixed height */<br>            overflow-y: auto; /* Scrollable */<br>        }<br><br>        .error {<br>            color: #FF3B30; /* Apple red */<br>            margin-top: 20px;<br>            text-align: center;<br>        }<br>    &lt;/style&gt;<br>&lt;/head&gt;</pre><p>The last component of the style portion of the code is for the english text translated text, and the error text components of the code. Important parameters to note here are the white-space parameters which are set to pre-wrap to mainly conserve white space for the incoming text to come in. The other parameter here is overflow-y which allows for content to be always properly formatted in the vertical axis and can be made scrollable if needed.</p><pre>&lt;h1&gt;Real-Time Translation App&lt;/h1&gt;<br>    &lt;div id=&quot;controls&quot;&gt;<br>        &lt;select id=&quot;language-select&quot;&gt;<br>            &lt;option value=&quot;es&quot;&gt;Spanish&lt;/option&gt;<br>            &lt;option value=&quot;fr&quot;&gt;French&lt;/option&gt;<br>            &lt;option value=&quot;de&quot;&gt;German&lt;/option&gt;<br>            &lt;option value=&quot;zh&quot;&gt;Chinese&lt;/option&gt;<br>            &lt;!-- Add more languages as needed --&gt;<br>        &lt;/select&gt;<br>        &lt;button id=&quot;startButton&quot;&gt;Start&lt;/button&gt;<br>        &lt;button id=&quot;stopButton&quot; disabled&gt;Stop&lt;/button&gt;</pre><p>With the style created and components initialized, we can actually start creating the format with more specific information. We’ll place the title as h1 and then place the controls right below and the language selection drop-down with the following languages: Spanish, French, German, Chinese and their corresponding codes based on the Translation API. We’ll then place the startButton and stopButton and give all of them functionality.</p><pre>&lt;div class=&quot;container&quot;&gt;<br>        &lt;div class=&quot;column&quot;&gt;<br>            &lt;h2&gt;English&lt;/h2&gt;<br>            &lt;div id=&quot;englishText&quot;&gt;English transcription will appear here&lt;/div&gt;<br>        &lt;/div&gt;<br>        &lt;div class=&quot;column&quot;&gt;<br>            &lt;h2&gt;Translation&lt;/h2&gt;<br>            &lt;div id=&quot;translatedText&quot;&gt;Translated text will appear here&lt;/div&gt;<br>        &lt;/div&gt;<br>    &lt;/div&gt;</pre><p>We will then set the text and the formatting for the place the transcription will occur along the translated text will be written out.</p><pre> &lt;div class=&quot;error&quot; id=&quot;error&quot;&gt;&lt;/div&gt;<br><br>    &lt;script src=&quot;https://cdnjs.cloudflare.com/ajax/libs/socket.io/4.0.1/socket.io.js&quot;&gt;&lt;/script&gt;</pre><p>The next chunk of code does the following:</p><ul><li>class = “error” creates the formatting for the error message if shown in the process</li><li>the Socket.IO script is added to add the socket io library to allow real-time communication between the client and the server. It is also needed for communication between the client and server.</li></ul><pre>function startStreaming() {<br>            const languageSelect = document.getElementById(&#39;language-select&#39;);<br>            const selectedLanguage = languageSelect.value;<br>            document.getElementById(&#39;englishText&#39;).innerText = &#39;&#39;; // Clear previous text<br>            document.getElementById(&#39;translatedText&#39;).innerText = &#39;&#39;; // Clear previous text<br>            socket.emit(&#39;start_stream&#39;, { language: selectedLanguage });<br>            document.getElementById(&#39;startButton&#39;).disabled = true;<br>            document.getElementById(&#39;stopButton&#39;).disabled = false;<br>            isStreaming = true;</pre><p>The next step is to build out two main functions — startStreaming and stopStreaming . We’ll start out with startStreaming . Here’s what the code does:</p><ul><li>set a constant languageSelect set to the component we made earlier: language-select</li><li>set another constant called selectedLanguage that retrieves the value passed in by the user.</li><li>clear any previous text from the previous session from the englishText and translatedText</li><li>Initiate the start_stream protocol by socket io library with a specific language form the selectedLanguage.</li><li>turn on the disabled property of the Start Button so that the user cannot click it while an audio stream is active</li><li>turn off the disabled the property of the Stop Button so that the user can stop the audio stream at any time.</li><li>set theisStreaming variable to true (we’ll create this once we’ve built out both start and stop streaming functions)</li></ul><pre>navigator.mediaDevices.getUserMedia({ audio: true }).then(stream =&gt; {<br>                mediaRecorder = new MediaRecorder(stream);<br>                mediaRecorder.ondataavailable = event =&gt; {<br>                    const reader = new FileReader();<br>                    reader.onloadend = () =&gt; {<br>                        socket.emit(&#39;audio&#39;, { audioData: reader.result, language: selectedLanguage });<br>                    };<br>                    reader.readAsArrayBuffer(event.data);<br>                };<br>                mediaRecorder.start(1000); // Send audio data every second<br>            });<br>        }</pre><ul><li>navigator.mediaDevices.getUserMedia({ audio: true }) requests access to the user’s microphone to capture audio</li><li>then(stream =&gt; { mediaRecorder = new MediaRecorder(stream); }) initializes a new MediaRecorder instance with the audio stream obtained from the microphone.</li><li>mediaRecorder.ondataavailable = event =&gt; { … } sets an event handler that is triggered whenever audio data is available. It processes the audio data in chunks</li><li>With in the event handler, it uses a FileReader to read the audio data as an array buffer and then emits it to the server via the socket io library</li><li>mediaRecorder.start(1000) starts the MediaRecorder which instructs it to capture audio data and emit chunks every second (1000 milliseconds)</li></ul><pre>function stopStreaming() {<br>            if (mediaRecorder) {<br>                mediaRecorder.stop();<br>                mediaRecorder.stream.getTracks().forEach(track =&gt; track.stop());<br>            }<br>            document.getElementById(&#39;startButton&#39;).disabled = false;<br>            document.getElementById(&#39;stopButton&#39;).disabled = true;<br>            socket.emit(&#39;stop_stream&#39;); // Notify server to stop streaming<br>            isStreaming = false;<br>        }<br>    &lt;/script&gt;<br>&lt;/body&gt;<br>&lt;/html&gt;</pre><p>The next function to build out is the stopStreaming, here’s what this code does:</p><ul><li>check if mediaRecorder is still enabled</li><li>if it is still enabled, stop the media recording by accessing all the audio tracks in the media stream using mediaRecorder.stream.getTracks(), and then iterate over each track with .forEach(track =&gt; { … }), and then call track.stop() to cease audio capture, that will terminate the media stream and releasing resources</li><li>set the disabled property of startButton to false, making the Start Button clickable</li><li>set the disabled property of stopButton to true, making the Stop Button unclickable.</li><li>call socket io’s stop_stream protocol</li><li>set isStreaming to false</li></ul><p>With both functions built out, we can go up above these chunks and build some logic to pass in these functions.</p><pre>const socket = io();<br>let mediaRecorder;<br>let isStreaming = false;<br><br>        socket.on(&#39;connect&#39;, () =&gt; {<br>            console.log(&#39;Connected to server&#39;);<br>        });<br><br>        socket.on(&#39;transcription&#39;, data =&gt; {<br>            const englishTextElem = document.getElementById(&#39;englishText&#39;);<br>            const translatedTextElem = document.getElementById(&#39;translatedText&#39;);<br>            englishTextElem.innerText += data.original + &#39;\n&#39;;<br>            translatedTextElem.innerText += data.transcript + &#39;\n&#39;;<br>        });</pre><p>To begin with, here is what the three variables do:</p><ul><li><strong>const socket = io(); </strong>will initialize a new Socket.IO client instance and assigns it to the constant variable socket</li><li><strong>let mediaRecorder; </strong>declares a variable mediaRecorder without assigning an initial value. This variable will be used to hold the MediaRecorder instance that we used in the two functions above.</li><li><strong>let isStreaming = false;</strong> declares a variable isStreaming and initializes it with the value false. This will act as a flag to see if an active audio stream is still running.</li></ul><p>Once the variables are initialized, the following logic allows us to do the following:</p><ul><li>Ensuring a connection to socket io is active and if it is, print a statement to the console of the terminal showing it is connected → ‘connected to server’</li><li>Recieve HTML Elements by setting two constants — englishTextElem &amp; translatedTextElem which will give us IDs for englishText and translatedText</li><li>Update the texts from english and translated text fields through englishTextElem.innerText += data.original + ‘\n’; and translatedTextElem.innerText += data.transcript + ‘\n’; . This appends the previous text (original from the audio source for English) &amp; (transcript from the STT api) and then adds a new line for each of areas</li></ul><pre>socket.on(&#39;error&#39;, data =&gt; {<br>            document.getElementById(&#39;error&#39;).innerText = data.error;<br>        });<br><br>        document.getElementById(&#39;startButton&#39;).onclick = () =&gt; {<br>            if (!isStreaming) {<br>                startStreaming();<br>            }<br>        };<br><br>        document.getElementById(&#39;stopButton&#39;).onclick = () =&gt; {<br>            if (isStreaming) {<br>                stopStreaming();<br>            }<br>        };</pre><p>The last part of the logic that we need to pass through is solving for three main use cases of the app — <strong>Error case</strong>, <strong>Starting Stream,</strong> and<strong> Stopping Stream</strong></p><p><strong>Error:</strong></p><ul><li>This code listens for the error event from Socket IO library and if it is detected, it has a callback function that it calls to update the UI</li><li><strong>document.getElementById(‘error’) </strong>will retrieve the proper HTML elements.</li><li><strong>innerText = data.error; </strong>will then update the innerText property and the error message as a whole</li></ul><p><strong>Starting Stream</strong>:</p><ul><li>document.getElementById(‘startButton’).onclick = () =&gt; will ensure that the start button is clicked by the user and then the following logic occur</li><li>if (!isStreaming) will then check isStream = false and if false, it will pass in startStreaming</li></ul><p><strong>Stopping Stream</strong>:</p><ul><li>document.getElementById(‘stopButton’).onclick = () =&gt; will ensure that the stop button is clicked by the user and then the following logic occur</li><li>if (isStreaming) will then check isStream = true and if true, it will pass in stopStreaming</li></ul><p>With the Web UI created the next step is to program the back-end &amp; test the app in the vision pro simulator!</p><h4>🖥️ Back-End: app2.py</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Recwx7mhL8BMSR9eZzHOww.png" /></figure><pre>import os<br>import queue<br>import re<br>import sys<br>import logging<br>from flask import Flask, render_template<br>from flask_socketio import SocketIO, emit<br>from google.cloud import speech, translate_v2 as translate<br><br>import pyaudio</pre><p>The first step in programming the server-side code are the import statements so we can use the APIs and the other libraries that will help us with development! From these import statements there are some other libraries that were not mentioned: os, re, &amp; sys</p><p><strong>os </strong>— this allows us way of using an operating system’s dependent functionality</p><p><strong>re</strong> — this library has support for regular expressions, will be useful as we would like to a bit of pattern matching in the back-end of the application</p><p><strong>sys</strong> — this library provides access to system-specific parameters and functions</p><pre># Configure logging<br>logging.basicConfig(level=logging.INFO)<br><br># Audio recording parameters<br>RATE = 16000<br>CHUNK = int(RATE / 10)  # 100ms<br><br>#Connect to Flask &amp; FlaskSocketIO<br>app = Flask(__name__)<br>socketio = SocketIO(app)<br><br># Set up Google Cloud clients<br>speech_client = speech.SpeechClient()<br>translate_client = translate.Client()</pre><p>The next set of code is setting our variables and controls so that we can use this in the main Class we are going to create — MicrophoneStream which will host the major functions we will need! The first thing we do is configure out logging for debugging, then set up our audio recording parameters that can be passed later along in the code with the variables, <strong>RATE</strong> and<strong> CHUNK. </strong>The next step is to connect to flask and flaskSocketIO<strong> </strong>to set up our web server and pass these variables along in MicrophoneStream and the final step in this stage is creating variables for Google STT and Translate.</p><pre>class MicrophoneStream:<br>    def __init__(self, rate=RATE, chunk=CHUNK):<br>        self._rate = rate<br>        self._chunk = chunk<br>        self._buff = queue.Queue()<br>        self.closed = True</pre><p>Once our variables are set, we can start building out the MicrophoneStream Class that helps us tap into the device’s microphone and capture audio. In this first function — <em>__init__</em> sets up the audio stream parameters and prepares a queue to hold audio data. Here’s what each variable means:</p><ul><li>self._rate = rate — this initializes the sampling rate of the audio which we have set at 16000 Hz from the inital RATE variable</li><li>self._chunk = chunk — this initializes the size of each audio chunk that needs to be sent to STT &amp; Translate. We set this variable in the previous section.</li><li>self._buff = queue — this allows us to store audio chunks in the queue module</li><li>self.closed = True — this is a flag indicating whether the audio stream is closed. We’ll set this to True.</li></ul><pre>def __enter__(self):<br>        self._audio_interface = pyaudio.PyAudio()<br>        self._audio_stream = self._audio_interface.open(<br>            format=pyaudio.paInt16,<br>            channels=1,<br>            rate=self._rate,<br>            input=True,<br>            frames_per_buffer=self._chunk,<br>            stream_callback=self._fill_buffer,<br>        )<br>        self.closed = False<br>        return self</pre><p>The next part of the MicrophoneStream is when the audio interface is initialized and the audio stream is opened — here’s what the function entails:</p><ul><li>self._audio_interface = pyAudio.PyAudio() — this opens an instance of the PyAudio module to interact with the device’s hardware</li><li>self._audio_stream = self._audio_interface.open() — this opens the audio stream with 6 specified parameters — <strong>format,</strong> <strong>channels,</strong> <strong>rate</strong>, <strong>input</strong>, <strong>frame per buffer</strong>, and <strong>stream callback</strong> in which all of our previously created variables exist!</li><li>self.closed = False — this flag will close the audio stream and then pass in a return self to end this function</li></ul><pre> def __exit__(self, type, value, traceback):<br>        self._audio_stream.stop_stream()<br>        self._audio_stream.close()<br>        self.closed = True<br>        self._buff.put(None)<br>        self._audio_interface.terminate()<br><br>    def _fill_buffer(self, in_data, frame_count, time_info, status_flags):<br>        self._buff.put(in_data)<br>        return None, pyaudio.paContinue</pre><p>The next section of the code has two main methods : <em>__exit__ </em>and <em>_fill_buffer.</em></p><p>The exit method simply closes the audio stream and the important thing to note here is that the closed flag here is True, other than that it passes in the following variables:</p><ul><li>self._audio_stream.stop_stream() — this simply stops the audio stream</li><li>self._audio_stream.close() — this closes the audio stream</li><li>self._buff.put(None) — this puts a <em>None</em> value in the buffer to signify the end of the audio stream</li><li>self._audio_interface.terminate() — this terminates the audio interface to release resources</li></ul><p>The fill buffer method is a method in pyAudio to always collect audio data in a running stream and place the audio in a buffer, this code essentially is saying is keep putting audio data in the buffer, if nothing is being returned keep continuing the stream indicated by pyaudio.paContinue.</p><pre>def generator(self):<br>        while not self.closed:<br>            chunk = self._buff.get()<br>            if chunk is None:<br>                return<br>            data = [chunk]<br>            while True:<br>                try:<br>                    chunk = self._buff.get(block=False)<br>                    if chunk is None:<br>                        return<br>                    data.append(chunk)<br>                except queue.Empty:<br>                    break<br>            yield b&quot;&quot;.join(data)</pre><p>The last section of <em>MicrophoneStream </em>is the generator method which is logic that continuously yields audio chunks from the buffer in a what/if loop framework, here’s what this code is doing —</p><p><strong>While the audio stream is not closed (basically while the audio is streaming) the following will happen:</strong></p><ul><li>chunk = self._buff.get() will retrieves the next chunk from the audio buffer.</li><li>If chunk is None, then the stream ends and the function returns.</li><li>If something exists in chunk, then you’ll initialize that audio data as a list and give it to the data variable</li></ul><p><strong>While there is more audio chunks in the buffer categorized as data, the following will happen (</strong><strong>while True:):</strong></p><ul><li>chunk = self._buff.get(block=False) will retrieves the next chunk without blocking the audio stream</li><li>If chunk is None, then the stream ends and the function returns.</li><li>data.append(chunk) will add chunk to the data list</li><li>If the buffer is empty, the inner loop will break</li></ul><p>Once your audio has been chunked into data and has passed all these logic tests , the data can be joined to create one object with yield b””.join(data)</p><pre>def listen_print_loop(responses, target_language):<br>    num_chars_printed = 0<br>    for response in responses:<br>        if not response.results:<br>            continue<br>        result = response.results[0]<br>        if not result.alternatives:<br>            continue<br>        transcript = result.alternatives[0].transcript<br>        <br>        # Log the intermediate and final results for debugging<br>        logging.info(f&quot;Transcript: {transcript}&quot;)</pre><p>The next big method we want to write out is the listen_print_loop — this function processes the responses from the Google Cloud STT API, logs and prints the transcriptions, translates the text, and emits the transcriptions and translations to the client (the HTML file we wrote earlier).</p><p>The function takes in two paramters — <strong>responses : </strong>A generator that yields responses from the STT API &amp;<strong> target_language </strong>which inputs the language code. This alongside a character counter (num_chars_printed)to keep track of written results sets up the basis of this function. Here’s how the first if-loop works:</p><ul><li>For every response in the API, check to see if there is a result, if no results are found , continue along with in the API</li><li>result = response.results[0] will extract the first result from the responses</li><li>If the result has no alternatives, then continue to the next response ( if not result.alternatives: continue)</li><li>transcript = result.alternatives[0].transcriptwill extract the first transcription text from the first alternative</li></ul><p>Once this process is done you will log the transcript for debugging in the last line of the above code — logging.info(f”Transcript: {transcript}”)</p><pre> overwrite_chars = &quot; &quot; * (num_chars_printed - len(transcript))<br>        if not result.is_final:<br>            sys.stdout.write(transcript + overwrite_chars + &quot;\r&quot;)<br>            sys.stdout.flush()<br>            num_chars_printed = len(transcript)<br>        else:<br>            print(transcript + overwrite_chars)</pre><ul><li><strong>overwrite_chars </strong>will calculate the number of characters to overwrite based on the difference between the current and previous transcript length</li><li>If the result is not final this will print the existing data in transcript followed by enough spaces to overwrite the previous transcript:</li><li>It will then update num_chars_printed to the length of the current transcript.</li><li>else (meaning the result is final) the code will print the final transcript followed by enough spaces to overwrite the previous transcript.</li></ul><pre> try:<br>   translation = translate_client.translate(transcript, target_language=target_language)<br>   translated_text = translation[&#39;translatedText&#39;]<br>   logging.info(f&quot;Translated Text: {translated_text}&quot;)<br>    socketio.emit(&#39;transcription&#39;, {&#39;original&#39;: transcript, &#39;transcript&#39;: translated_text})<br>  except Exception as e:<br>         logging.error(f&quot;Translation Error: {e}&quot;)<br>          socketio.emit(&#39;error&#39;, {&#39;error&#39;: str(e)})<br>           num_chars_printed = 0</pre><p>The next part of this code will tap into STT &amp; translate and give us the logic necessary to pass our text through the translation APIs — here’s what this code does:</p><p>• the codes tries to translate the transcript using the Translate API.</p><p>• translated_text will then extract the translated text from the translation response.</p><p>• the code then logs the translated text for debugging purposes.</p><p>• It then emits the original and translated text to the client using Socket.IO framework</p><p>• If an error occurs during translation, logs the error and emits an error message to the client and then resets the num_chars_printed variable back to 0</p><p>Now that we have wrote all of our logic that tap into both APIs, we can get started on writing logic that will send all the previous logic to our client which is the web-page we built in the previous section.</p><pre>@app.route(&#39;/&#39;)<br>def index():<br>    return render_template(&#39;index.html&#39;)</pre><p>This piece of code will simply route the code to the proper client which is the URL our console will create once we run the app. Here are what each of the variable means:</p><ul><li><strong>Route</strong>: This route is associated with the root URL (‘/’) of the web app</li><li><strong>Function</strong>: The index function is called when the root URL is accessed.</li><li><strong>Rendering</strong>: The function uses render_template to render the index.html file</li></ul><pre>@socketio.on(&#39;start_stream&#39;)<br>def start_stream(data):<br>    language_code = &quot;en-US&quot;<br>    target_language = data[&#39;language&#39;]<br>    config = speech.RecognitionConfig(<br>        encoding=speech.RecognitionConfig.AudioEncoding.LINEAR16,<br>        sample_rate_hertz=RATE,<br>        language_code=language_code,<br>    )<br>    streaming_config = speech.StreamingRecognitionConfig(<br>        config=config, interim_results=True<br>    )</pre><p>This logic is correlated with the start_stream event with pyaudio — in this code we do the following things:</p><ul><li>This method is triggered when the client starts to stream audio with the start button we created earlier</li><li>Parameters for the data that is being sent is given by the client including the target language that needs to be translated (given by the language_code and target_language variables)</li><li>config this is an instance of speech.RecognitionConfig, which is configured with the <strong>audio encoding</strong>, <strong>sample rate</strong>, and <strong>language code</strong> (these are all variables that we initalized before)</li><li>streaming_config: this is an instance of speech.StreamingRecognitionConfig which is configured with the recognition config and interim results set to true.</li></ul><pre> global mic_stream<br>    mic_stream = MicrophoneStream(RATE, CHUNK)<br><br>    with mic_stream as stream:<br>        audio_generator = stream.generator()<br>        requests = (<br>            speech.StreamingRecognizeRequest(audio_content=content)<br>            for content in audio_generator<br>        )<br>        responses = speech_client.streaming_recognize(streaming_config, requests)<br>        listen_print_loop(responses, target_language)</pre><p>To finish up the mehod —<strong> start_stream </strong>here’s the remaining code we have to build that does the following<strong>:</strong></p><ul><li>Set a global variable called mic_stream that manages the microphone stream across different function calls.</li><li>Initialize<strong> </strong>an instance of MicrophoneStream with the specified rate and chunk size.</li><li>give the mic_stream variable context by adding the with statement and then set the following variables:</li><li><strong>audio_generator </strong>will retrieve the audio data chunk from the microphone stream using the generator method.</li><li><strong>requests</strong> will construct StreamingRecognizeRequest objects for each chunk of audio data.</li><li><strong>responses </strong>will then pass the requests to the STT API and retreive responses</li><li>Then the code will take the final result of <strong>responses and</strong> then pair that with the target_language variable to go through the <strong>listen_print_loop</strong> method we wrote earlier</li></ul><pre>@socketio.on(&#39;audio&#39;)<br>def handle_audio(data):<br>    if mic_stream and not mic_stream.closed:<br>        audio_stream = [data[&#39;audioData&#39;]]<br>        target_language = data[&#39;language&#39;]<br>        requests = (speech.StreamingRecognizeRequest(audio_content=chunk) for chunk in audio_stream)<br>        responses = speech_client.streaming_recognize(streaming_config, requests)<br>        listen_print_loop(responses, target_language)</pre><p>The next client oriented method we have to build is the <strong>handle_audio</strong> method which will essentially handles the audio once audio has been emitted — it handles real-time transcription and translation for us. This is what this function does:</p><ul><li>The method firsts check if mic_stream exists and is not closed.</li><li>It then converts the received audio data into a list: [data[‘audioData’]]</li><li>It will then extracts the target language for translation from the data: data[‘language’]</li><li>requests &amp; responses will both construct and send StreamingRecognizeRequest objects to the STT &amp; Translate APIs and processes the responses using listen_print_loop</li></ul><pre>@socketio.on(&#39;stop_stream&#39;)<br>def stop_stream():<br>    if mic_stream and not mic_stream.closed:<br>        mic_stream.closed = True<br><br>if __name__ == &#39;__main__&#39;:<br>    socketio.run(app, debug=True)</pre><p>The last part of building our back-end is the method <strong>stop_stream </strong>which checks if mic_stream exists and is not closed, it will set mic_stream.closed = True .</p><p>The last part of the code is simply a closer for python apps to allow to run on Flask and run the app in debug mode for development mode.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qfcE34tlsM0DpUDLXiMU0g.png" /><figcaption>running app in vs code</figcaption></figure><p>Now that we have this file done, you can test your app by calling the function python app2.py in the terminal and should get a link to your running app!</p><p>Building this web app was a product of months of research and coming to a conclusion that right now this app can’t be built natively and right now you have to take a couple of loopholes to put this on AVP — So as a designer it got me thinking how this app could look if everything was native to Swift, the STT and Translate APIs!</p><h3>🪞 Designing native UI/UX for visionOS</h3><p>To build up my design skills on top of just development, I wanted to figure out what this application could look like if it was built natively for visionOS, and here’s what I came up with 👇</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/700/1*xIsRaH7SUR8X0VVD3Y4rmw.gif" /></figure><p>In creating this entire end-to-end design application, there were three main steps I took:</p><h4>(1) 🛣️ User Flow</h4><h4><strong>(2) 🎨 Aesthetics</strong></h4><h4>(3) 🔄 Animations</h4><h3><strong>🛣️ User Flow</strong></h3><p>The first step in creating this design concept is just slowly figuring out the user flow from end-to-end like any other app, but the biggest difference in designing XR apps is that user interactions are expanded from just touch to three other inputs:</p><ol><li><strong>Eye Tracking</strong>,</li><li><strong>Hand Tracking</strong></li><li><strong>Voice Control</strong></li></ol><p>More info on user interactions w/ visionOS <a href="https://medium.com/@piram.singh/getting-started-with-visionos-cd55e693e603">here</a></p><p>With that being said, here’s the user flow 👇</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*aB8oRTn_tLgY-T55lHx5aw.png" /><figcaption>UX map</figcaption></figure><p>With this UX map built out and having done some previous<a href="https://www.youtube.com/watch?v=o_vy3cSUChA"> research of similar apps</a> that exist on the market, it was time to figure out the color scheme and the general aesthetic I wanted to create for the app. Let’s dive into figma!</p><h3>🎨 Aesthetics</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wBpKAyJnhau83WWFSGObOw.png" /></figure><p>For this app, I wanted it to feel as native as possible and literally put myself in the shoes as a<em> UX designer at Appl</em>e — so there was only one place I needed to go — the official <a href="https://www.figma.com/community/file/1253443272911187215">figma design library for visionOS</a>.</p><p>Using this guide, I cared about figuring out three key aspects: <br>1. <strong>Primary &amp; Secondary Colors</strong> — the main colors that would be dominant throughout design <br>3. <strong>Text Fonts — </strong>the main font and variations that would be used app-wide<br>4. <strong>Interaction Colors —</strong> the colors that would be used for the interactions like the language drop-down menu.</p><h4><strong>Primary &amp; Secondary Colors</strong></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pubpsLS-nkVUUXYug1MIaA.png" /><figcaption>apple vs SpatialTranslate</figcaption></figure><p>Since the UX flow was based off a <strong>Start Record/Stop Record</strong> framework, I wanted to make the base color of the system red, so I headed to the color section of the guide, and after testing the red, it was too bright for the simulated environment and it was just too alarming of a color.</p><p>I ended up just toning the red down for a darker red that more resembled the “in-studio recording” feeling.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/562/1*TuzoP7PAf-hT3HSg2-6IJA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/974/1*crKCFXu1kJjL1EBiFfEvrw.png" /></figure><p>This became the primary color in the app, and toned down versions of this color became the secondary color in multiple components like the <em>recording circle</em> as that was a secondary portion in the design.</p><h4><strong>Text Fonts</strong></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1008/1*IB0Qj4Cn2GThQBXxj30FDw.png" /><figcaption>text families</figcaption></figure><p>When it comes to text and visionOS, bigger is always better as you are looking for more visibility in XR apps. I kept with native Apple font —<strong> San Francisco</strong> or <em>SF</em>.</p><p>The primary font choice is SF Pro (Bold) for best visibility in all primary areas of the app and the secondary font was SF Pro Display (Regular) for best visibility in secondary areas of the app.</p><h4>Interaction Colors</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*gUhHNGkd28up8_0yT4aOow.png" /><figcaption>language selector &amp; selected language</figcaption></figure><p>The last part in building out the aesthetics for the app are the interaction colors that help the user identify in which state components. Since the main animation is just the <em>drop-down menu</em>, we only need to care about three main states for two components: <strong>the language selector </strong>and <strong>the selected language </strong>(e.g. “English”, “Spanish”)</p><p>For the language selector, there are three states the drop-down can be in:</p><ul><li><strong>Default</strong>: the idle state of the component — will use the hex color of <strong>#463E36</strong> with no transparency as it is layered on more translucent backgrounds that allow light to come through for better layering.</li><li><strong>Hover</strong>: the second state which will occur once the user looks at the component — this is just the default state set at a 75% transparency rate.</li><li><strong>Selected:</strong> the last state is when the language becomes selected, I wanted to mix colors to create something secondary in nature but stands out to show selection — I mixed the native visionOS primary colors with <strong>#8D8686</strong> to create the earth- like tone.</li></ul><p>For the selected language (English), there are three states the component can be in:</p><ul><li><strong>Default: </strong>this is the idle state of the language within the drop-down. I wanted to keep this at high visibility, I used the glass window from the design kit and added a linear gradient of white to make it shine, I used <strong>#FFFFFF</strong> at 0%, 41%, 57%, and 100% to keep it balanced throughout the component.</li><li><strong>Hover: </strong>this is the default state at a 75% transparency, it will occur if the user uses their eyes to look at the component.</li><li><strong>Active: </strong>the active state is simply the default state with some added coloring to create a more “selected” look. The additional colors I used were:<strong> #808080</strong> at a 30% transparency alongside <strong>#8D8686</strong> at 100% to create more of a grey tone.</li></ul><p>Now that these interactions are done — we can take the colors, UX map, and connect them all together with animations to make an end-to-end prototype!</p><h3>🔄 Animations</h3><p>With this design, there are three interactions that need to be created : <strong>buttons</strong>, <strong>typing effect</strong>, and the <strong>drop-down menu</strong></p><h4><strong>Button interactions</strong></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/700/1*L_3x7-mJrfXiBJ2tQ_MIvw.gif" /><figcaption>start/stop button animation</figcaption></figure><p>The first animation we want to create will be with the Start and Stop button interaction — once the start button is pressed, we want the recording screen to appear from the bottom, here’s how I did it 👇</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OnuYb8ZAJ9JCjw1x-j_azA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1002/1*gKuds0UufpCCfh0LmDG8pg.png" /><figcaption>Start Recording to Stop Recording</figcaption></figure><p>Here are the steps you want to take to creating these two different states in design mode: <br>1. <strong>Group the Start Recording button and the recording menu<br>2. Create a component from this group, with the <em>Create Component </em>function </strong>— ( Opt + Cmd + K)<br><strong>3. Hide the recording menu frame from the group<br>4. From the top menu, add a variant to this state </strong>(it’s the icon with the diamond with the plus sign)<strong><br>5. Unhide the record menu<br>6. Reduce the transparency of the button to 75%</strong></p><p>You have the two states created, lets put some interactions to these two variants — lets switch into prototype mode!</p><ol><li><strong>Click on the Start Recording button and click “add interactions” from the right hand-side menu</strong></li><li>Draw a line from the Start Recording button to the Stop Recording button and will want to apply the<strong> </strong>following settings → Input: <strong>Click</strong>, Action: <strong>Change to</strong>, State: <strong>“Stop Recording”</strong> (should be auto selected, but can do this stage manually), Animation: <strong>Smart Animate &amp; Ease Out at 300ms</strong></li><li>Repeat from Step 1 but create the interaction from Stop Recording to Start Recording, ( interactions always travel 2x, once going forward and then backwards)</li></ol><p>Once this is done, we need to finish this by adding the typing effect that is going to be layered on top of this interaction!</p><h4>Typing effect</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cU2zoIJh5KvMFCu7_lhtmA.png" /></figure><p>To create that typing effect from the ground-up, its a lot of work because you have to create two way interactions per letter you want to type out, this is wear the power of plug-ins come handy. After some research — I used the <a href="https://www.figma.com/community/plugin/1258805651488403681/typeff"><strong><em>typeff </em></strong></a><strong>plug-in </strong>to create the super-fast typing effect.</p><p>I simply inputted the <strong>Content, Width, Delay, Variant Name, and the effect type</strong> you want to implement.</p><p>After playing around with the settings to my personal taste and watching <a href="https://www.youtube.com/watch?v=q-6JV3DQ4lk">some videos</a>, I was able to build the component and it auto created<strong> 393 variants</strong> from my content.</p><p>Once the component is created do the following 👇</p><ol><li>Verify the typing effect works, by putting a temporary flow screen</li><li>Place the component outside any frame, and make a copy of it</li><li>Paste the component in the final frame where you are putting final builds!</li></ol><p>Using this knowledge of plug-ins and the techniques we learned previously, it’s time to build the core part of this demo — <strong>the language drop-down menu</strong></p><h4>Drop-down menu</h4><p>The most complex part of this design is building out the drop-down menu because of how many states you need to account for and how many interactions it requires — the best way to learn is to build this from the ground up!</p><p>I used this <a href="https://www.youtube.com/watch?v=WgbiGtPVm8Q&amp;t=2s">youtube video</a> to help me with this — it’s a simple break-down to help you build it but can get complex (if you still reading till here, thank you so much 😊) so here’s a basic breakdown of what you need to do:</p><ul><li><strong>Grouping : </strong>group both components — <strong>language selector</strong> &amp; <strong>selected language</strong> together as a one combined component to then manipulate and create different variants</li><li><strong>Variants</strong>: With a grouped component, there are two main variants you’ll go through creating — <strong>open </strong>or <strong>closed. </strong>For example, if English is the selected language, the menu of the languages will be closed and that will be one variant</li><li><strong>Interactions</strong>: Once all of the variants are created — you’ll begin to connect each of the variants with other variants via interactions that connect everything together — this can tend to be quite confusing so refer to the tips in the<strong> 🔄 Animations</strong> section.</li></ul><p>With the design and the web app created, this project is for the books! If you are still reading up to this point — 🙏🏽 Thank You, almost done here! Creating both the native design and the web app was more work than I had initially expected and took longer than I initially expected due to a lot of trial and error — but I got it done with the help of two main resources:</p><ol><li><strong>🤖 Chat-GPT 4o:</strong> I was at a really big cross-roads of how to develop this app — there were so many different AI — enabled solutions like this github repo —<a href="https://github.com/argmaxinc/WhisperKit"> WhisperKit</a> which allowed you to use CoreML models on the AVP and have transcription/translation. It honestly was too hard for me to use and implement — for me using the latest model of 4o to act as a coding tutor for building a web app was all i needed!</li><li><strong>✨ Figma: </strong>One of the biggest resources and tools that I added into my arsenal in this project was getting better and better at Figma, I’ve grown so familiar with the visionOS design library, it’s making me hungry for creating more and more in figma!</li></ol><p>With this project in the books, it’s been really exciting to explore visionOS and been able to build personalized design strategies for the platform, but I’ve realized it’s time to diversify my design skills with more traditional platforms (Mobile, Web) and other interesting platforms like holograms such as <a href="https://hal51.ai/">Hal51.ai</a>! Stay tuned for my newsletter and upcoming projects that I have down the pipeline!</p><p><em>👋 Hey, i’m Piram and i’m an aspiring UI/UX designer, exploring how AI is changing the design world. connect with me on </em><a href="https://www.linkedin.com/in/piramsingh/"><em>linkedin</em></a><em> to follow me on this journey!</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=cd4482e143a7" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[My first Config! — June 2024]]></title>
            <link>https://medium.com/@piram.singh/my-first-config-june-2024-8963ad8bc8ee?source=rss-37e444058d76------2</link>
            <guid isPermaLink="false">https://medium.com/p/8963ad8bc8ee</guid>
            <category><![CDATA[config]]></category>
            <category><![CDATA[development]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[design]]></category>
            <dc:creator><![CDATA[Piram Singh]]></dc:creator>
            <pubDate>Wed, 10 Jul 2024 19:41:04 GMT</pubDate>
            <atom:updated>2024-07-10T19:41:04.972Z</atom:updated>
            <content:encoded><![CDATA[<h3>My first Config! — June 2024</h3><h4>A recap of my first ever design conference with over 10K designers at moscone center</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Rr25C68YRurqOS-KgbS0dg.jpeg" /></figure><p>I’ve been designing, developing and sharing my work actively for the past 7 months and all that work has led up to this going to Config 2024 — where all the best and brightest designers come to SF to show off their latest and greatest and meet the amazing people in the design community!</p><p>It’s essentially <strong>Disneyland for designers </strong>with so many rides to choose from <strong>the keynote</strong>, <strong>the amazing talks</strong>, <strong>the networking</strong>, and just having a damn good time — Here’s a quick summary of the biggest updates from Figma:</p><ul><li>🤖 <strong>Figma’s AI Model</strong> — that allows designers to do more, here are my favorite features 👇<br>- Figma’s Text-to-Design Model<br>- AI-based Visual Search <br>- Generative Prototyping<br>- Naming Layers</li><li>🪞 <strong>UI3</strong> — a more redesigned, simplistic way to use Figma</li><li>💻 <strong>Improved Dev Mode w/ Code Connect — </strong>making the bridge between engineering and design even closer and easier to work with the development team!</li></ul><p>More about my experience below, hope you enjoy!</p><h3>🎉<strong> The Keynote — the grand opening parade</strong></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GO8zu0MrqYJrvIIMfDYgpA.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*djOVP7I_sh7vNNBMMZuhBw.jpeg" /><figcaption>opening pictures of the keynote</figcaption></figure><p>Day 1 started off with the <a href="https://www.youtube.com/watch?v=n5gJgkO2Dg0&amp;list=PLXDU_eVOJTx402DljIPagaDKLibF-qfF0">Keynote </a>where they announced a slew of new features that ranged from a redesigned UI, enhancements to dev mode, figma slides and of course — Figma AI. Now you can read up on all of the cool minute upgrades , but here’s what made my jaw drop from the Keynote:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/700/1*R1JB4lT4oe1qqm_sAr6hxw.gif" /><figcaption>figma’s text-to-design model</figcaption></figure><ul><li><strong>Figma’s Text-to-Design Model: </strong>they unveiled<a href="https://twitter.com/jsngr/status/1284511080715362304"> jordan singer’s </a>idea to the whole figma community reaching a whole new wave of users! Now while Figma AI is going through a hiatus right now, I think it’s interesting to see how this Design LLM get’s evolved over time with mediums like spatial UXs being adapted!</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/700/1*okQthjPiqeAJ8kv2n2QYDw.gif" /><figcaption>visual search</figcaption></figure><ul><li><strong>Visual Search: </strong>this AI feature really just blew me away as it really previews a future problem I might encounter as a UX designer working with large design system libraries!</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/700/1*6XrVhSZAzkTslhhPV7fpUA.gif" /><figcaption>generative protoyping</figcaption></figure><p><strong>Generative Prototyping: </strong>as I keep working on new projects in figma and designing more complex interactions, the hardest job for me is the “noodling” — dragging from component to component to build something more interactive. This is going to be a time-saver!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/700/1*9YCegB9Z83IZBP9eltjJng.gif" /></figure><p><strong>Naming Layers: </strong>The biggest pop at Config defenitely goes to the naming layers feature as it is literally the biggest headache, but the best quality of life feature I think Figma has ever released — thank you so much 😊</p><p>After the keynote, I embarked on going on the thrills and the big attracations which were the talks by some of the greatest companies like Apple, Humane, Roblox and more!</p><h3><strong>🎢 Amazing Talks — the thrills and big attractions</strong></h3><p>There was a lot of these big thrill rides from amazing different companies, here are the ones that stood out to me:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SWwpWTrqNUKl_zT3nypVkA.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Fp0e5B661RuM3BzIiTJN2g.jpeg" /><figcaption>peter yang’s talk</figcaption></figure><p><a href="https://www.youtube.com/watch?v=GJJU7enXSRc"><strong>Product Management by Peter Yang @ Roblox</strong></a><strong> — </strong>this talk was filled with so many product managers as it was simple and straight forward: 10 key strategies to help you become a better product manager. My long-term goal is to really become a product manager to help UX designers shine These were his key tactics to follow:</p><ol><li><strong>Building with the community — </strong>build your product with the community through actively creating online communities for consumers to get together</li><li><strong>Feel the customer’s pain — </strong>actively do customer discovery to feel what the customers are feeling (be on that journey with them)</li><li><strong>Look Up &amp; Around</strong> — Always be sure to really look at the big picture from your perspective (as the PM) and the customer’s perspective.</li><li><strong>Strategy = focus —</strong> your primary as a PM should be primarily just be strategy</li><li><strong>Quality and Speed over scope — </strong>you can iterate on scope, start small and ship fast.</li><li><strong>Craft quality product vs. docs — </strong>PMs get in this habit of crafting beautiful documentation, always focus on product, product, and more product!</li><li><strong>Protect your craft time —</strong> spend less time in meetings and talking, have deep-work set aside for your craft as a PM.</li><li><strong>Set the quality bar —</strong> The PM is the one who sets the quality of work engineers, designers, and others have to deliver to.</li><li><strong>Use AI to focus on what matters</strong> — Use AI for the small stuff so you can focus on your craft.</li><li><strong>Remember why you got into this field for the first place!</strong></li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*c3vWQo9Q0x5U4LdzDCXxiA.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6F16FGjd89t_kiX9dZCnxg.jpeg" /><figcaption>nan yu’s talk</figcaption></figure><p><a href="https://www.youtube.com/watch?v=I4vvBidQcck">t<strong>he heirlooom tomato org chart by Nan Yu @ Linear</strong></a> — this talk surprised me this most, it was definitely meant for an exec but I gained so much as I hunt for my first job!</p><p>My main takeaways here are the following:</p><ul><li>there are three key main areas in creating a successful org chart : <strong>🔭 Scope</strong>, <strong>📏 Size,</strong> and<strong> 📐 Shape</strong></li><li>Resist symmetry and hierarchy — org charts need to resemble the the product development process — uneven and non-linear.</li><li>Always over-provision more people on what the most important task at hand</li><li>Distribute your younger employees across the org, don’t clump them up so that they can work on high-impact projects as well as see how well formed teams work</li><li>This is a hard problem to solve — every team is going to have something different based on their size, shape, and scope</li></ul><p>Why did I find this so intresting? It was such a well-designed presentation and gave me something to add to my current tool box that was not AI or design related.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*0iMyBN8lZiU0sXd9" /><figcaption>linda dong — credit to <a href="https://twitter.com/seven11nash/status/1806093873028227173">Marc Muller on Twitter</a></figcaption></figure><p><strong>Spatial Computing by Linda Dong &amp; Mike Stern @ Apple:</strong> this talk was just nostalgia, it went back to my old blog posts and highlighted some old blog posts that I had written about getting started with visionOS!</p><p>They really touched on how they were re-inventing design from the ground up to be the industry leaders in designing a revolutionary UX from a realistic perspective, incorporating elements of skeuomorphism like they did with the earliest versions of macOS and iOS!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Jax_x9tzHDjGi-pUJsv9RQ.jpeg" /><figcaption>lenny’s podcast live</figcaption></figure><p><a href="https://www.youtube.com/watch?v=yJQYBjto41s&amp;t=1198s"><strong>Lenny’s Podcast Live w/ Dylan Field from Figma</strong></a><strong> — </strong>One of my goals for the past couple of months is to start thinking for myself and part of that proces is reassesing the type of content you interact with on a daily basis — one of the first pieces of content that I really like to tune into is Lenny’s Podcast — He has a slew of smart people and asks insightful questions that are specific to the guest’s personal life and something you can’t just get from googling! Seeing this interaction at the tail end of the conference was just so refreshing to see and tapped more in Dylan’s thought process as the CEO of Figma!</p><h3><strong>🤝 Networking — the really cool character encounters</strong></h3><p>I’ll be honest, when I walked into the conference room on the first Day, it was super overwhelming — 10 thousand of the smartest people in the design community was just super daunting, but after settling I was able to find way just to talk to people, here were the coolest people I met:</p><p><a href="https://medium.com/u/9e444bbe698f">Nava Babaei</a> — an old friend who was with her HCI Master’s Program from Carnegie Mellon University — <em>Thank you for reconnecting and introducing me to your cohort!</em></p><p><a href="https://medium.com/u/80e5a43dd59b">Zander Whitehurst</a> — the founder and one of the legendary teachers of memorisely, one of the reasons I got into design — <em>Thank you for listening to my design journey and talking more about AVP and Edtech!</em></p><p><a href="https://www.linkedin.com/in/mrosenzweig/">Matt Rosenzweig </a>— a design engineer at peacock who is building amazing things for user testing and other functions for the streaming service! <em>Thank you for an amazing conversation about talking AVP and the future of media consumption!</em></p><p><a href="https://www.linkedin.com/in/heysaik/overlay/about-this-profile/?lipi=urn%3Ali%3Apage%3Ad_flagship3_profile_view_base%3BtKoebgOjStqfp9aQEC5Tcw%3D%3D">Sai Kambampati</a> — a software engineer at Humane where we had an amazing conversation on the future of design for a screenless future! <em>Thank you for the amazing talk on humane’s design and where we see the company going in the future!</em></p><p>Here are some more photos from the conference (one of them show my coolest exp — using a R1 &amp; Humane AI Pin 👀)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*T8q9rwCe6fCJ3j8EN7m2QQ.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0TSKBag6GywQ1j5aJb9-Tg.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/768/1*Tgpk1VfXveJjDMN9kYEhhg.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mYggtoAKBnXWvoe31X4Dqw.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9NpmXeBVnO277uU76BBurw.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/768/1*WE9EujBTS5nhqT2dMTpmWg.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*x01G0JJZiDVs-DK_nDti0Q.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/768/1*teXzuUBdE8QdcmcyhrT3lQ.jpeg" /></figure><h3>👀 What’s Next ?</h3><p>In the next couple of months, here’s what I got planned…</p><ol><li>🗣️<strong> Ship Translate Project : </strong>Shipping my long-awaited project in the next week is my number 1 priority right now!</li><li><strong>🗂️ Portfolio Website: </strong>I’ve built so much since January, my next project is creating a high-quality website to show off my hard work.</li><li><strong>✨ Building a Hologram: </strong>I recently went to a meet-up at Studio 55 where they were showing off some new developments in AI * Product Design, where I got my hands on the <a href="https://hal51.ai/">LemurBox</a> from Hal51.AI — if you have ideas, hit me up!</li></ol><p><em>👋 Hey, i’m Piram and i’m an aspiring UI/UX designer, exploring how AI is changing the design world. connect with me on </em><a href="https://www.linkedin.com/in/piramsingh/"><em>linkedin</em></a><em> to follow me on this journey!</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8963ad8bc8ee" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[First Vision Pro Residency @ f.inc — March 2024]]></title>
            <link>https://medium.com/@piram.singh/first-vision-pro-residency-f-inc-march-2024-46f53aa579c9?source=rss-37e444058d76------2</link>
            <guid isPermaLink="false">https://medium.com/p/46f53aa579c9</guid>
            <category><![CDATA[residency]]></category>
            <category><![CDATA[growth]]></category>
            <category><![CDATA[build-in-public]]></category>
            <category><![CDATA[vision-pro-ar]]></category>
            <dc:creator><![CDATA[Piram Singh]]></dc:creator>
            <pubDate>Thu, 14 Mar 2024 06:22:37 GMT</pubDate>
            <atom:updated>2024-03-14T06:22:37.649Z</atom:updated>
            <content:encoded><![CDATA[<h3>First Vision Pro Residency @ f.inc — March 2024</h3><h4>A reflection on building my first visionOS app!</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*EvmkloHHyqMnMlvoySb42A.jpeg" /></figure><p>Since late 2023, I aspired to get a role in UI Design — building figma mockups, talking to user groups, creating prototypes &amp; more — but I was then questioned with this:</p><blockquote>“How do you prepare yourself to be a designer for the next 10 years ?”</blockquote><p>From that question, I started to do a deep dive on how design would change in the next 10 years with AI, wearables, and different forms of a more natural UX! I wrote about that initial journey <a href="https://piramsingh.substack.com/p/what-does-the-next-iphone-look-likewithout">here</a>.</p><p>From that initial post, I kept digging and digging to find the answer to that question and naturally found myself curious about the Vision Pro as the mechanism to create more meaningful and natural user experiences and designs that were powered by AI. That jolt of excitement made me immediately start writing about it where I <a href="https://medium.com/@piram.singh/getting-started-with-visionos-cd55e693e603">broke down the design and exploring what the future of the device was.</a></p><p>From that I built two replicate projects — <a href="https://medium.com/@piram.singh/exploring-space-with-visionos-78a766949573">🚀 Immersive Space</a> &amp; <a href="https://medium.com/@piram.singh/building-an-ai-assistant-for-vision-pro-b261939d8907">🤖 SpatialGPT</a> and from those experiences — I really wanted to build something from the ground up and thats how where I found about <a href="https://f.inc/">Founder’s Inc</a> (f.inc), a high-caliber incubator where companies such as these are founded:</p><ul><li><a href="https://fluid.so/"><strong>🥽 Fluid</strong></a> — virtual workstations for productivity (available on quest)</li><li><a href="https://buildspace.so/">🧱 <strong>buildspace</strong></a><strong> — </strong>building ideas from the ground up in six weeks ($10 mil raised)</li><li><a href="https://www.wisdolia.com/"><strong>🌳 Wisdolia</strong></a><strong> —</strong> creating AI enabled flashcards for more personalized learning (200k users)</li></ul><p>f.inc was hosting a residency program for 30+ of the best developers to come to SF for a four-week program to build the most ambitious apps for the vision pro and potentially be like one of the portfolio companies raising millions of dollars and growing like crazy — this was a historic event for the XR space.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DIDlisgcWqPHzsfPvwjdIQ.jpeg" /><figcaption>day 1 breakfast kick-off</figcaption></figure><p>The day I walked in on for the kick-off breakfast and just shocked at the amount of experience there was in the room and the ambition to build some epic stuff.</p><p>Here are some of the standouts of the community:</p><ul><li><a href="https://www.linkedin.com/in/krcnow/">Ravi Krishnan</a> (10+ years) : developer from India, built two apps before the residency even started and came out as one of the fastest builders every week</li><li><a href="https://medium.com/u/2a92a9c763fd">Ethan Sherbondy</a> (10+ years): CTO and co-founder of Betafi — made two games with in the residency (Mahjong &amp; Dueal Space_ and made the highest amount of revenue from the cohort</li><li><a href="https://www.linkedin.com/in/devoncopley/">Devon Copley</a> (10+ years) : Co-founder of Avatour — a VR camera and meeting productivity suite for better real-time collaboration in all sorts of settings.</li></ul><p>Just being in the same room as these amazing individuals, it sparked some amazing ideas that led me on a journey that I am really excited to keep building on!</p><h3>🛣️ The Journey at f.inc</h3><p>A couple days into the residency program, I was sitting in the break room when Ethan &amp; Ravi were eating their breakfast and just having a conversation about vision pro &amp; the intersection of language learning, education, and VR — and it led to this crazy idea where you immerse yourself in any part of the world….</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*ontJut5ljxlBBo5Z.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/540/0*C1DXb_odKpnGcXrc.jpg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*C32cpChxV8pYZf05.jpg" /><figcaption>🇮🇹, 🇮🇳, 🇫🇷</figcaption></figure><p>and interact with anyone to learn a language! It would have been the most personalizable and immersive way to learn languages instead of playing with a gamified model to get points — you’d actually get to learn for the situations you might encounter on a business trip, meeting family, or even a leisurely trip!</p><p>From this wild idea, I really wanted to see what a scoped down version could be in something achievable in four weeks. This led me to figuring out to creating an app that would do live transcriptions and translations natively on vision pro and also figuring out a UX to create a tri-lingual communication app by utilizing mixed reality…</p><h3><strong>✏️ Designing a new UX</strong></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QHU3hvZ2WlMSBjYWL6QkBQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*y_n2Ju9iMG4oivHMbMpgbw.gif" /><figcaption>before &amp; after</figcaption></figure><p>With this design thought experiment in creating a tri-lignual expereince, I started out just by simply drawing out scenarios in GoodNotes and seeing what needed to be true and eventually went on a quest for finding a spatial design tool similar to figma that had all the elements I was really looking for and came across <a href="https://www.bezi.com/">bezi.com</a> and started building this environment out, here are the components:</p><ul><li><strong>Animated Orb</strong>: A mixed reality component that would act as the <strong>conversation visualizer </strong>for your chat with different colors signifying different languages that are being spoken</li><li><strong>Identifier Cards: C</strong>ards that show beside your name with your name and the language you are currently speaking</li><li><strong>Translation Cards: </strong>Each speaker will get their own caption card with the current language being spoken (greyed out) and their language being displayed in a more prominent white text.</li><li><strong>Chat History: </strong>An iMessage style screen, where users can see chat history and the languages that were being spoken in the chat.</li></ul><h3><strong>🗣️Live Transcriptions &amp; Translations</strong></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ylcnR_hCjLPy52C-Lozi7Q.png" /><figcaption>attempts at solving at back-end using google STT api. more from the presentation <a href="https://docs.google.com/presentation/d/1s9_OYtalzFKt3ER6IrGamAxsdmkpq3r4s2guBLtNaMw/edit?usp=sharing">here</a></figcaption></figure><p>The second component of my goal was creating a live transcription and translation application that could be used natively for Vision Pro — I researched a multitude of different API’s and honestly had some trouble coding the back-end as the interoperability of these Speech — To-Text (STT) APIs with Swift was not compatible</p><p>That being said, one of my better attempts was utilizing <a href="https://github.com/grpc/grpc-swift">this github repo</a> to model a google STT on the vision pro</p><p>That being said, I am still working on this side and switching gears over to <a href="https://github.com/argmaxinc/WhisperKit">this WhisperKit github repo</a>!</p><h3><strong>👀 What’s Next?</strong></h3><p>Here’s what you can expect from me in the next upcoming months…</p><ul><li><strong>🧑🏻‍💻 DreamXR Hack:</strong> I really loved my experience w/f.inc that I am going to their hackathon in partnership with Meta to build something even super cool</li><li>🤝<strong> Meta Quest : </strong>At this hack, I am going to change things up and actually build something with the Quest platform and see if this is something I like working with and seeing what the difference is between the development of AVP and Quest!</li><li>🗣️ Translate App: I’m going to ship a scoped down version of polyglot.vr — and ship a real time bi-lingual translation app and see how many users I can get!</li></ul><p><em>👋 Hey, i’m Piram and i’m an aspiring UI/UX designer, exploring how AI is changing the design world. connect with me on </em><a href="https://www.linkedin.com/in/piramsingh/"><em>linkedin</em></a><em> to follow me on this journey!</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=46f53aa579c9" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Building an AI Assistant for Vision Pro!]]></title>
            <link>https://medium.com/@piram.singh/building-an-ai-assistant-for-vision-pro-b261939d8907?source=rss-37e444058d76------2</link>
            <guid isPermaLink="false">https://medium.com/p/b261939d8907</guid>
            <dc:creator><![CDATA[Piram Singh]]></dc:creator>
            <pubDate>Thu, 01 Feb 2024 14:39:13 GMT</pubDate>
            <atom:updated>2024-02-07T10:10:32.530Z</atom:updated>
            <content:encoded><![CDATA[<h4>a guide about creating SpatialGPT- An AI Voice Assistant for the the Apple Vision Pro!</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Xz9GSPRZtxeCOXz2ai8uQQ.jpeg" /></figure><p>Apple just released the Vision Pro and it’s literally about to change the way we have high quality experiences — think of immersive tours, games, and educational experiences, business use cases — the ideas are limitless with Vision Pro and were only getting started.</p><p>Why does the release of a VR headset making so much noise? Because it’s Apple. Their commitment to high quality user experiences are always the first thing to mind with any product throughout the product development cycle. They were the first ones in the space to release a VR headset that has:</p><ul><li><strong>Eye Tracking as the main cursor for selection for screens</strong></li><li><strong>Micro-OLED screens for 4K resolution screen</strong></li><li><strong>Use of Hands &amp; Voice as main input</strong></li></ul><p>Now this being said, I’ve thought about a number of ideas in my head in ways I can really innovate with the Vision Pro to push the boundaries. To illustrate this, i’m going to take you on a quick journey.</p><p>Let’s say hypothetically, my cousin was coming to the Bay Area to visit me and he wanted to see different American museums around the country.👇</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*ePBiv9RW6HFqb10E.jpg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*ZATidpEm7f6Rb-rG.jpg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*pEdPGJ46Ohlqa4On.jpg" /><figcaption>nyc moma, art institute of chicago, &amp; smithosonian air museum in DC</figcaption></figure><p>Now, building immersive experiences for my cousin to hop from museum to museum would be really cool! — but i’ve also realized that just simply being immersed can feel static. That’s why I’ve been building in visionOS to integrate an <em>interactive assistant</em> using OpenAI’s API.</p><p><em>Now back to the story…</em></p><p>My cousin’s favorite piece of art is <em>Starry Night</em> by Vincent Van Gogh — This is currently at NY Moma and he would really like to visit this and actually get more information about the painting, but he wants his answer to be in Hindi! Watch below ⬇️</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2F5WY94iw3Usc%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D5WY94iw3Usc&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2F5WY94iw3Usc%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/e34e8a381e2f01e2175b02ef096f64cc/href">https://medium.com/media/e34e8a381e2f01e2175b02ef096f64cc/href</a></iframe><blockquote><em>🤯 Just from asking that simple question to chat in a virtual space, my cousin’s</em><strong><em> mind was blown</em></strong><em>.</em></blockquote><p>That was a quick demo of SpatialGPT, Let’s dive deeper and show you how I built this app from the ground up!</p><p>We can split the project into four main sections:</p><h4><strong>(1) 🛠️ Project Set-Up</strong></h4><h4>(2)👨🏽‍💻 Back-End Algorithms</h4><h4><strong>(3) 🎙️ Front-End Design</strong></h4><h4><strong>(4)🤖 Integrating OpenAI’s API</strong></h4><h3><strong>🛠️ Project Set-Up</strong></h3><p>After we click “new project” in Xcode, we want to set up four key areas for the project:</p><ul><li><strong>Connecting to OpenAI</strong></li><li><strong>Interoperability between iOS, macOS, and visionOS</strong></li><li><strong>Importing Siri Waveform UI</strong></li><li><strong>Screen Standardization</strong></li></ul><h4><strong>Connecting to OpenAI</strong></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*GrhelCjfmUYm_CG_awZUMg.png" /><figcaption>connecting to the OpenAI API</figcaption></figure><p>To connect to OpenAI, we simply need to click on the project name and on the left-hand side, click the project name that has the word “TARGETS” bolded on the top. Click on “Outgoing Connections (Client)” in Network. In Hardware, select “Audio Input”.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_xq5LFWN0Du9Rm_LkUFCiw.png" /><figcaption>privacy property</figcaption></figure><p>We also want to add a privacy property on the info tab of this window. You can label it “Talk with AI Assistant” for the value.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MTsCM3__UajPPheyahezSg.png" /><figcaption>Importing OpenAI API</figcaption></figure><p>To import the API we PROJECTS Tab &gt; Package Dependencies. Add this link : <a href="https://github.com/alfianlosari/XCAOpenAIClient">https://github.com/alfianlosari/XCAOpenAIClient</a>. You could also search “XCAOpenAIClient”</p><h4><strong>Interoperability between iOS, macOS, and visionOS</strong></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lZHecYRpPdPzQYNKK4AhhQ.png" /><figcaption>iOS, macOS, and visionOS</figcaption></figure><p>Go back to the “TARGETS” page &gt; General &gt; Supported Destinations. Make sure to add Apple Vision, iPhone, iPad, and Mac for easier testing than the simulator (it can be quite slow).</p><p>Some other things to remeber here: For vision pro, your Mac must be on the new silicon than intel based. Your Xcode should be 15.2 or higher (this includes the current visionOS SDK!)</p><h4><strong>Importing Siri Waveform UI</strong></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VB9yumVfmRQC7PKJQyg06Q.png" /><figcaption>importing siri waveform UI.</figcaption></figure><p>One of the biggest tasks in the front-end of the code will be controlling the speed of waveform animations in the response state of the assistant. To do this (&amp; honestly make our lives easier), we are going to import the UI from another git hub repo.</p><p>Use the same steps as the one for Chat but add this link instead: <a href="https://github.com/alfianlosari/SiriWaveView">https://github.com/alfianlosari/SiriWaveView</a> or search up “SiriWaveView”. With the packages installed in our Xcode project, we also want to set some screen standardization for the app in what developers call the “App File”</p><h4>Screen Standardization</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Dkxo-SxjjousXiwH4YRxoQ.png" /></figure><p>When we open Xcode, we are going to see a file on the right handside with our app name — open that up and we are going to set some screen standardization based on the OS the app is running on!</p><pre>@main<br>struct XCAAiAssistantApp: App {<br>    var body: some Scene {<br>        WindowGroup {<br>            ContentView()<br>            #if os(macOS)<br>                .frame(width: 400, height: 400)<br>            #endif<br>        }<br>        #if os(macOS)<br>        .windowStyle(.hiddenTitleBar)<br>        .windowResizability(.contentSize)<br>        #elseif os(visionOS)<br>        .defaultSize(width:0.4,height:0.4,depth:0.0,in:.meters)<br>        .windowResizability(.contentSize)<br>        #endif<br>    }<br>}</pre><p>In this initial set-up code, we are passing in ContentView(), which will hold our front-end design and setting up conditional compilation statements to set certain things based on the OS!</p><p>The first one essentially says is that if the app is being run on macOS set the frame of the app to a width of 400 pixel and a height of 400 pixels. The second statements tells the program to hide the title and keep the windows to <em>.contentSize </em>(an Apple standard in SwiftUI) if on macOS.</p><p>If on visionOS, have the window size by 0.4 m x 0.4 m x 0.0 m and the same <em>.contentSize </em>standard for window resizability.</p><p>With our packages installed &amp; operating systems optimized , let’s move into the first part of coding — building out the back-end algorithms!</p><h3>👨🏽‍💻 Back-End Algorithms</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qbhkCAnjcoMW4O-_IxhB9g.jpeg" /><figcaption>back-end design</figcaption></figure><p>To set up the back-end for the application, we’ll create a file called ViewModel.swift which will store variables and functions that our algorithms will be stored in so that our app will be able to use TTS and communicate with OpenAI for a controlled system!</p><p>This being said, ViewModel.swift is split up into three main sections:</p><ul><li><strong>Imports &amp; ViewModel Setup</strong></li><li><strong>Variables</strong></li><li><strong>Functions</strong></li></ul><h4><strong>Imports &amp; ViewModel Setup</strong></h4><pre>import AVFoundation<br>import Observation<br>import Foundation<br>import XCAOpenAIClient</pre><p>To setup ViewModel, we need to import four different libraries — <em>AVFoundation </em>(AV Player Framework — check out my work <a href="https://medium.com/@piram.singh/programming-spatial-audio-for-vr-a1540fe3a0df">here</a> on this), <em>Observation</em>( a type-safe framework that allows for an observable to be called), <em>Foundation </em>( framework for all of Swift), and <em>XCAOpenAIClient </em>(the package we imported in the last section)</p><pre>@Observable<br>class ViewModel: NSObject, AVAudioRecorderDelegate, AVAudioPlayerDelegate{</pre><p>The next step is to call the macro of observable and create the class ViewModel() with a couple of attributes — <em>NSObject</em> (will serve as a bridge to old objective-c protocols), <em>AVAudioRecorderDelegate (</em>protocol that allows for audio recording and encoding), and <em>AVAudioPlayerDelegate </em>( protocol that allows for audio playing)</p><h4><strong>Variables</strong></h4><pre>    let client = OpenAIClient(apiKey: &quot;ENTER API KEY HERE&quot;)<br>    var audioPlayer: AVAudioPlayer!<br>    var audioRecorder: AVAudioRecorder!</pre><p>The first set of variables is <em>client</em>, <em>audioPlayer</em>, and <em>audioRecorder </em>which passes in your own API Key (you have to get this from chat gpt developer’s site: look <a href="https://medium.com/@pawan329/how-to-generate-chat-gpt-api-key-daace2acc032">here</a> for a step-by-step tutorial by <a href="https://medium.com/u/f766e9984444">Pawan Yadav</a>!), a AVAudioPlayer data type and a AVAudioRecorder data type w/optional statements denoted by the !</p><pre>#if !os(macOS)<br>    var recordingSession = AVAudioSession.sharedInstance()<br>    #endif<br>    var animationTimer: Timer?<br>    var recordingTimer: Timer?<br>    var audioPower = 0.0<br>    var prevAudioPower: Double?<br>    var processingSpeechTask: Task &lt; Void,Never&gt;?</pre><p>The second segment of the code starts with a compile statement saying that if the OS is not macOS than intialize a variable called <em>recordingSession</em> of type <em>AVAudioSession.sharedInstance() </em>which allows for the app to optimize the audio source and find the nearest one. For example, when using the visionOS simulator, sharedInstance allows for the app to tap into my mac’s mics.</p><p>The next variables are <em>animationTimer</em> &amp; <em>recordingTimer</em> which are of type <em>Timer</em> and an optional variable denoted by the ‘?’ The other variables are <em>audioPower,</em> <em>prevAudioPower</em>, and<em> processingSpeechTask</em>. The first two pass in an audio number in the form of a decimal point and a Double optional to be used for the following functions. The latter passes in a Task type which refers to work done asychronously by the app. The<em> Void, Never</em> paramters ensure that the task is non-failing and has no return value.</p><pre> var selectedVoice = VoiceType.alloy<br>    <br>    var captureURL: URL {<br>        FileManager.default.urls(for: .cachesDirectory, in: .userDomainMask)<br>            .first!.appendingPathComponent(&quot;recording.m4a&quot;)<br>    }<br>    var state = VoiceChatState.idle {<br>        didSet { print(state) }<br>    }<br>    var isIdle: Bool {<br>        if case .idle = state {<br>            return true<br>        }<br>        return false<br>    }</pre><p>The third segment of variables is where it get’s a little more tricky, (but I got your back!)</p><p>There are four variables in this set: <em>selectedVoice</em>, <em>captureURL</em>, <em>state</em>, &amp; <em>isIdle . </em>Here’s what they do:</p><p>(1) <strong>selectedVoice is making a default VoiceType variables of case alloy (this is coming from chat-gpt)</strong></p><p><strong>(2) captureURL is returning a URL that is capturing the sound recording of your query into file called recording.m4a</strong></p><p><strong>(3) state is returning the app’s state, passing in VoiceChatState.idle as the default.</strong></p><p><strong>(4) isIdle is a boolean that checks if the state of the app is Idle or not</strong></p><pre> var siriWaveFormOpacity: CGFloat {<br>        switch state {<br>        case.recordingSpeech, .playingSpeech: return 1<br>        default: return 0<br>            <br>        }<br>        <br>    }</pre><p>The last variable of the back-end is <em>siriWaveFormOpacity </em>which will allow us to present a virtual cue if the person is speaking or not. If the state is <em>.recordingSpeech </em>or <em>.playingSpeech, </em>the opacity will be 1, or else it will default to 0.</p><p>With all these variables we can start building out our functions!</p><h4>Functions</h4><pre>    func resetValues(){<br>        audioPower = 0<br>        prevAudioPower = nil<br>        audioRecorder?.stop()<br>        audioRecorder = nil<br>        audioPlayer?.stop()<br>        audioPlayer = nil<br>        recordingTimer?.invalidate()<br>        recordingTimer = nil<br>        animationTimer?.invalidate()<br>        animationTimer = nil<br>    }<br>}</pre><p>The first function is <em>resetValues —</em> sets all variables to <em>0</em>, <em>nil</em>, <em>.stop</em>, or <em>.invalidate .</em></p><pre>    func audioRecorderDidFinishRecording(_ recorder: AVAudioRecorder, successfully flag: Bool) {<br>        if !flag {<br>            resetValues()<br>            state = .idle<br>        }<br>    }<br>    <br>    func audioPlayerDidFinishPlaying(_ player: AVAudioPlayer, successfully flag: Bool) {<br>        resetValues()<br>        state = .idle<br>    }</pre><p>The next two functions check if the user’s recording finished &amp; and if the audio player finished playing chat’s message! Both functions pass in the <em>resetValues() </em>function and set the <em>state</em> to idle.</p><pre>    func cancelRecording(){<br>        resetValues()<br>        state = .idle<br>    }<br>    func cancelProcessingTask(){<br>        processingSpeechTask?.cancel()<br>        processingSpeechTask = nil<br>        resetValues()<br>        state = .idle<br>    }</pre><p>The third segment of functions are used to cancel the recording and to cancel the processing task when the query is sent to ChatGPT! Both functions will pass in <em>resetValues() </em>and<em> </em>set the state to idle. (We’ll set up the processing task function in the last section of blogpost!)</p><pre> func playAudio(data:Data) throws{<br>        self.state = .playingSpeech<br>        audioPlayer = try AVAudioPlayer(data: data)<br>        audioPlayer.isMeteringEnabled = true<br>        audioPlayer.play()<br>        <br>        animationTimer = Timer.scheduledTimer(withTimeInterval: 0.2, repeats: true, block:{ [unowned self]_ in<br>            guard self.audioPlayer != nil else {return}<br>            self.audioPlayer.updateMeters()<br>            let power = min(1, max(0,1-abs(Double(self.audioPlayer.averagePower(forChannel: 0))/160) ))<br>            self.audioPower = power<br>        })<br>        <br>        <br>    }</pre><p>The next function is 1 of 2 what I call “main functions” that has the most math involved. playAudio first passes in the <em>state</em> variable to be <em>.playingSpeech. </em>It then sets up 3 lines of code for the audioPlayer object. It will first pass in the data being sent from Chat-GPT, enable metering (shows the audio waves for the answer), and then plays the audio.</p><p>The algorithm for the timer is as follows: the timer will parse through this block of code every 0.2 seconds to do the following:</p><ul><li><strong>checks if the audioPlayer is still running or not</strong></li><li><strong>updates the audio’s metering data based on the incoming file</strong></li><li><strong>calculates a normalized value for the audio power level and then setting it in a range from 0–1 to easily track the audio power.</strong></li></ul><pre> func startCaptureAudio() {<br>        resetValues()<br>        state = .recordingSpeech<br>        do{<br>            audioRecorder = try AVAudioRecorder(url: captureURL,<br>                                                settings: [<br>                                                    AVFormatIDKey: Int(kAudioFormatMPEG4AAC),<br>                                                    AVSampleRateKey: 12000,<br>                                                    AVNumberOfChannelsKey: 1 ,<br>                                                    AVEncoderAudioQualityKey: AVAudioQuality.high.rawValue<br>                                                    <br>                                                ])<br>            audioRecorder.isMeteringEnabled = true<br>            audioRecorder.delegate = self<br>            audioRecorder.record()</pre><p>Here is the other main function — <em>startCaptureAudio(). </em>We’ll start the function by going through and adjusting the settings for the audioRecorder variable. We’ll pass in captureURL, and specific settings for the AVFormat.</p><p>We’ll also keep updating the audioRecording settings with .<em>isMeteringEnabled,</em> .<em>delegate</em>, and .<em>record</em>.</p><pre> animationTimer = Timer.scheduledTimer(withTimeInterval: 0.2, repeats: true, block:{ [unowned self]_ in<br>                guard self.audioRecorder != nil else {return}<br>                self.audioRecorder.updateMeters()<br>                let power = min(1, max(0,1-abs(Double(self.audioRecorder.averagePower(forChannel: 0))/50) ))<br>                self.audioPower = power<br>            })<br>            recordingTimer = Timer.scheduledTimer(withTimeInterval: 1.6, repeats: true, block: {[unowned self]_ in<br>                guard self.audioRecorder != nil else {return}<br>                self.audioRecorder.updateMeters()<br>                let power = min(1, max(0,1-abs(Double(self.audioRecorder.averagePower(forChannel: 0))/50) ))<br>                if self.prevAudioPower == nil {<br>                    self.prevAudioPower = power<br>                    return</pre><p>We’ll also set two different timers that do the same thing above in the article! The only difference to note here between the two functions:</p><ul><li><strong>The recording timer is monitoring the audio power of the query as it comes in and code is being executed 1.6 seconds instead of 0.2 seconds</strong></li><li><strong>The denominator in the normalized power algorithm is 50 instead of 160</strong></li><li><strong>We are also analyzing audioPower in different times, hence the variable of prevAudioPower.</strong></li></ul><pre>  if let prevAudioPower = self.prevAudioPower, prevAudioPower &lt; 0.25 &amp;&amp; power &lt; 0.175 {<br>                    self.finishCaptureAudio()<br>                    return<br>                }<br>                self.prevAudioPower = power<br>                 <br>            })<br>        }catch {<br>            resetValues()<br>            state = .error(error)<br>            <br>        }<br>    }</pre><p>The last part of this function before heading into <em>finishCaptureAudio</em> is to run a quick test to check to see if the prevAudioPower is less than 0.25 and power is less than 0.175, to then pass through the <em>finishCaptureAudio</em> function!</p><pre>func finishCaptureAudio() {<br>        resetValues()<br>        do {<br>            let data = try Data(contentsOf: captureURL)<br>            processingSpeechTask = processSpeechTask(audioData: data)<br>        }catch {<br>            state = .error(error)<br>            resetValues()<br>        }<br>    }</pre><p>The last part in the capturing audio phase is <em>finishCaptureAudio(). </em>This will convert the captured audio data and pass it into the processingSpeechTask which will send the audio to Chat!</p><pre>override init() {<br>        super.init()<br>        #if !os(macOS)<br>        do {<br>            #if os(iOS)<br>            try recordingSession.setCategory(.playAndRecord, mode: .voiceChat, options: [.defaultToSpeaker, .allowBluetooth])<br>            #else<br>            try recordingSession.setCategory(.playAndRecord, mode: .spokenAudio)<br>            #endif<br>            try recordingSession.setActive(true)<br><br>            recordingSession.requestRecordPermission { [unowned self] allowed in<br>                if !allowed {<br>                    self.state = .error(&quot;Recording not allowed by the user&quot;)<br>                }<br>            }<br>            <br>        } catch {<br>            state = .error(error.localizedDescription)<br>        }<br>        #endif<br>    }</pre><p>The last function to know before we get into designing the front-end of the application is more about security &amp; and an override init if the shared instance does not work.</p><p>If the OS is IOS, the app will default to <em>.voiceChat</em> mode via the speaker and allow bluetooth connections. If the app is not running in iOS, it will default to <em>.spokenAudio . </em>The app will also always ask for record permission regardless of OS.</p><p>With the main functions, variables, and packages, we can start implementing the User Interface!</p><h3><strong>🎙️ Front-End Design</strong></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1020/1*VGnmgkUDsABW5onbz1YVKQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/716/1*CKQqVE01YJwiTNLER1PCDA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/708/1*YFeg1E32Vdmxo1ZU7f7B4Q.png" /><figcaption>general progression of the app</figcaption></figure><p>To set up the front-end, there are two swift files we have to create — <strong>Models &amp; Content View</strong></p><h4>Models.swift</h4><p>This file is an input for <strong>ContentView</strong> and the back-end. Writing these out is a going to be a big time-saver in writing back-end and front-end code.</p><p>Let’s get started below with this file 👇</p><pre>import Foundation<br><br>enum VoiceType: String,Codable,Hashable,Sendable,CaseIterable {<br>    case alloy<br>    case echo<br>    case fable<br>    case onyx<br>    case nova<br>    case shimmer<br>}</pre><p>First thing to note here, Models is a swift file because we are not actually coding any user interface — we are just setting up some variables and cases to refer back to.</p><p>In the first enum or enumeration, VoiceType — we set 6 cases for 6 different voices (alloy, echo, fable, onyx, nova, &amp; shimmer) that are being imported from the Text-To-Speech (TTS) API. (We imported this in the project set-up phase if you’re confused.)</p><pre>enum VoiceChatState {<br>    case idle<br>    case recordingSpeech<br>    case processingSpeech<br>    case playingSpeech<br>    case error(Error)<br>}</pre><p>The second enum is setting up the different States for the application which is VoiceChatState. There are five different cases that this app could be in — idle (resting state), recordingSpeech (recording the user’s speech), processingSpeech (using TTS to send to Chat GPT), playingSpeech(the answer or query is being read out) and an error state.</p><p>With this down, let’s jump into <strong>ContentView.swift</strong></p><h4>ContentView.swift</h4><p>When we start this file, we want to import the following libraries as this is going to be the basis for the front-end design of the application:</p><pre>import SwiftUI<br>import SiriWaveView</pre><p>The next step is to initialize previews with the different states, starting from <strong>case error:</strong></p><pre>#Preview (&quot;Error&quot;) {<br>    let vm = ViewModel()<br>    vm.state = .error(&quot;An error has occured&quot;)<br>    return ContentView(vm: vm)<br>}</pre><p>In the error case, we set the variable vm to ViewModel() and call in the function vm.state = .error(“An error has occured”)</p><p><strong>case playingSpeech:</strong></p><pre>#Preview (&quot;Playing Speech&quot;) {<br>    let vm = ViewModel()<br>    vm.state = .playingSpeech<br>    vm.audioPower = 0.3<br>    return ContentView(vm: ViewModel())<br>}</pre><p>The playingSpeech preview initializes the variable vm as ViewModel(), sets the state of vm = .playingSpeech ( from models.swift), audioPower to 0.3 (audio variable for the power of the audio input), and a return statement to ContentView.</p><p><strong>case processingSpeech:</strong></p><pre>#Preview (&quot;Processing Speech&quot;) {<br>    let vm = ViewModel()<br>    vm.state = .processingSpeech<br>    return ContentView(vm: vm)<br>}</pre><p>The processingSpeech preview is the same format as before, the only change is we set the state of the preview to . processingSpeech, and no audioPower variable needs to be changed here.</p><p><strong>case recordingSpeech:</strong></p><pre>#Preview (&quot;Recording Speech&quot;) {<br>    let vm = ViewModel()<br>    vm.state = .recordingSpeech<br>    vm.audioPower = 0.2<br>    return ContentView(vm: vm)<br>}</pre><p>The recordingSpeech preview is the same format as before, only changes are to the state, and the audioPower level decreased by 0.1.</p><p><strong>case idle:</strong></p><pre>#Preview (&quot;Idle&quot;) {<br>    ContentView()<br>}</pre><p>The idle preview just passes in ContentView() to show the app in the idle state.</p><p>With previews set for an easier dev process, let’s design the UI of the application!</p><pre>struct ContentView: View {<br>    @State var vm = ViewModel()<br>    @State var isSymbolAnimating = false</pre><p>We are going to go back to the top of the file after our import lines and initialize a <em>struct</em> called ContentView and start with two <em>State </em>initializers (marking the variables with <em>State</em> initializers allows the user to see more accurate information) — <em>vm</em> and <em>isSymbolAnimating</em>.</p><p>These two variables will come in handy as we will need to pass in <em>ViewModel() </em>heavily in the front-end and the <em>isSymbolAnimating</em> boolean allows us to properly control the animation for the brain icon when the TTS file is sent to OpenAI for processing. Let’s move to the overall layout of the app!</p><pre> var body: some View {<br>        VStack(spacing: 16){<br>            Text(&quot;XCA AI Voice Assistant&quot;)<br>                .font(.title2)<br>            Spacer()<br>            SiriWaveView()<br>                .power(power: vm.audioPower)<br>                .opacity(vm.siriWaveFormOpacity)<br>                .frame(height:256)<br>                .overlay{ overlayView }<br>            <br>            Spacer()</pre><p>In this part of the code, we’ll give the set the title of the app, and pass in the <em>SiriWaveView()</em> and give them both some modifiers. The most important to note here are that for the <em>.power </em>modifier, we’ll pass in ViewModel’s audioPower variable and for the <em>.opacity </em>modifier, we’ll pass in ViewModel’s siriWaveFormOpacity variable.</p><pre>            switch vm.state {<br>            case .recordingSpeech:<br>                cancelRecordingButton<br><br>            case .processingSpeech, .playingSpeech:<br>                cancelButton<br><br>            default:EmptyView()<br>            }</pre><p>This segment of the code is to insert switch statement that will pass certain buttons to different states of the app. The next step is to create the voice picker at the bottom of the home screen!</p><pre>  Picker(&quot;Select Voice&quot;, selection: $vm.selectedVoice) {<br>                ForEach(VoiceType.allCases,id: \.self){<br>                    Text($0.rawValue).id($0)<br>                }<br>            }<br>            .pickerStyle(.segmented)<br>            .disabled(!vm.isIdle)<br>            <br>            if case let .error(error) = vm.state {<br>                Text(error.localizedDescription)<br>                    .foregroundStyle(.red)<br>                    .font(.caption)<br>                    .lineLimit(2)<br>            }<br>        }<br>        .padding()<br>    }</pre><p>This segment will create a picker at the bottom of this VStack and passes in all the VoiceTypes we initialized in ViewModel() and Models.swift. This code also has an if loop to format the error message if there is an issue with the app!</p><p>With this settled, let’s get to creating our overlay buttons for different states!</p><p><strong>cancelButton</strong></p><pre> var cancelButton: some View {<br>        Button(role: .destructive){<br>            vm.cancelProcessingTask()<br>        }label: {<br>            Image(systemName:&quot;stop.circle.fill&quot;)<br>                .symbolRenderingMode(.monochrome)<br>                .foregroundStyle(.red)<br>                .font(.system(size: 44))<br>        }.buttonStyle(.borderless)<br>    }<br>    <br>}</pre><p>The first button is the cancelButton which will cancel the query anytime after the recording ends till chat finishes your answer. The button utilizes ViewModel’s cancelProcessingTask function to work properly end to end.</p><p><strong>cancelRecordingButton</strong></p><pre> var cancelRecordingButton : some View {<br>        Button(role: .destructive) {<br>            vm.cancelRecording()<br>        }label: {<br>            Image(systemName:&quot;xmark.circle.fill&quot;)<br>                .symbolRenderingMode(.multicolor)<br>                .font(.system(size: 44))<br>        }.buttonStyle(.borderless)<br>    }</pre><p>The second button is the cancelRecordingButton which will cancel any recording from the time you hit the mic and it sends the file to chat. The button utilizes ViewModel’s cancelRecording function to get it to work properly end to end.</p><p><strong>startCaptureButton</strong></p><pre> var startCaptureButton: some View {<br>        Button{<br>            vm.startCaptureAudio()<br>        }label:{<br>            Image(systemName:&quot;mic.circle&quot;)<br>                .symbolRenderingMode(.multicolor)<br>                .font(.system(size: 128))<br>        }.buttonStyle(.borderless)<br>    }</pre><p>The last button is the startCaptureButton which starts the voice query from the user. The button utilizes ViewModel’s startCaptureAudio function to get it to work from end -to- end! With the last button made, we can animate the brain!</p><pre>@ViewBuilder<br>    var overlayView: some View {<br>        switch vm.state{<br>        case .idle,.error:<br>            startCaptureButton<br>        case .processingSpeech:<br>            Image(systemName:&quot;brain&quot;)<br>                .symbolEffect(.bounce.up.byLayer, options: .repeating, value: isSymbolAnimating)<br>                .font(.system(size: 128))<br>                .onAppear{ isSymbolAnimating = true}<br>                .onDisappear{isSymbolAnimating = false}<br>        default: EmptyView()<br>        }<br>    }</pre><p>The final part of the front-end design is to animate the brain screen to signify that the voice query is being processed by OpenAI! We start this code by making sure that this part of the code is before all the buttons we made earlier (make sure to work backwards for the UI). We’ll intialize <em>ViewBuilder</em> to allow for multiple types of UI components can fit on 1 view. We’ll then initialize a view variable called <em>overlayView </em>with a switch statement for the brain animation to only take place during .<em>processingSpeech.</em></p><p>For the brain animations the modifiers to look out for is .<em>symbolEffect </em>and pass in the boolean, <em>isSymbolAnimating</em>, for the <em>value </em>parameter. We also want to pass in <em>.onAppear</em> and <em>.onDisappear</em> and set the boolean accordingly.</p><p>With the back-end &amp; front-end done, let’s go back to ViewModel to input the OpenAI Integrations!</p><h3><strong>🤖 Integrating OpenAI’s API</strong></h3><pre>   func processSpeechTask(audioData: Data) -&gt; Task&lt;Void, Never&gt; {<br>        Task {@MainActor [unowned self] in<br>            do {<br>                self.state = .processingSpeech<br>                let prompt = try await client.generateAudioTransciptions(audioData: audioData)<br>                <br>                try Task.checkCancellation()<br>                let responseText = try await client.promptChatGPT(prompt: prompt)<br>                <br>                try Task.checkCancellation()<br>                let data = try await client.generateSpeechFrom(input: responseText,voice: <br>                        .init(rawValue: selectedVoice.rawValue) ?? .alloy)<br>                <br>                try Task.checkCancellation()<br>                try self.playAudio(data: data)<br>                <br>            }catch{<br>                if Task.isCancelled {return}<br>                state = .error(error)<br>                resetValues()<br>            }<br>        }<br>    }</pre><p>If you made it all the way down here — 🙏🏽 thank you and we are almost done!</p><p>The last part of the project is to go back into our back-end file (ViewModel.swift) and create a function called <em>processSpeechTask. processSpeechTask</em> will do the following:</p><ul><li>pass in the <em>state </em>to be .<em>processingSpeech</em></li><li>generate an audio transcription, prompt ChatGPT, and generate Speech to take the app through TTS &amp; ChatGPT and back to SpatialGPT.</li><li>Use the selected voice as an audio input source from Whisper, which is built into ChatGPT.</li></ul><p>Now with the coding done, you can run the app, test, and debug any issues that might have come up!</p><p>That being said, I used a lot of different resources with this coding process, here are the best ones I got to give credit to:</p><p>(1) ⏯️<strong> The Youtube Video</strong>: I used this as a guide for the app. followed every single line of code he wrote in <a href="https://www.youtube.com/watch?v=2Lpb9k9XeAA&amp;t=757s">this</a> video.</p><p>(2)<strong> 👨🏽‍💻 Swiftful Thinking</strong> : I used <a href="https://www.youtube.com/@SwiftfulThinking">this</a> youtube channel to better understand swiftUI this time around so it would be a faster time to coding.</p><p>(3) <strong>🤖 SwiftGPT: </strong>Used a new custom gpt called SwiftGPT from the gpt store that was much more refined when it came to explaining concepts in swift!</p><p>While building this, my own curiosity and ambition has led me to think of different ways I can really push the boundaries with visionOS. One of the greatest ideas I’ve had ever since this journey started was always something at the intersection of Music + VR. For those who know me personally, they know sikh music or <em>gurmat sangeet </em>has been a big part of my life…..</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*J0uxadhDrktOWkCo1S_sIg.jpeg" /><figcaption>harmonium AI coach 👀</figcaption></figure><p>So, what if I could create an AI coach integrated w/ visionOS that could teach you instruments like the <em>harmonium </em>guitar hero style! This idea does not stop there, you could build out AI coaches + Mixed Reality Interfaces for a whole host of skills such as:</p><ul><li>Learning how to build something off of an IKEA booklet</li><li>Learning how to cook something off of a Youtube Video</li><li>Learning how to paint something off of an old bob ross videos</li></ul><p>With all these ideas in my head &amp; meeting more amazing people in the visionOS dev community, I’ve been really happy to get some amazing opportunities such as f.inc’s vision pro residency starting tomorrow &amp; the first AI + Vision Pro Hack in SF this weekend hosted by <a href="https://medium.com/u/8c3cd9f310f5">michael raspuzzi</a>! I’m super excited to keep building in this space and just stay tuned for what comes next 👀</p><p><em>👋 Hey, i’m Piram and i’m an aspiring UI/UX designer, exploring how AI is changing the design world. connect with me on </em><a href="https://www.linkedin.com/in/piramsingh/"><em>linkedin</em></a><em> to follow me on this journey!</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b261939d8907" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Transfer Functions — ITD, ILD, and HRTFs with Applications in Swift]]></title>
            <link>https://medium.com/@piram.singh/programming-spatial-audio-for-vr-a1540fe3a0df?source=rss-37e444058d76------2</link>
            <guid isPermaLink="false">https://medium.com/p/a1540fe3a0df</guid>
            <category><![CDATA[spatial-audio]]></category>
            <category><![CDATA[hrtf]]></category>
            <category><![CDATA[sound]]></category>
            <category><![CDATA[apple]]></category>
            <category><![CDATA[vr]]></category>
            <dc:creator><![CDATA[Piram Singh]]></dc:creator>
            <pubDate>Tue, 30 Jan 2024 23:22:47 GMT</pubDate>
            <atom:updated>2024-01-30T23:47:46.338Z</atom:updated>
            <content:encoded><![CDATA[<h4>a deep dive of the algorithms behind spatial audio, it’s applications for VR headsets, and how we can code such algorithms.</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*tiqb0KjC8zuQqkErO3Lpig.png" /></figure><p><em>Ignoring the math behind spatial audio for VR is like ignoring user research for great product design — let’s dive deep into spatial audio!</em></p><p>Now to really understand the math behind HRTFs and spatial audio, I explored the realm of audio and came to these key ideas:</p><ul><li><strong>Spatial Audio or 3D Audio is recorded as normal (2D) audio and then converted into spatial audio through a number of <em>post-production processes</em>.</strong></li><li>The main algorithms behind these post-production processes are:<br>- <strong>Interaural Level Difference (ITD)</strong><br>- <strong>Interaural Time Difference (ILD)</strong><br>- <strong>Head Related Transfer Functions (HRTFs)</strong></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*D4XndifGBLW9tvPZMUDOWQ.jpeg" /></figure><h3><strong>⌛️ Interaural Time Difference (ITD)</strong></h3><p>The first method is called Interaural Time Difference or ITD is a sound localization cue and this method is measured in terms of time. In easier terms, <strong>the ITD is the difference in arrival time of a sound between two ears</strong>.</p><p>With <strong>ITD</strong>, we can use that number to delay a sound from ear to ear, causing a 3D environment to be formed in the listener’s head.</p><p>More on it’s applications later, Let’s dive into the math 👇</p><p><strong><em>(rθ + r sin θ) / c</em></strong></p><p><strong>r</strong> = radius of the listener’s head</p><p><strong><em>θ </em></strong><em>= </em>the angle of from where the sound source is coming from(also known as the azimuth)</p><p><strong>c</strong> = speed of the sound wave (mainly calculated in meters/second)</p><p>With this formula in mind, let’s do a quick example just to show you how this could be applied in post-production or coding.</p><p><strong>Step 1: Setting <em>θ</em></strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*S-XkXjXMZEsP--uKHDEtQQ.jpeg" /></figure><p>In the example above, the listener’s sound source is coming from behind them, so if you go back to trig and unit circle — the sound source sits directly at 180° which needs to be converted into radians ,so <em>θ = π </em>. Here’s a list of main sound angles you can memorize if solving for ITD:</p><ul><li><strong>0 Degrees (0 Radians) Azimuth</strong>: Directly in front of you.</li><li><strong>90 Degrees (π/2 Radians) Azimuth</strong>: To your right.</li><li><strong>180 Degrees (π Radians) Azimuth</strong>: Directly behind you.</li><li><strong>270 Degrees (3π/2 Radians) Azimuth</strong>: To your left.</li></ul><p><strong>Step 2 : Setting r &amp; c</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fkwtMdqMemMlgJzimpSoDA.jpeg" /></figure><p>The next step is to set our r &amp; c variables. In these two cases, I took the average diameter of the human head ,<strong>18 cm </strong>and<strong> divided it by 2 </strong>to get a<strong> radius of 9 cm. </strong>After that, you need to convert centimeters to meters as our c variable is in terms of meters/second. That being said, <strong>r = 0.09.</strong></p><p>In setting our c, the average sound of speed is 343 meter/second so <strong>c = 343</strong>.</p><p><strong>Step 3: Solving the equation</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Kq5sU0rehEoA5NyTxRdHTQ.jpeg" /></figure><p>The last step to this example problem is solving the equation, here it should be pretty simple to understand but here’s a quick explanation of the work:</p><ol><li>Solve <em>0.09 sin (π). sin(π) = 0,</em> therefore the entire expression equals 0</li><li>Solve 0.09 π , this equals 0.282743</li><li>divide by 343 (this our sound speed, we express the answer in m/s) = 0.00082 m/s</li></ol><p>Just from this solution alone — we can state that the ITD at this point in space (behind the listener’s head) is really small that the listener’s ability to hear this delay is probably minimal and will make a very marginal difference in the overall listening experience.</p><p>… But, if we combine <strong>ITD</strong> numbers with <strong>ILD</strong> numbers — the combination make for a solid cost effective post production process that allow for some pretty good audio experiences. Let’s dive into <strong>ILD!</strong></p><h3><strong>🔊 Interaural Level Difference (ILD)</strong></h3><p>ILDs on the other hand from ITDs are far more complex and varying equations that rely a lot of anatomical knowledge of the ear — and we’ll get to one of those methods with HRTFs, but if you need to know one thing about ILD’s, it’s this: <strong>the difference in loudness and frequency distribution between the two ears.<br></strong><em>ILD’s will essentially allow you to understand in which ear is sound louder or quieter and help you determine where the sound originated from.</em></p><p>With that in mind, let’s get to the math 👇</p><p>ILD functions have many different interpretations and many variations as there are an infinite amount of factors when calculating sound density. From my research, the best formula that takes the overall phenemona which include the sound angle (azimuth) and the frequency is:</p><p><strong>ILD = 0.18 √f sin(<em>θ)</em></strong></p><p>Let’s take the same model from above and find the ILD of those conditions:</p><p><strong>Step 1: Setting θ &amp; f</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dd7Ocog4nNsubBBeANLfBw.jpeg" /></figure><p>In this example, we are using a slightly modified version of the last model, instead of calculating speed of the sound, we look at the frequency of the sound measured in Hz.</p><p>For θ, we keep it to<strong> π radians </strong>as the distance has not changed. For f, I went with <strong>432 hz</strong> as that sound allows for “Enhanced Clarity” in the mind.</p><p><strong>Step 2: Solving the equation</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*V0JFCJOuv5bSD5W47Nsv1g.jpeg" /></figure><p>an ILD of 0 dBs, I was confused too — but here’s a property of ILDs you should know:</p><ul><li>There is no level difference when sound waves are in front or behind you. Meaning when θ = 90° (π/2) or 180° (π), ILD should always equal 0</li><li>The effects of an ILD will increase once your azimuth(θ) hits 45° (π/4).</li></ul><p>That being said, let’s see what happens when we replace π with π/4 👇</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*i8jGjB9J-ljyzu6K-KAvPg.jpeg" /></figure><p>Now look how useful this is — we are able to see that just by changing the positioning of the sound source we are able to get a better delay in the intensity of the sound — creating a better environment.</p><p>This being said, ILDs and ITDs are very good algorithms to utilize when post producing audio but they only scratch the surface and can visually only give us what happens to the ears. If we want to add more precise spatial tracking — we need to study<strong> HRTFs or Head Related Transfer Functions.</strong></p><h3>👦🏽 Head Related Transfer Functions (HRTFS)</h3><p>The last method and most important to understand is the Head Related Transfer Function. To understand this equation we need to understand the following parts:</p><ul><li><strong>Understanding Laplace Transforms</strong></li><li><strong>Understanding Transfer Functions</strong></li></ul><p><strong>Laplace Transforms</strong></p><p>Laplace transforms are the key to understanding how a transfer function works. Laplace functions allows us to convert a function in the time domain (t) into a function into the frequency domain (s). It’s also heavily used to convert differential equations into algebraic expressions. (<em>it’s a tool that makes equations easier to understand</em>) Here’s the formula to focus in on:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sCXniMBupOcIrnSVG8FJRA.jpeg" /></figure><p>Essentially the laplace transform , <em>L{f(t)} </em>is an improper integral (because the max limit is infinity) where you multiply the function <em>f(t) * e^-s *t. </em>This last part is where you convert from the time domain into the frequency domain.</p><p>That being said, I needed to learn more and actually do some practice problems to understand the concept. As said in definition up top, one of the uses is to convert differential equations into algebraic expressions. Here’s an example I worked through :</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vchIhvh58tTeFwCOrWakog.jpeg" /></figure><p>In this example we start out with a basic differential equation you might find in a calculus class. We then apply the notation of the Laplace Transform by isolating the y’s and taking the coefficients out. In the next slide, were going to use that rule to replace the first and second derivatives into an easier expressions.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*nnZ4NRMlqkg6pjnTiViF9A.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lcmr8g2Tlu1fZYOXIKKXtA.jpeg" /></figure><p>In the second and third steps — we simplify all the parts of the equation to be Laplace Form so we can then manipulate to an algebraic form.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*aPoUJj3ByyM-RN8Ora7nFQ.jpeg" /></figure><p>Now, we have it in laplace form, remember we had those two variables in the first step where <em>y(0) = 2</em> and <em>y’(0) = 3. </em>Take a look at the equation where we can now substitute those values in and further simplify.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IQVczxDoW1iiJdZdgjwgiQ.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*u5kHQLOE9HEhpe-KF5qnjQ.jpeg" /></figure><p>In this fifth &amp; sixth step, the second part to doing these Laplace Transforms is Partial Fractions (something you probably learned in Algebra 1/2). Essentially, we’ve hit the most simplified version of the equation where we have to do a factor of the dominator and find A and B.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ze--1SSmSgFF4Ttsifn92w.jpeg" /></figure><p>In this step, we can plug back in A &amp; B, 9 and -7, to the simplified equation. Now here’s where Laplace functions flow back in — L{e^at} = 1/s-a. We essentially have that in our answers but just the opposite integer. We can use this rule, do a little bit of pattern matching and land on an answer where the equation where L{y} = 9L{e^-2t}- 7L{e^-3t}</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4F22SnvxGTFNVuOHaFLFPw.jpeg" /></figure><p>In the last step, we just solve for Y and the Laplace transform essentially cancels out and gives us the expression for Y, which is <em>Y = 9e^-2t -7e^-3t.</em></p><p>With the fundamentals of the Laplace functions understood, we can get a deeper understanding behind the mechanics of <strong>transfer functions</strong>.</p><p><strong>Understanding Transfer Functions</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*j0UL1azE94-lIo7zjljORg.jpeg" /></figure><p>Transfer functions are simply this, take any engineering system you know and it is a comparison of the output and the input to understand how the system works. Let’s use an example to illustrate this:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VClosKqVLIp5IEq07_cFMQ.jpeg" /></figure><p>Let’s say we have a airplane, an airplane is a pretty complex system with multiple sub-systems. The transfer function will allow to take 1 input and 1 output and find any causality between only those two variables. For example, we could use a transfer function to explain causality between the rudder of the aircraft (input) and the angle of attack (output). This is really good example to help you learn more about the system as a whole —<a href="https://www.youtube.com/watch?v=Uh_-RZQIaEs"> see the full video to get more info.</a></p><p>Let’s go through a quick example problem of a transfer function:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KfvYBKe-pI5pbPTinzhhag.jpeg" /></figure><p>In this example, we are going to a look at very common example problem that many engineers are known to — the mass &amp; spring problem. In the drawing above we are trying to compare our input, <em>u(t)</em> which is the <strong>force the mass is being pushed</strong> at and output, <em>y(t), </em>which is the position the mass ends up at. There is also the constants k and c for the spring and the dampener. We essentially use a basic equation of motion to derive the differential equation for the system.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*V9OHoQT7x2QZX-fURZJuWA.jpeg" /></figure><p>In the second step we take out the constants and apply the Laplace transform notation and get ready to substitute the y’s for TF Differential Theorem. There are two key things to note here:</p><ul><li><strong>Transfer Functions convert variables in the time domain (t-domain) to the frequency (s-domain)<br>-<em> </em></strong><em>Here’s a quick explaination on the two domains: The time domain is where most of our reality goes through; things we can see. The frequency domain is stuff we can’t see and really the frequency of sounds &amp; their amplitudes. More on this </em><a href="https://www.youtube.com/watch?v=piIujfV3Nsw&amp;t=68s"><em>here</em></a><em>.</em></li><li><strong>The intial conditions of the system always need to equal zero. This is so that the mathematical model we get is an objective view of the relationship between output and input.<br></strong>-<em> These are denoted in the equation by y(0) and y’(0)</em></li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AGpKf-tS6jaj-JJLSg-TmA.jpeg" /></figure><p>In the third step we convert every part of the Laplace Transform using the differential theorem and into the s-domain.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7m0jwURhUDKkpyGyQ8xoCQ.jpeg" /></figure><p>In the fourth step we set the initial conditions to zero and simplify to solve the equation for G(s), which is Y(s)/U(s) → 1/(ms² + cs + k). Now this is cool and all, but we really need to visualize this transfer function to see what a hypothetical situation could be like. To do this, let’s use Mathematica, a tool by WolframAlpha!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/908/1*1YYo-9-i1sZHV81I2ar08g.png" /></figure><p>So to create a more realistic solution, I’ve set some constants for m, c, &amp; k and solve it with those variables in mind.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*C_vdcGbpAQMhrNMeNnzdSA.png" /></figure><p>The next step is to set our U(s), which I am taking the Laplace transform of a unit step (a concept in a physics) which is 1/s. We use that as an input to solve for Y(s) and the output is an equation.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*T1ksH-sJVtmaZ9RLarnDKA.png" /></figure><p>Everything so far is converting from time domain to the frequency domain, to visualize the graph we need to convert it back into the time domain so us (humans) can explicitly see the causality. To do this we use the InverseLaplaceTransform call to convert the equation and we are left with a graphable equation.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mcgvTqu4bg1f7K-xdhC-0Q.png" /></figure><p>This is the plotted graph for time to be in a range of 0 to 10. We can see the causality between our force and the end position. Now that being said, I was curious how does the graph looked like for HRTFs and here’s what I found:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*uAuaPjkhdojxo7FL.png" /></figure><p>Here’s some conclusions we can come to with these graphs:</p><ul><li><strong>The causality that these graphs are four- dimensions. The two main inputs and the control variable are: Frequency being compared with Normalized Magnitude of a sound wave.</strong></li><li><strong>The changing variables of these graphs is at the azimuth of the sound source and which ear the sound is being hit at.</strong></li><li><strong>These graphs are the result of very expensive testing that is highly specific to a listener’s ear size, head size, and general upper body shape.</strong></li></ul><p>HRTFs have no 1 specific equations that can be stated as fact because of how highly specific &amp; customized the process is. Many companies try to not use specialized HRTFs and take averages of lower-cost solutions such as ILDs and ITD to create immersive audio experiences. With this in mind, I wondered if there are companies creating HRTF innovations to help programmers integrate spatial audio into their applications…</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*p4X6gIzcGySwcwiN0XrMSA.png" /></figure><p>and that’s when I came across this <a href="https://www.patentlyapple.com/2021/09/apple-won-a-major-spatial-audio-patent-last-week-covering-head-related-transfer-function-hrtf-maps.html">patent</a> by Apple that is building out innovative virtual HRTF maps for programmers and users to create better spatial audio and signs of this is showing up in Swift libraries.</p><h4>👨🏽‍💻 HRTFs and Spatial Audio in Swift</h4><p>We’ve learned about all these algorithms — there are multiple ways these algorithms are applied: music production, speaker production, software applications (spotify, apple music), and VR audio experiences.</p><p>As someone who is passionate about programming in Swift, i’ll explain how we can see some of these in swift:</p><p><strong>AVAudioEnvironmentNode</strong></p><pre>class AVAudioEnvironmentNode : AVAudioNode</pre><p>AVAudioEnvironmentNode is inherited from AVAudioNode class which connects to old apple frameworks that were built in objective-c (an older apple programming language)</p><p>There are some structure &amp; variables that directly relate to this class as they can relate to the three algorithms:</p><p>To set your positional properties for spatial audio environment, we can use the following code:</p><pre>var listenerPosition: AVAudio3DPoint { get set }</pre><p>You set the the listener’s position in the space (in terms of meters).</p><pre>var listenerAngularOrientation: AVAudio3DAngularOrientation { get set }<br>var listenerVectorOrientation: AVAudio3DVectorOrientation { get set }</pre><p>These two variables allow for the user to make a more detailed approach where the the listner is sitting. It uses a x-y-z plane to plot a certain point where the user is. AngularOrientation allows to control to see at what angle the user is place, VectorOrientation allows to move the vector of the listener’s location across the environment. A change in one of them will correspond a change in the other.</p><p>The default values of AngularOrientation sits on the -z axis has (0°, 0°, 0°)</p><p>The default values of VectorOrientation sits on the -z axis and can be moved a forward vector by inputting (0, 0, -1) and an up vector by inputting (0, 1, 0)</p><p>AVEnvironmentAudioNode helps in setting up positional properties, there are more properties in Swift that directly integrate HRTFs.</p><p><strong>AVAudio3DMixingRenderingAlgorithm</strong></p><pre>enum AVAudio3DMixingRenderingAlgorithm : Int, @unchecked Sendable</pre><p>An enum in AVAudio Framework is AVAudio3DMixingRenderingAlgorithm where there are multiple cases that the users can pass through their apps:</p><pre>case auto<br>case equalPowerPanning<br>case HRTF<br>case HRTFHQ<br>case soundField<br>case sphericalHead<br>case stereoPassThrough</pre><p>We really care about three cases in this enum HRTF,HRTFHQ, &amp; sphericalHead</p><p>In the first one, case HRTF, we set case HRTF = to an integer that allows us to set the map of the listener in a HRTF environment. This code is integral in creating more personalized HRTF maps for VR environments.</p><p>In case HRTFHQ , this allows for more accurate mapping and sound localization in audio rendering. It still requires an integer to pass through the code as in the previous one.</p><p>The last case is case sphericalHead which simulates a 3D environment for headphone users and can implement interaural time delays. More likely than not this code has algorithms such as <strong><em>(rθ + r sin θ) / c </em></strong>built in the back-end of swift.</p><p><strong>What’s the main difference between these three?</strong> Well, it’s pretty simple — To build a HRTF map of a user, the cases — HRTF,HRTFHQ are more CPU intensive and more customizable but cost more money.</p><p>Most VR companies tend to go with programs that utilize parameters along the lines of case sphericalHead because they are easier to calculate and are cost effective.</p><p><strong>If you read all the way through and still confused, here’s a summary what we just learned:</strong></p><ul><li>Spatial Audio is the key to building immersive &amp; amazing VR applications</li><li>There are three key algorithms behind Spatial Audio: ITDs, ILDs, and HRTFs</li><li>ITDs measure the difference in time when a sound travels from one source to both ears</li><li>ILDs are more complex algorithms that measure the decibel difference between a sound hitting both of your ears</li><li>HRTFs are highly specific functions that are graphed to explain where and how hard a sound is hitting you. Apple is already building innovative ways for developers to include HRTF maps in their code.</li></ul><p><em>👋 Hey i’m Piram and i’m an aspiring UI/UX designer, exploring how AI is changing the design world. connect with me on </em><a href="https://www.linkedin.com/in/piramsingh/"><em>linkedin</em></a><em> to follow me on this journey!</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a1540fe3a0df" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[AI for Vision Pro!]]></title>
            <link>https://medium.com/@piram.singh/ai-for-vision-pro-29923a5a9d43?source=rss-37e444058d76------2</link>
            <guid isPermaLink="false">https://medium.com/p/29923a5a9d43</guid>
            <dc:creator><![CDATA[Piram Singh]]></dc:creator>
            <pubDate>Mon, 15 Jan 2024 01:47:13 GMT</pubDate>
            <atom:updated>2024-01-15T01:47:13.942Z</atom:updated>
            <content:encoded><![CDATA[<h4>an update on my latest vision pro project</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3bTQqsNd2GOoET7lWY9Ejw.png" /></figure><p>As I continue to build my next project, here’s a short update of what I’ve accomplished and what is next:</p><ol><li><strong>Learning SwiftUI</strong></li><li><strong>Exploring AI + XR</strong></li><li><strong>Project Update</strong></li></ol><h4>Learning SwiftUI</h4><p>During the start of this journey, I was always really opposed to Frontend Engineering because I had it stuck in my head that I wanted to become a designer and all I needed to learn was figma. I think Frontend engineering might be my jam!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*X-m6SovIMyxC00i6EsPWeA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Z1PFxTRGtyB0ORfU0YzChg.png" /></figure><p>I spedrun a course by <a href="https://www.youtube.com/@SwiftfulThinking">Swiftful Thinking</a> on SwiftUI and foundmyself loving the language as it was easy to learn, logical to me, and I didn’t see myself being frustrated after every 1/2 an hour.</p><p>I have more to go, but this made me really curious about a potential career in Front-end engineering.</p><h4>Exploring AI + XR</h4><p>I wanted to keep my next project to be with the Vision Pro and keep building up my skills in Swift and Coding in general — here’s some of the videos and rabit holes I went down 👇</p><p>🚀<a href="https://www.youtube.com/watch?v=Ox_eN-k0Z2k"> Building on my last project about Rockets and Immersive Areas</a></p><p><a href="https://github.com/barisozgenn/NetflixVisionPro">⏯️ Netflix XR App</a></p><p>🚗 Self Driving Car Projects</p><p><a href="https://www.youtube.com/watch?v=2Lpb9k9XeAA&amp;t=3551s">🤖 ChatGPT4 in VisionOS, iOS, &amp; macOS</a></p><p>After that research was done, I wanted to stay relevant + level up my skills from the last project, the last project was a clear winner.</p><h4>Project Update</h4><p>Here’s what’s been going well and some things I’m noticing:</p><ul><li><strong>Coding Faster: </strong>I am coding at a much quicker rate than I thought, the reps I’ve got with the last project + the SwiftUI course is doing me wonders!</li><li><strong>UI Coding</strong>: The UI implementation was really easy this time around after doing the course — everything made sense this time around.</li><li><strong>ChatGPT&gt; Phind : </strong>In my last project, I utilized a new tool called Phind AI as pair programmer. This time around, I tried SwiftGPT from the Chat Store that explained unknown concepts better.</li><li><strong>Nuanced Video &amp; Skillset: </strong>This was my first time utilizing an open source API and it’s not that hard to use — The structure of the project was easier than I thought</li></ul><p>Here’s where I could use some help and some more understanding:</p><ul><li><strong>Understanding the AV Framework </strong>: A lot of the backend in the app is creating algorithms for Audio Control (when to start &amp; stop recording, listening, processing). Understanding the AVFramework in Swift would be key.</li><li><strong>Swift Knowledge</strong> : There were many times where I could understand some of the language in Swift, but new topics came up that did not make sense in my head, so taking the time to researching some of the syntax and methods Alfian uses is the next step.</li></ul><p>Overall, this project is going really good and I can’t wait to share a more finalized project with everyone!</p><p><em>👋 Hey i’m Piram and i’m an aspiring UI/UX designer, exploring how AI is changing the design world. connect with me on </em><a href="https://www.linkedin.com/in/piramsingh/"><em>linkedin</em></a><em> to follow me on this journey!</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=29923a5a9d43" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[ ➡  Creating Carbon Black from the Air]]></title>
            <link>https://medium.com/@piram.singh/creating-carbon-black-from-the-air-0b2c1ceb3366?source=rss-37e444058d76------2</link>
            <guid isPermaLink="false">https://medium.com/p/0b2c1ceb3366</guid>
            <dc:creator><![CDATA[Piram Singh]]></dc:creator>
            <pubDate>Mon, 08 Jan 2024 20:46:07 GMT</pubDate>
            <atom:updated>2024-01-08T20:46:07.238Z</atom:updated>
            <content:encoded><![CDATA[<h4>building the future of carbon valorization.</h4><blockquote>Carbon gets a pretty bad rap when it comes to climate change because of all the harmful things humans have done with it to hurt the earth — but there’s one big caveat — <em>capturing it will probably save the earth.</em></blockquote><p>Carbon capture technology (CCT) is an upcoming technology that currently has three primary applications:</p><ol><li>🛢️ Enhanced Oil Recovery: turning CO2 into oil; creating carbon dioxide to put more carbon dioxide back in the air (kinda ironic lol)</li><li>🧪 Creating Chemicals: companies like <a href="https://www.twelve.co/">twelve.co</a> are harnessing carbon capture through their industrial photosynthesis tech to create more sustainable biofuel and other critical chemicals for the supply chain.</li><li>🪨 Storing CO2 in other materials: utilizing carbon capture to get the carbon dioxide, store it in rocks, and sink it into the ground. <a href="https://climeworks.com/?utm_source=googleBrand&amp;utm_medium=cpc&amp;utm_campaign=GS-AO-World-en-Brand&amp;utm_term=climeworks&amp;gclid=Cj0KCQjwrfymBhCTARIsADXTabl8h4f3QEpCyo8CkLknuB0fCVR_-Y2NU1bmoLraobCvVRdOK5DTi3caAqPjEALw_wcB">climeworks</a> is a company that has direct air capture plants (DAC) that are mineralizing carbon dioxide into basalt rocks and storing them underground.</li></ol><p>While these are novel uses of CCT, we want to be able to generate revenue which is why we went on a rabbit hole of <strong>carbon valorization</strong>. carbon valorization is the act of extracting value from captured carbon and implementing it today. for example, CO2 can be made into natural gas, e-fuels, ethanol, and other types of materials. chemist iris ten breaks down carbon valorization and the status quo of the valorization market <a href="https://medium.com/extantia-capital/dont-bury-money-how-to-create-value-from-co2-c253ff4ee93f">here</a>.</p><p>As valorization was the answer for us, we researched the most novel materials on the market and concluded that creating a more <strong>sustainable version of carbon black</strong> would make the most sense, and here’s how we’re going to do it:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/900/0*NNDmgZS5Nm96i6aK.png" /></figure><p>This is a high level of what our innovation is — we’re going to break this process down into three steps:</p><ol><li><strong>Capturing Carbon Dioxide</strong></li><li><strong>Converting CO2 into Methane</strong></li><li><strong>Converting Methane into Carbon Black</strong></li></ol><h4>Capturing Carbon Dioxide</h4><p>carbon capture is the process of trapping CO2 emissions through different industrial processes. one of the most prominent processes is the DAC plants and here is how the ones built by <a href="https://carbonengineering.com/">carbon engineering</a> work:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/451/0*py824ph7p9O8z7y7.png" /></figure><ol><li>air travels into the <em>air contactor plant</em> where they have their own capture solution coated to the top of the plant.</li><li>the air and capture solution meet in the middle of the plant in a sheet of PVC where the capture solution is latched onto the PVC plant.</li><li>once the air hits the absorbed PVC sheets — the CO2 is turned into liquid carbonate and is dripped into a bucket below the plant. the trapped CO2 liquid goes through the pipeline for further processing.</li><li>*carbon engineering has a <a href="https://www.youtube.com/watch?v=GkEAA7VnyhE">video</a> that explains this process in more detail if you’re really interested.</li></ol><h4>Converting CO2 into Methane</h4><p>To convert CO2 into Methane (CH4), the most cost-effective and validated method that we are using is called the sabatier method.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/946/0*tXolyWYiF7DVKQQb.png" /></figure><p>We are using the methods of this <a href="https://www.journal.csj.jp/doi/full/10.1246/cl.190930">research paper</a> — where we use a ruthenium ceric oxide (the Ru/CeO part of the diagram) catalyst (a chemical that makes a reaction happen easily) to make the chemical reaction occur with 7x less energy than the industry standard.</p><p>What’s happening to the CO2 is that we break the carbon-oxygen bonds in the CO2 to form new bonds with hydrogen to create methane. with this process at the helm we are able to produce methane with the only byproduct being water ( which is a good thing!)</p><h4>Converting Methane into Carbon Black</h4><p>To convert our newly made methane into carbon black, we mainly used plasma pyrolysis as the main process outlined in this <a href="https://www.sciencedirect.com/science/article/abs/pii/S0360319922048388">research paper</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/634/0*j0_m1WmHHW_D_kAk.png" /></figure><p><strong>We can break this complex process down into three easy steps:</strong></p><p>(1) methane flows through a large tank that is heated up to 200 degrees celsius where plasma is shot 💥 at the methane!</p><p>(2) this heat allows the methane to be broken down into two atoms: carbon and hydrogen.</p><p>(3) we harvest both portions — using carbon for carbon black production and using hydrogen as input for step 2</p><h4>🤔What’s Next?</h4><p>While this process can work in a hypothetical situation, we are taking a headstart and contacting potential customers, figuring out how to transport black carbon efficiently, and figuring out how to scale this process — so if you can help in any of these areas, contact <a href="https://www.linkedin.com/in/piram-singh-881b1b132/">piram</a> and <a href="https://www.linkedin.com/in/ahnaaf-khan/">ahnaaf</a> from black carbon labs!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=0b2c1ceb3366" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Piram’s 2023 Update]]></title>
            <link>https://medium.com/@piram.singh/pirams-2023-update-fddd48158557?source=rss-37e444058d76------2</link>
            <guid isPermaLink="false">https://medium.com/p/fddd48158557</guid>
            <category><![CDATA[ambition]]></category>
            <category><![CDATA[undergraduate]]></category>
            <category><![CDATA[growth]]></category>
            <category><![CDATA[graduation]]></category>
            <category><![CDATA[year-in-review]]></category>
            <dc:creator><![CDATA[Piram Singh]]></dc:creator>
            <pubDate>Sun, 07 Jan 2024 19:56:07 GMT</pubDate>
            <atom:updated>2024-01-07T20:09:48.675Z</atom:updated>
            <content:encoded><![CDATA[<h4>A recollection of one of the transformational years i’ve had.</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xtzl-23GLdUNn0ZiLf3Gug.jpeg" /><figcaption>a quick shot during my grad shoot @ sjsu!</figcaption></figure><p>Hello 👋,</p><p>2023 has been one of the most transformational years for me — I was able to push myself to become more creative and have an ambitious mindset; something I had when I was in grade school.</p><p>Alongside this, I have made a ton of memories and have so much to be thankful for this year. In this end-of-year update, here are the biggest hits:</p><ol><li>Project Highlight : visionOS project showcase</li><li>3 Quick Updates: exploring design, ari-global program, &amp; graduating college</li><li>5 Personal Learnings: 5 key takeaways from personal experiences, the web, books, &amp; smart people I met</li><li>Movie Rankings: top 5 movies of the year!</li></ol><p>Hope you enjoy!</p><h4><strong>Project Highlight: visionOS Project Showcase</strong></h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*E_xAW7bRjTi5NQVx6dEIMQ.png" /></figure><p>One of my biggest personal achievements this year is that I completed a <em>replicate</em> project! As I explored the future of design, VR really caught my eye as it is an amazing medium to test out the future of UX. With that in mind, I developed an application that could show what an immersive Spacex mission could look like with a VR headset!</p><p>Learn more in the <a href="https://medium.com/@piram.singh/exploring-space-with-visionos-78a766949573">medium article</a> &amp; <a href="https://youtu.be/bCBN171F3Ok">video</a>!</p><h4>3 Updates: ari-global, Exploring Design, &amp; Graduating College</h4><p>1️⃣ <strong>How ari-global transformed me</strong></p><p>It was early july when my mom had pitched me this idea to apply to this 2-week climate-tech bootcamp and my intial response was “Nah, not for me at all”. However, with 2 hours of convincing and nudging, I was writing an application essay and submitting a video essay. Fast forward a month, and I was attending my first session via butter!</p><p>I fully expected this entire experience to be the traditional summer bootcamp with a competition at the end — I was completely wrong. It was about building skills that would benefit my future self with the added bonus about learning the climate-tech space.</p><p>My highlights from this experience were:</p><ul><li><strong>Creating a personal operating system</strong></li><li><strong>Learning how to write stellar blog posts</strong></li><li><strong>Creating stellar presentation designs</strong></li><li><strong>Meeting smart people including my current mentor — </strong><a href="https://medium.com/u/8c3cd9f310f5"><strong>michael raspuzzi</strong></a>!</li></ul><p>You can see my slew of work from ari-global below 👇</p><p><a href="https://michaelraspuzzi.notion.site/Piram-Singh-s-Notion-Page-67b7741121c341e69e40803a48f8c887?pvs=4">Piram Singh&#39;s Notion Page | Built with Notion</a></p><p>2️⃣ <strong>Exploring Design</strong></p><p>At the start of this year, I was going through UX Certification from Google to sort of catapult myself as a UX designer &amp; focused on getting a job as soon as possible, but then after ari-global, I was guided into another way of thinking and essentially got asked the question:</p><blockquote>“How do you prepare yourself to be a designer for the next 10 years ?”</blockquote><p>This led me to analyze what the current state of design is, the future of design, and projects that I can currently build out to preview what the future of design will look like. I’ve only gotten started with this with the slew of articles, projects that I built in the back half of the year. Check some of them out below 👇</p><ul><li><a href="https://medium.com/@piram.singh/getting-started-with-visionos-cd55e693e603">Getting started with visionOS!</a></li><li><a href="https://medium.com/@piram.singh/understanding-don-norman-in-2023-d19628a00ed7">Understanding Don Norman in 2023</a></li><li><a href="https://medium.com/@piram.singh/redesigning-teslas-charging-ux-1c35e779fdcd">Redesigning Tesla’s Charging UX</a></li></ul><p><a href="https://www.linkedin.com/posts/piramsingh_went-on-a-deep-dive-on-the-creation-of-airbnb-activity-7132918504558641153-4IHb?utm_source=share&amp;utm_medium=member_desktop"><strong>Brian Chesky Post</strong></a></p><p><a href="https://www.linkedin.com/posts/piramsingh_for-those-that-know-me-personally-i-am-a-activity-7131456133705175041-3HV3?utm_source=share&amp;utm_medium=member_desktop"><strong>Pixar Founder’s Post</strong></a></p><p>This slew of work is only the beginning — (more to come this year 👀)</p><p><strong>3️⃣ Graduating College</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*r4mDzGD94B_wXMtyA-TFQw.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3dT18Ls9CYKl7g6U2lDzyQ.jpeg" /><figcaption>graduation day pics!</figcaption></figure><p>This year was about opening new doors to new &amp; unknown topics, but I also closed the door and wrapped up college! I graduated from San Jose State with a B.S. in Management Information Systems!</p><p>It’s been quite a journey from experiencing dorm &amp; apartment, navigating a pandemic, commuting hassles (parking @ SJSU lol) , meeting new people, and learning about myself. With all this mind, here are some of the big highlights:</p><ul><li><strong>🤝 Finding Quality Friends —</strong> Before going into college, I was known as the extroverted kid that could be friends with everyone. I realized that my values did not match with the normal college kid. I then seeked quality friends who have been way more impactful in my life in the past 4.5 years. For those reading this — love you guys.</li><li><strong>🏢 Cisco Internship — </strong>My junior summer I scored an internship at Cisco as a Business Analyst role, but emerged into a UI/UX analyst position. It was there where my passion for UI/UX emerged from and have not looked back since.</li><li>🤖<strong> Machine Learning —</strong> In my last semester, I decided to take an M.L. class that was really outside of my comfort zone and pretty damn tough. In hindsight, that was one of the best classes I took, because it allowed me to be in charge of what I wanted to learn, and just enhance my knowledge.</li><li>🪯<strong> Sikh Student Association (SSA) — </strong>For those that know me well, they know sikhism plays a big role in my life and especially<em> kirtan — </em>classical sikh music. Working with the SSA, I brought together many schools from the Bay Area for some epic <em>kirtan </em>nights.</li></ul><p>Here are some other pics from my time at SJSU! 👇</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*JhMMSITn8UAKg0oXXRuXSA.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zh_Ae8T5GpFk6wHv1l3gqA.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oipH6S2M665nTwuCauxnEA.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4swpSkziTasBBJ-ZqoBMAQ.jpeg" /></figure><h4><strong>5 Personal Learnings: 5 key takeaways from personal experiences, the web, books, &amp; smart people I met</strong></h4><p>With a new year comes new learnings — here are the top 5.</p><ol><li><strong>👿 Design is the second most evil role in society — </strong>The godfather of design, Don Norman, explains how designers are always at the low level with no input from the start, making them an implicit evil in society. More in my <a href="https://medium.com/@piram.singh/understanding-don-norman-in-2023-d19628a00ed7">piece</a> and his <a href="https://www.youtube.com/watch?v=FMEzKQpTosY">talks</a>.</li><li><strong>🧍🏼‍♂️ Design is more than being “user-centric” —</strong> Another concept that Norman has brought into the status quo. Designers need to be taught the entire picture than just what they are being told to design. More in my<a href="https://medium.com/@piram.singh/understanding-don-norman-in-2023-d19628a00ed7"> piece</a> and this <a href="https://www.youtube.com/watch?v=92apECwSbvo">talk</a>.</li><li>👶🏽 <strong>Your inner-child is the best mental state — </strong>Throughout the year, I litsened to naval, met with some designers, and learned more about the mind. Most of them came to the conclusion that many of us live in a “monkey-state ” where we go into delusions about the future, and reminisce way too much about the past. Be focused on the present and attack what is in front of you. <a href="https://parachutebook.com/"><em>What Color is Your Parachute?</em></a><em> i</em>s a book recommendation to help with this.</li><li>🕹️ <strong>Play the right moves in the great online game —</strong> In Packy McCormick’s <a href="https://www.notboring.co/p/the-great-online-game"><em>The Great Online Game</em></a><em> </em>, we are essentially competing to hit keys on our keyboards at the right time to call ourselves “successful”. Learn how to play in this online game. More in the article.</li><li>📈 <strong>Build as much stuff as you can — </strong>The more things of note we can build, the better our chances are in the great online game &amp; the more we can put in our toolbox for later.</li><li>(Bonus Takeaway) 👨‍👩‍👧‍👦 <strong>Taking care of yourself is taking care of your family</strong> — In the past few months, I have been focusing on how I can deliver value to the family unit through times of need, and realized investing in your self while providing value to your family is as important.</li></ol><h4>Movie Rankings: top 5 movies of the year!</h4><p>For those who know me well, I love going to the movies pretty often! That being said, every year I am going to share my top 5 movies! Here are my top 5 for 2023:</p><p><strong>5.</strong> ⛹🏾<strong> Air (Dir: Ben Affleck) — </strong>A good film, not the best work of Affleck’s but really entertaining story of how MJ was recruited by Nike to be their star athlete. I just wish they would have shown more of MJ’s home life, would have been a more complete storey. Score: <em>6.7/10</em></p><p><strong>4. 🕵🏽‍♂️ Mission Impossible: Dead Reckoning, Part 1 (Dir: Christopher McQuarrie) —</strong> A solid entry in the MI series, really love seeing Tom Cruise do his own stunts at his age. The only issue I really had with this is that it felt like an incomplete story for a 2 parter and some of the CGI was pretty shotty for a MI film. Score: <em>7.8/10</em></p><p><strong>3.</strong> <strong>🦝 Guardians of the Galaxy: Volume 3 (Dir: James Gunn) — </strong>The only good MCU movie to come out this year as it really blended Marvel’s needs and what Gunn wanted to make. It’s such an impeccable send off for the way they have treated these characters for the past 10 years. Excited to see what they do with Star-Lord. Score: <em>9.0/10</em></p><p><strong>2.</strong> <strong>🕷️ Spider-Man: Across the Spider-Verse (Dir: Powers, Thompson, Santos) — </strong>One of the best comic book movies (CBMs) and animated movies. I literally loved every single minute of this movie — the animation, storytelling, the Spidey references, and the cliffhanger made this an amazing part 1 to a 2-part story. Score: <em>9.5/10</em></p><p><strong>1.👨🏽‍🔬 Oppenheimer (Dir: Chris Nolan) — </strong>An amazing movie-going experience that affected me in ways that I did not see coming. The movie-making was incredible — amazing cinematography (70 mm IMAX) , special effects, and storytelling is some of Nolan’s best (🦇 The Dark Knight is still up there though). Score: <em>9.7/10</em></p><h4>What’s next for me in 2024…</h4><p>2024 is going to be a huge year for me as I figure out what life is going to look like post graduation! Here is what some of that entails:</p><ul><li><strong>📂 Building out more projects for my portfolio — </strong>Making more cool stuff to set myself up for success</li><li><strong>💼 Finding a meaningful job that aligns w/ my interest — </strong>This last point is really a key into this, but yeah im looking for a job!</li><li>💪<strong> Being Healthy —</strong> Increasing the amount of times I go to the gym and being in nature more often<strong> </strong>(🚴🏽‍♂️ getting back into biking in Niles!)</li><li>👥 <strong>Meeting People in Design — </strong>One of the key learnings from last year was about meeting smart people so you can stay curious about everything. I intend meeting more people in the design community through meetups, conferences, &amp; more! (I’ll be at Config 2024 😉)</li><li>🪯<strong> SSA Involvement — </strong>Giving back to the sikh college experience is something I care deeply about. Giving back to the SSA’s that shaped me is something I will defenitely I will do.</li></ul><p><em>👋 Hey i’m Piram and i’m an aspiring UI/UX designer, exploring how AI is changing the design world. connect with me on </em><a href="https://www.linkedin.com/in/piramsingh/"><em>linkedin</em></a><em> to follow me on this journey!</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=fddd48158557" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[ Understanding Psychology Behind Design.]]></title>
            <link>https://medium.com/@piram.singh/understanding-psychology-behind-design-616fbaa1c6d7?source=rss-37e444058d76------2</link>
            <guid isPermaLink="false">https://medium.com/p/616fbaa1c6d7</guid>
            <category><![CDATA[design]]></category>
            <category><![CDATA[psychology]]></category>
            <category><![CDATA[vr]]></category>
            <category><![CDATA[growth]]></category>
            <category><![CDATA[ai]]></category>
            <dc:creator><![CDATA[Piram Singh]]></dc:creator>
            <pubDate>Fri, 15 Dec 2023 06:57:04 GMT</pubDate>
            <atom:updated>2023-12-15T06:57:04.394Z</atom:updated>
            <content:encoded><![CDATA[<h4>breaking down 4 psychology principles from growth.design.</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*krqtLMMkCeYb9Cww1viEeQ.jpeg" /></figure><p>As I keep studying design and the future of design w/ AI — one thing is clear: designers will always need to consider the human use case as the center point of their work through a big-picture approach ( read my latest blog post on <a href="https://medium.com/@piram.singh/understanding-don-norman-in-2023-d19628a00ed7">Don Norman</a> to learn about this concept)</p><p>With that being said, I wanted to learn more about the psychology behind modern design to see how other mediums outside of the normal “technical UX design field” could help me understand these concepts. That being said, here are four psychology concepts that I studied:</p><h4><strong>🖼️ Framing</strong></h4><p>The framing effect is that the way information is presented can have a greater effect on us than the actual content of the info. Here’s a couple of examples how the framing effect works:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*IYnXPx_uw6sagEaZ.png" /><figcaption>Apple Marketing using the framing effect</figcaption></figure><p>We see framing being used by highly effective marketing campaigns like Apple. In the ad above, it is showing you how the iPhone is better than other phones on the market , not telling you — all by framing the ad in a certain way to convey a bigger message.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/0*-0WYAPPZIWpvjyK1" /><figcaption>🕷️ scene from into the spider-verse</figcaption></figure><p>Hollywood also takes into account of framing (good movies do this amazingly). In the end scene of into the spider-verse, Miles has a conversation with his dad about a bad guy he just helped stop after decimating NYC with other spider-people. No where in the scene does Miles tell his dad that he is spider-man, but it is implied that his dad knows his secret identity This is how good framing is — showing it visually and the tone of the language.</p><h4>🦄 Scarcity</h4><p>This one is for the mobile gamers, here you go — Scarcity is essentially invoked when you want to people to buy something quick , but it can also be used for people to make better decisions. Let me give you an example:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/646/1*i0pr35ULunj1Nk8ndYxdnA.png" /><figcaption>⏰ season pass timer</figcaption></figure><p>I used to play this card game called Marvel Snap where you could create your own virtual decks of supers from the comics and online battle with anyone from around the world. Every month, there would be a season &amp; a theme. The timer here invokes scaracity to a player, with them thinking “theres 24 days left in this season, how do I get the most points &amp; the get the most upgrades?” — that’s scarcity for you.</p><h4><strong>👅 Sensory Appeal</strong></h4><p>The next concept is sensory appeal. It’s when a product taps into our 5 senses to increase desirability. Here are some examples:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/400/0*zx-qoi4BJ_ED5W6M.gif" /><figcaption>👂🏻+ 👁️: the marvel studios intro</figcaption></figure><p>Back to a movie example, the Marvel Studios logo intro is a sensory appeal the score of the iconic score will jog the mamory of the audience with saying “hey you are watching a marvel movie — know what type of movie to expect” and also visually — the logo will trigger the behavior of the audience in a certain way.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*s6RYVOfvd3V_E6yI" /><figcaption>👅 taco bell advertising</figcaption></figure><p>Another example of sensory appeal is through taste — this taco bell ad of the new nacho fries will get people excited about the taste of the nacho fries, which would increase the number of people buying it.</p><p><strong>🕹️ Skeuomorphism</strong></p><p>The last concept that is making the biggest shift in design is Skeuomorphism. Essentially this is when we incorporate real life textures, materials, and elements from the real world to incoroporate into real-life design.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zBqRqjVCuKBrkhgQ7V73ag.png" /><figcaption>🚀 rocketship rendering</figcaption></figure><p>Now, the best example of this is something from my latest project! I recently built an app in the visionOS SDK about the Inspiration 4 SpaceX mission! One of the pages in the app is an immersive area with the <em>Falcon 9. </em>It uses an actual model of the rocketship to be implemeneted in the view! Check out more about my project <a href="https://medium.com/@piram.singh/exploring-space-with-visionos-78a766949573">here</a>!</p><h3>🔮<strong> Future Applications</strong></h3><p>With all these concepts learned, here is an idea for each of them in the future with VR-enabled AI applications as the focus:</p><p><strong>(1) 🖼️ Framing:</strong> A chat-type of UX where information is formatted in a way where the user can respond with natural voice without a constant nudge from the AI.</p><p><strong>(2) 🦄 Scarcity: </strong>A gaming application where immersive ai-enabled levels are only offered once a month or a for a limited amount of time.</p><p><strong>(3) 👅 Sensory Appeal: </strong>A food-based application that would analyze the food you are eating and create AI-based storytelling experiences when you take the first bite. (Think of that scene in ratatouille when remy’s brother tries cheese for the first time)</p><p><strong>(4) 🕹️ Skeuomorphism: </strong>I mentioned an idea like this earlier, but I recently met the CEO of a company called <a href="https://www.faunabio.com/">Fauna Bio</a> which specializes in taking animal genomes for human therapies. Creating an immersive promotional experience that allows you to visualize DNA, Animals, and other immersive environments would be sick with an AI running in the background.</p><p>Thanks for checking out my breakdown of growth.design’s psych terms. You can check more of them <a href="https://growth.design/psychology#social-proof">here</a>.</p><p><em>👋 Hey i’m Piram and i’m an aspiring UI/UX designer, exploring how AI is changing the design world. connect with me on </em><a href="https://www.linkedin.com/in/piramsingh/"><em>linkedin</em></a><em> to follow me on this journey!</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=616fbaa1c6d7" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>