<?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 Pan Wangperawong on Medium]]></title>
        <description><![CDATA[Stories by Pan Wangperawong on Medium]]></description>
        <link>https://medium.com/@panw?source=rss-7971be52b730------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*bfCBZtAVcxbIw_ywq542hA@2x.jpeg</url>
            <title>Stories by Pan Wangperawong on Medium</title>
            <link>https://medium.com/@panw?source=rss-7971be52b730------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Thu, 19 Nov 2026 23:52:36 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@panw/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[Announcing the Wit-Unity Plug-In for Building Voice Enabled AR and VR Experiences]]></title>
            <link>https://medium.com/wit-ai/announcing-the-wit-unity-plug-in-for-building-voice-enabled-ar-and-vr-experiences-b4106cb89520?source=rss-7971be52b730------2</link>
            <guid isPermaLink="false">https://medium.com/p/b4106cb89520</guid>
            <category><![CDATA[voice-assistant]]></category>
            <category><![CDATA[conversational-ui]]></category>
            <category><![CDATA[ar]]></category>
            <category><![CDATA[unity]]></category>
            <category><![CDATA[vr]]></category>
            <dc:creator><![CDATA[Pan Wangperawong]]></dc:creator>
            <pubDate>Thu, 15 Jul 2021 17:14:44 GMT</pubDate>
            <atom:updated>2021-07-15T17:14:44.358Z</atom:updated>
            <content:encoded><![CDATA[<p>In this past F8 2021 Wit.ai Hackathon, we challenged developers to build voice enabled AR and VR experiences. As a result, we received many submissions that integrated voice in creative ways, such as interactive storytelling, guided dance lessons, and voice based game controls (see the <a href="https://developers.facebook.com/blog/post/2021/06/02/f8-refresh-hackathon-winners-announced/">announcement post</a> for the winning hackathon projects).</p><p>To continue supporting AR and VR developers looking to build immersive voice experiences, we are happy to announce that the Wit-Unity plug-in is now available. With the plug-in, you can easily integrate voice into your Unity app allowing you to focus on the creative and functional aspects of your app experience rather than spending time on the configuration. All of the code is also open-sourced and available on GitHub. To get started, you can visit <a href="https://github.com/wit-ai/wit-unity">https://github.com/wit-ai/wit-unity</a>.</p><p>In the repository, we’ve also included a <a href="https://github.com/wit-ai/wit-unity/tree/main/Samples">voice enabled VR sample app</a> where users can change the color of 3D shapes through voice commands. Accompanying it, is an in-depth <a href="https://wit.ai/docs/tutorials#wit-unity-shapes-tutorial">tutorial</a> with step by step instructions.</p><figure><img alt="Wit-Unity 3D shapes demo" src="https://cdn-images-1.medium.com/max/480/1*6diU2GJHNXEnn1iKelTyMw.gif" /><figcaption>Wit-Unity 3D shapes demo</figcaption></figure><p>For more information about integrating voice into your AR and VR apps, watch our F8 session, where we discuss how developers are using Wit.ai to provide conversational user experiences in different ways.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FXlE_iM8Ln3g%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DXlE_iM8Ln3g&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FXlE_iM8Ln3g%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/77214b197b475fa5c0879dc0630cbf67/href">https://medium.com/media/77214b197b475fa5c0879dc0630cbf67/href</a></iframe><p>Keep in mind that in augmented and virtual reality environments, the laws of physics no longer apply, so don’t feel constrained by the limitations of physical reality. We can’t wait to see what you will build with the Wit-Unity plug-in!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b4106cb89520" width="1" height="1" alt=""><hr><p><a href="https://medium.com/wit-ai/announcing-the-wit-unity-plug-in-for-building-voice-enabled-ar-and-vr-experiences-b4106cb89520">Announcing the Wit-Unity Plug-In for Building Voice Enabled AR and VR Experiences</a> was originally published in <a href="https://medium.com/wit-ai">Wit.ai</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Build an Interactive Voice-Enabled Android App with Wit.ai]]></title>
            <link>https://medium.com/wit-ai/build-an-interactive-voice-enabled-android-app-with-wit-ai-6f6d72cf94be?source=rss-7971be52b730------2</link>
            <guid isPermaLink="false">https://medium.com/p/6f6d72cf94be</guid>
            <category><![CDATA[nlp]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[wit]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[voice-assistant]]></category>
            <dc:creator><![CDATA[Pan Wangperawong]]></dc:creator>
            <pubDate>Mon, 21 Sep 2020 19:43:20 GMT</pubDate>
            <atom:updated>2020-09-21T19:43:20.509Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kmMSS8Y2kfI_KZ_OyjdbNw.png" /></figure><h3>Build an Interactive Voice-Enabled Android App With Wit.ai</h3><h3>Overview</h3><p>The complement of voice and touch interfaces can enable a new app experience for users that would not be possible with traditional touch-based apps. In this tutorial, I will be showing you how to add a voice user interface to an Android app, so you can start creating new app experiences.</p><p>The app we’ll be creating will be a simple greeting app that can ask the user for their name and respond back appropriately. The key things we will explore are how to:</p><ul><li>Design the user interaction</li><li>Create and train a Wit app to do natural language processing (NLP)</li><li>Integrate a <a href="http://wit.ai/">Wit.ai</a> app with your Android app</li></ul><blockquote><em>For your reference, we also published the code sample on</em><a href="https://github.com/wit-ai/android-voice-demo"><em> GitHub</em></a><em> and</em><a href="https://www.facebook.com/itspanw/videos/10201370230639090/"><em> Facebook Live session</em></a><em> so you can follow along at your own pace.</em></blockquote><iframe src="https://www.facebook.com/plugins/video.php?width=500&amp;height=281&amp;href=https%3A%2F%2Fwww.facebook.com%2Fitspanw%2Fvideos%2F10201370230639090%2F" width="500" height="281" frameborder="0" scrolling="no"><a href="https://medium.com/media/b00329d84379e33ef3c959f8cc89d6a4/href">https://medium.com/media/b00329d84379e33ef3c959f8cc89d6a4/href</a></iframe><h3>Prerequisites</h3><p>Before we begin with the tutorial, please make sure to do the following:</p><ul><li>Create a<a href="https://wit.ai/"> Wit.ai</a> account</li><li>Download the<a href="https://github.com/wit-ai/android-voice-demo/tree/base-setup"> Wit.ai Voice demo base-setup</a> branch from GitHub</li><li>Download and install<a href="https://developer.android.com/studio"> Android Studio</a></li><li>Have an Android device/emulator with</li><li>Internet access</li><li>Microphone access</li><li>API Level 28 or greater</li></ul><blockquote>If you are using a device<a href="https://developer.android.com/studio/debug/dev-options"> enable USB debugging</a></blockquote><h3>Design the User Interaction</h3><p>When designing applications with voice interactions, it’s important to understand the various ways that a user may interact with your app. You can model the conversation by writing a script or creating a flow diagram. For our greeting app, let’s write a script to outline it.</p><pre>Wit:  &quot;Hi, welcome to the Wit.ai voice demo. I&#39;m Wit. What is your name?&quot;<br><br>User: &quot;My name is Pan&quot;<br><br>Wit:  &quot;Nice to meet you Pan!&quot;</pre><p>Now let’s think about scenarios were the user can deviate:</p><pre>Wit:  &quot;Hi, welcome to the Wit.ai speech demo. I&#39;m Wit. What is your name?&quot;<br><br>User: &quot;I want pizza&quot;<br><br>Wit:  &quot;Sorry, I didn&#39;t get that. What is your name?&quot;<br><br>User: &quot;My name is Pan&quot;<br><br>Wit:  &quot;Nice to meet you Pan!&quot;</pre><p>There are many other scenarios to consider as well, but for the tutorial let’s just focus on these.</p><h3>Add an introduction to your Android app</h3><p>Import the<a href="https://github.com/wit-ai/android-voice-demo/tree/base-setup"> Wit.ai Voice demo base-setup</a> into Android Studio and open <strong>app</strong> &gt; <strong>src</strong> &gt; <strong>main</strong> &gt; <strong>java</strong> &gt; <strong>com.facebook.witai.voicedemo</strong> &gt; <strong>MainActivity.java</strong>.</p><p>Next update initializeTextToSpeech function to include the introduction announcement as follows:</p><pre>public class MainActivity extends AppCompatActivity {<br> /* Truncated variable declarations */<br> @Override<br> protected void onCreate(Bundle savedInstanceState) {<br>   /* ... Truncated code */<br> }<br> private void initializeTextToSpeech(Context applicationContext) {<br>   textToSpeech = new TextToSpeech(applicationContext, new TextToSpeech.OnInitListener() {<br>     @Override<br>     public void onInit(int ttsStatus) {<br>       speechTranscription.setHint(&quot;Loading app ...&quot;);<br>       speakButton.setEnabled(false);<br>       if (ttsStatus == TextToSpeech.SUCCESS) {<br>         /*<br>           * ADD the following to have the app speak the welcome message<br>         */<br>         textToSpeech.speak(&quot;Hi! Welcome to the Wit a.i. voice demo. My name is Wit. What is your name?&quot;, TextToSpeech.QUEUE_FLUSH, null, UUID.randomUUID().toString());<br>         speechTranscription.setHint(&quot;Press Speak and say something!&quot;);<br>         speakButton.setEnabled(true);<br>       } else {<br>         displayErrorMessage(&quot;TextToSpeech&quot;, &quot;TextToSpeech initialization failed&quot;);<br>       }<br>     }<br>   });<br> }<br> /* Truncated code */<br>}</pre><h3>Training your Wit app to do natural language processing (NLP)</h3><p>Now that the Android app can speak the introduction, let’s train our Wit app to process the user’s response.</p><h4>Create a New Wit App</h4><ol><li>Go to<a href="https://wit.ai/"> Wit.ai</a>.</li><li>Create a new <a href="http://wit.ai/">Wit.ai</a> app</li><li>Enter a name e.g. <em>VoiceDemo</em></li><li>Select Open or Private for visibility</li><li>Click Create</li></ol><h4>Train the Wit App with Utterances</h4><ol><li>Select <strong>Understanding</strong> from the left-hand menu</li><li>Type <em>My name is Wit</em> into the Utterance text box</li><li>Label an entity in the utterance by highlighting <em>Pan</em> with your mouse and selecting wit/contact as the Entity type</li></ol><h4>Link the Utterances to an Intent</h4><ol><li>Add an intent</li><li>Click on the Intent dropdown.</li><li>Enter <em>Greeting_Intent</em> as the name of your new Intent.</li><li>Click Create Intent.</li></ol><h4>Start the Training</h4><p>To submit your first utterance, click <strong>Train and Validate</strong>. The training should start within a few seconds — you can see the training status in the top right.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/960/1*svvzXps26PNiJppH_rxP2A.gif" /></figure><p>You might have heard that the most important part of machine learning is the training data. At this point, we’ve only provided our Wit app with one data point, so let’s think of natural variations that a user might respond with and repeat steps #2 through #4.</p><p>Here are some variations that can be added as training utterances:</p><ul><li>I’m <strong>Rasheeda</strong></li><li>I am <strong>Nancy</strong></li><li>Call me <strong>Julien</strong></li><li>My name is <strong>Scott</strong></li><li><strong>Lintao</strong>, nice to meet you</li></ul><p>For more information on this, see the<a href="https://wit.ai/docs/quickstart"> Quick Start</a> guide.</p><h4>Extend entities with more data</h4><p>A machine learning model is the product of the data it trains on, so when providing sample utterances make sure to provide a broader set of examples to optimize the language model to support your scenarios..</p><p>For example, here are some utterances with more names that we can add:</p><ul><li>My name is <strong>Lee Jun-fan</strong></li><li>I’m <strong>Musa</strong></li><li><strong>Jennifer</strong></li><li><strong>Pat</strong> is the name</li></ul><h3>Integrate Wit with your Android app</h3><p>When you download the Android <a href="http://wit.ai/">Wit.ai</a> Voice Demo from the<a href="https://github.com/wit-ai/android-voice-demo/tree/base-setup"> base setup branch</a>, the app will be capable of doing text to speech. In this part, we will enable voice processing capabilities by streaming the user’s voice audio (or utterance) to the<a href="https://wit.ai/docs/http/20200513#post__speech_link"> Wit Speech API</a> via HTTP. For this tutorial, we will use<a href="https://square.github.io/okhttp/"> OkHttp</a> as the HTTP client for making requests.</p><h3>Initialize the HTTP client to communicate with Wit Speech API endpoint</h3><p>Open <strong>app</strong> &gt; <strong>src</strong> &gt; <strong>main</strong> &gt; <strong>java</strong> &gt; <strong>com.facebook.witai.voicedemo </strong>&gt; <strong>MainActivity.java</strong> and make the following updates:</p><pre>public class MainActivity extends AppCompatActivity {<br> /* ... Truncated variable declarations */<br> /*<br>   * ADD the following variable declarations<br> */<br> private OkHttpClient httpClient;<br> private HttpUrl.Builder httpBuilder;<br> private Request.Builder httpRequestBuilder;<br> /* Go to your Wit.ai app Management &gt; Settings and obtain the Client Access Token */<br> private final String CLIENT_ACCESS_TOKEN = &quot;&lt;YOUR CLIENT ACCESS TOKEN&gt;&quot;;<br> @Override<br> protected void onCreate(Bundle savedInstanceState) {<br>   /* ... Truncated code */<br> }<br> /*<br>   * ADD the following function to initialize OkHttp for streaming to the Speech API<br> */<br> private void initializeHttpClient() {<br>   httpClient = new OkHttpClient();<br>   httpBuilder = HttpUrl.parse(&quot;https://api.wit.ai/speech&quot;).newBuilder();<br>   httpBuilder.addQueryParameter(&quot;v&quot;, &quot;20200805&quot;);<br>   httpRequestBuilder = new Request.Builder()<br>                 .url(https://medium.com/httpBuilder.build())<br>                 .header(&quot;Authorization&quot;, &quot;Bearer &quot; + CLIENT_ACCESS_TOKEN)<br>                 .header(&quot;Content-Type&quot;, &quot;audio/raw&quot;)<br>                 .header(&quot;Transfer-Encoding&quot;, &quot;chunked&quot;);<br> }<br> /* ... Truncated code */<br>}</pre><h3>Capture and stream the user’s voice response to Wit for processing</h3><p>With a configured HTTP client, let’s add the Android AudioRecord to record the user’s voice response and have it streamed to the Wit Speech API for processing.</p><pre>public class MainActivity extends AppCompatActivity {<br> /* ... Truncated variable declarations */<br> /*<br>   * ADD the following variable declartation<br> */<br> private static final int BUFFER_SIZE = AudioRecord.getMinBufferSize(SAMPLE_RATE, CHANNEL, AUDIO_FORMAT) * 10;<br> private static final AtomicBoolean recordingInProgress = new AtomicBoolean(false);<br> @Override<br> protected void onCreate(Bundle savedInstanceState) {<br>   /* ... Truncated code */<br> }<br> /*<br>   * ADD a Runnable to record and stream the voice data to Wit<br> */<br> private class StreamRecordingRunnable implements Runnable {<br>   @Override<br>   public void run() {<br>     final ByteBuffer buffer = ByteBuffer.allocateDirect(BUFFER_SIZE);<br>     RequestBody requestBody = new RequestBody() {<br>       @Override<br>       public MediaType contentType() {<br>           return MediaType.parse(&quot;audio/raw;encoding=signed-integer;bits=16;rate=8000;endian=little&quot;);<br>       }<br>       @Override<br>       public void writeTo(@NotNull BufferedSink bufferedSink) throws IOException {<br>           while (recordingInProgress.get()) {<br>               int result = recorder.read(buffer, BUFFER_SIZE);<br>               if (result &lt; 0) {<br>                   throw new RuntimeException(&quot;Reading of audio buffer failed: &quot; +<br>                           getBufferReadFailureReason(result));<br>               }<br>               bufferedSink.write(buffer);<br>               buffer.clear();<br>           }<br>       }<br>     };<br>     Request request = httpRequestBuilder.post(requestBody).build();<br>     try (Response response = httpClient.newCall(request).execute()) {<br>         if (response.isSuccessful()) {<br>             String responseData = response.body().string();<br>             respondToUser(responseData);<br>             Log.v(&quot;Streaming Response&quot;, responseData);<br>         }<br>     } catch (IOException e) {<br>         Log.e(&quot;Streaming Response&quot;, e.getMessage());<br>     }<br>   }<br>   private String getBufferReadFailureReason(int errorCode) {<br>     switch (errorCode) {<br>       case AudioRecord.ERROR_INVALID_OPERATION:<br>         return &quot;ERROR_INVALID_OPERATION&quot;;<br>       case AudioRecord.ERROR_BAD_VALUE:<br>         return &quot;ERROR_BAD_VALUE&quot;;<br>       case AudioRecord.ERROR_DEAD_OBJECT:<br>         return &quot;ERROR_DEAD_OBJECT&quot;;<br>       case AudioRecord.ERROR:<br>         return &quot;ERROR&quot;;<br>       default:<br>         return &quot;Unknown (&quot; + errorCode + &quot;)&quot;;<br>     }<br>   }<br> }<br> /* ... Truncated code */<br>}</pre><h3>Wire-up speakButton to start recording and streaming the voice data</h3><p>With a configured HTTP client, let’s add the Android AudioRecord to capture the voice response and have it streamed to the Wit Speech API for processing.</p><pre>public class MainActivity extends AppCompatActivity {<br> /* ... Truncated variable declarations */<br> /*<br>   * ADD the following variable declarations<br> */<br> private AudioRecord recorder;<br> private static final int SAMPLE_RATE = 8000;<br> private static final int CHANNEL = AudioFormat.CHANNEL_IN_MONO;<br> private static final int AUDIO_FORMAT = AudioFormat.ENCODING_PCM_16BIT;<br> private static final int BUFFER_SIZE = AudioRecord.getMinBufferSize(SAMPLE_RATE, CHANNEL, AUDIO_FORMAT) * 10;<br> private Thread recordingThread;<br> @Override<br> protected void onCreate(Bundle savedInstanceState) {<br>   /* ... Truncated code */<br>   /*<br>   * UPDATE speakButton OnClickListener to invoke startRecording and stopRecording<br>   */<br>   speakButton.setOnClickListener(new View.OnClickListener() {<br>     @Override<br>     public void onClick(View view) {<br>       Log.d(&quot;speakButton&quot;, &quot;clicked&quot;);<br>       if (!recordingInProgress.get()) {<br>         startRecording();<br>         speakButton.setText(&quot;Listening ...&quot;);<br>       } else {<br>         stopRecording();<br>         speakButton.setText(&quot;Speak&quot;);<br>       }<br>     }<br>   });<br> }<br> /*<br>   * ADD function to instantiate a new instance of AudioRecord and<br>   * start the Runnable to record and stream to the Wit Speech API<br> */<br> private void startRecording() {<br>   recorder = new AudioRecord(MediaRecorder.AudioSource.MIC, SAMPLE_RATE, CHANNEL, AUDIO_FORMAT, BUFFER_SIZE);<br>   recorder.startRecording();<br>   recordingInProgress.set(true);<br>   recordingThread = new Thread(new StreamRecordingRunnable(), &quot;Stream Recording Thread&quot;);<br>   recordingThread.start();<br> }<br> /*<br>   * ADD function to stop the recording and release the memory for<br>   * AudioRecord, Runnable thread, etc<br> */<br> private void stopRecording() {<br>   if (recorder == null) return;<br>   recordingInProgress.set(false);<br>   recorder.stop();<br>   recorder.release();<br>   recorder = null;<br>   recordingThread = null;<br> }<br> /* ... Truncated code */<br>}</pre><h3>Respond to the user based on the Wit results from Speech API</h3><p>When the StreamRecordingRunnable is finished recording and streaming the voice data, Wit will return the resolved intents and entities in the response. We will need to extract that information from the JSON and respond to the user appropriately.</p><pre>public class MainActivity extends AppCompatActivity {<br> /*  ... Truncated variable declarations */<br> @Override<br> protected void onCreate(Bundle savedInstanceState) {<br>   /* ... Truncated code */<br> }<br> /*<br>   * ADD a function to respond to the user based on the response<br>   * returned from the Wit Speech API.<br> */<br> private void respondToUser(String response) {<br>   Log.v(&quot;respondToUser&quot;, response);<br>   String intentName = null;<br>   String speakerName = null;<br>   String responseText = &quot;&quot;;<br>   try {<br>     JSONObject data = new JSONObject(response);<br>     // Update the TextView with the voice transcription<br>     // Run it on the MainActivity&#39;s UI thread since it&#39;s the owner<br>     final String utterance = data.getString(&quot;text&quot;);<br>     MainActivity.this.runOnUiThread(new Runnable() {<br>       @Override<br>       public void run() {<br>         speechTranscription.setText(utterance);<br>       }<br>     });<br>     // Get most confident intent<br>     JSONObject intent = getMostConfident(data.getJSONArray(&quot;intents&quot;));<br>     if (intent == null) {<br>       textToSpeech.speak(&quot;Sorry, I didn&#39;t get that. What is your name?&quot;, TextToSpeech.QUEUE_FLUSH, null, UUID.randomUUID().toString());<br>       return;<br>     }<br>     intentName = intent.getString(&quot;name&quot;);<br>     Log.v(&quot;respondToUser&quot;, intentName);<br>     // Parse and get the most confident entity value for the name<br>     JSONObject nameEntity = getMostConfident((data.getJSONObject(&quot;entities&quot;)).getJSONArray(&quot;wit$contact:contact&quot;));<br>     speakerName = (String) nameEntity.get(&quot;value&quot;);<br>     Log.v(&quot;respondToUser&quot;, speakerName);<br>   } catch (JSONException e) {<br>       e.printStackTrace();<br>   }<br>   // Handle intents<br>   if (intentName.equals(&quot;Greeting_Intent&quot;)) {<br>     responseText = speakerName != null ? &quot;Nice to meet you &quot; + speakerName : &quot;Nice to meet you&quot;;<br>     textToSpeech.speak(responseText, TextToSpeech.QUEUE_FLUSH, null, UUID.randomUUID().toString());<br>   } else {<br>     textToSpeech.speak(&quot;What did you say is your name?&quot;, TextToSpeech.QUEUE_FLUSH, null, UUID.randomUUID().toString());<br>   }<br> }<br> /*<br>   * ADD helper function to select the most confident intents and entities<br>   * from the response to be used.<br> */<br> private JSONObject getMostConfident(JSONArray list) {<br>   JSONObject confidentObject = null;<br>   double maxConfidence = 0.0;<br>   for (int i = 0; i &lt; list.length(); i++) {<br>     try {<br>         JSONObject object = list.getJSONObject(i);<br>         double currConfidence = object.getDouble(&quot;confidence&quot;);<br>         if (currConfidence &gt; maxConfidence) {<br>           maxConfidence = currConfidence;<br>           confidentObject = object;<br>         }<br>     } catch(JSONException e) {<br>       e.printStackTrace();<br>     }<br>   }<br>   return confidentObject;<br> }<br> /* ... Truncated code */<br>}</pre><h3>Review and continue improving your Wit app</h3><p>As you are testing the app, you might notice that certain utterances are not resolving to the proper intents. To address this, go to<a href="https://wit.ai/"> Wit.ai</a> and on the Understanding page you should see utterances that have been sent to the API endpoint. You can review each utterance by expanding one and making sure that the entity is properly identified and resolving to the correct intent. If there are utterances not relevant to your use case (invalid utterances), you can mark them as Out of Scope.</p><h3>Next Steps</h3><p>For demonstration purposes, we’ve created a very simple greeting app, but you can create a much more engaging and interactive voice-enabled app. Try sketching out a larger conversation flow with various scenarios and see our<a href="https://wit.ai/docs"> documentation</a> to learn more about other Wit features e.g. other built-in entities, custom entities, and traits (I recommend the<a href="https://wit.ai/docs/built-in-entities#wit_sentiment"> sentiment analysis trait</a>).</p><p>You can find the full code sample on<a href="https://github.com/wit-ai/android-voice-demo"> GitHub</a> and a step-by-step video on<a href="https://www.facebook.com/itspanw/videos/10201370230639090/"> Facebook Live</a>.</p><p>We look forward to what you will develop! To stay connected, join the<a href="https://www.facebook.com/groups/withackers"> Wit Hackers Facebook Group</a> and follow us on<a href="https://twitter.com/fbplatform"> Twitter @FBPlatform</a>.</p><h3>Related Content</h3><ul><li><a href="https://wit.ai/docs/http#post__speech_link">Wit Speech API</a></li><li><a href="https://square.github.io/okhttp/">OkHttp</a></li><li><a href="https://developer.android.com/reference/android/media/AudioRecord">Android AudioRecord</a></li><li><a href="https://developer.android.com/reference/android/speech/tts/TextToSpeech">Android TextToSpeech</a></li><li><a href="https://wit.ai/docs">Wit Documentation</a></li><li><a href="https://github.com/wit-ai">Wit GitHub</a></li><li><a href="https://wit.ai/blog">Wit Blog</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6f6d72cf94be" width="1" height="1" alt=""><hr><p><a href="https://medium.com/wit-ai/build-an-interactive-voice-enabled-android-app-with-wit-ai-6f6d72cf94be">Build an Interactive Voice-Enabled Android App with Wit.ai</a> was originally published in <a href="https://medium.com/wit-ai">Wit.ai</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Fundamentals JavaScript Beginners Should Be Aware Of]]></title>
            <link>https://medium.com/@panw/fundamentals-javascript-beginners-should-be-aware-of-a894f6aa3c0?source=rss-7971be52b730------2</link>
            <guid isPermaLink="false">https://medium.com/p/a894f6aa3c0</guid>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[programming]]></category>
            <dc:creator><![CDATA[Pan Wangperawong]]></dc:creator>
            <pubDate>Mon, 23 Apr 2018 17:02:08 GMT</pubDate>
            <atom:updated>2018-04-24T23:30:00.502Z</atom:updated>
            <content:encoded><![CDATA[<p>From my experience training junior developers and teaching newcomers to the JavaScript community, it is extremely helpful to understand two concepts (1) <strong>Closure and Scope</strong> and (2) <strong>Asynchronous</strong>. I emphasize these two concepts from a functional stand point because it is something you either get right or your code may not work properly.</p><h3>Closure and Scope</h3><p>1. <strong>Closures</strong><br>In JavaScript a closure could be created by declaring a function. It is a way to encapsulate data and logic with a specific responsibility.</p><pre>var jsClosure = function() {<br>  // Everything in here is inside a closure<br>}</pre><pre>or</pre><pre>function jsClosure() {<br>  // Everything in here is inside a closure<br>}</pre><p>2. <strong>Scope<br></strong>When a closure is created it also comes with an accompanying scope. Through scopes, variables specific to the function (closure) are encapsulated. There are two types of scope (a) <strong><em>global</em></strong> which is accessible everywhere in the code and (b) <strong><em>local</em></strong> which is only accessible within a specific closure.</p><pre>/* <br>Open a JavaScript console and execute each part of the code below in your browser JavaScript console to see it in action (On <em>Windows</em> and <em>Linux</em>: Ctrl + Shift + J. On <em>Mac</em>: Cmd + Option + J).<br>*/</pre><pre>var <strong>globalVariable</strong> = &quot;Hi, I&#39;m global and could be accessed anywhere&quot;</pre><pre>function <strong>jsClosure</strong>() {<br>  var <strong>localVariable</strong> = &quot;Hi, I&#39;m local to jsClosure()&quot;<br>  <br>  console.log(<br>    &quot;Global variables are accessible in jsClosure() and everywhere&quot;,<br>    <strong>globalVariable</strong><br>  )<br>}</pre><pre>console.log(<br>   &quot;I am local to jsClosure() and will not accessible outside of my<br>   scope. Executing this will actually not work at all and lead to<br>   an error&quot;, <br>   <strong>localVariable<br></strong>)</pre><p>To elaborate further closures and scopes could be nested.</p><pre>var <strong>globalVariable</strong> = &quot;Hi, I&#39;m global and could be accessed anywhere&quot;</pre><pre>function <strong>jsClosure</strong>() {<br>  var <strong>localVariable</strong> = &quot;Hi, I&#39;m local to jsClosure()&quot;<br>  <br>  console.log(<br>    &quot;I am global so I am accessible in jsClosure() and everywhere&quot;,<br>    <strong>globalVariable</strong><br>  )</pre><pre>  function jsInnerClosure() {<br>    var innerLocalVariable = &quot;Hi, I&#39;m local to jsInnerClosure()&quot;<br>    <br>    console.log(<br>      &quot;Globally accessible variables could be accessed here and<br>       everywhere&quot;,<br>       <strong>globalVariable<br>    </strong>)</pre><pre>    console.log(<br>      &quot;Variables defined in the outer scope is also accessible<br>       in here. In this case localVariable&quot;, <br>       <strong>localVariable<br>    </strong>)<br>   }<br>}</pre><h3>Asynchronous</h3><p>A major benefit to JavaScript is the asynchronous functionality built into the language. This allows us to write code that is “non-blocking” which is crucial for user experience when some piece of code could take an indefinite amount of time to execute.</p><p>Below is an example of how we asynchronously fetch transactions for the my PAN 🍳 tokens (yes, I really created a PAN token) that does not block the execution of the next console log.</p><pre>console.log(&quot;I am going to print 1st&quot;)</pre><pre>fetch(&quot;<a href="https://api-ropsten.etherscan.io/api?module=account&amp;action=tokentx&amp;contractaddress=0x3723268a20af802e37958ea2b37e2ba8ffc9cf17&amp;page=1&amp;offset=100&amp;sort=asc">https://api-ropsten.etherscan.io/api?module=account&amp;action=tokentx&amp;contractaddress=0x3723268a20af802e37958ea2b37e2ba8ffc9cf17&amp;page=1&amp;offset=100&amp;sort=asc</a>&quot;)<br>  .then(function(<strong>response</strong>) {<br>    return response.json()<br>  })<br>  .then(function(<strong>panTransactions</strong>) {<br>    console.log(<br>      &quot;I will not print 2nd because I am asynchronous and will print<br>       3rd after I am done processing&quot;,<br>      <strong>panTransactions<br>    </strong>)<br>  })</pre><pre>console.log(&quot;Although I am 3rd to execute, I will print 2nd&quot;)</pre><h3>Conclusion</h3><p>If you are going to program in JavaScript knowing <strong>Closure and Scope</strong> and <strong>Asynchronous</strong> is helpful for writing effective code. There are other things that would also help, but I think this is a good starting point.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a894f6aa3c0" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[A Miraculous Framework for Thinking About Software Development and Maybe Decision Making]]></title>
            <link>https://medium.com/@panw/a-miraculous-framework-for-thinking-about-software-development-20b4a4487196?source=rss-7971be52b730------2</link>
            <guid isPermaLink="false">https://medium.com/p/20b4a4487196</guid>
            <category><![CDATA[personal-growth]]></category>
            <category><![CDATA[engineering]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[philosophy]]></category>
            <category><![CDATA[personal-development]]></category>
            <dc:creator><![CDATA[Pan Wangperawong]]></dc:creator>
            <pubDate>Fri, 19 Jan 2018 19:05:06 GMT</pubDate>
            <atom:updated>2018-04-23T00:33:08.044Z</atom:updated>
            <content:encoded><![CDATA[<p>In this post, I want to provide a simple framework for making decisions that can have system wide affects on people, specifically for software developers based on my personal experience. It is nothing miraculous contrary to the title, but I hope it may help some.</p><p>Often in our life we are faced with unknown situations that leaves us indecisive. The scenario I want to specifically discuss is when software engineers are unsure how something should be implemented. In these situation unfortunately, people too often chose the easier approach which can lead to unintended consequences.</p><h4>The Miraculous Framework</h4><p>I would say if you are faced with something unfamiliar, make it familiar. Gain empathy for the situation/users. For example, in the hypothetical case were you do not know what information to expose through a public API, start by imagining yourself as the user of the service then ask yourself would you be alright with the information exposed (i.e. “<em>Would I be alright with my email or phone number through this public API endpoint?”). </em>Then an unfamiliar situation now becomes very relatable and you will definitely have a better idea on what to do.</p><h4>Conclusion</h4><p>If you feel disconnected from what you are building, start reconnecting and let empathy guide your decision.</p><p><em>Originally posted on </em><a href="http://pan.wangperawong.com/"><strong><em>pan.wangperawong.com</em></strong></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=20b4a4487196" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Highlights from React Conf 2017]]></title>
            <link>https://medium.com/@panw/highlights-from-react-conf-2017-174659bbbd37?source=rss-7971be52b730------2</link>
            <guid isPermaLink="false">https://medium.com/p/174659bbbd37</guid>
            <category><![CDATA[react-native]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[reactjs]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[react]]></category>
            <dc:creator><![CDATA[Pan Wangperawong]]></dc:creator>
            <pubDate>Fri, 17 Mar 2017 21:04:53 GMT</pubDate>
            <atom:updated>2017-11-19T03:46:41.345Z</atom:updated>
            <content:encoded><![CDATA[<h3>Redux or MobX?</h3><p>Good explanation of how Redux and MobX works with a fun <em>comparison</em>, watch <a href="https://youtu.be/76FRrbY18Bs?t=9m58s"><strong><em>here</em></strong></a>. For her <em>summary</em>, watch <a href="https://youtu.be/76FRrbY18Bs?t=20m21s"><strong><em>here</em></strong></a>. Although using a standard state management library would be nice, don’t forget that <em>setState</em>,<em> Redux</em>,<em> </em>and <em>MobX </em>could all coexist. It’s all JavaScript!</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2F76FRrbY18Bs%3Ffeature%3Doembed&amp;url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D76FRrbY18Bs&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2F76FRrbY18Bs%2Fhqdefault.jpg&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/6cb65777df326cbafaa7947ba7839152/href">https://medium.com/media/6cb65777df326cbafaa7947ba7839152/href</a></iframe><h3>Cool things that could be done with React besides websites</h3><p>Short talk where Ken demos how React could be used to build things outside of websites. For example, <a href="https://github.com/Yomguithereal/react-blessed">terminal</a>, <a href="https://facebookincubator.github.io/react-vr/">VR</a>, <a href="https://facebook.github.io/react-native/">mobile</a>, <a href="https://github.com/douglowder/react-native-appletv/blob/master/README-appletv.md">tv</a>, <a href="https://github.com/FormidableLabs/react-music">music</a>, <a href="https://github.com/FormidableLabs/victory">visualization</a>, <a href="https://github.com/FormidableLabs/react-game-kit">games</a>, and <a href="https://github.com/iamdustan/react-hardware">hardware</a>.</p><p>Would love it if the talk title was <em>Shit You Could Do with React.</em></p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2F-VC7o6wZ_a8%3Ffeature%3Doembed&amp;url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D-VC7o6wZ_a8&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2F-VC7o6wZ_a8%2Fhqdefault.jpg&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/0f934d5b56f805214d72a9648016a7ae/href">https://medium.com/media/0f934d5b56f805214d72a9648016a7ae/href</a></iframe><h3>Liberate Yourself from Code Formatting with <em>Prettier</em></h3><p>Programming is art — an expression with intent. Sometimes as developers, we get distracted from nuances such as code formatting and consistency, and lose sight of the bigger picture. <a href="https://github.com/prettier/prettier"><strong>Prettier</strong></a> liberates you from all of this, so “d<em>on’t think, just code</em>”.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FhkfBvpEfWdA%3Ffeature%3Doembed&amp;url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DhkfBvpEfWdA&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FhkfBvpEfWdA%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/d8df4e703dae8044ca6dc2fe901e763a/href">https://medium.com/media/d8df4e703dae8044ca6dc2fe901e763a/href</a></iframe><h3>Adapting CSS for the Age of Component Based Apps</h3><p>Max explains how to adapt CSS to component based application and how he solves this problem through <a href="https://github.com/styled-components/styled-components">Styled Components</a>.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FjjN2yURa_uM%3Ffeature%3Doembed&amp;url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DjjN2yURa_uM&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FjjN2yURa_uM%2Fhqdefault.jpg&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/1f5febb52b3be22659e7aeef8085079c/href">https://medium.com/media/1f5febb52b3be22659e7aeef8085079c/href</a></iframe><h3>Server Side Rendering and Static Websites</h3><p>Informative intro to server side rendering and Guillermo is entertaining. He discusses the motivation for <a href="https://zeit.co/blog/next">Next.js</a>.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FevaMpdSiZKk%3Ffeature%3Doembed&amp;url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DevaMpdSiZKk&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FevaMpdSiZKk%2Fhqdefault.jpg&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/4539551c8d156be28767e459bbe0ac73/href">https://medium.com/media/4539551c8d156be28767e459bbe0ac73/href</a></iframe><p><em>Follow me </em><a href="https://twitter.com/itspanw"><em>@itspanw</em></a><em> | Originally posted on </em><a href="https://pan.wangperawong.com/"><em>pan.wangperawong.com</em></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=174659bbbd37" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How Hollywood Got AI All Wrong]]></title>
            <link>https://medium.com/@panw/how-hollywood-got-ai-all-wrong-4d3e566b08a8?source=rss-7971be52b730------2</link>
            <guid isPermaLink="false">https://medium.com/p/4d3e566b08a8</guid>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[hollywood]]></category>
            <category><![CDATA[technology]]></category>
            <category><![CDATA[artificial-intelligence]]></category>
            <category><![CDATA[hollywood-movies]]></category>
            <dc:creator><![CDATA[Pan Wangperawong]]></dc:creator>
            <pubDate>Thu, 05 Jan 2017 06:37:20 GMT</pubDate>
            <atom:updated>2017-01-11T00:37:43.112Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/718/1*PNhpZw_LGLaYOWiXbs3_7w.jpeg" /></figure><p>The Hollywood mainstream depiction of AI through movies and TV shows such as Ex Machina and West World has got it all wrong. They portray humans utilizing AI system to model humans. If you’ve worked on AI, that sounds odd. Why would we utilize something that has superior computing capabilities to model humans who are generally bad at fast calculations. Besides the misuse of such a tool, AI systems relies on the fact that things could be quantified. For example, how do we represent human emotions, such as inspiration. It seems backwards and wasteful. Kind of like trying to fit a square peg in a round hole. Perhaps that is the reason why no one has accomplished building a system that can pass the Turing Test like what is depicted in West World.</p><p>I would encourage anyone looking to utilize AI, to think about things that they find inconvenient in their daily rather than what is depicted by Hollywood.</p><p><em>Originally posted on </em><a href="http://panw.weebly.com/"><em>panw.weebly.com</em></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4d3e566b08a8" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What is Art?]]></title>
            <link>https://medium.com/@panw/what-is-art-e5a0645ecd2d?source=rss-7971be52b730------2</link>
            <guid isPermaLink="false">https://medium.com/p/e5a0645ecd2d</guid>
            <category><![CDATA[engineering]]></category>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[startup]]></category>
            <category><![CDATA[art]]></category>
            <dc:creator><![CDATA[Pan Wangperawong]]></dc:creator>
            <pubDate>Fri, 18 Nov 2016 05:32:23 GMT</pubDate>
            <atom:updated>2018-02-11T17:09:13.574Z</atom:updated>
            <content:encoded><![CDATA[<p>There seems to be a strong distinction between art and engineering, which I would argue is no different. Both are very different, but none the less both a creative processes that expresses.</p><p>Formally I would say, <em>Art</em> is <strong><em>an expression with an intent</em></strong>.</p><p>If we think about the process of creating art, it is taking an abstract idea turning it into something people can consume in some form. The exact same statement could be applied to engineering.</p><p>I think everyone could be an artist, the question just what kind.</p><p><em>Originally posted at </em><a href="https://pan.wangperawong.com/"><em>pan.wangperawong.com</em></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e5a0645ecd2d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Bend The Word - Eminem’s Lesson On Success]]></title>
            <link>https://medium.com/@panw/bend-the-word-eminems-lesson-on-success-a6cad9343708?source=rss-7971be52b730------2</link>
            <guid isPermaLink="false">https://medium.com/p/a6cad9343708</guid>
            <category><![CDATA[creativity]]></category>
            <category><![CDATA[successful-entrepreneurs]]></category>
            <category><![CDATA[entrepreneurship]]></category>
            <category><![CDATA[life-advice]]></category>
            <category><![CDATA[advice]]></category>
            <dc:creator><![CDATA[Pan Wangperawong]]></dc:creator>
            <pubDate>Mon, 18 Aug 2014 15:11:04 GMT</pubDate>
            <atom:updated>2017-02-17T15:14:03.855Z</atom:updated>
            <content:encoded><![CDATA[<iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2F_kQBVneC30o%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D_kQBVneC30o&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2F_kQBVneC30o%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/7bba693cc6fd081bbc2fbb267581c64f/href">https://medium.com/media/7bba693cc6fd081bbc2fbb267581c64f/href</a></iframe><p>Eminem is someone I would consider talented and entrepreneurial. When watching this video, it may seem like the importance of this clip is his ability to rhyme with the word <em>orange. </em>Looking deeper, what makes this video interesting is his attitude. He is not affected by the status quo, has a can do attitude, and thinks outside the box.</p><blockquote><strong><em>“When people say the word orange doesn’t rhyme with anything, it kind of pisses me off … If you are taking the word at face value, nothing is going to rhyme with it exactly.”</em></strong></blockquote><p>A good attitude mixed with creativity really goes a long way.</p><blockquote><strong><em>“If you enunciate it and you make it more than one syllable, like oor-range, you could say, ‘ I put my oor-range, four inch, door hinge in storage, and ate porridge with jorage’. You just have to find the science to breaking down words.”</em></strong></blockquote><p>Funny how I discovered this video due to a poorly constructed rhyme I attempted (or plainly jumbling words) in front of a friend (thanks Will). What a serendipitous occurrence, I guess this is what it means to learn from failure :D.</p><p>If you enjoyed reading this post, recommend it to a friend and follow me <a href="https://twitter.com/_panw">@_panw</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a6cad9343708" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Easy Cooking Video Series: Staying Fit & Healthy As A Programmer]]></title>
            <link>https://medium.com/@panw/easy-cooking-video-series-staying-fit-healthy-as-a-programmer-c0b39dfa19d?source=rss-7971be52b730------2</link>
            <guid isPermaLink="false">https://medium.com/p/c0b39dfa19d</guid>
            <dc:creator><![CDATA[Pan Wangperawong]]></dc:creator>
            <pubDate>Sun, 13 Jul 2014 18:42:08 GMT</pubDate>
            <atom:updated>2014-07-13T18:42:08.140Z</atom:updated>
            <content:encoded><![CDATA[<h4>Chicken Fried Rice In 15 Minutes</h4><p>In <em>Staying Fit &amp; Healthy As A Programmer</em> series, I’m advocating you to start cooking your food in order to improve your health and fitness. Check out the articles here:</p><ul><li><a href="http://panprogramming.tumblr.com/post/90804360777/staying-fit-healthy-as-a-programmer-part-2-what-to">Staying Fit &amp; Healthy As A Programmer Part 2</a></li><li><a href="http://panprogramming.tumblr.com/post/91520053942/staying-fit-healthy-as-a-programmer-part-3-eat-kale">Staying Fit &amp; Healthy As A Programmer Part</a> 3</li></ul><p>When I suggested that you start cooking your own meals, I realize it could be daunting, so I’m launching the <a href="http://youtu.be/8RheGzpdlLQ?list=PLpYRrZhTOBNo-0fRO7N31I89AHjVSvC1q"><strong><em>Easy Cooking</em></strong></a><strong><em> </em></strong>video series on Youtube to introduce you to simple recipes that don’t take a lot of time or effort and taste great. In this video, learn to cook Chicken Fried Rice in 15 minutes:</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2Fvideoseries%3Flist%3DPLpYRrZhTOBNo-0fRO7N31I89AHjVSvC1q&amp;url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D8RheGzpdlLQ%26list%3DPLpYRrZhTOBNo-0fRO7N31I89AHjVSvC1q&amp;image=http%3A%2F%2Fi1.ytimg.com%2Fvi%2F8RheGzpdlLQ%2Fhqdefault.jpg&amp;key=d04bfffea46d4aeda930ec88cc64b87c&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/9c6632febca26c63b65353a62270c12e/href">https://medium.com/media/9c6632febca26c63b65353a62270c12e/href</a></iframe><p>I’ll be uploading my cooking videos to this <a href="http://youtu.be/8RheGzpdlLQ?list=PLpYRrZhTOBNo-0fRO7N31I89AHjVSvC1q">Youtube playlist</a></p><p>Get updates on when I release more videos by following me on Twitter: <a href="https://twitter.com/itspanw">@itspanw</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c0b39dfa19d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Staying Fit & Healthy As A Programmer]]></title>
            <link>https://medium.com/@panw/staying-fit-healthy-as-a-programmer-bdc6a9065227?source=rss-7971be52b730------2</link>
            <guid isPermaLink="false">https://medium.com/p/bdc6a9065227</guid>
            <dc:creator><![CDATA[Pan Wangperawong]]></dc:creator>
            <pubDate>Sat, 12 Jul 2014 05:18:30 GMT</pubDate>
            <atom:updated>2014-07-12T15:52:22.313Z</atom:updated>
            <content:encoded><![CDATA[<h4>Part 3 — Eat Kale</h4><p><em>This is a series of articles discussing tactics I use to stay fit and healthy as a programmer working at a startup company. </em><a href="http://panprogramming.tumblr.com/post/90537634477/staying-fit-healthy-as-a-programmer-part-1-defining"><em>Part 1</em></a><em>, Part2, </em><a href="http://panprogramming.tumblr.com/post/91520053942/staying-fit-healthy-as-a-programmer-part-3-eat-kale"><em>Part </em></a><em>3</em></p><p>Last article, I talked about how you should start transitioning to cooking your own food. It’s essential for fitness and health. If you compare the average person who cooks all his meals versus a person who purchases his meals, it’s evident. The restaurant and preprepared food business always tries to squeeze as much marginal profit out as possible, so unfortunately they will find ways to cut down cost and use lower quality ingredients (high fructose corn syrup vs sugar in the US).</p><p>This article is dedicated to KALE — no joke. Ok maybe not entirely, but on <strong>COARSE VEGETABLES and LEGUMES. </strong>It will be a major tool to help you transition to a more healthy eating habit and eventually cooking your own meals. Here’s a list of some coarse vegetables and legumes:</p><blockquote>kale</blockquote><blockquote>broccoli</blockquote><blockquote>cauliflower</blockquote><blockquote>lentil beans</blockquote><blockquote>black beans</blockquote><blockquote>pinto beans</blockquote><p>Before I get into the rational for coarse vegetable, let me share with you how I use kale with my meals. This will vary from person to person, but this works for me:</p><blockquote><strong>Kale with meals</strong><br>I have 3-5 leaves of kale before I have my meal.</blockquote><blockquote><strong>Kale with snacks<br></strong>I primarily eat 1-2 leaves of kale for snacks that has processing, such as bread and peanut butter or cookies.</blockquote><p>A lot of people who has shared a meal with me will remember me eating raw kale and it really sticks with them. They always wonder why and I explain it to them. Then the next time I see them they are eating kale. I don’t think they always understand my explanation, but I guess from looking at the shape I’m in, they are convinced. Don’t take anything I say blindly though.</p><p>The reason why you want to eat coarse vegetables such as kale or legumes is because we</p><ol><li>tend to overeat</li><li>eat a lot of sweet, salty, and carby food</li><li>eat processed food</li></ol><blockquote><strong>(1) We tend to overeat<br></strong>It’s hard to gauge how much food our body needs to consume, so we tend to eat until we feel full. By that time you have already overeaten. If you incorporate coarse vegetables or legumes into the beginning of your meals, you’ll start to feel full faster, as a result you eat less or in this case an amount relatively closer to how much you really need.</blockquote><blockquote><strong>(2) We eat a lot of sweet, salty, and carby food<br></strong>This goes back to the period when humans were migrating and hunting all the time. Humans of this period would have to migrate based on seasons, hunt food, run away from predators, and they didn’t have the conveniences we have today. These tasks requires a lot more energy than we use in present day for the average person and our body hasn’t had enough evolutionary time to update this craving. With coarse vegetables, it slows down your stomach acids from processing these types of food, so we don’t get a bunch of sugar at once. These types of food tends to gives you food coma, but if you have it with coarse vegetables or legumes it’ll remedy it.</blockquote><blockquote><strong>(3) We eat processed food<br></strong>When you consume processed food your body will break it down faster since it’s processed. This leads to your body intaking the food too fast and when your body doesn’t need that amount then it becomes fat and waste, so if we have coarse vegetables or legumes with it then the intake is slower.</blockquote><p>If you do this and make it a habit, I guarantee your body will start craving more healthy food. Most restaurant and processed food will taste like crap — unless they are really good. Start doing this with your meals and slowly transition to cooking your own meals. Post below if you have any questions.</p><p>Oh btw this is what Dino Kale looks like, just in case you are looking for it in the supermarket today :D</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/1*BB3rRdrgyx0rMvXTl6inNA.jpeg" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=bdc6a9065227" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>