<?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 Jazz Lien on Medium]]></title>
        <description><![CDATA[Stories by Jazz Lien on Medium]]></description>
        <link>https://medium.com/@ro5112?source=rss-d868d749a9cc------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*bOHL8kt0-8VWylbRpaFpMw.png</url>
            <title>Stories by Jazz Lien on Medium</title>
            <link>https://medium.com/@ro5112?source=rss-d868d749a9cc------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 24 Nov 2026 08:59:18 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@ro5112/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[How to Make Films with AI Tools: Step by Step]]></title>
            <link>https://medium.com/@ro5112/how-to-make-films-with-ai-tools-step-by-step-65e69b9f267e?source=rss-d868d749a9cc------2</link>
            <guid isPermaLink="false">https://medium.com/p/65e69b9f267e</guid>
            <dc:creator><![CDATA[Jazz Lien]]></dc:creator>
            <pubDate>Tue, 17 Nov 2026 00:00:46 GMT</pubDate>
            <atom:updated>2026-11-17T09:15:41.220Z</atom:updated>
            <content:encoded><![CDATA[<p><a href="https://x.com/Jazzpujols34/status/2122516205248676016/video/1">https://x.com/Jazzpujols34/status/2122516205248676016/video/1</a></p><p>Nothing in this 94-second film about Taiwan was shot with a camera. Every frame is a gouache-style painting made by Gemini. Claude Code edited it by writing code.</p><p>This guide splits the work into the nine steps I actually followed. Each step includes where I got stuck, so you can skip those detours. If you would rather have your own AI agent walk you through it, there is a full prompt to copy near the end.</p><h3>The three tools</h3><p>Each tool handles one part of the job.</p><p><strong>Gemini</strong> paints the images. Google’s image models draw from a text description. You can also attach a reference image and ask for the same painting style.</p><p><strong>Remotion</strong> turns the images into a video. You describe the film in code: “this image, zoom in slowly, fade out over one second, hold for this many frames.” Remotion renders an MP4.</p><p><strong>Claude Code</strong> writes all the code. It is an AI coding agent that creates files and runs commands on your computer. You do not need to know React. You do need to watch what it makes and say when something is wrong.</p><p>My own role was closer to a director. I set the shot list, watched every version, and rejected what did not work.</p><h3>Step 1: Write the brief and pick a style reference</h3><p>Before anything gets painted, decide two things: how the film should feel, and what the paintings should look like.</p><p>My brief to Claude Code was short. A slow, warm, slightly nostalgic travel film, about 90 seconds, vertical, made for phones. Only gentle camera pushes and drifts, soft dissolves between shots, almost no text.</p><p>For the style, I used 17 Taiwan illustrations I had made with AI earlier: the Alishan forest train, tea pickers, Jiufen and the Pingxi sky lanterns. Every new image was generated with one of them attached as a reference. That is the most reliable way to make 18 scenes look like one set.</p><p>If you have no reference yet, spend some time getting one or two images you like. Then use them as the reference for everything after.</p><h3>Step 2: Put the shot list in a config file and batch-generate</h3><p>Do not keep the shot list in the chat. Put it in a config file, one entry per shot: what to paint, the time of day, how long it holds, which reference to use. Mine looks like this (trimmed):</p><p>Then ask Claude Code for a small script that sends each shot to Gemini with its reference image. The core is two lines:</p><p>I generated two takes per shot and had them tiled into one contact sheet. Thirty-two images took about 12 minutes. Picking from one contact sheet is much faster than opening images one by one.</p><p>Two warnings before you start.</p><p>First, the model matters more than you would expect. My first batch used Gemini’s cheapest image model at 1K. My whole reply was: “This looks too ugly right now. I can’t accept it.” Switching to Nano Banana 2.1 gave 2K images, 1536 by 2752 pixels. That is sharper than the final 1080 by 1920 video, and the style matched my references almost exactly. It costs less than two cents more per image.</p><p>Second, do not put the same object in every scene. I wanted one sky lantern to drift through the whole film as a through-line. Claude Code cut a lantern out of my Pingxi painting and placed it over a salt field to test the idea. It looked pasted on.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*bxy1JMwd_2Rhvx3Q.jpg" /></figure><p>The angle could be fixed. The light could not, unless every scene was repainted and checked. A lit lantern over a salt field at noon also makes no sense. I dropped the idea and used the time of day as the through-line instead, from dawn to late night. The lantern appears once, at the end, in Pingxi where it belongs.</p><p>Think about shot length early too. Ninety seconds across 10 scenes means 9 seconds per shot, which is long on a phone. I cut it to about 6 seconds, so the scene count went from 10 to 18.</p><h3>Step 3: Fix the local details the AI gets wrong</h3><p>This step took the most time. The images were beautiful, but the details were often wrong in ways only a local would notice.</p><p>Bubble tea was the first case. The first version had dome lids and pastel cups. Nobody in Taiwan drinks it like that. I sent Claude Code a photo, and it wrote the details into the prompt: a tall clear 700 ml cup, a flat sealed film on top, a thick straw punched straight through, a dense layer of big pearls at the bottom. The next version was right.</p><p>Taipei 101 was also fixed with a photo. The color was wrong and the fireworks were scattered across the sky. After the photo, the tower turned dark navy-teal at night, and the fireworks shot from the tower’s corners and drooped down, like a real New Year’s Eve.</p><p>Images with text were the hardest. The lottery shop sign said 彩券 (lottery) correctly. The posters next to it were full of fake Chinese, characters that look real at a glance and are not.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*bUryDP5ojRH7OSEj.jpg" /></figure><p>In the election scene, the first round had 凍蒜 (a campaign chant meaning “get elected”) on almost every flag, sometimes only half of it. One candidate looked a lot like a real politician, and another image had someone waving a national flag. I am not showing that round, for the same reasons I rejected it.</p><p>For any scene with text, I ended up using two fixes. One: hard rules for the writing. Flags carry only a circled number. 凍蒜 appears exactly once, on the side of the sound truck. Every candidate gets clearly invented features. Two: a different model. These two scenes moved to the pricier Gemini 3 Pro Image, which writes Chinese far more accurately. The lottery shop worked on the first try. The election took two rounds.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*X7pNTCDi9WeyxJA5.jpg" /></figure><p>I also tried a map of Taiwan as the opening. Both versions added English place names I had asked it to leave out, and one put the Meinong paper umbrellas on the east coast. I did not use it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*G6v9wvzX9yPfMpRg.jpg" /></figure><p>The lesson was the same every time. The model’s idea of a place is a tourist’s idea. What worked was a photo plus a specific description. Rewording the prompt alone almost never helped.</p><h3>Step 4: Turn the images into a film with Remotion</h3><p>Once the images are picked, ask Claude Code to set up a Remotion project. Each shot is a component: one image with a slow push or drift, joined to the next with a one-second fade. The skeleton of the whole film looks like this:</p><p>Do not build the whole film first. I asked for a 10-second sample with two shots to check the camera speed, the transition and the type. Only then did we assemble the full film. Render previews at half resolution; it is much faster.</p><p>One small thing to ask for: a new file name for every preview. At one point I kept thinking a change had not worked. My player was still showing the old file.</p><h3>Step 5: Add music and cut on the beat</h3><p>I found the music on Pixabay, a free library: “Sentimental Emotional Piano &amp; Strings” by Tunetank. Claude Code suggested slow piano and strings. It also suggested avoiding guzheng and erhu, because foreign audiences tend to hear those as Chinese first.</p><p>This next trick made the biggest difference in feel. Claude Code analyzed the track in code and found a steady beat about every 0.83 seconds. It set every shot to a whole number of beats, so every cut lands on the beat. That is what the beats field in the config is for. Busy shots get fewer beats, quiet ones more. The cut to Taipei 101 lands on the loudest moment of the song.</p><p>One catch: Claude Code cannot hear. It can measure where the track is loudest, but volume is your call. It started the music at 90% of the original level. I said “too loud” three times before it settled at 15%.</p><h3>Step 6: Overlay text in code, and draw the position for the AI</h3><p>I wanted “I ♥ TW” on Taipei 101, the way the tower lights up messages on New Year’s Eve. Do not ask the image model to paint text like this. Ask Claude Code to overlay it in code. The letters are then always correct, they can light up one by one, and changing the message is a one-line edit.</p><p>Placing it was another story. It took six tries: vertical, horizontal, two lines, then vertical again on the seam between two faces of the tower. My reply to that one was: “Even more crooked…”</p><p>The problem was that it kept guessing where the seam was. First it used the exact center of the tower, then a darker line to the right. In the end I drew a line on a screenshot and said, “Put the letters on this line.” The next version was right.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/768/0*zPh8XbGviMaurPcM.jpg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/360/0*v3XhQAjoSKdH1Y7z.jpg" /></figure><p>So for anything about position, stop describing it in words. Draw it on a screenshot. My “middle line” and its “middle line” were never the same line.</p><p>This is also when the small motion effects went in: steam from the train, flickering lanterns, embers under the Pingxi lanterns, glints on the sea at Lanyu, and a faint paper texture over everything so the 18 images feel like one set. Expect to tune the strength. My first reaction was “too subtle.” After it was turned up, the steam over the night market food looked wrong, so it came out.</p><h3>Step 7: The opening and the ending</h3><p>I made the opening three times. It is the easiest part to underestimate.</p><p>Version one was a still title card held for 4.5 seconds. People scrolling social media decide in about two seconds. Version two had the title rising out of white steam before revealing the train. It still felt abrupt. Version three added a painting of the Alishan sunrise over a sea of clouds before the train. The film opens in white mist, the title surfaces, and the mist clears to reveal the sunrise. That one stayed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*trnSyQ_Mh0O9QB_K.jpg" /></figure><p>The ending was easier. The last shot shrinks into a postcard wall of all 18 scenes, and the same title returns in the middle.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/360/0*db8Q3YzRG0Ej-pLO.jpg" /></figure><h3>Step 8: Export for sharpness and a sane file size</h3><p>My first real export was 132 MB and looked slightly soft. Claude Code looked for the cause before touching any settings.</p><p>It ruled out the usual suspects. The frames were just as soft before compression, so compression was not the cause. Removing the paper texture changed nothing. Rendering at twice the resolution did not help either. It found two causes. The Gemini images are only 1536 pixels wide, and the camera push enlarges them by about 10%. And Remotion saves every frame as a compressed image before building the video, which loses a little more.</p><p>The fix was to capture every frame at maximum quality and add a light sharpening pass. The picture improved, but the file grew to 335 MB. My reaction: “It’s a 90-second video and it’s that big? I can’t accept that.”</p><p>File size is controlled by a number called CRF. A lower number keeps more detail and makes a bigger file. Claude Code tried three settings and measured how close each one was to the sharpened version, where 1 means identical.</p><p>The scores are close. Side by side and zoomed in, I could not see a difference, and the night scenes showed no color banding. I went with 50 MB, using an encoder mode tuned for animation that saves space on large flat areas of color.</p><p>To do it in one pass, use these two commands:</p><p>The first renders at maximum quality, which makes a large file. The second sharpens lightly and compresses to a normal size.</p><h3>Step 9: Don’t let the transfer ruin it</h3><p>When I sent the finished file to my phone, it looked soft again. This time the file was fine. The app I used to transfer it had compressed it on the way. Resending it with AirDrop brought the quality back.</p><p>Here is the same frame of the umbrella maker four ways. The old files were deleted during the project, so panels 1 and 2 are re-renders with the settings used at the time. Panel 4 is a screenshot from my phone, scaled to the same size, so it went through a different path from the other three.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*KS5MlhVQ8PiViDTT.png" /></figure><p>Panel 1 is the half-resolution preview. Panel 2 is the first export. Panel 3 is the final sharpened 50 MB version. Panel 4 is the phone screenshot after the transfer app compressed it. Sharpening helped a little. The transfer did the most damage.</p><p>So when you post to X or LinkedIn, upload the original file from a computer. If you post from your phone, move the original there with AirDrop or cloud storage, not a messaging app.</p><h3>Hand it to your AI agent</h3><p>To make your own, copy the whole block below and paste it into Claude Code, or any AI agent that can create files and run commands on your computer. It follows the nine steps in this guide, one at a time, and stops after each step for your approval.</p><p>You need two things first: a Gemini API key (the pass that lets a program call Gemini, free to create in Google AI Studio), and Node.js, Python and ffmpeg installed. If anything is missing, the agent checks in step 0 and helps you install it.</p><p>Every mistake in this guide is built into that prompt. The agent asks you for photos, quotes the cost before spending, uses new file names, and never asks the image model to write text. You only need to watch the results and make the calls.</p><h3>Cost per task</h3><p>The whole film had a Cost per Task of about $22: $4.15 for images and $18.07 for Claude Code. These are list prices, not an actual bill. The 17 reference images I made earlier are not included.</p><p>The images came to about $4, for 79 images in total.</p><p>Claude Code came to about $18, converted at Claude API prices per token (the unit AI models use to count text). Most of it ran on Opus 5.5, for $16.95. Early on, one call to the stronger Fable 5.2 to review the plan added $1.12. The count stops when I approved the finished film.</p><p>Most of that money went to re-reading. Every time Claude Code replies, it reads the whole conversation again. With caching, which stores what it has already read, each re-read token is cheap. But by the time the film was done, it had re-read about 35 million tokens. By step, it breaks down like this:</p><p>Setup, first batch, the failed lantern idea (incl. one plan review)</p><p>$4.17</p><p>Generating 16 scenes, picking takes</p><p>$0.96</p><p>Fixing bubble tea, 101, the lottery shop, the election</p><p>$2.21</p><p>Sample, music, opening and ending</p><p>$1.96</p><p>Placing “I ♥ TW” on 101</p><p>$2.00</p><p>Volume, motion effects, beat sync, three openings</p><p>$3.09</p><p>First export, drafting the post</p><p>$1.09</p><p>Chasing the blur, compressing the file</p><p>$2.59</p><p>Later work costs more per message, because there is more conversation to re-read. Those four letters on Taipei 101 cost $2, about half as much as all 79 images.</p><p>Nothing else cost money. The music is from Pixabay, and rendering and compression ran on my laptop. Remotion is free for individuals and small companies; larger companies need a paid license, see <a href="https://www.remotion.dev/license">its license page</a>.</p><p>If you make your own, the money goes to revisions, not images. Images are cheap enough to generate two takes per scene and throw one away. Save your budget and patience for the local details and the few letters that will not sit straight.</p><p>The caption I posted with it was my own line: “90 seconds of Taiwan. We’re more than stinky tofu!” The stinky tofu is on the table in the night market scene, next to a plate of pickled cabbage.</p><p><em>A Chinese version of this guide is on </em><a href="https://jazzlien.com/blog/taiwan-film-gemini-claude-code"><em>jazzlien.com</em></a><em>.</em></p><p><em>Originally published at </em><a href="https://jazzlien.com/blog/how-to-make-a-short-film-with-ai-tools/"><em>https://jazzlien.com</em></a><em> on November 17, 2026.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=65e69b9f267e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Dejargonizing AI: The Vital Difference Between Skills, Subagents, and MCPs]]></title>
            <link>https://medium.com/@ro5112/dejargonizing-ai-the-vital-difference-between-skills-subagents-and-mcps-d401eee68ec4?source=rss-d868d749a9cc------2</link>
            <guid isPermaLink="false">https://medium.com/p/d401eee68ec4</guid>
            <dc:creator><![CDATA[Jazz Lien]]></dc:creator>
            <pubDate>Mon, 05 Jan 2026 07:02:31 GMT</pubDate>
            <atom:updated>2026-01-05T07:02:31.693Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ONGSkcj2vN1CZcyuWFrjYw.jpeg" /></figure><p>The current landscape of Artificial Intelligence is moving at breakneck speed. Every week, a new framework, a new architecture, or a new buzzword emerges, promising to revolutionize how we work. If you are trying to build actual workflows with Large Language Models (LLMs), the noise can be deafening.</p><p>Everyone is talking about building “agents.” But an agent isn’t just a single, monolithic block of code. To build effective, reliable AI systems, you need to look under the hood.</p><p>When you start peeling back the layers of advanced AI workflows, you inevitably encounter three critical concepts that are often confused or used interchangeably: <strong>Skills, Subagents, and MCPs (Model Context Protocol).</strong></p><p>Lumping these together is a recipe for buggy, unreliable, and expensive AI implementations. Understanding the distinct role of each is the key to moving from “playing around with chatbots” to building robust enterprise automation.</p><p>Here is a deep dive into the simple breakdown: <strong>Skills are the <em>how</em>, Subagents are the <em>who</em>, and MCPs are the <em>what tools</em>.</strong></p><h3>1. Skills: The “Standard Operating Procedures”</h3><p>At its core, an LLM is a brilliant improviser. It has read the entire internet, so it knows a little bit about everything. But in a business context, improvisation is rarely what you want. You want consistency. You want adherence to brand guidelines. You want specific output formats.</p><p>This is where <strong>Skills</strong> come in.</p><p>A Skill is fundamentally a set of explicit, written instructions — often in the form of robust system prompts or few-shot examples — that tell the LLM exactly <em>how</em> to perform a specific task.</p><p>Think of an LLM as a brilliant new hire fresh out of university. They are smart, but they don’t know <em>your</em> company’s way of doing things. A Skill is the employee handbook or the Standard Operating Procedure (SOP) manual you hand them on day one.</p><h4>Examples of Skills:</h4><ul><li><strong>Data Analysis Norms:</strong> “When analyzing spreadsheets, always calculate year-over-year growth percentages first, identify top 3 outliers, and summarize findings in bullet points limited to 20 words each.”</li><li><strong>Brand Voice Guidelines:</strong> “Write customer emails using a professional but empathetic tone. Avoid jargon. Always close with ‘warm regards.’ Never admit fault directly but focus on solutions.”</li></ul><h4>Why Skills Matter:</h4><p>Without defined Skills, the LLM will guess how you want the task done based on its general training data. Sometimes it will be brilliant; sometimes it will be wildly off-base. Skills turn stochastic, random generation into reliable, reusable business processes. They ensure that no matter which specific model you are using, the <em>style</em> and <em>structure</em> of the output remain consistent.</p><h3>2. Subagents: The Specialized Workforce</h3><p>If you give a single human employee five totally different jobs — say, writing code, testing that code, documenting it, marketing it, and handling customer support for it — they will eventually burn out, make mistakes, and context-switch themselves into oblivion.</p><p>LLMs suffer from a similar problem. If you ask one LLM instance to handle a massive, complex workflow in a single prompt chain, it often gets confused. It “hallucinates,” loses track of instructions, or produces mediocre results across the board.</p><p><strong>Subagents</strong> are the solution. A Subagent is an “extra copy” or a distinct instance of the LLM that is assigned one specific job within a larger workflow.</p><p>Instead of one generalist trying to do everything serially, you spin up specialized Subagents to work in parallel. This mimics a real-world organizational structure.</p><h4>The Software Development Analogy:</h4><p>Imagine automating a software update. It’s unlikely that one person can do it all. You would have a team that looks like this:</p><ul><li><strong>Subagent A (The Coder):</strong> Assigned the role of writing the feature based on the spec.</li><li><strong>Subagent B (The Reviewer):</strong> Assigned the role of reviewing Subagent A’s code for security flaws.</li><li><strong>Subagent C (The Writer):</strong> Assigned the role of updating the documentation based on the approved changes.</li></ul><h4>Why Subagents Matter:</h4><p>Subagents allow for <strong>parallelism and specialization</strong>. By narrowing the scope of what each LLM instance has to worry about, you increase accuracy. The “Reviewer” agent doesn’t need to know how to write the code; it only needs to know how to <em>critique</em> it. This separation of concerns keeps the workflow organized and resilient.</p><h3>3. MCPs (Model Context Protocol): The Universal Power Plug</h3><p>We have the “how” (Skills) and the “who” (Subagents). But LLMs, by default, their knowledge is cut off at their training date. They cannot see live database nor cannot check the current weather, and they certainly cannot update a ticket in your project management software.</p><p>For an agent to actually <em>do</em> work in the real world, it needs hands.</p><p>This is where <strong>MCPs</strong>, or the <strong>Model Context Protocol</strong>, come into play.</p><p>While “Skills” and “Subagents” are general architectural concepts, MCP is a specific technical standard designed to solve the connectivity problem.</p><p>Think of MCP as a “universal power plug” or a standardized API bridge for LLMs. Before standardized protocols, connecting an LLM to an external tool required writing custom, brittle glue-code for every single integration. MCP provides a standardized way for the LLM to ask, “What tools do I have available?” and then structure a request to use those tools.</p><h4>Examples of MCP Usage:</h4><ul><li>“I need to check the status of ticket id#123.” (The MCP provides the bridge to the API).</li><li>“Query the ‘Users’ PostgreSQL database for accounts created in the last 24 hours.” (The MCP provides the bridge to your SQL database).</li><li>“Search the internal company Notion wiki for our refund policy.”</li></ul><h4>Why MCPs Matter:</h4><p>MCPs change AI from a passive knowledge retrieval system into an active participant in your business. They act as the secure gateway between the probabilistic reasoning engine of the LLM and the deterministic reality of your software ecosystem.</p><h3>Putting It All Together: Where It Clicks</h3><p>The true power of modern AI automation doesn’t come from using just one of these; it comes from their synergy.</p><p>Let’s visualize a sophisticated workflow: <strong>Handling a Customer Support bug report.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DlgsyM9LapTHt2FNYcaVzw.jpeg" /><figcaption><strong>Handling a Customer Support bug report workflow</strong></figcaption></figure><ol><li>A new ticket arrives. The “<strong>Root Agent</strong>” delegate it to the <strong>“Triage Subagent”</strong> (The Who).</li><li>It uses an <strong>MCP</strong> (The Tool) to connect to Jira and read the ticket details.</li><li>It applies a <strong>“Classification Skill”</strong> (The How) to determine if this is a critical bug or a feature request.</li><li>Finding it’s a bug, it passes the info to the <strong>“Developer Subagent.”</strong></li><li>The Developer Subagent uses a different <strong>MCP</strong> to search GitHub for similar existing issues.</li><li>Finally, a <strong>“Communication Subagent”</strong> uses a <strong>“Brand Voice Skill”</strong> to draft a reply to the customer, assuring them it’s being looked into.</li></ol><h3>Conclusion</h3><p>The most common mistake beginners make is trying to cram everything into one “God Prompt” — five pages of instructions, list twenty tools, and expect the LLM to manage the multi-step project perfectly — this rarely works.</p><p>By separating your logic (Skills), your workforce (Subagents), and your connectivity (MCPs), you build systems that are modular, debuggable, and significantly more powerful.</p><p>To summarize the simple breakdown:</p><ul><li><strong>Skills</strong> = The written guides on <strong>how</strong> to do something correctly.</li><li><strong>Subagents</strong> = The specialized roles defining <strong>who</strong> does what (often in parallel).</li><li><strong>MCPs</strong> = The universal plugs defining <strong>what external tools</strong> the agents can reach.</li></ul><p>I hope this breakdown has clarified how these pieces fit together in the modern AI stack. I’d love to hear from you: <strong>What are some of the fun ideas or specialized agents you’ve built using similar framework?</strong> Whether it’s a personal research assistant or a complex coding pipeline, feel free to share your projects with us!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d401eee68ec4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Use Docker to Run Nginx Web Server in Ubuntu! — Part II: Running and Managing Nginx]]></title>
            <link>https://medium.com/@ro5112/use-docker-to-run-nginx-web-server-in-ubuntu-part-ii-running-and-managing-nginx-2b9d7f7f3dac?source=rss-d868d749a9cc------2</link>
            <guid isPermaLink="false">https://medium.com/p/2b9d7f7f3dac</guid>
            <category><![CDATA[ubuntu]]></category>
            <category><![CDATA[nginx]]></category>
            <category><![CDATA[docker]]></category>
            <dc:creator><![CDATA[Jazz Lien]]></dc:creator>
            <pubDate>Tue, 28 May 2024 02:02:34 GMT</pubDate>
            <atom:updated>2024-05-28T03:16:45.646Z</atom:updated>
            <content:encoded><![CDATA[<h3>Use Docker to Run Nginx Web Server in Ubuntu! — Part II: Running and Managing Nginx</h3><p>Welcome back to the second part of our series on using Docker to run an Nginx web server in Ubuntu!</p><p>This is a two-series articles, in <strong>Part I</strong>, we covered the basics of Docker, from installation to running your first Nginx container. If you missed it, be sure to check it out:</p><p><a href="https://medium.com/@ro5112/use-docker-to-run-nginx-web-server-in-ubuntu-part-i-getting-started-with-docker-20f8eb1bf5fb">Use Docker to Run Nginx Web Server in Ubuntu! — Part I: Getting Started with Docker</a></p><p>Now that we have a solid foundation, it’s time to dive deeper. In this part, we’ll explore how to manage and configure our Nginx container, tailor it to our specific needs, and make use of advanced Docker commands.</p><p>In the previous article, we had a nginx container running, let’s run docker --help and we can see that in order to list containers, use:</p><pre>docker ps</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Ix6Lwd6luNOnx8MNBqLiJw.png" /></figure><p>If we run docker ps, we only see one container, that’s because it only shows containers that are running, if we want to see all the containers, we add the -a option , run</p><pre>docker ps -a</pre><p>we can see the stopped containers are also listed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*DEg4EmousX3JXi6sV_pUng.png" /></figure><p>To start or stop a container, use:</p><pre>docker start &lt;image-name&gt;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*P8E4TMtUP_783KbKG-h-EQ.png" /></figure><pre>docker stop &lt;image-name&gt;</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LGntm30G__tN5svG0Coihw.png" /></figure><p><strong>Networking and Testing</strong></p><p>With <strong>mywebserver</strong> running, test its connection with the Nginx server:</p><pre>nc localhost 8080</pre><p>And typeGET / to send a get request to the web server which should in return a web page and the index web page specifically in text format.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-5Aq_hX5pd3xrOqEw2WdbA.png" /></figure><p>This confirms that our containerized Nginx works and the port is indeed published to our host.</p><h3>Docker run vs. Docker Start</h3><p>It can be a bit confusing about what’s the difference between these two commands.</p><p>The <strong>docker run</strong> command builds and starts a container from an image, while the <strong>docker start</strong> command only starts an existing container.</p><p>We can remember this way:</p><ul><li>If the container doesn’t exist, use <strong>docker run</strong> to initialize it.</li><li>If it does, use <strong>docker start</strong>.</li></ul><h3><strong>Managing Docker Images and Containers</strong></h3><p>In the first part, we learned that we could use <strong>docker rmi</strong> to remove an image. However, sometimes you might encounter conflicts because the image is being used.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*014xASsA9kI1OdgZnKsdWg.png" /></figure><p>To resolve this:</p><ul><li>stop the container</li><li>remove the container</li><li>then remove the image</li></ul><p>You can force delete an image with the <strong>-f</strong> option:</p><pre>docker rmi -f &lt;image-name&gt;</pre><p>After running <strong>docker images</strong> again, you should see that the image has been successfully removed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FF9E_dTfHy3_s8NSvJ2bow.png" /></figure><h3><strong>Dockerfile and Building Custom Images</strong></h3><p>Let’s talk about building our own Docker image.</p><p>So far, we’ve worked with publicly available container images, like the Nginx image.</p><p>But in the real world, these generic images might not be enough, and we’ll need to build our own.</p><p>Create a new directory named <strong>myimage</strong> and a simple <strong>index.html</strong> file inside it</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wQqk15fCflWrBPI7tAjBpQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*C4DSJmvH5FtXHBZuRvZpXw.png" /></figure><p>Next, tell Docker how to build this image.</p><p>The instructions should be in a file named <strong>Dockerfile</strong> (with a capital D).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TqcpE6Z51jl2Vdnw4vPmkA.png" /></figure><p>Add the following text to the Dockerfile:</p><pre>FROM nginx <br>COPY index.html /usr/share/nginx/html/index.html</pre><p>This tells Docker to use the nginx base image and copy our <strong>index.html</strong> file to a specific path inside the container, replacing the pre-existing file with our custom one.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Rvu5JT35FBCt39XyMTK-mQ.png" /></figure><p>To build our image, use:</p><pre>docker build --tag student/customnginx:1.0 myimage</pre><p>Here, <strong>myimage</strong> is the directory where we included our project files and Dockerfile.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yroBLwBqamRJcsDmTrKp4g.png" /></figure><p>After the image is built, run a container based on this image:</p><pre>docker run --detach --publish 9000:80 --name mywebserver3 student/customnginx:1.0</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CxWhvxheIHhTa2vrF-4j8w.png" /></figure><p>Test the Nginx container by running:</p><pre>nc localhost 9000 <br>GET /</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9NO9qen50yzJgOY3ome44w.png" /></figure><p>Notice how Nginx returns the content we inserted in our <strong>index.html</strong> file.</p><p>This confirms that our modifications took effect and we successfully built our own image with a custom index page!</p><h3>Conclusion</h3><p>This tutorial covered a variety of Docker commands and how to use them in real-world scenarios. From setting up Docker and running basic commands to deploying and managing an Nginx web server, we’ve walked through the steps to containerize your applications. I hope you found this guide useful and feel confident using Docker to streamline your development process.</p><p>Happy containerizing!</p><h3>Thank you so much for reading my article, before you go, please</h3><ol><li><em>Clap 50 times for this story</em> 👏👏👏</li><li><em>Leave a comment telling me your thoughts</em></li><li><em>Highlight your favourite part of the story</em></li></ol><p>Thank you! These tiny actions go a long way, and I really appreciate it!😃</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2b9d7f7f3dac" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Use Docker to Run Nginx Web Server in Ubuntu! — Part I: Getting Started with Docker]]></title>
            <link>https://medium.com/@ro5112/use-docker-to-run-nginx-web-server-in-ubuntu-part-i-getting-started-with-docker-20f8eb1bf5fb?source=rss-d868d749a9cc------2</link>
            <guid isPermaLink="false">https://medium.com/p/20f8eb1bf5fb</guid>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[nginx]]></category>
            <category><![CDATA[ubuntu]]></category>
            <dc:creator><![CDATA[Jazz Lien]]></dc:creator>
            <pubDate>Mon, 27 May 2024 02:02:20 GMT</pubDate>
            <atom:updated>2024-05-28T03:16:11.612Z</atom:updated>
            <content:encoded><![CDATA[<h3>Use Docker to Run Nginx Web Server in Ubuntu! — Part I: Getting Started with Docker</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZFp_cJD4g1wOfW-UOw6jcw.png" /></figure><p>In today’s fast-paced tech world, efficiency and consistency are key to successful software development and deployment. Docker, a leading containerization platform, has revolutionized the way developers build, ship, and run applications.</p><p>If you’re new to Docker or looking to solidify your understanding, you’re in the right place.</p><p>This is a two-series articles, if you are very familiar with Docker already, you can jump to the second part of the story:</p><p><a href="https://medium.com/@ro5112/use-docker-to-run-nginx-web-server-in-ubuntu-part-ii-running-and-managing-nginx-2b9d7f7f3dac">Use Docker to Run Nginx Web Server in Ubuntu! — Part II: Running and Managing Nginx</a></p><h3>What is Docker?</h3><p>Docker is a powerful tool designed to make it easier to create, deploy, and run applications by using containers.</p><p>But what exactly is a container? Imagine you have a set of items you need to ship: different pieces of furniture, appliances, and boxes of personal belongings. Instead of shipping each item separately, you pack everything into a single container. This container ensures all your items are kept together, safe, and can be moved easily regardless of where they are shipped.</p><p>Similarly, in the world of software, a Docker container packages all the parts needed to run a software application, including the code, libraries, dependencies, and system tools. This container can run on any machine, making it incredibly versatile and efficient. Whether you’re running your application on your local computer, a server, or in the cloud, Docker ensures it runs smoothly every time.</p><p>I recommend watching this video for a quick overview of what Docker is:</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FGjnup-PuquQ%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DGjnup-PuquQ&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FGjnup-PuquQ%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/4c75f7326ae45d70a10af8272c8ec8c8/href">https://medium.com/media/4c75f7326ae45d70a10af8272c8ec8c8/href</a></iframe><p>In this two-part guide, we will start with the basics of setting up Docker and understanding its fundamental commands. By the end, you’ll be ready to deploy and manage an Nginx web server using Docker in Ubuntu, making your development process faster and more reliable.</p><p>Let’s dive in!</p><h3><strong>Install and Enable Docker in Linux</strong></h3><p>Let’s start by installing Docker on our virtual machine. Run the following command to install Docker:</p><pre>sudo apt install docker.io</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/958/1*pf1vtktnDCessoGgpIfxdA.png" /></figure><p>After the installation is complete, enable the Docker service and check the status of the Docker service to ensure it’s running:</p><pre>sudo systemctl enable docker<br>sudo systemctl status docke</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/958/1*t0uh9U594VZcuqYiTEMegQ.png" /></figure><p>You should see a status message indicating that Docker is <strong>active (running)</strong>.</p><p>Now that Docker is up and running, let’s pull the first quickstart image by executing:</p><pre>sudo docker run hello-world</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/958/1*l1PG0OAZytrOU804BDMwOw.png" /></figure><p>If you see the message <strong>Hello from Docker!</strong>, congratulations!</p><p>Docker has been successfully installed and is ready to use.</p><h3><strong>Add User to Docker Group</strong></h3><p>Notice that if we try to run Docker commands without <strong>sudo</strong>, we get a &quot;permission denied&quot; error. This is because the current user is not in the Docker group. To run Docker commands without needing to add <strong>sudo</strong> every time, we need to add the user to the Docker group.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/958/1*4Ld9Z6UxmWf5DhntVlENbA.png" /></figure><p>First, add the docker group if it doesn&#39;t already exist:</p><pre>sudo groupadd docker</pre><p>Next, add your user (who has root privileges) to the Docker group:</p><pre>sudo usermod -aG docker $USER</pre><p>As the current user, we can run groups to see that we are indeed in the docker group, and we can run docker commands without adding sudo.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/892/1*eQEBX8C_B3k2XFKgOfCqSg.png" /></figure><h3><strong>Docker Commands Introduction</strong></h3><p>Now that we have Docker up and running, let’s look at how to use it!</p><p>There are a lot of commands in Docker. The first place to find them is:</p><p>docker --help</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/958/1*fKdEcMPFxPDJvlKrukD1_w.png" /></figure><h4><strong>Docker Search and Pull</strong></h4><p>Let’s see how to find the images we need to build our Nginx web server.</p><p>Use <strong>docker search</strong> to find the images:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/958/1*6E4Myg1Pt7SQjZTNI7yngQ.png" /></figure><p>Let’s run:</p><pre>docker search enginx</pre><p>The first one on the list, with almost twenty thousand stars, is exactly what we want for this demo!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jRpXFJRYe1RcyLHEtH2n6w.png" /></figure><p>Download the image by running:</p><pre>docker pull nginx</pre><p>You can also pull other images you like, for example:</p><pre>docker pull ubuntu/nginx</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OW2tuCD9WM37j5968zQENQ.png" /></figure><p>Now that we have the images, check them with:</p><pre>docker images</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hgu0oXLMzuOfY-D7Jg6-9A.png" /></figure><p>The images we pulled have the “latest” tag, which is used to differentiate image variations.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OW2tuCD9WM37j5968zQENQ.png" /></figure><p>The default is “latest,” but we can set it to the desired version.</p><p>You can specify the version with:</p><pre>docker pull nginx:1.22.1</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*--5avYMeo2Gwc1EfrsTudw.png" /></figure><p>And check it with docker images we see that we pull a nginx with tag 1.22.1 successfully.</p><p>To remove an image, use: docker rmi nginx:1.22.1</p><p>Use docker images , we can see that nginx:1.22.1 is no longer there!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Vr1BB9q-yQJHMOOriGuPXg.png" /></figure><p><strong>Running Nginx Container</strong></p><p>Now that we have the nginx image, let’s run it:</p><p>docker run nginx</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7dazDzUe-vqA-1fyV_Nalw.png" /></figure><ul><li>If the terminal gets stuck, fix it by running:</li></ul><p>docker run --detach --publish 8080:80 --name mywebserver nginx</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jg_I92TFeCOKP8Zt7VS6CQ.png" /></figure><p>The parameters are:</p><ul><li><strong>-detach</strong>: Detach from the container.</li><li><strong>-publish 8080:80</strong>: Redirect network traffic from port 8080 to port 80 of the container.</li><li><strong>-name mywebserver</strong>: Name the container.</li><li><strong>nginx</strong>: The image to use.</li></ul><p>If you see a unique identifier, congratulations, you have a running Nginx container!</p><p>By following these steps, we have</p><ol><li>Successfully installed Docker</li><li>Added our user to the Docker group</li><li>Pulled the Nginx image</li><li>Run our first Nginx container</li></ol><p>This setup ensures that your Docker environment is ready and capable of running web servers.</p><p>But we’re just getting started.</p><p>In <strong>Part II</strong>, we’ll dive deeper into managing our Nginx container, configuring it to suit our needs, and exploring more advanced Docker commands to optimize our web server setup.</p><p>Be sure to check out the next part of this series, where we’ll take our Docker skills to the next level!</p><h3>Thank you so much for reading my article, before you go, please</h3><ol><li><em>Clap 50 times for this story</em> 👏👏👏</li><li><em>Leave a comment telling me your thoughts</em></li><li><em>Highlight your favourite part of the story</em></li></ol><p>**Thank you! These tiny actions go a long way, and I really appreciate it!**😃</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=20f8eb1bf5fb" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Quick Tutorial: How to deploy GPT-4o on Azure OpenAI]]></title>
            <link>https://medium.com/@ro5112/quick-tutorial-how-to-deploy-gpt-4o-on-azure-openai-160bbeeb4b4f?source=rss-d868d749a9cc------2</link>
            <guid isPermaLink="false">https://medium.com/p/160bbeeb4b4f</guid>
            <category><![CDATA[data-analysis]]></category>
            <category><![CDATA[gpt-4]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[openai]]></category>
            <category><![CDATA[azure]]></category>
            <dc:creator><![CDATA[Jazz Lien]]></dc:creator>
            <pubDate>Fri, 24 May 2024 02:54:43 GMT</pubDate>
            <atom:updated>2024-05-24T02:54:43.390Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XkWtL3qy31P6iX6SkhXn_g.jpeg" /></figure><p>Previous GPT-3 and GPT-4 models were large language models, meaning they only supported text input and output.</p><p>It wasn’t until later that they could be paired with Azure AI’s Vision to enable image reading capabilities.</p><p>However, the newly launched GPT-4o model no longer requires pairing with Vision to read images and respond.</p><p>This is a quick tutorial on how to deploy your own “gpt-4o” on Azure OpenAI Service.</p><p>First, go to your Azure OpenAI Studio, under “<strong>Management</strong>” -&gt; Seletct “<strong>Deployments</strong>” -&gt; Select “<strong>Create new deployment</strong>”</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/913/1*CSjfTMdV1q5Q3sZ9oj0M4g.png" /></figure><p>On the dropdown, select the “<strong>gpt-4o</strong>” model &gt;&gt; Give a cutom deployment name &gt;&gt; Select “<strong>Create</strong>”</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/772/1*5T-KS2dvAHftYth2GVijFg.png" /></figure><p>After the model deployment was successful, Under “<strong>Playground</strong>” &gt;&gt; Select “<strong>Chat</strong>” &gt;&gt; Select the<strong> gpt-4o model deployment</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*T0Ef_czIpkVS1igxdtcHHw.png" /></figure><p>Now you can upload an image for the model to answer questions:</p><p>I uploaded a chart of the Taiwan stock market trends and my prompt for the model was as simple as “Analyze this pic.”</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IPN_bhs8CXTGwYxSNqZlfw.png" /></figure><p>Here is the model’s response to my image:</p><p>The image shows a financial market summary with several key indicators and a chart tracking the performance of a specific index over a single day.</p><p>Here’s a breakdown of the information provided:</p><h3>Key Indicators:</h3><p><strong>Taiwan Capitalization Weighted Stock Index (台灣加權指數)</strong>:</p><ul><li>Current Value: 21,607.43</li><li>Change: +55.60 (+0.26%)</li></ul><p><strong>USD/TWD (US Dollar to Taiwan Dollar Exchange Rate)</strong>:</p><ul><li>Current Value: 32.304</li><li>Change: +0.05 (+0.16%)</li></ul><p><strong>CNY/TWD (Chinese Yuan to Taiwan Dollar Exchange Rate)</strong>:</p><ul><li>Current Value: 4.4605</li><li>Change: +0.01 (+0.15%)</li></ul><p><strong>Dow Jones Industrial Average (道瓊指數)</strong>:</p><ul><li>Current Value: 39,065.26</li><li>Change: -605.78 (-1.53%)</li></ul><p><strong>NASDAQ Composite (那斯達克指數)</strong>:</p><ul><li>Current Value: 16,736.03</li><li>Change: -65.51 (-0.39%)</li></ul><h3>Chart Analysis:</h3><ul><li>The chart depicts the performance of the Taiwan Capitalization Weighted Stock Index over the course of a single day.</li><li>The market opens at 9:00 AM and shows a sharp decline initially.</li><li>After hitting a low point, the index rebounds and shows a general upward trend before stabilizing.</li><li>The index experiences some fluctuations around noon but remains relatively stable in the afternoon.</li><li>The dotted line represents a specific value, 21,551.83, which could be a previous close or a significant threshold.</li></ul><h3>Time Frames:</h3><ul><li>The chart is currently set to display data for 1 day. Options to view data for 5 days, 1 month, 1 year, 5 years, or the maximum available period are also present.</li></ul><h3>Market Status:</h3><ul><li>The bottom right corner indicates that the Taiwan market is currently open.</li><li>Overall, the provided data indicates that the Taiwan Capitalization Weighted Stock Index had a volatile start but managed to gain a positive overall change by the end of the day, despite fluctuations in global indices like the Dow Jones and NASDAQ.</li></ul><p>For me it’s really mind-blowing what this model can achieve in such a short period of time, and it’s really exciting how much potential it will help us unlock in the near future!</p><p>Currently, the regions where the “gpt-4o” model can be deployed include “<strong>eastus”, “eastus2”, “northcentralus”, “southcentralus”, “westus”, </strong>and “<strong>westus3”</strong> (as of May 2024).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*x_TD61pIjMtfbE13VKZ9Tw.png" /></figure><p>Azure cloud platform changes rapidly, and it’s very possible that the regions available for deployment may be adjusted soon.</p><p>When planning to establish a new AOAI resource, it is advised to refer to the latest news provided by the official Microsoft Azure OpenAI documents: <a href="https://learn.microsoft.com/en-us/azure/ai-services/openai/concepts/models#model-summary-table-and-region-availability">Model summary table and region availability</a>.</p><h3>Thank you so much for reading my article, before you go, please</h3><ol><li><em>Clap 50 times for this story</em> 👏👏👏</li><li><em>Leave a comment telling me your thoughts</em></li><li><em>Highlight your favourite part of the story</em></li></ol><p><strong>Thank you! These tiny actions go a long way, and I really appreciate it!</strong>😃</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=160bbeeb4b4f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Azure OpenAI Usage Guide: How to Assign the Right Roles for Your Team]]></title>
            <link>https://medium.com/@ro5112/azure-openai-usage-guide-how-to-assign-the-right-roles-for-your-team-1f30f1aec19d?source=rss-d868d749a9cc------2</link>
            <guid isPermaLink="false">https://medium.com/p/1f30f1aec19d</guid>
            <category><![CDATA[azure]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[cloud]]></category>
            <category><![CDATA[step-by-step-guide]]></category>
            <dc:creator><![CDATA[Jazz Lien]]></dc:creator>
            <pubDate>Fri, 22 Mar 2024 02:29:32 GMT</pubDate>
            <atom:updated>2024-03-22T02:29:32.070Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/822/1*bvEKUwdfMetJUINFyAVQ8Q.jpeg" /><figcaption>Created by Bing Image Creator</figcaption></figure><h3>Introduction</h3><p>Configuring different roles on Azure is crucial for effective team collaboration and protecting key resources.</p><p>Role-Based Access Control (RBAC) not only ensures that each user can access the resources they need to perform their work but also prevents them from accessing sensitive information or settings they shouldn’t.</p><p>The hierarchical management of permissions facilitates a clear division of responsibilities, enhances security, and ensures the smooth operation of projects.</p><p>Before using Azure OpenAI, we also need to grant appropriate permissions to team members to deploy and manage AI models, to protect these resources from unauthorized access and reduce security risks.</p><p>In this article, we’ll look at how to correctly assign roles, allowing team members to smoothly use the Azure OpenAI (AOAI) service!</p><h3>Insufficient Permissions</h3><p>If you’ve set up an AOA resource but see the deployment option grayed out, displaying the following message:</p><blockquote>“Authorization failed: the user does not have permissions for this operation. Check the user roles to add the required permissions.”</blockquote><p>This indicates that you do not have the permission to access and deploy models, and we need to add the required roles to your account.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VKFGj46TZmL2XGHWswmDtg.jpeg" /></figure><p>First, let’s return to the AOAI resource we just created and select <strong>Access control (IAM)</strong>’on the left sidebar.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZSwoWFwvTDulb02l74s3gg.jpeg" /></figure><p>Click <strong>Add </strong>and select <strong>Add role assignments</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ob3bqEZGufVA5_BbMbuawg.jpeg" /></figure><h3>Permission Assignment Demonstration</h3><p>To use the AOAI service, we can assign the following permissions:</p><ul><li><strong>Cognitive Services OpenAI User</strong></li><li><strong>Cognitive Services OpenAI Contributor</strong></li><li><strong>Cognitive Services Contributor</strong></li><li><strong>Cognitive Services Usages Reader</strong></li></ul><p>We won’t go into the differences between each permission here, but you can refer to the official documentation for further reading:</p><p><a href="https://learn.microsoft.com/en-us/azure/ai-services/openai/how-to/role-based-access-control">Role-based access control for Azure OpenAI - Azure AI services</a></p><p>I chose to use the <strong>Cognitive Services Contributor </strong>for this article.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KvcqkQZo9kDwCtw4geb8Uw.jpeg" /></figure><p>After selecting the role to assign, the next step is to choose the person to assign it to.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7T_hciGYALwvw0LrT6_WQA.jpeg" /></figure><p>Click <strong>Select </strong>to choose the members, and assign them the permissions.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*z7mdJcfJ_ASC12fpEp7esg.jpeg" /></figure><p>Once you’ve confirmed the members and the role to be assigned, click <strong>Review + assign</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3x1LU19dU-b05Abms-2kWQ.jpeg" /></figure><p>You will see <strong>Added Role assignments</strong> displayed in the upper right corner shortly after the role assignment is completed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vEq8DncxhB61xXDbkymo3A.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*j_suLVFHOoj-tteA14jTQA.jpeg" /></figure><p>We can click <strong>View my access</strong> for further veryfication, where you can see the <strong>Cognitive Services Contributor</strong> I just assigned has been successfully added.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*uX3CDFgmefx0Wb1ER-o3Hw.jpeg" /></figure><p>At last, let’s return to AI Studio, and this time we are able to create LLM models provided in this region!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KsHAmEXSYn-muWbm_BafSg.jpeg" /></figure><h3>Conclusion</h3><p>In today’s rapidly digitalizing era, correctly configuring roles and access permissions is extremely important for cloud services. Through Role-Based Access Control (RBAC), we can ensure team members access the resources they need, protecting sensitive data from being exposed to risks.</p><p>This article demonstrated how to assign appropriate roles to team members on Azure. Through practical guide, I hope you can better how to configure the roles for your members, understand the importance of managing access permissions on cloud platforms and confidently apply Azure OpenAI services in their projects.</p><p>Happy Coding!</p><h3>Thank you so much for reading my article, please share your feedbacks!</h3><p>If you would like to further discuss on the topic or have any questions, feel free to leave a comment or contact me 😃</p><p>If you like this article, please don&#39;t forget to give me claps 👏👏👏 thank you!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1f30f1aec19d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Step-by-Step Guide on How to enable GitHub Copilot in Jetbrain IDEs (Take PyCharm for example)]]></title>
            <link>https://medium.com/@ro5112/step-by-step-guide-on-how-to-enable-github-copilot-in-jetbrain-ides-take-pycharm-for-example-3e4677c1d0d2?source=rss-d868d749a9cc------2</link>
            <guid isPermaLink="false">https://medium.com/p/3e4677c1d0d2</guid>
            <category><![CDATA[github-copilot]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[pycharm]]></category>
            <category><![CDATA[python]]></category>
            <dc:creator><![CDATA[Jazz Lien]]></dc:creator>
            <pubDate>Tue, 30 Jan 2024 09:00:00 GMT</pubDate>
            <atom:updated>2024-01-30T09:00:00.043Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*kBMYCrj2SZf01GWNNO2Adg.png" /></figure><p>Consider this scenario: You’re trying to change the fifth element in a list, or perhaps you’re struggling to add audio files to your application. Suddenly, you’re stuck with an error that seems unsolvable.</p><p>It’s a common experience for programmers to spend countless hours on Google, searching for those seemingly simple solutions that our minds just can’t seem to grasp in the moment.</p><p>In today’s rapidly evolving tech landscape, we’re fortunate to have the power of AI at our disposal to streamline these tedious tasks, allowing us to focus on the more intricate aspects of our work.</p><p>Among the myriad of AI tools accelerating our developmental pace, GitHub Copilot stands out as a remarkable boon for programmers. Its wide-ranging compatibility across programming languages and platforms makes it accessible to almost every developer.</p><p>While the benefits of AI in transforming our world are immense, this article specifically aims to guide you through enabling the GitHub Copilot feature in PyCharm.</p><p>Let’s dive in and get started!</p><h3><strong>Prerequisites</strong></h3><p>If you haven’t yet subscribed to GitHub Copilot and are curious to try it out, there’s an option to start with a free trial of Copilot Individual.</p><p>Remember, if you cancel before the trial period ends, you won’t incur any charges.</p><p>Apply for access here:</p><p><a href="https://github.com/features/copilot">GitHub Copilot · Your AI coding agent · GitHub</a></p><p>In this guide, I’m using PyCharm Community Edition — a robust, open-source, and free IDE, particularly beneficial for Python developers.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*r5cVcBaQ7EKGM9q3L7jnOA.jpeg" /></figure><p>You can download PyCharm here:</p><p><a href="https://www.jetbrains.com/pycharm/download/?section=windows">Download PyCharm: The Python IDE for data science and web development by JetBrains</a></p><h3><strong>Install GitHub Copilot Plugin</strong></h3><p>Let’s begin by installing GitHub Copilot.</p><p>Once the PyCharm installation is complete, create a new Python file named ‘app.py’. You’ll notice that GitHub Copilot isn’t enabled initially; the IDE doesn’t generate code based on your comments.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/843/1*zwX_w0-5mBDfp0hgxXZqgg.jpeg" /></figure><p>On the top left panel, select <strong>File &gt; Settings</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/459/1*SPxfopSmYbFV-cnuhoJ7RQ.jpeg" /></figure><p>Select <strong>Plugins</strong> and <strong>search for GitHub Copilot </strong>and install the plugin<strong>.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1017/1*a-9547C2IFrHnHCfyx3mIA.jpeg" /></figure><p>After the installation, we’ll need to restart the PyCharm to enable the feature. Select <strong>Restart.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*H54dj16iM9n_aYRkCkkzBg.jpeg" /></figure><p>After restarting PyCharm, GitHub Copilot should be active. To utilize its features, you’ll need to log in to your GitHub account and link it with PyCharm.</p><p>Select <strong>Sign in to GitHub</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Kfq8bohMSXlHSvxp_lSKtA.jpeg" /></figure><h3><strong>Link GitHub account to Copilot Plugin</strong></h3><p>In order to authorize our account, let’s copy and paste the device code to our GitHub Activation page.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/619/1*FSbGrn9d2kuO2a-xGyWMDQ.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/577/1*j0TRs5i0Azijp9_cZL8sNg.jpeg" /></figure><p>Once the device code is verified, your GitHub account will be successfully linked with the GitHub Copilot Plugin in the PyCharm IDE.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/725/1*mPzFrJURtSBcr5v9Njj5Jg.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/885/1*rkiO_DL0iXmoocYSV090mw.jpeg" /></figure><p>Let’s head back PyCharm and we see that Copilot is suggesting code based on the comment! 🎉</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/891/1*KxymuPX2hFqLPdYal0Qebw.jpeg" /></figure><h3><strong>GitHub Copilot Chat</strong></h3><p>For those already acquainted with ChatGPT-like features, GitHub Copilot offers a ChatGPT-like tool known as Copilot Chat.</p><p>This can be found in the right-hand panel, represented by a chat icon. Copilot Chat saves us the hassle of switching between tabs and applications to copy-paste code into ChatGPT. It keeps you in the coding ‘flow,’ which is essential for efficient programming.</p><p>It’s worth noting that for JetBrains IDEs, Copilot Chat is still in the preview stage. Users with an individual subscription need to join a waitlist to access this feature.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/682/1*afcAs_9kNvgxB3XbWBjvnQ.jpeg" /></figure><p>I’m optimistic that soon, we’ll all experience the profound benefits of this tool, elevating our programming skills to the next level!</p><h3><strong>Conclusion</strong></h3><p>GitHub Copilot represents a significant leap forward in the world of programming by seamlessly integrating AI-driven coding assistance directly into the IDE. It not only enhances our productivity but also introduces a new level of efficiency in developers and problem-solving.</p><p>Whether you’re experimenting with the free trial or diving into the full experience, the potential of GitHub Copilot in streamlining your coding workflow is immense.</p><p>As we anticipate the advancement of AI, the future of programming looks more promising than ever. Embracing these advancements, we stand on the brink of a new era in software development, where AI tools like GitHub Copilot are indispensable allies in our coding journey.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3e4677c1d0d2" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Create an AI Chatbot on a Microsoft Teams Channel with Power Automate! — A Step-by-Step Guide]]></title>
            <link>https://medium.com/@ro5112/create-an-ai-chatbot-on-a-microsoft-teams-channel-with-power-automate-a-step-by-step-guide-f7d043e62c40?source=rss-d868d749a9cc------2</link>
            <guid isPermaLink="false">https://medium.com/p/f7d043e62c40</guid>
            <category><![CDATA[azure]]></category>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[microsoft-teams]]></category>
            <category><![CDATA[power-automate]]></category>
            <category><![CDATA[openai]]></category>
            <dc:creator><![CDATA[Jazz Lien]]></dc:creator>
            <pubDate>Thu, 09 Nov 2023 05:33:11 GMT</pubDate>
            <atom:updated>2023-11-09T05:35:58.539Z</atom:updated>
            <content:encoded><![CDATA[<h3>Create an AI Chatbot on a Microsoft Teams Channel with Power Automate! — A Step-by-Step Guide</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*c3nLZGFvyPx3fZ23v-IlOw.jpeg" /><figcaption>Generated by Leonardo.Ai</figcaption></figure><p>This article introduces how to create an AI Chatbot on a Microsoft Teams channel using a powerful automation tool — Power Automate.</p><p>Power Automate allows users to design and execute automated workflows with ease using drag-and-drop functions and parameter settings, enabling the creation of an intelligent chatbot effortlessly.</p><p>Follow this step-by-step guide to learn how to use Power Automate’s features in conjunction with the Azure OpenAI service on the Azure platform. Soon, members in your Teams channel will be able to call upon and utilize the Chatbot, giving everyone an AI assistant!</p><p>This implementation spans across three platforms, and I will divide it into three main phases for explanation, as follows:</p><ol><li><strong>Data Preparation</strong></li><li><strong>Building Power Automate Flow</strong></li><li><strong>Testing the Flow</strong></li></ol><h3>#1 Data Preparation Phase</h3><p>We will demonstrate how to gather the necessary data on each platform during this phase. If you already have the required data, such as a Teams channel or the key to the Azure OpenAI resource, you may skip this stage and proceed to the next phase of building the workflow.</p><h3>Power Automate</h3><ul><li>Power Automate account (Note: <strong>A Power Automate Premium license is required to complete this project</strong>)</li><li><a href="https://powerautomate.microsoft.com/en-us/pricing/">Power Automate Pricing and Subscription Plans | Microsoft Power Automate</a></li><li><a href="https://powerautomate.microsoft.com/en-us/pricing/">https://powerautomate.microsoft.com/en-us/pricing/</a></li></ul><h3>Azure OpenAI Resource</h3><p>We need access to the Key and Endpoint of the Azure OpenAI resource.</p><ul><li><a href="https://azure.microsoft.com/en-us/get-started/azure-portal">Go to the Azure Portal</a></li><li>Create an Azure OpenAI resource (Or request access through this link: <a href="https://customervoice.microsoft.com/Pages/ResponsePage.aspx?id=v4j5cvGGr0GRqy180BHbR7en2Ais5pxKtso_Pz4b1_xUOFA5Qk1UWDRBMjg0WFhPMkIzTzhKQ1dWNyQlQCN0PWcu">Request Access to Azure OpenAI Service</a>)</li></ul><p><a href="https://customervoice.microsoft.com/Pages/ResponsePage.aspx?id=v4j5cvGGr0GRqy180BHbR7en2Ais5pxKtso_Pz4b1_xUOFA5Qk1UWDRBMjg0WFhPMkIzTzhKQ1dWNyQlQCN0PWcu">Dynamics 365 Customer Voice</a></p><ul><li>Go to the resource’s “Keys and Endpoint”</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*ZTYmlk4mbn_DRvjW4fkzrg.jpeg" /></figure><ul><li>Copy and save the Key value for later use</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LMzmbjcmSBCdQNzi47WgJA.jpeg" /></figure><ul><li>Enter Azure OpenAI Studio</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/1*a_Wq858NuetO98oaMICCfg.jpeg" /></figure><ul><li>Model Deployment: The model used for this demonstration is “<strong>gpt-3.5-turbo-instruct</strong>” (currently available only in regions: <strong>East US</strong> and <strong>Sweden Central</strong>). After deployment, go to “Playground” under “Completions”</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/790/1*Gul10Leek3idiy2NSYg7BQ.jpeg" /></figure><ul><li>Click on “View code,” copy the “Endpoint” and save it for later use</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/723/1*kZJlFmujpkJD2qHnz-axyQ.jpeg" /></figure><h3>Microsoft Teams</h3><p>Create a basic test channel. It’s a simple demonstration on how to create a new channel, you can also adjust according to your needs.</p><ul><li>Click on “Create team” in Teams</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/530/1*S71jkUIUgn7MzBL-m9SaJw.jpeg" /></figure><ul><li>Choose “From scratch”</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*t1kaunqHJQ5UZXql76a0qw.jpeg" /></figure><ul><li>Choose “Private”</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/753/1*icgXt-p0IwG6DyhUd47IDw.jpeg" /></figure><ul><li>Name the channel of your choice, I name it “ChatGPT”.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/752/1*ZRBzlzQXv0NLM9TC9w7z_Q.jpeg" /></figure><ul><li>Ensure the channel is successfully created</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/532/1*Sc2bkli6PyYn3SRDgvDbuQ.jpeg" /></figure><h3>#2 Building Power Automate Flow Phase</h3><p>Once the data is prepared, we can start building our AI Chatbot!</p><ul><li>First, go to Power Automate</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*b3tVUGeOQ4Vt6ojVl3knCQ.jpeg" /></figure><ul><li>Click on “My flows” on the left and create an “Automated cloud flow”</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/663/1*hlqMaxHXofm3cwA9Lie2ZQ.jpeg" /></figure><ul><li>Give the flow a name, and for the trigger, choose “When keywords are mentioned”</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*No6PpxLyE73v00-FRQqymw.jpeg" /></figure><ul><li>Choose to execute in a “Channel” and set the keyword. I’m using “<strong>ChatGPT</strong>” here, then select the channel to execute in. After completion, click “+ New step”</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/757/1*H2ETiB8IhtAOBnPKgg5pLg.jpeg" /></figure><ul><li>Search and select “Get message details,” choose “Message ID” for the message field, and “Reply to message ID” for the Parent message ID field. Then click “Add an action”</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/794/1*H5BXG8qaJaIOF3aNf36CzQ.jpeg" /></figure><ul><li>Search and select “HTTP,” which also requires a <strong>PREMIUM</strong> account. You can apply for a trial account first and later decide if you want to apply for a subscription.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/795/1*IyjUjMR7lpaFDLtpVYWjVA.jpeg" /></figure><ul><li>For the Method, choose “POST,” paste the “Endpoint” saved earlier, and add two Headers: “api-key” and “Accept”</li><li>Paste the Key value in the value of “api-key”, and add “application/json” to the Accept header</li><li>In the Body part, the value for “prompt” needs to include “Body Content”</li><li>After completion, click “Add an action.”</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/635/1*DeoZ9_hyqQLt5C7RwtnHWA.jpeg" /></figure><ul><li>Search and select “Reply with a message in a channel,”</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/792/1*0ipIisazl2qboCmhn2n9AQ.jpeg" /></figure><ul><li>Choose “Reply to message ID” for the Message ID field.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/790/1*NHzA6Ug5F6YkieqrDLRQdQ.jpeg" /></figure><ul><li>For the Message part, select “Expression” and we want to extract only the text part of the ChatGPT model’s response, add the value:</li></ul><pre>body(&#39;HTTP&#39;)[&#39;choices&#39;][0]?[&#39;text&#39;]</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1qH0ieNxF6ytrfXEe2IuTA.jpeg" /></figure><p>Once the above steps are completed, click “Save,” and our AI Chatbot is all set!</p><p>Now let’s go to the Teams channel and test it out!</p><h3>#3 Testing the Flow Phase</h3><p>Go to the designated channel and add “<strong>ChatGPT</strong>” (or the keyword you chose) before the message you send.</p><p>The model will then generate a reply (completions) based on the prompt you provided!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*q18K4ojuxjEmBuIf6liWtA.jpeg" /></figure><p>We can also return to Power Automate and click on “Flow checker” to see if the automation has been successfully executed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hGwN5EQmTTtfa4V72ypPgg.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vqFgNi6t9MUcdua1EHR26w.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/644/1*u1KHCHO7CwIUOJKEC2DZ9A.jpeg" /></figure><h3>Conclusion</h3><p>This article has shown how to easily create a powerful AI Chatbot in a Microsoft Teams channel without writing any code, just by dragging and dropping with Power Automate’s tools and setting parameters, we experienced the convenience of Power Automate as an automation tool and its powerful functionality when combined with Azure OpenAI service.</p><p>Now, your Teams channel has an AI assistant on standby, ready to answer queries, execute commands, and interact in various ways.</p><p>Go and experience the changes what AI can bring to our world!</p><h3>Thank you so much for reading my article, feedback is welcome!</h3><p>Feel free to leave any feedback in the comments😀</p><p>If you like the article, please don&#39;t forget to give me claps, thank you!👏👏👏</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f7d043e62c40" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Comparison of Azure OpenAI Models: GPT-3.5 Turbo vs. GPT-3.5 Turbo Instruct]]></title>
            <link>https://medium.com/@ro5112/comparison-of-azure-openai-models-gpt-3-5-turbo-vs-gpt-3-5-turbo-instruct-0f87ba83bf36?source=rss-d868d749a9cc------2</link>
            <guid isPermaLink="false">https://medium.com/p/0f87ba83bf36</guid>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[api]]></category>
            <category><![CDATA[llm]]></category>
            <category><![CDATA[openai]]></category>
            <category><![CDATA[azure]]></category>
            <dc:creator><![CDATA[Jazz Lien]]></dc:creator>
            <pubDate>Tue, 31 Oct 2023 02:20:42 GMT</pubDate>
            <atom:updated>2023-10-31T02:20:42.149Z</atom:updated>
            <content:encoded><![CDATA[<p>Microsoft announced that in September, the Azure OpenAI service now supports the GPT-3.5 Turbo Instruct model.</p><p>Upon hearing this news, some may wonder: <strong>GPT-3.5 Turbo Instruct?</strong> Is it different from <strong>GPT-3.5 Turbo</strong>? What’s the connection between them?</p><p>This article will introduce the differences between these two models, paired with actual use cases, so we can better understand which model to choose in suitable scenarios.</p><p>For more recent updates on Azure OpenAI services, you can find them here:</p><p><a href="https://learn.microsoft.com/en-us/azure/ai-services/openai/whats-new">What&#39;s new in Azure OpenAI Service? - Azure AI services</a></p><h3>What is “GPT-3.5 Turbo Instruct”?</h3><p>So, what is “GPT-3.5 Turbo Instruct”? GPT-3.5 Turbo Instruct is a LLM Model that’s similar to “text-davinci-003”, using the Completion API with 4097 token limit.</p><p>As of the first release of the model, only two regions can create “GPT-3.5 Turbo Instruct”: <strong>East US</strong> and <strong>Sweden Central.</strong></p><p>In 2023 June, Azure platform added models like GPT-35 Turbo and GPT-4 that use the ChatCompletion API to replace models that use the Completion API (“text-davinci-003”). Many applications based on this model have been affected, and the code must also be modified according to the “ChatCompletion API”.</p><p>Next, we will dive into the differences of<strong> “Completion” &amp; “ChatCompletion”</strong> to have a better understanding between these 2 types of APIs.</p><h3>Completion? ChatCompletion?</h3><p>If we want the content output by the Azure OpenAI model to be more in line with the expected results, we must understand the differences between these two APIs.</p><p>Using both Completion and ChatCompletion APIs can achieve similar results in simple tasks, but ChatCompletion is more flexible in prompts construction.</p><p>ChatCompletion model has been optimized for chat scenarios. In terms of features, it has the option of defining AI model system messages, while also having a built-in structure to provide previous messages.</p><p>The Completion API can also achieve similar results, but additional formatted prompts are required. This is achieved through so-called <em>meta prompts</em> to help the AI model understand the relationship between previous and subsequent prompts.</p><p><strong>Completion vs. ChatCompletion Comparison Table</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/875/1*l4RJFDB-IoDHMazB7Idtbw.jpeg" /></figure><h3>Azure OpenAI Studio Playground</h3><p>Still sounds a bit vague? The best way is to go directly to the Azure OpenAI Studio to try out the two models yourself.</p><p><strong>Prerequisites:</strong></p><ul><li>Azure subscription</li><li>Azure OpenAI Service resource</li><li>Deployment the “GPT-3.5 Turbo” model</li><li>Deployment the “GPT-3.5 Turbo Instruct” model</li></ul><h3><strong>Completion:</strong></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qzG9u4tf4Vdp6jI30ZGNQg.jpeg" /></figure><ul><li>Go to Azure AI Studio</li><li>Click on “Completions”</li><li><strong>Description</strong>: This method seems to be a more traditional approach to interacting with a model. The user provides a single input or “prompt” to the model, and the model responds with a completion or continuation of that input.</li><li><strong>Code Example</strong>:</li></ul><pre>openai.Completion.create</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/714/1*2IOaUajOErJ998_a-er1fg.jpeg" /></figure><ul><li>Usage: The user instructs the model using a “Prompt” to specify what kind of response or completion they are expecting from the model.</li></ul><h3><strong>ChatCompletion:</strong></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2lp4iHMbmbuqM_0biz8B4Q.jpeg" /></figure><ul><li>Go to Azure AI Studio</li><li>Click on “Chat”</li><li><strong>Description</strong>: This method simulates a chat-based interaction with the model. Instead of just providing a single prompt, the user can have a back-and-forth conversation with the model. It’s more dynamic and can be especially useful for multi-turn conversations.</li><li><strong>Code Example</strong>:</li></ul><pre>openai.ChatCompletion.create</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/709/1*xiGc6IqaFhhtwp8Ism6owA.jpeg" /></figure><ul><li>Usage: The model takes on a role (like “system” or “assistant”), and the user interacts with the model in a chat format. Both the user and the model have roles in the conversation, facilitating a more interactive and dynamic exchange.</li></ul><h3><strong>GPT-3.5 Turbo vs. GPT-3.5 Turbo Instruct Model Performance</strong></h3><p>After understanding the basic concepts and differences of the two models, we let the two models perform 5 tasks and use three measurement standards to judge the performance of the model. They are:</p><ul><li><strong>CPU times</strong>: The total time the program runs on the Central Processing Unit (CPU)</li><li><strong>Wall time</strong>: The actual elapsed time from the start of the program to its completion. Includes time for I/O operations, waiting for other programs, system scheduling, etc.</li><li><strong>Model Completion</strong> : The complete string replied by the model.</li></ul><p><strong>Task #1: True or False Question</strong></p><p>Question (Prompt): Did Microsoft acquire OpenAI?</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*vXf9GhAPODvnSIo9qyN5Uw.jpeg" /><figcaption><strong>Task #1</strong>: True or False Question</figcaption></figure><p><strong>Task #2: Compassion</strong></p><p>Question (Prompt): “I’m so sad, can you say some encouraging words to me?”</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*WUIkQCyP5dd97kGfqwG2fQ.jpeg" /><figcaption><strong>Task #2: Compassion</strong></figcaption></figure><p><strong>Task #3: Code Generation</strong></p><p>Question (Prompt): “Can you write a Python fuction that reads a CSV file and prints out every other row?”</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oXLylsZmAfqrtRklJxRPmw.jpeg" /><figcaption><strong>Task #3: Code Generation</strong></figcaption></figure><p><strong>Task #4: Sentiment Analysis</strong></p><p>Question (Prompt): “Please provide a sentiment analysis of the following paragraph: ‘Coca-Cola Company’s third-quarter shareholder attributable profit was 2.825 billion US dollars, an annual increase of 14%; after adjustment, earnings per share were 69 US cents, exceeding market expectations.’”</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/691/1*VSnCzDcwihb8fOew-HPaUw.jpeg" /><figcaption><strong>Task #4: Sentiment Analysis</strong></figcaption></figure><p><strong>Task #5: Wikipedia Summary</strong></p><p>Question (Prompt): “Search: Times Square, please tell me 5 interesting facts.”</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TgNpkqsd8l4c8U1mh3jXFw.jpeg" /><figcaption><strong>Task #5: Wikipedia Summary</strong></figcaption></figure><p>From the above tasks, we can see that in terms of CPU computation and execution time, “GPT-3.5 Turbo” is somewhat more than “GPT-3.5 Turbo Instruct”, as for the response part, each has its merits and unique highlights. Which one do you prefer?</p><h3>Conclusion</h3><p>This article revolves around two large language models in Microsoft’s Azure OpenAI: “GPT-3.5 Turbo” and “GPT-3.5 Turbo Instruct”. Although the names are similar, their usage methods have some differences due to the fact that each uses the above-mentioned “Completion API” and “ChatCompletion API” that essentially determine the style in which the model responds to us.</p><p>After reading this article, I hope you have a better understanding of these two models and their respective API response methods.</p><p>Different models and APIs are suitable for different scenarios. Understanding their characteristics and applicable scenarios, when you want to apply Azure OpenAI to your programs in the future, you will make the best choice with more confidence, maximizing the potential of AI!</p><h3>Thank you so much for reading my article, feedbacks are welcome!</h3><p>Feel free to leave any feedback in the comments😀</p><p>If you like the article, please don&#39;t forget to give me claps, thank you!👏👏👏</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=0f87ba83bf36" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How to Use Postman to Call Azure OpenAI’s API — A Step-by-Step Tutorial]]></title>
            <link>https://medium.com/@ro5112/how-to-use-postman-to-call-azure-openais-api-a-step-by-step-tutorial-765aec0fba96?source=rss-d868d749a9cc------2</link>
            <guid isPermaLink="false">https://medium.com/p/765aec0fba96</guid>
            <category><![CDATA[postman]]></category>
            <category><![CDATA[step-by-step]]></category>
            <category><![CDATA[openai]]></category>
            <category><![CDATA[api]]></category>
            <category><![CDATA[azure]]></category>
            <dc:creator><![CDATA[Jazz Lien]]></dc:creator>
            <pubDate>Fri, 13 Oct 2023 02:22:29 GMT</pubDate>
            <atom:updated>2023-10-13T02:29:00.106Z</atom:updated>
            <content:encoded><![CDATA[<h3>How to Use Postman to Call Azure OpenAI’s API — A Step-by-Step Tutorial</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XLDUGIgxx6tyMhz3czd0TQ.png" /><figcaption>Azure X OpenAI X Postman</figcaption></figure><p>Hello everyone, today’s article will introduce how to use Postman to call the Azure OpenAI API.</p><p>The article will be divided into several stages:</p><ol><li>Introducing API and Postman</li><li>Creating Azure OpenAI Service, obtaining the service Key and Endpoint</li><li>Establishing a new Collection on Postman and connecting to Azure OpenAI</li><li>Enhancing security measures, writing Key and Endpoint into environment variables</li><li>Conclusion</li></ol><p>Before moving on to the formal steps, let’s first introduce the concept of API and the useful tool Postman!</p><h3>Introducing API and Postman</h3><h3>What is an API?</h3><p>The full name of <strong>API</strong> is “Application Programming Interface,” which we can use to create software or <strong>interact with external systems</strong>. It acts somewhat like a bridge between our program and the outside world. APIs come in many forms; they can be a command, function, protocol, or an object.</p><p>For example, if we go to a restaurant and want to order a pizza, the roles in the restaurant are similar to:</p><ul><li>Us (User)</li><li>Counter staff (API)</li><li>Chef (Application)</li></ul><p>Getting an API is like we don’t need to make a pizza ourselves: we (User) enter the restaurant, order (give a command) to the counter staff (API), who then passes our request to the chef (Application). The chef understands the request, makes the delicious food (response), and delivers it to us 😋.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2Fs7wmiS2mSXY%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3Ds7wmiS2mSXY&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2Fs7wmiS2mSXY%2Fhqdefault.jpg&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/dc0d4b1c7980784e90ccea523d44855d/href">https://medium.com/media/dc0d4b1c7980784e90ccea523d44855d/href</a></iframe><p>With a basic understanding of APIs, let’s move on to what Postman is.</p><h3>What is Postman?</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/500/1*IJwQFw7qMV894E2muApRkg.png" /><figcaption>Rource: Postman Youtube Channel</figcaption></figure><p>Postman is one of the most widely used API interaction tools, with over five million users each month. It provides a user-friendly interface to send requests to APIs and receive responses from APIs. Using Postman makes API development easy and straightforward, as it can handle various types of HTTP requests (GET, POST, PUT, PATCH), retain environments for later use, and even convert APIs into various programming languages (like JavaScript, Python).</p><p>Imagine we now have a big box full of toys (Application), but it’s locked, and a special key (API) is needed to open it. Now, Postman is like our good friend, skilled in using this special key. We just need to tell Postman what toys we want to take out or what new toys we want to put in, and it will help us accomplish that. Postman is a friendly “postman” helping us communicate with the computer.</p><p>Download Postman through this link:</p><p><a href="https://www.postman.com/downloads/">Download Postman | Get Started for Free</a></p><p>Now let’s dive into the main subject of this tutorial, integrating Azure OpenAI with Postman. Let’s get started!</p><h3>Creating Azure OpenAI Service, Obtaining the Service Key and Endpoint</h3><ol><li>Go to <a href="https://portal.azure.com/#home"><strong>Azure Portal</strong></a></li><li>Search for “OpenAI” and create a service</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/903/1*2nxzhHHXOg59amyj46H4MQ.png" /></figure><p>Once the service is created,</p><ol><li>Navigate to “Keys and Endpoint” under “Resource Management”</li><li>Obtain the KEY value for later use</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*qBBXEcqhaFZwM3SKE_YW0w.png" /></figure><p>Next, click on “Go to Azure OpenAI Studio”</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*JZAvubGYKe1Cu97vDccRXg.png" /></figure><ol><li>Go to “Deployments,” deploy the model</li><li>Proceed to “Playground” chat</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ez7CSxCJ4Zrs5brYaArcEg.png" /></figure><p>Once the model is confirmed to be usable,</p><ol><li>click on “View code”, switch the setting to “json”.</li><li>Copy the code.</li><li>Then copy the service endpoint (Endpoint).</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*5Bk6kK1Z3QU48ErwOq4omQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/719/1*gj4LUC22QNz_LT21y7yBmQ.png" /></figure><p>That concludes the Azure part!</p><p>Remember to keep the copied data safe for later use 😁</p><h3>Establishing a New Collection on Postman and Connecting to Azure OpenAI</h3><p>For first-time Postman users,</p><ol><li>Create a new “Workspaces”</li><li>Choose “New” to create a new “Collection”</li><li>After creation, select “Add a request”</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SX1rKCGQqjpyPvz9_aDYIA.png" /></figure><p>Adjust the newly created Request</p><ol><li>change GET to “POST”,</li><li>Select the “raw” option under “Body”</li><li>switch “Text” to “JSON” format</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*xnf1C0hUgPXhDyN63wMQZg.png" /></figure><p>Paste the “Endpoint” and code copied earlier and try sending a “POST” Request</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VR-Qbnq3TkAOx448SsPNGA.png" /></figure><p>However, you will find that the HTTP status code returns “401 Permission Denied” because we have not provided the Key for the service</p><p>(Note: Readers interested in understanding HTTP status codes can refer to here: <a href="https://www.webfx.com/web-development/glossary/http-status-codes/">HTTP Status Codes Glossary</a>)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*k8-LvVqSlxW7qYlZsSg08w.png" /></figure><p>So let’s add our API KEY to our Postman requests:</p><ol><li>Select “Params,” add the parameter “api-key”</li><li>Paste the key copied earlier in the Value section, and</li><li>Send the “POST” request again.</li></ol><p>Seeing the HTTP status code display “200 OK,” and getting the content indicates that we have successfully called the Azure OpenAI API! 🤩</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*44OJL3UCzhPUnwLzdLf6jQ.png" /></figure><p>It’s exciting to successfully call the API, but exposing sensitive keys still feels odd. After all, data security is a serious issue we all need to be cautious about. If it’s leaked, it could lead to confidentiality breaches or significant financial losses.</p><p>Next, let’s look at how to enhance security measures to use Postman more securely.</p><h3>Enhancing Security Measures, Writing Key and Endpoint into Environment Variables</h3><p>Writing the Key and Endpoint into environment variables is a great protective measure!</p><ol><li>Click on the “Environment” beside, add the Key and Endpoint, and set the Type to “secret”</li></ol><p>(The deployed model and API version can also be written into environment variables, but unlike the Key and Endpoint, these values are not sensitive information, so it’s up to you.)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pLtnv_ZC33COKhTdOPfdSg.png" /></figure><ol><li>Change the URL for sending the “POST” request to the following format and send the request. If you get the content, it means the request is successful!</li></ol><pre>{{OPENAI_API_BASE}}/openai/deployments/{{CHATCOMPLETION_MODEL}}/chat/completions?api-version={{OPENAI_API_VERSION}}&amp;api-key={{OPENAI_API_KEY}}</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IdtTu8gRiRHAaUXklMh2mg.png" /></figure><p>Adopting this approach brings many benefits. It not only enhances security but also makes the program easier to maintain. Firstly, it prevents sensitive information from being written directly into the program, protecting the key from unauthorized use or exposure. Secondly, if we delete the original Azure OpenAI Service and create a new one, we only need to change the variables in the environment without modifying any code. This significantly reduces the complexity of maintenance and improves efficiency.</p><p>Now, store your keys in environment variables and add more protection to your programs!</p><h3>Conclusion</h3><p>Through this article, we’ve walked step-by-step on how to use Postman to call Azure OpenAI’s API. From basic introductions of API and Postman, to practical operations and security enhancements through Postman’s user-friendly interface, we can easily interact with Azure OpenAI. Storing keys and endpoints in environment variables not only makes our programs safer but also facilitates maintenance.</p><p>Postman is a very useful tool. In the future, whether conducting API testing or interfacing with different services, after reading this, you should have a clearer understanding of the whole process. It’s hoped that through this tutorial, you’ve gained some practical knowledge to apply in your future programming journey.</p><h3>Thank you so much for reading my article, feedback is welcome!</h3><p>Feel free to leave any feedback in the comments😀</p><p>Don&#39;t forget to give me claps, thank you!👏👏👏</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=765aec0fba96" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>