<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>Forem: FastApply</title>
    <description>The latest articles on Forem by FastApply (@fastapplyai).</description>
    <link>https://forem.com/fastapplyai</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Forganization%2Fprofile_image%2F10148%2F2d5868a3-6267-48c7-91f9-5ebeca0a1449.png</url>
      <title>Forem: FastApply</title>
      <link>https://forem.com/fastapplyai</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://forem.com/feed/fastapplyai"/>
    <language>en</language>
    <item>
      <title>How to Create a Resume That Lands Interviews in 2026</title>
      <dc:creator>Oluchi John</dc:creator>
      <pubDate>Mon, 16 Feb 2026 13:06:06 +0000</pubDate>
      <link>https://forem.com/fastapplyai/how-to-create-a-resume-that-lands-interviews-in-2026-191d</link>
      <guid>https://forem.com/fastapplyai/how-to-create-a-resume-that-lands-interviews-in-2026-191d</guid>
      <description>&lt;p&gt;Your resume has less than 10 seconds to land you an interview. Recruiters spend an average of 7.4 seconds scanning a resume before deciding whether to move forward or pass. With hundreds of applications flooding every job posting, your resume needs to work harder than ever to get noticed.&lt;/p&gt;

&lt;p&gt;After reviewing thousands of resumes and having extensive conversation with successful hiring managers, we have identified clear patterns that separate resumes that land interviews from those that disappear into the void. This guide breaks down exactly what works, from the strategic framework to the tactical details that make recruiters stop scrolling.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why Your Resume Matters More Than You Think
&lt;/h2&gt;

&lt;p&gt;A resume makes the first impression in a job application. It speaks for you when recruiters search for candidates on LinkedIn or when an internal referral forwards your profile for consideration.&lt;/p&gt;

&lt;p&gt;The document follows you through the entire hiring process. A weak resume can cost you opportunities before you ever get a chance to prove yourself but a strong resume showcases your value and sets you up for success in interviews and negotiations.&lt;/p&gt;

&lt;p&gt;An effective resume is written with the reader in mind. What convinces the reader you are ready and able to do the job? That question should guide every line you write.&lt;/p&gt;

&lt;p&gt;The difference between landing interviews and hearing nothing often comes down to how strategically you approach resume creation.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Create-Curate-Craft Framework
&lt;/h2&gt;

&lt;p&gt;Building a resume from scratch feels overwhelming. Staring at a blank document, trying to remember every accomplishment while worrying about formatting and keywords, looks like a lot of work.&lt;/p&gt;

&lt;p&gt;Break the process into three distinct phases instead.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcxrpx3lk27482o80o188.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcxrpx3lk27482o80o188.png" alt="How_To_Write_A_Resume" width="800" height="420"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Phase 1: Create Your Master Resume
&lt;/h3&gt;

&lt;p&gt;Start by dumping everything into a single document. Do not worry about length, formatting, or whether something belongs. Just capture your entire career history in one place.&lt;/p&gt;

&lt;p&gt;Include contact information, every position you have held, job descriptions as you remember them, education details, certifications, skills you have developed, projects you have completed, volunteer work, publications, awards, and anything else related to your professional life.&lt;/p&gt;

&lt;p&gt;This master resume becomes your career database. It might run five or ten pages. That is fine. You will never send this version to anyone. Its purpose is to give you raw material to work with when tailoring applications.&lt;/p&gt;

&lt;p&gt;Most people skip this step and try to build tailored resumes from memory each time they apply. That approach leads to inconsistent applications and forgotten achievements. The master resume solves both problems.&lt;/p&gt;

&lt;h3&gt;
  
  
  Phase 2: Curate for Each Application
&lt;/h3&gt;

&lt;p&gt;With your master resume complete, you now have a menu to select from. When applying to a specific role, review the job description and identify what matters most to that employer.&lt;/p&gt;

&lt;p&gt;Pull the most relevant experiences, skills, and achievements from your master resume. Leave out anything that does not strengthen your case for that particular position. A software engineer applying for a backend role does not need to highlight frontend projects. A marketer pursuing a content strategy position should emphasize writing over paid advertising.&lt;/p&gt;

&lt;p&gt;Curation means choosing what to include and what to exclude. Not everything belongs on every resume.&lt;/p&gt;

&lt;h3&gt;
  
  
  Phase 3: Craft the Language
&lt;/h3&gt;

&lt;p&gt;Once you have selected the right content, refine how you present it. Match your language to the job description. Use similar terminology and mirror the priorities they emphasize.&lt;/p&gt;

&lt;p&gt;Transform job duties into achievements by replacing vague descriptions with specific, measurable results. For example, "Managed social media accounts" becomes "Grew Instagram following from 5,000 to 50,000 in 18 months while maintaining 4% engagement rate."&lt;/p&gt;

&lt;p&gt;This three-phase approach prevents the paralysis of trying to do everything at once. Create your foundation, curate for relevance, then craft for impact.&lt;/p&gt;

&lt;h2&gt;
  
  
  How Recruiters Actually Read Resumes
&lt;/h2&gt;

&lt;p&gt;Understanding recruiter behavior helps you design resumes that work with their reading patterns instead of against them.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fm5d8khfo2ridzg8dnnac.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fm5d8khfo2ridzg8dnnac.png" alt="How_Recruiters_Read_Your_Resume" width="800" height="420"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. The F-Pattern Skim (1-3 Seconds)&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Recruiters start by skimming in an F-pattern. Their eyes move across the top of the resume, then down the left side. They look at job titles, company names, and employment dates.&lt;/p&gt;

&lt;p&gt;In these first seconds, they answer one question: Does this person have relevant experience? If your titles and companies do not suggest qualifications, they move to the next resume.&lt;/p&gt;

&lt;p&gt;This is why the top third of page one matters so much. Weak openings kill applications before recruiters reach your best content.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. The Z-Pattern Keyword Scan&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Candidates who pass the initial skim get a second look. Now recruiters scan in a Z-pattern, moving diagonally across the page looking for keywords that match the job requirements.&lt;/p&gt;

&lt;p&gt;They search for specific skills, tools, certifications, and industry terminology. If the job posting mentions Python, they look for Python. If it emphasizes project management, they scan for those words.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://www.indeed.com/career-advice/resumes-cover-letters/10-resume-writing-tips" rel="noopener noreferrer"&gt;Indeed's Career Guide&lt;/a&gt; emphasizes that integrating keywords from the job post directly into your resume helps you land a position.&lt;/p&gt;

&lt;p&gt;Resumes without matching keywords get filtered out, even when candidates have relevant experience buried in different language.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. The Deep Read (60 Seconds to 2 Minutes)&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Only truly qualified candidates make it to this stage. Recruiters slow down and read the content. They study achievements, evaluate progression, and form impressions about what this candidate would bring to the team.&lt;/p&gt;

&lt;p&gt;This is where strong bullet points and quantified accomplishments make the difference between interview invitations and rejection emails.&lt;/p&gt;

&lt;h2&gt;
  
  
  Anatomy of a Resume That Works
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;1. The Hook: Your Top Third&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;As earlier said, the top third of page one determines whether anyone reads the rest. Treat it like premium real estate.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Contact Information:&lt;/strong&gt; Keep it minimal. Name, phone, email, LinkedIn URL, and location (city only). Skip full addresses, multiple phone numbers, or unprofessional email addresses. Everything should project competence.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Target Title:&lt;/strong&gt; Add a title that projects where you are headed, not just where you have been. If you are a Marketing Coordinator pursuing Marketing Manager roles, consider "Marketing Manager" as your target title. This helps recruiters immediately understand what you are seeking.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Professional Summary:&lt;/strong&gt; Write two to four sentences that pitch your career. Highlight your biggest wins and most relevant experience. Skip this section entirely if you are early in your career with limited work history. Generic summaries waste space better used for actual achievements.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;2. The Proof: Work Experience&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;This section proves you have the skills to do the job. Present positions in reverse chronological order, starting with your most recent role.&lt;/p&gt;

&lt;p&gt;Group experience by company rather than listing every title separately. Showing multiple positions at one company demonstrates growth and loyalty. Job hopping appears more prominent when every role gets its own entry.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Write achievement-focused bullets.&lt;/strong&gt; Every bullet should answer the question: What did I accomplish? Not what did I do, but what result did I produce?&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Weak&lt;/th&gt;
&lt;th&gt;Strong&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Responsible  for managing customer accounts&lt;/td&gt;
&lt;td&gt;Managed portfolio of 45 enterprise accounts generating $3.2M annual revenue with 94% retention rate&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Use numbers whenever possible. Percentages, dollar amounts, time saved, efficiency gained, team sizes, and growth rates all add credibility. Vague claims are forgettable but specific results are memorable.&lt;/p&gt;

&lt;p&gt;According to &lt;a href="https://novoresume.com/career-blog/10-second-resume-rule" rel="noopener noreferrer"&gt;Andrei Kurtuy&lt;/a&gt;, a career expert, hiring managers spend less than 10 seconds deciding if you are qualified. Quantified achievements help you pass that test.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. The Depth: Education, Skills, and More&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Education:&lt;/strong&gt; List degrees, institutions, and graduation years. Include relevant coursework or honors only if you are early in your career. Once you have substantial work experience, education becomes less prominent.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Certifications:&lt;/strong&gt; Include credentials relevant to your target role. AWS certifications matter for cloud engineering positions. PMP matters for project management roles. Random certifications that do not support your application waste space.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Skills:&lt;/strong&gt; List 10-15 skills maximum. Pull them directly from job descriptions in your target field. Generic skills like "Microsoft Office" or "communication" add little value. Specific technical skills and tools relevant to the role demonstrate readiness.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Projects, Volunteering, Publications:&lt;/strong&gt; Include these only when they strengthen your case. A side project demonstrating skills not evident in your work history adds value. Volunteer work unrelated to your target role does not.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Formatting Best Practices
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Keep your resume under two pages. One page works for early-career candidates. Two pages suit experienced professionals. Three or more pages suggest you do not know how to edit.&lt;br&gt;
Make page one count. If a recruiter only sees the first page, would they want to interview you?&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Export as PDF. PDFs maintain formatting across different devices and systems. Word documents display differently depending on the recipient's software.&lt;br&gt;
Ensure text remains selectable. Some PDF creation methods turn text into images. Applicant Tracking Systems fail to read image-based text. Test by selecting text in your PDF. If you are unable to highlight it, neither is the ATS.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Use clean, professional templates. Avoid excessive graphics, unusual fonts, or creative layouts that confuse ATS parsing. Simple and clear beats elaborate and risky.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The Problem With Manual Resume Tailoring
&lt;/h2&gt;

&lt;p&gt;Here is the reality most job seekers face: tailoring resumes works, but it takes forever.&lt;/p&gt;

&lt;p&gt;The average job seeker applies to 100-200 positions during an active search. Spending 20-30 minutes tailoring each resume means 50-100 hours just on resume customization. That does not include searching for jobs, writing cover letters, or preparing for interviews.&lt;/p&gt;

&lt;p&gt;Most people give up on tailoring after a few applications. They send the same generic resume everywhere and wonder why response rates stay low.&lt;/p&gt;

&lt;p&gt;The candidates who land the most interviews do not just apply more. They apply smarter, with resumes that speak directly to what each employer needs. But doing this manually at scale is nearly impossible.&lt;/p&gt;

&lt;p&gt;Time is your greatest asset so it's always best you use automated job application systems to streamline the process and save you time.&lt;/p&gt;

&lt;h2&gt;
  
  
  How FastApply Solves the Tailoring Problem
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://fastapply.co/" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt; eliminates the trade-off between quality and volume.&lt;/p&gt;

&lt;p&gt;The Chrome extension sits in your browser while you search for jobs. When you find a position worth applying to, FastApply reads the job description and automatically tailors your resume to match. Keywords get emphasized. Relevant experiences move to the top. The language shifts to mirror what the employer wants to see.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fi16uctt7wlz4dvmk0g9q.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fi16uctt7wlz4dvmk0g9q.png" alt="FastApply_Resume_Tailoring" width="800" height="420"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Why FastApply Works Better Than Other Tools
&lt;/h3&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Human-in-the-Loop Review:&lt;/strong&gt; Unlike fully automated tools that spray generic applications everywhere, FastApply pauses before submission. You review the tailored resume, make adjustments if needed, and approve. This prevents embarrassing mismatches and maintains the quality that gets callbacks.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Intelligent Keyword Matching:&lt;/strong&gt; FastApply analyzes job descriptions and identifies the specific terms, skills, and qualifications employers prioritize. Your resume gets optimized for both ATS systems and human reviewers simultaneously.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Resume Optimization On The Fly:&lt;/strong&gt; Instead of building a new resume from scratch for each application, FastApply transforms your master resume into a targeted version in seconds. The 30-minute tailoring process becomes a 3-minute review.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Cover Letter Generation:&lt;/strong&gt; FastApply creates customized cover letters that reference specific company details and job requirements. Generic cover letters get ignored. Customized ones demonstrate genuine interest and get read.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Broad Platform Coverage:&lt;/strong&gt; FastApply works across all major job boards, including Indeed, LinkedIn, Glassdoor, Lever, Greenhouse, and Workday. Apply across platforms without learning different interfaces or filling the same information repeatedly.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  The Speed Advantage
&lt;/h3&gt;

&lt;p&gt;For job seekers applying across multiple platforms, &lt;a href="https://fastapply.co" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt; transforms the math of job searching.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Without FastApply&lt;/th&gt;
&lt;th&gt;With FastApply&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;10 tailored applications per week at 30 minutes each = 5hours&lt;/td&gt;
&lt;td&gt;50 tailored applications per week at 3 minutes each = 2.5 hours&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;You get 5x more quality applications in half the time. That compounds over weeks and months of searching.&lt;/p&gt;

&lt;p&gt;The pause-and-review workflow means you never sacrifice quality for speed. Every application gets your approval before submission, ensuring each one represents you well.&lt;/p&gt;

&lt;h2&gt;
  
  
  Building Your Resume System
&lt;/h2&gt;

&lt;p&gt;Combine the Create-Curate-Craft framework with FastApply for maximum results.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 1: Build Your Master Resume&lt;/strong&gt;&lt;br&gt;
Spend 2-3 hours creating a comprehensive master resume with everything you have ever accomplished. This is a one-time investment that pays dividends across your entire job search.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 2: Set Up FastApply&lt;/strong&gt;&lt;br&gt;
Connect your master resume to FastApply. Configure your preferences for the types of roles you want and the keywords that matter most in your field.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 3: Search and Apply Strategically&lt;/strong&gt;&lt;br&gt;
Browse job boards as usual. When you find positions that match your goals, let FastApply tailor your resume automatically. Review each version before submission.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 4: Track and Iterate&lt;/strong&gt;&lt;br&gt;
Monitor which applications generate responses. FastApply tracks everything, so you know which versions of your resume perform best. Use that data to refine your master resume over time.&lt;/p&gt;

&lt;p&gt;This system lets you maintain the quality of hand-tailored applications while achieving the volume needed to generate consistent interview opportunities.&lt;/p&gt;

&lt;h2&gt;
  
  
  Common Resume Mistakes to Avoid
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Using the same resume everywhere.&lt;/strong&gt; Generic resumes get generic results. Each application should speak directly to what that specific employer needs.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Focusing on duties instead of achievements.&lt;/strong&gt; Hiring managers do not care what you were supposed to do. They care about what you accomplished.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Ignoring ATS requirements.&lt;/strong&gt; Fancy formatting, graphics, and creative layouts often break ATS parsing. Keep it clean and simple.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Burying the best content.&lt;/strong&gt; Your strongest qualifications belong in the top third of page one. Do not make recruiters hunt for reasons to interview you.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Forgetting to proofread.&lt;/strong&gt; Typos and grammatical errors signal carelessness. Read your resume backward to catch mistakes. Have someone else review it too.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Including irrelevant information.&lt;/strong&gt; Every line should strengthen your case for the specific role. Cut anything that does not contribute.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Creating a resume that lands interviews starts with tailoring it to the specific role you're applying for. When your resume aligns with the employer's needs, it becomes easier to move your application forward.&lt;/p&gt;

&lt;p&gt;The challenge is doing this consistently, tailoring resumes for multiple roles takes time and time is one of your most valuable assets in a job search. Being among the first applicants often makes a measurable difference. You need a process that allows you to apply efficiently while still standing out.&lt;/p&gt;

&lt;p&gt;This is where a job automation system like &lt;a href="https://fastapply.co/" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt; comes in. It helps tailor your resume to multiple roles in minutes. Automating this process saves you time and energy while you prepare for interview.&lt;/p&gt;

</description>
      <category>howtowritearesume</category>
      <category>resumethatlandsinterviews</category>
      <category>atsresume</category>
      <category>resumetailoring</category>
    </item>
    <item>
      <title>How to Land a Tech Job in the USA in 90 Days: Your 2026 Action Plan</title>
      <dc:creator>Oluchi John</dc:creator>
      <pubDate>Mon, 16 Feb 2026 12:24:56 +0000</pubDate>
      <link>https://forem.com/fastapplyai/how-to-land-a-tech-job-in-the-usa-in-90-days-your-2026-action-plan-4mkh</link>
      <guid>https://forem.com/fastapplyai/how-to-land-a-tech-job-in-the-usa-in-90-days-your-2026-action-plan-4mkh</guid>
      <description>&lt;p&gt;Landing a tech job in 2026 requires an active plan. The average time to fill a tech position in the U.S. is &lt;a href="https://www.corporatenavigators.com/articles/recruiting-trends/the-average-time-to-fill-by-industry-in-2024/" rel="noopener noreferrer"&gt;41 days&lt;/a&gt;, and senior technical roles often stretch well beyond that. Job seekers apply to anywhere from 32 to 200+ positions before landing an offer, with tech sitting at the high end of that range.&lt;/p&gt;

&lt;p&gt;But here is the good news: the &lt;a href="https://www.bls.gov/ooh/computer-and-information-technology/" rel="noopener noreferrer"&gt;U.S. Bureau of Labor Statistics&lt;/a&gt; projects roughly 317,700 openings in computer and IT occupations every single year through 2034. The jobs exist, you just need a system to land one in 90 days or less. &lt;/p&gt;

&lt;p&gt;This guide breaks down a week-by-week plan to go from "starting my search" to "signing my offer letter" in three months flat.&lt;/p&gt;

&lt;h2&gt;
  
  
  The 2026 Tech Job Market: Where the Opportunities Are
&lt;/h2&gt;

&lt;p&gt;Before you start applying, you need to know where hiring is strongest. The tech job market in 2026 is selective but active. Employers posted nearly 1.1 million technology jobs in 2025, according to &lt;a href="https://www.roberthalf.com/us/en/insights/research/data-reveals-which-technology-roles-are-in-highest-demand" rel="noopener noreferrer"&gt;Robert Half's hiring analysis&lt;/a&gt;. And 61% of technology leaders plan to increase permanent headcount in the first half of 2026.&lt;/p&gt;

&lt;p&gt;The hottest areas for hiring, per the same &lt;a href="https://www.roberthalf.com/us/en/insights/research/data-reveals-which-technology-roles-are-in-highest-demand" rel="noopener noreferrer"&gt;Robert Half analysis&lt;/a&gt; include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;AI, ML, and data science:&lt;/strong&gt; 49,200 postings in 2025, up 163% from 2024&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cybersecurity:&lt;/strong&gt; 66,800 postings in 2025, up 124% year over year&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Software development:&lt;/strong&gt; 15% projected growth through 2034, with about 129,200 openings annually&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cloud infrastructure and DevOps:&lt;/strong&gt; Consistent demand as companies modernize systems&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The &lt;a href="https://www.bls.gov/ooh/computer-and-information-technology/" rel="noopener noreferrer"&gt;Bureau of Labor Statistics&lt;/a&gt; reports that the median annual wage for computer and IT occupations reached $105,990 in 2024. Professionals with AI and machine learning expertise command a 15-25% salary premium over generalist counterparts.&lt;/p&gt;

&lt;p&gt;The bottom line: companies are hiring, but they are being deliberate about it. They want specialized skills, proof of ability, and candidates who stand out from the noise. Your 90-day plan needs to account for that reality.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fod8llbm3z8cxqvngz160.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fod8llbm3z8cxqvngz160.png" alt="90_day_tech_job_search_plan" width="800" height="420"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Phase 1: Foundation Building (Days 1-30)
&lt;/h2&gt;

&lt;p&gt;The first month is about preparation, not applications. Spend these 30 days building a foundation that makes every future application count.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Week 1: Skills Audit and Market Alignment&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Start by mapping your existing skills against what employers are hiring for right now. Python, AWS, APIs, CI/CD, and AI has been ranked among the top five tech skills with the largest year-over-year increase in job listings.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs1kzbjqrkk8bu1ac5x1k.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fs1kzbjqrkk8bu1ac5x1k.png" alt="Fastest_Growing_Tech_Jobs_In_2026" width="800" height="420"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Action items for Week 1:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;List every technical skill you have, including tools, languages, and frameworks&lt;/li&gt;
&lt;li&gt;Search 30-50 job postings for your target role on LinkedIn, Indeed, and Glassdoor&lt;/li&gt;
&lt;li&gt;Identify the top 10 skills that appear most frequently in those postings&lt;/li&gt;
&lt;li&gt;Highlight the gaps between your current skills and what employers demand&lt;/li&gt;
&lt;li&gt;Choose 1-2 high-impact skills to build or sharpen during your 90-day sprint&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you are targeting AI-related roles, know that 78% of information and communications technology positions now include AI technical skills, according to the &lt;a href="https://newsroom.cisco.com/c/r/newsroom/en/us/a/y2025/m09/ai-workforce-consortium-finds-78-of-ict-roles-now-include-ai-technical-skills-while-human-skills-gain-priority-for-responsible-tech-adoption.html" rel="noopener noreferrer"&gt;AI Workforce Consortium report led by Cisco&lt;/a&gt;. Even if AI is not your specialty, basic AI literacy gives you a competitive edge for almost any tech role in 2026.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Week 2: Resume Overhaul for ATS and Humans&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Your resume for tech jobs needs to clear automated tracking systems before a human ever sees it.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Build your resume with these principles:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Use a clean, single-column format with standard section headers (Experience, Education, Skills, Projects)&lt;/li&gt;
&lt;li&gt;Mirror the exact language from job descriptions in your skills section&lt;/li&gt;
&lt;li&gt;Quantify every accomplishment with numbers (revenue generated, users served, performance improved by X%)&lt;/li&gt;
&lt;li&gt;Remove outdated technologies that no longer appear in current job postings&lt;/li&gt;
&lt;li&gt;Keep it to one page for under 10 years of experience, two pages maximum for senior roles&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Write a master resume that includes all your relevant experience. Then tailor it for each application by adjusting the skills section and reordering bullet points to match the job description.&lt;/p&gt;

&lt;p&gt;This is where the manual process breaks down for most people. Tailoring 100+ resumes at 20-30 minutes each adds up to 50-100 hours of repetitive work. &lt;a href="https://www.fastapply.co" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt; solves this problem directly. The Chrome extension reads each job description and automatically tailors your resume to match the position. Keywords get emphasized and relevant experiences move to the top.&lt;br&gt;
Unlike fully automated tools that spray generic applications everywhere, FastApply lets you review the process before submission. That 30-minute tailoring process becomes a 3-minute review.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Week 3: Build Your Online Presence&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;A LinkedIn profile is no longer optional. Recruiters and hiring managers check your online presence before scheduling interviews. According to the &lt;a href="https://www.redglobal.com/news-blog/the-us-tech-job-market-unveiled-" rel="noopener noreferrer"&gt;Dice 2025 Tech Salary Report&lt;/a&gt;, 47% of tech professionals were actively pursuing new roles in 2025, meaning your profile competes with a large share of the industry.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Strengthen your LinkedIn profile by:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Writing a headline that names your target role and top skill (e.g., "Software Engineer | Python &amp;amp; AWS | Building Scalable Backend Systems")&lt;/li&gt;
&lt;li&gt;Adding a summary that reads like a pitch, not a biography&lt;/li&gt;
&lt;li&gt;Listing 3-5 projects with measurable results&lt;/li&gt;
&lt;li&gt;Requesting recommendations from past colleagues or managers&lt;/li&gt;
&lt;li&gt;Setting your profile to "Open to Work" (visible to recruiters only if you prefer privacy)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;To further enhance your professional online presence, refer to our detailed guide on &lt;a href="https://blog.fastapply.co/how-to-get-a-tech-interview-in-30-days-resume-linkedin-strategy" rel="noopener noreferrer"&gt;LinkedIn strategy&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Also, set up or update your GitHub profile. For developers, a clean GitHub with 2-3 well-documented projects speaks louder than a resume bullet point. Include a README for each project that explains the problem, your solution, and the tech stack.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;4. Week 4: Networking Foundations&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Networking remains the single most effective job search strategy. Referred candidates are hired at a rate of about &lt;a href="https://salesso.com/blog/recruitment-referral-statistics/" rel="noopener noreferrer"&gt;30%, compared to an average rate of 7%&lt;/a&gt; for applicants sourced through other methods. Studies also shows that while only &lt;a href="https://theundercoverrecruiter.com/infographic-employee-referrals-hire/" rel="noopener noreferrer"&gt;7% of applicants come from referrals, they account for 40%&lt;/a&gt; of all hires. Networking is not optional in your 90-day plan.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8s93ztwdgbkfqrih2u8u.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8s93ztwdgbkfqrih2u8u.png" alt="Referral_Vs_Cold_Applications" width="800" height="420"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Start building your network this week:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Identify 20 companies you want to work for&lt;/li&gt;
&lt;li&gt;Find 2-3 employees at each company on LinkedIn (aim for people in your target department)&lt;/li&gt;
&lt;li&gt;Send personalized connection requests (mention a shared interest, a project they worked on, or a company initiative you admire)&lt;/li&gt;
&lt;li&gt;Join 2-3 relevant tech communities on Discord, Slack, or Reddit&lt;/li&gt;
&lt;li&gt;Attend at least one virtual or in-person tech meetup or webinar&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Do not ask for a job in your first message. Build genuine relationships first. Ask about their experience at the company, what they are working on, or what skills they value most. The job referrals come naturally after you build rapport.&lt;/p&gt;

&lt;h2&gt;
  
  
  Phase 2: Active Application Sprint (Days 31-60)
&lt;/h2&gt;

&lt;p&gt;With your foundation set, month two is about volume with quality. Your goal is to submit 5-10 tailored applications per day while continuing to network.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Week 5-6: Targeted Applications Across Multiple Platforms&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Do not put all your applications on one platform. Spread your efforts across the major job boards and company career pages.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Where to focus your applications:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;LinkedIn:&lt;/strong&gt; Largest professional network with strong tech job listings. Use the "Easy Apply" filter and saved job alerts for your target roles.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Indeed:&lt;/strong&gt; High volume of postings across all experience levels. Set up daily email alerts for your target keywords.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Glassdoor:&lt;/strong&gt; Useful for company reviews and salary data alongside job listings.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Company career pages:&lt;/strong&gt; Many companies post jobs on their own sites before listing them on boards. Check the careers pages of your top 20 target companies weekly.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;ATS platforms like Lever, Greenhouse, and Workday:&lt;/strong&gt; Many mid-size and large companies use these systems. Understanding how they work gives you an advantage in formatting your application.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;At this pace, you are looking at 50-100 applications over two weeks. Without automation, that means 25-50 hours of resume tailoring alone. &lt;br&gt;
&lt;a href="https://fastapply.co" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt; works across Indeed, LinkedIn, Glassdoor, Lever, Greenhouse, Workday, and dozens of other platforms. The extension detects the job posting, pulls the description, and generates a tailored resume and cover letter. You review and approve each one before submission. This workflow turns a full day of applications into a focused morning session.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;2. Week 7-8: Follow-Up and Tracking&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Most candidates never follow up after applying. That is a missed opportunity. A polite follow-up email one week after applying shows genuine interest and puts your name back in front of the hiring team.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Track every application with these details:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Company name and role title&lt;/li&gt;
&lt;li&gt;Date applied&lt;/li&gt;
&lt;li&gt;Platform used&lt;/li&gt;
&lt;li&gt;Contact person (if known)&lt;/li&gt;
&lt;li&gt;Follow-up date&lt;/li&gt;
&lt;li&gt;Current status (applied, phone screen, interview, offer, rejected)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Use a spreadsheet, Notion board, or a dedicated tool to stay organized. &lt;a href="https://fastapply.co" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt; includes application tracking so you keep a record of every position you have applied to without maintaining a separate system.&lt;/p&gt;

&lt;p&gt;During this phase, continue networking. Aim for 3-5 informational conversations per week. When you apply to a company where you have a connection, ask if they would be willing to put in a referral. That single action multiplies your chances of getting an interview.&lt;/p&gt;

&lt;h2&gt;
  
  
  Phase 3: Interview Preparation and Closing (Days 61-90)
&lt;/h2&gt;

&lt;p&gt;By month three, you should have callbacks and interviews lined up. This final phase is about converting those opportunities into offers.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. Week 9-10: Technical Interview Preparation&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Tech interviews in 2026 remain rigorous. Companies now conduct 42% more interviews per hire than they did in 2021. Prepare for multiple rounds, including coding challenges, system design, behavioral questions, and take-home assignments.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Build a study plan around these areas:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Data structures and algorithms:&lt;/strong&gt; Practice on LeetCode, HackerRank, or NeetCode. Aim for 2-3 problems daily, focusing on medium-difficulty questions.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;System design:&lt;/strong&gt; Study common patterns like load balancing, caching, database sharding, and microservices architecture. The "System Design Interview" book by Alex Xu is a solid resource.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Behavioral questions:&lt;/strong&gt; Prepare 8-10 stories using the STAR method (Situation, Task, Action, Result). Focus on teamwork, conflict resolution, leadership, and handling failure.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Domain-specific knowledge:&lt;/strong&gt; If you are targeting AI/ML roles, review statistics, model evaluation, and common frameworks (TensorFlow, PyTorch). For cybersecurity, brush up on threat modeling and security protocols.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;2. Week 11: Mock Interviews and Refinement&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Practice under realistic conditions. Schedule mock interviews with friends, mentors, or platforms like Pramp and Interviewing.io. Record yourself if possible and review your answers for clarity, conciseness, and confidence.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Common mistakes to avoid in tech interviews:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Jumping into coding without asking clarifying questions&lt;/li&gt;
&lt;li&gt;Failing to talk through your thought process out loud&lt;/li&gt;
&lt;li&gt;Ignoring edge cases in your solutions&lt;/li&gt;
&lt;li&gt;Not asking the interviewer thoughtful questions about the team or product&lt;/li&gt;
&lt;li&gt;Underselling your past achievements during behavioral rounds&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;3. Week 12: Negotiation and Offer Acceptance&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;When offers arrive, do not accept the first number you see. The &lt;a href="https://www.comptia.org/en-us/resources/research/state-of-the-tech-workforce-2025/" rel="noopener noreferrer"&gt;CompTIA State of the Tech Workforce 2025 report&lt;/a&gt; found that the median wage for tech workers is 127% higher than the median national wage. You have room to negotiate.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Negotiate with confidence:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Research salary ranges for your role and location on Glassdoor, Levels.fyi, and Blind&lt;/li&gt;
&lt;li&gt;Ask for 24-48 hours to review any offer&lt;/li&gt;
&lt;li&gt;Negotiate base salary first, then bonuses, equity, remote flexibility, and PTO&lt;/li&gt;
&lt;li&gt;Use competing offers as a reference point if you have them&lt;/li&gt;
&lt;li&gt;Be professional and gracious throughout the process. Hiring managers expect negotiation and respect candidates who advocate for themselves.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The Skills That Get You Hired
&lt;/h2&gt;

&lt;p&gt;The tech roles with the strongest demand right now share a common thread: they sit at the intersection of technical depth and business impact.&lt;/p&gt;

&lt;h3&gt;
  
  
  High-Demand Technical Skills
&lt;/h3&gt;

&lt;p&gt;According to the &lt;a href="https://insight.ieeeusa.org/articles/2026-tech-hiring-outlook/" rel="noopener noreferrer"&gt;IEEE-USA 2026 Tech Hiring Outlook&lt;/a&gt;, the five skills with the largest year-over-year increase in tech job listings are Python, AWS, APIs, CI/CD, and AI. Data management and data analytics for AI implementation will be among the most sought-after skills in 2026.&lt;/p&gt;

&lt;p&gt;If you are making a career change into tech, focus on one of these high-demand paths:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Software development:&lt;/strong&gt; Learn Python or JavaScript, build 2-3 portfolio projects, and earn a cloud certification (AWS Cloud Practitioner or Azure Fundamentals)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Data science:&lt;/strong&gt; Study Python, SQL, statistics, and a visualization tool like Tableau. Complete a capstone project with a real dataset.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cybersecurity:&lt;/strong&gt; Earn CompTIA Security+ or Google Cybersecurity Certificate. Set up a home lab to practice threat detection.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Cloud/DevOps:&lt;/strong&gt; Get certified in AWS or Azure. Learn Docker, Kubernetes, and Terraform through hands-on projects.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  The Rise of Skills-First Hiring
&lt;/h3&gt;

&lt;p&gt;A degree still matters, but less than it used to. The number of HR leaders using skills-first hiring has tripled in two years, according to the &lt;a href="https://generalassemb.ly/blog/the-state-of-tech-talent-2025-critical-insights-for-hr-leaders-from-hr-leaders/" rel="noopener noreferrer"&gt;General Assembly's State of Tech Talent 2025 report&lt;/a&gt;. This means certifications, bootcamps, and portfolio projects carry real weight, especially for roles in software engineering, data analytics, and UX design.&lt;/p&gt;

&lt;p&gt;Coursera, edX, and Google Career Certificates all offer programs that employers recognize. The &lt;a href="https://extension.harvard.edu/" rel="noopener noreferrer"&gt;Harvard Extension School's professional development courses&lt;/a&gt; also provide strong credentials if you want an academic-backed option.&lt;/p&gt;

&lt;h2&gt;
  
  
  Common Mistakes That Extend Your Job Search Beyond 90 Days
&lt;/h2&gt;

&lt;p&gt;Plenty of qualified candidates take six months or longer to find a tech job. Here is what separates the 90-day success stories from the prolonged searches.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Applying without tailoring:&lt;/strong&gt; Generic resumes get filtered out. Every application needs customization, even if it is just adjusting the skills section and top three bullet points. FastApply handles this automatically, keeping your applications tailored at scale.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Ignoring networking:&lt;/strong&gt; Cold applications have a 0.1-2% success rate. Referrals have a 30% success rate. The math is clear. Spend 30-40% of your job search time building relationships.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Over-preparing and under-applying:&lt;/strong&gt; Some candidates spend months studying for interviews before sending a single application. Start applying by day 31 at the latest. You will learn more from real interviews than from another week of LeetCode.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Not tracking results:&lt;/strong&gt; If you do not know your conversion rates (applications to interviews, interviews to offers), you do not know what to fix. Track everything and adjust your approach every two weeks.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Targeting only FAANG companies:&lt;/strong&gt; Big tech companies receive hundreds of thousands of applications. Mid-size companies and startups often hire faster (12 days average versus 42 days at enterprise companies) and offer competitive compensation with equity upside.&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Frequently Asked Questions
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;### How many applications does it take to get a tech job in 2026?&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Studies show a wide range, from 32 to 200+ applications for a single offer. The number drops significantly when you tailor each resume and include referrals. Candidates with employee referrals are 5 times more likely to get hired than cold applicants.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;### What is the average salary for tech jobs in the USA in 2026?&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The Bureau of Labor Statistics reports a median annual wage of $105,990 for computer and IT occupations as of 2024. Salaries range from approximately $50,000 at entry level to nearly $200,000 for senior roles. AI and ML specialists earn a 15-25% premium over generalist tech workers.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;### Do I need a computer science degree to get a tech job?&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Not always. Skills-first hiring has tripled among HR leaders in the past two years. Certifications from Google, AWS, CompTIA, and recognized bootcamps now carry significant weight. A strong portfolio of projects and relevant certifications opens doors at many companies.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;### What are the fastest-growing tech jobs in 2026?&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Data scientists and data analysts (414% projected growth), cybersecurity analysts and engineers (367% projected growth), and software developers and engineers (297% projected growth), according to CompTIA's 2025 State of the Tech Workforce report.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;### How long does the tech hiring process take?&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;The average time-to-hire across all industries sits at about 42 days. For senior technical positions, expect up to 68 days. AI and ML roles take the longest, averaging 89 days. Plan your timeline accordingly and keep multiple applications active simultaneously.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;### Does FastApply work on all job platforms?&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;FastApply works across major platforms including Indeed, LinkedIn, Glassdoor, and ATS systems like Lever, Greenhouse, and Workday. The Chrome extension detects job postings, generates tailored resumes and cover letters, and pauses for your review before submitting.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;### What tech certifications are most valuable in 2026?&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;AWS certifications (Cloud Practitioner, Solutions Architect), CompTIA Security+, Google Career Certificates in Data Analytics or Cybersecurity, and Azure Fundamentals all rank highly among employers. AI-specific certifications are growing in demand as 81% of hiring managers now consider AI-related skills a hiring priority.&lt;/p&gt;

&lt;h2&gt;
  
  
  Your 90-Day Timeline at a Glance
&lt;/h2&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Phase&lt;/th&gt;
&lt;th&gt;Days&lt;/th&gt;
&lt;th&gt;Focus&lt;/th&gt;
&lt;th&gt;Weekly Goal&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Foundation&lt;/td&gt;
&lt;td&gt;1-7&lt;/td&gt;
&lt;td&gt;Skills audit and market research&lt;/td&gt;
&lt;td&gt;Map skills to 50 job postings&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Foundation&lt;/td&gt;
&lt;td&gt;8-14&lt;/td&gt;
&lt;td&gt;Resume overhaul&lt;/td&gt;
&lt;td&gt;Build ATS-friendly master resume&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Foundation&lt;/td&gt;
&lt;td&gt;15-21&lt;/td&gt;
&lt;td&gt;Online presence&lt;/td&gt;
&lt;td&gt;Complete LinkedIn and GitHub profiles&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Foundation&lt;/td&gt;
&lt;td&gt;22-30&lt;/td&gt;
&lt;td&gt;Networking launch&lt;/td&gt;
&lt;td&gt;Connect with 40-60 professionals&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Application Sprint&lt;/td&gt;
&lt;td&gt;31-44&lt;/td&gt;
&lt;td&gt;Targeted applications&lt;/td&gt;
&lt;td&gt;5-10 tailored applications per day&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Application Sprint&lt;/td&gt;
&lt;td&gt;45-60&lt;/td&gt;
&lt;td&gt;Follow-ups and tracking&lt;/td&gt;
&lt;td&gt;3-5 informational calls per week&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Interview and Close&lt;/td&gt;
&lt;td&gt;61-75&lt;/td&gt;
&lt;td&gt;Technical interview prep&lt;/td&gt;
&lt;td&gt;2-3 coding problems daily&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Interview and Close&lt;/td&gt;
&lt;td&gt;76-84&lt;/td&gt;
&lt;td&gt;Mock interviews&lt;/td&gt;
&lt;td&gt;3-4 practice sessions&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Interview and Close&lt;/td&gt;
&lt;td&gt;85-90&lt;/td&gt;
&lt;td&gt;Negotiation and acceptance&lt;/td&gt;
&lt;td&gt;Close your best offer&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

</description>
      <category>howtolandatechjobinusa</category>
      <category>landatechjobin90days</category>
      <category>90daystechjobplan</category>
      <category>2026techjobplan</category>
    </item>
    <item>
      <title>How to Get a Tech Interview in 30 Days: Resume + LinkedIn Strategy (2026 Guide)</title>
      <dc:creator>Oluchi John</dc:creator>
      <pubDate>Mon, 16 Feb 2026 11:53:32 +0000</pubDate>
      <link>https://forem.com/fastapplyai/how-to-get-a-tech-interview-in-30-days-resume-linkedin-strategy-2026-guide-11nd</link>
      <guid>https://forem.com/fastapplyai/how-to-get-a-tech-interview-in-30-days-resume-linkedin-strategy-2026-guide-11nd</guid>
      <description>&lt;p&gt;The average tech job seeker sends &lt;a href="https://blog.theinterviewguys.com/how-many-applications-does-it-take-to-get-one-interview/" rel="noopener noreferrer"&gt;42 applications&lt;/a&gt; before landing a single interview. In a market where &lt;a href="https://www.finaldraftresumes.com/post/tech-job-market" rel="noopener noreferrer"&gt;tech job postings dropped 36%&lt;/a&gt; from pre-pandemic levels and &lt;a href="https://ravio.com/blog/early-career-hiring" rel="noopener noreferrer"&gt;entry-level hiring has fallen 73%&lt;/a&gt; in the past year, a scattershot approach wastes your most limited resource: time.&lt;/p&gt;

&lt;p&gt;But here is the good news. With a focused 30-day plan, you do not need to be one of those people sending hundreds of untailored applications into the void. This guide breaks your job search into four tactical weeks: resume optimization, LinkedIn positioning, targeted outreach, and interview preparation. Each week builds on the last, so by Day 30, you have a polished resume, a recruiter-visible LinkedIn profile, an active application pipeline, and the interview skills to close.&lt;/p&gt;

&lt;p&gt;A quick note: this plan is designed to get you interviews, not offers. Interviews come from positioning and volume. Offers come from preparation and performance. We will cover both, but set your 30-day goal as "scheduled interviews on my calendar."&lt;/p&gt;




&lt;h2&gt;
  
  
  Week 1: Build a Tech Resume That Passes ATS Filters (Days 1-7)
&lt;/h2&gt;

&lt;p&gt;Before you apply to a single job, your resume needs to work. Not "look good." Work. That means passing automated screening software and grabbing a recruiter's attention in the &lt;a href="https://www.theladders.com/static/images/basicSite/pdfs/TheLadders-EyeTracking-StudyC2.pdf" rel="noopener noreferrer"&gt;7.4 seconds&lt;/a&gt; they spend on each resume.&lt;/p&gt;

&lt;p&gt;Over &lt;a href="https://www.weforum.org/stories/2025/03/ai-hiring-human-touch-recruitment/" rel="noopener noreferrer"&gt;90% of employers&lt;/a&gt; now use automated systems to filter job applications. About &lt;a href="https://www.thebridgechronicle.com/tech/ats-impact-job-applications-careers?form=MG0AV3" rel="noopener noreferrer"&gt;75% of resumes&lt;/a&gt; get rejected before a human ever reads them. Your Week 1 goal is making sure yours is not one of them.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fk33c1vd9j9vp9lxfzn46.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fk33c1vd9j9vp9lxfzn46.png" alt="Tech_Job_Application_Funnel" width="800" height="420"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Day 1-2: Analyze 15-20 Target Job Descriptions
&lt;/h3&gt;

&lt;p&gt;Open 15-20 job postings for roles you want. Copy the full descriptions into a document. Highlight the skills, tools, and qualifications that appear across multiple listings.&lt;/p&gt;

&lt;p&gt;You are looking for patterns. If 12 out of 15 postings mention "Python," "AWS," and "CI/CD," those terms belong on your resume. If eight mention "cross-functional collaboration" or "Agile methodologies," note those too.&lt;/p&gt;

&lt;p&gt;Create three lists from your research:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Technical skills&lt;/strong&gt; mentioned in 10+ postings (these are non-negotiable for your resume).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Soft skills and methodologies&lt;/strong&gt; repeated across postings (weave these into your experience bullets).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Nice-to-have tools&lt;/strong&gt; mentioned in 5-7 postings (include if you have experience, skip if you do not).&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Day 3-4: Rewrite Your Resume for ATS and Relevance
&lt;/h3&gt;

&lt;p&gt;Now rebuild your resume with these tech resume tips:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Use standard section headers:&lt;/strong&gt; ATS software looks for "Experience," "Education," and "Skills." Creative headers like "Where I Have Made an Impact" confuse parsing algorithms.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Match exact keyword phrasing:&lt;/strong&gt; If a job posting says "React.js," write "React.js" on your resume, not "React" alone, not "ReactJS." Automated filters often match exact strings.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Quantify every accomplishment:&lt;/strong&gt; "Improved API response time by 40%, reducing average load time from 2.3s to 1.4s" beats "Improved API performance" every time. Numbers give recruiters something concrete to evaluate.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Front-load your bullets with action verbs:&lt;/strong&gt; Start each bullet with what you did: "Built," "Reduced," "Designed," "Migrated," "Automated." Avoid starting with "Responsible for" or "Helped with."&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Keep it to one page (early career) or two pages (10+ years):&lt;/strong&gt; Recruiters spend 7.4 seconds on a first scan. Dense three-page resumes get skimmed or skipped entirely.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Day 5-6: Create a Master Resume and 2-3 Tailored Versions
&lt;/h3&gt;

&lt;p&gt;Your master resume holds everything: every project, every skill, every accomplishment. You will never send this version to anyone.&lt;/p&gt;

&lt;p&gt;From the master, create 2-3 tailored versions for the types of roles you are targeting. A frontend developer applying to both React-heavy product companies and full-stack startup roles needs at least two versions, each emphasizing different projects and skills.&lt;/p&gt;

&lt;p&gt;Here is the reality most job seekers face: tailoring resumes works, but it takes forever. The average job seeker applies to 100-200 positions during an active search. Spending 20-30 minutes tailoring each resume means 50-100 hours just on resume customization.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Foik01qxnr620ylr4ryc5.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Foik01qxnr620ylr4ryc5.gif" alt="Auto-apply to 100+ jobs with fastapply" width="720" height="426"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https:fasapply.co" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt; eliminates the trade-off between quality and volume. The Chrome extension reads each job description and automatically tailors your resume to match. Relevant experiences move to the top. Keywords from the posting get emphasized in your skills and experience sections. But unlike fully automated tools that spray generic applications everywhere, FastApply pauses before submission. You review the tailored resume, make adjustments if needed, and approve. This prevents embarrassing mismatches while maintaining the speed you need.&lt;/p&gt;

&lt;h3&gt;
  
  
  Day 7: Test and Refine
&lt;/h3&gt;

&lt;p&gt;Run your resume through an ATS checker. Several free tools exist for this, including &lt;a href="https://www.jobscan.co/" rel="noopener noreferrer"&gt;Jobscan&lt;/a&gt; and &lt;a href="https://resumeworded.com/" rel="noopener noreferrer"&gt;Resume Worded&lt;/a&gt;. Aim for a match score of 70% or higher against your target job descriptions.&lt;/p&gt;

&lt;p&gt;Also send your resume to 2-3 people in your target industry for feedback. Ask specific questions: "Does my most recent role clearly show what I built?" and "Would you interview me for a mid-level backend role based on this?"&lt;/p&gt;




&lt;h2&gt;
  
  
  Week 2: Turn Your LinkedIn Into a Recruiter Magnet (Days 8-14)
&lt;/h2&gt;

&lt;p&gt;With your resume ready, Week 2 focuses on LinkedIn job search tips that make recruiters come to you. The data here is striking: &lt;a href="https://www.linkedin.com/pulse/linkedins-impact-job-hunting-facts-figures-2025-sagar-hedau-okdwf/" rel="noopener noreferrer"&gt;87% of recruiters use LinkedIn to find candidates&lt;/a&gt;. Profiles with complete information get &lt;a href="https://www.forbes.com/sites/jodiecook/2025/03/11/the-ultimate-guide-to-a-high-converting-linkedin-profile-in-2025/" rel="noopener noreferrer"&gt;21 times more views&lt;/a&gt;. Job seekers with comprehensive LinkedIn profiles have a &lt;a href="https://blog.theinterviewguys.com/i-analyzed-1000-linkedin-profiles-that-got-hired/" rel="noopener noreferrer"&gt;71% higher chance of landing an interview&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ff5woxb2zv4kwi1wup6y6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ff5woxb2zv4kwi1wup6y6.png" alt="LinkedIn Profile Optimization" width="800" height="420"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;LinkedIn is not a digital resume. It is a searchable database that recruiters query dozens of times per day. Your job is to show up in those searches.&lt;/p&gt;

&lt;h3&gt;
  
  
  5. Day 8-9: Rewrite Your Headline and About Section
&lt;/h3&gt;

&lt;p&gt;Your headline is the single most searched field on LinkedIn. Recruiters type job titles and skills into LinkedIn Recruiter, and the algorithm weights your headline heavily.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;Bad headline:&lt;/strong&gt; "Looking for New Opportunities"&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Good headline:&lt;/strong&gt; "Senior Full-Stack Engineer | React, Node.js, AWS | Building Scalable SaaS Products"&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The formula: [Target Role] | [Top 3-4 Technical Skills] | [Value Statement or Domain]&lt;/p&gt;

&lt;p&gt;For your About section, write 3-4 short paragraphs in first person. Open with what you do and who you do it for. Follow with your technical specialties. Close with what you are looking for. Stuff this section with the same keywords from your resume research in Week 1.&lt;/p&gt;

&lt;h3&gt;
  
  
  Day 10-11: Rebuild Your Experience Section with Metrics
&lt;/h3&gt;

&lt;p&gt;Your LinkedIn experience section should mirror your tailored resume, but with one difference: you have more space. Use it.&lt;/p&gt;

&lt;p&gt;Each role should include 4-6 bullet points with quantified results. Here is a simple framework for writing tech achievement bullets:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;[Action verb] + [what you built/did] + [technology used] + [measurable result]&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Example: "Designed a microservices architecture using Kubernetes and Go that reduced deployment time from 45 minutes to 3 minutes and supported 10x traffic growth."&lt;/p&gt;

&lt;h3&gt;
  
  
  Day 12: Add Skills, Get Endorsements, and Toggle Open to Work
&lt;/h3&gt;

&lt;p&gt;LinkedIn lets you list up to 50 skills. Add as many as you can, prioritizing the ones from your job description research. Profiles listing 5 or more skills get &lt;a href="https://thunderbit.com/blog/linkedin-stats" rel="noopener noreferrer"&gt;17 times more recruiter discovery&lt;/a&gt; than profiles with fewer.&lt;/p&gt;

&lt;p&gt;Turn on the "Open to Work" badge. &lt;a href="https://www.linkedin.com/pulse/open-work-linkedin-banner-gets-recruiter-dms-interviewbee-ojcvc/" rel="noopener noreferrer"&gt;Data from LinkedIn&lt;/a&gt; shows this feature increases recruiter InMail messages by 40%. Select the specific job titles, locations, and work types you want.&lt;/p&gt;

&lt;p&gt;Message 10-15 former colleagues and ask them to endorse your top 5 skills. Offer to endorse theirs in return. This takes 15 minutes and boosts your search ranking.&lt;/p&gt;

&lt;h3&gt;
  
  
  Day 13-14: Start Posting and Engaging
&lt;/h3&gt;

&lt;p&gt;Recruiters do not just search for candidates. They also notice people who show up in their feeds. Only about &lt;a href="https://www.forbes.com/sites/jodiecook/2025/05/28/the-secret-to-growing-on-linkedin-without-posting-every-day/" rel="noopener noreferrer"&gt;1% of LinkedIn's 310 million&lt;/a&gt; monthly active users post content weekly. This means even basic posting puts you ahead of 99% of the platform.&lt;/p&gt;

&lt;p&gt;You do not need to write thought leadership essays. Post about:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;A technical problem you solved recently and what you learned.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;An interesting article from your field with your take on it.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;A project you shipped and the tradeoffs you made.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;A question about a technology you are learning.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Comment on 5-10 posts per day from people in your target companies and industry. Thoughtful comments (not "Great post!") increase your visibility and create warm connections for Week 3 outreach.&lt;/p&gt;




&lt;h2&gt;
  
  
  Week 3: Launch a Targeted Application Blitz (Days 15-21)
&lt;/h2&gt;

&lt;p&gt;Your resume is ATS-ready. Your LinkedIn is recruiter-visible. Now you apply with purpose and speed.&lt;/p&gt;

&lt;p&gt;The math matters here. &lt;a href="https://blog.theinterviewguys.com/how-many-applications-does-it-take-to-get-one-interview/" rel="noopener noreferrer"&gt;Research from career data platforms&lt;/a&gt; shows that about 42 applications yield one interview for the average job seeker. But "average" includes people sending untailored resumes to irrelevant roles. With your polished materials from Weeks 1-2, your hit rate should be significantly higher. Target 1 interview for every 15-20 quality applications.&lt;/p&gt;

&lt;h3&gt;
  
  
  Day 15-16: Build Your Target List
&lt;/h3&gt;

&lt;p&gt;Create a spreadsheet with four columns: Company, Role, URL, and Status. Populate it with 40-60 roles across these sources:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Job boards:&lt;/strong&gt; Indeed, LinkedIn Jobs, and Glassdoor for broad coverage.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Company career pages:&lt;/strong&gt; Go directly to the career pages of 10-15 companies you admire. Roles posted here sometimes do not appear on aggregator sites.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Startup-specific boards:&lt;/strong&gt; Wellfound (formerly AngelList), Y Combinator's Work at a Startup, and Hacker News "Who's Hiring" threads.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Niche boards:&lt;/strong&gt; If you specialize in a specific area, check boards like &lt;a href="https://climatebase.org/" rel="noopener noreferrer"&gt;Climatebase&lt;/a&gt; for climate tech, &lt;a href="https://www.dice.com/" rel="noopener noreferrer"&gt;Dice&lt;/a&gt; for general tech, or &lt;a href="https://builtin.com/" rel="noopener noreferrer"&gt;Built In&lt;/a&gt; for startup-heavy markets.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Day 17-19: Apply in Batches with Quality Control
&lt;/h3&gt;

&lt;p&gt;Apply to 8-12 positions per day across platforms. For each application:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Read the full job description (not just the title).&lt;/li&gt;
&lt;li&gt;Tailor your resume to emphasize the most relevant skills.&lt;/li&gt;
&lt;li&gt;Write a brief, specific cover letter for roles at companies you care about.&lt;/li&gt;
&lt;li&gt;Track every application in your spreadsheet.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is where the time math gets brutal. At 20-30 minutes per tailored application, 10 applications eat 3-5 hours of your day. &lt;a href="https://fastapply.co" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt; compresses this process. The extension works across Indeed, LinkedIn, Glassdoor, Lever, Greenhouse, and Workday platforms. It reads the job description, tailors your resume, generates a role-specific cover letter, and fills out the application form. What normally takes 30 minutes becomes a 3-minute review and approval.&lt;/p&gt;

&lt;p&gt;Over three days of batch applications, FastApply users typically submit 40-60 tailored applications instead of the 15-20 they would manage manually. That is the difference between scraping by with one interview and scheduling three or four.&lt;/p&gt;

&lt;h3&gt;
  
  
  Day 20-21: Activate Your Network
&lt;/h3&gt;

&lt;p&gt;Referral candidates get hired at &lt;a href="https://blog.theinterviewguys.com/how-many-applications-it-takes-to-get-hired-in-2025/" rel="noopener noreferrer"&gt;a 30% rate compared to the 1-2% rate for cold applications&lt;/a&gt;. Spend these two days reaching out to your network.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frky2qshsfd4n4461suwp.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Frky2qshsfd4n4461suwp.png" alt="Referrals Vs Cold Applications" width="800" height="420"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Message 15-20 people with this framework:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;strong&gt;First line:&lt;/strong&gt; Specific reference to their work or your shared connection.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Second line:&lt;/strong&gt; What you are looking for (be precise about role type and level).&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Third line:&lt;/strong&gt; A soft ask. "Would you be open to a 15-minute call about what it is like working at [Company]?" works better than "Do you know of any openings?"&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Also reach out to 5-10 recruiters who specialize in your tech stack or domain. Recruiters fill roles that never get posted publicly. A brief, skills-focused message with your resume attached gets their attention.&lt;/p&gt;




&lt;h2&gt;
  
  
  Week 4: Follow Up and Prepare to Convert (Days 22-30)
&lt;/h2&gt;

&lt;p&gt;By Week 4, your applications are out and your network is activated. Some responses will start coming in. This week is about converting interest into scheduled interviews and preparing to perform.&lt;/p&gt;

&lt;h3&gt;
  
  
  Day 22-23: Send Strategic Follow-Ups
&lt;/h3&gt;

&lt;p&gt;For applications submitted in Week 3, send a follow-up email or LinkedIn message to the hiring manager or recruiter. A short message works best:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;"Hi [Name], I applied for the [Role] position at [Company] last week. I am especially interested in [specific project or challenge the team is working on]. I would welcome the chance to discuss how my experience with [relevant skill] could contribute. Happy to share more detail at your convenience."&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Research from recruiting data shows that 80% of job offers happen after five or more follow-ups, but most candidates never follow up once. A single polite message puts you ahead of the majority.&lt;/p&gt;

&lt;h3&gt;
  
  
  Day 24-26: Prepare for Technical Interviews
&lt;/h3&gt;

&lt;p&gt;With interviews starting to land on your calendar, shift into preparation mode.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;For coding interviews:&lt;/strong&gt; Spend 1-2 hours daily on &lt;a href="https://leetcode.com/" rel="noopener noreferrer"&gt;LeetCode&lt;/a&gt; or &lt;a href="https://neetcode.io/" rel="noopener noreferrer"&gt;NeetCode&lt;/a&gt;. Focus on the most common patterns: arrays, hash maps, trees, graphs, and DP problems. Practice talking through your approach out loud as you solve problems.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;For system design interviews:&lt;/strong&gt; Study 3-5 common system design problems. Resources like &lt;a href="https://github.com/donnemartin/system-design-primer" rel="noopener noreferrer"&gt;the System Design Primer on GitHub&lt;/a&gt; and the book "Designing Data-Intensive Applications" by Martin Kleppmann provide strong foundations. Practice drawing architectures on a whiteboard or digital tool.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;For behavioral interviews:&lt;/strong&gt; Prepare 8-10 stories using the STAR format (Situation, Task, Action, Result). Cover common themes: a time you disagreed with a teammate, a project that failed, a time you led without authority, and your biggest technical accomplishment.&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  Day 27-28: Run Mock Interviews
&lt;/h3&gt;

&lt;p&gt;Practice with a real person. Options include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A friend or former colleague in tech (free, but quality varies).&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://www.pramp.com/" rel="noopener noreferrer"&gt;Pramp&lt;/a&gt; for free peer-to-peer mock coding interviews.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://interviewing.io/" rel="noopener noreferrer"&gt;Interviewing.io&lt;/a&gt; for anonymous practice with engineers from top companies.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Record yourself if possible. Watch for filler words, unclear explanations, and moments where you rush through your reasoning.&lt;/p&gt;

&lt;h3&gt;
  
  
  Day 29-30: Review, Adjust, and Plan Ahead
&lt;/h3&gt;

&lt;p&gt;Look at your numbers from the past 30 days:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;How many applications did you send?&lt;/li&gt;
&lt;li&gt;How many responses did you receive?&lt;/li&gt;
&lt;li&gt;What is your application-to-interview ratio?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If your ratio is worse than 1 interview per 25 applications, revisit your resume and targeting. If you are getting interviews but not advancing, the issue is interview performance, not materials.&lt;/p&gt;

&lt;p&gt;Set your plan for the next 30 days based on what the data tells you. The job search does not always wrap up in one month, but after these four weeks, you have every piece of the system in place.&lt;/p&gt;




&lt;h2&gt;
  
  
  Tools and Systems to Keep You on Track
&lt;/h2&gt;

&lt;p&gt;A structured job search needs tracking. Here is what to set up:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Application tracker:&lt;/strong&gt; A simple spreadsheet with columns for company, role, date applied, status, follow-up date, and notes. Google Sheets works. So does Notion or Airtable.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Calendar blocks:&lt;/strong&gt; Schedule 2-3 hours daily for job search activities. Treat these blocks like meetings you would not cancel.&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;&lt;a href="https://fastapply.co" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt;:&lt;/strong&gt; For application volume without sacrificing quality. The extension handles resume tailoring, cover letter generation, and form-filling across six platforms (Indeed, LinkedIn, Glassdoor, Lever, Greenhouse, Workday). You maintain control through the review-before-submit workflow. The built-in application tracking keeps your pipeline organized without a separate spreadsheet.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;LinkedIn alerts:&lt;/strong&gt; Set up job alerts for your target titles and locations. New postings get sent to your inbox so you apply within the first 24-48 hours, when response rates are highest.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;




&lt;h2&gt;
  
  
  FAQ
&lt;/h2&gt;

&lt;h3&gt;
  
  
  How many applications should I send to get a tech interview?
&lt;/h3&gt;

&lt;p&gt;Research from 2025 shows the average is about 42 applications per interview. With a tailored resume and targeted approach, you should aim for 1 interview per 15-20 quality applications. Referral-based applications perform far better, with a 30% success rate compared to 1-2% for cold applications.&lt;/p&gt;

&lt;h3&gt;
  
  
  Does tailoring my resume for each job posting make a real difference?
&lt;/h3&gt;

&lt;p&gt;Yes. Over 90% of employers use automated screening tools, and about 75% of resumes get filtered out before a human sees them. Matching your resume keywords to each job posting significantly increases your chances of passing these filters.&lt;/p&gt;

&lt;h3&gt;
  
  
  How do I get recruiters to find me on LinkedIn?
&lt;/h3&gt;

&lt;p&gt;Complete your profile fully (profiles with complete information get 21 times more views). Use your target job title in your headline. List 5 or more skills (this increases recruiter discovery by 27 times). Turn on "Open to Work" for a 40% increase in recruiter messages. Post or comment regularly to appear in recruiter feeds.&lt;/p&gt;

&lt;h3&gt;
  
  
  Is it worth applying on company career pages directly?
&lt;/h3&gt;

&lt;p&gt;Yes. Some roles appear only on company career pages and never reach job boards. Applying directly also shows initiative. Combine direct applications with board applications for the broadest reach.&lt;/p&gt;

&lt;h3&gt;
  
  
  What is the best time to apply for tech jobs?
&lt;/h3&gt;

&lt;p&gt;Apply within the first 48 hours of a posting going live. Early applicants get reviewed before the volume builds up. Monday through Wednesday mornings tend to see the highest recruiter activity.&lt;/p&gt;

&lt;h3&gt;
  
  
  Should I use AI tools for my job applications?
&lt;/h3&gt;

&lt;p&gt;AI tools help with the repetitive parts of applying: tailoring resumes, generating cover letters, and filling forms. The best approach combines AI speed with human judgment. Tools like FastApply handle the automation while letting you review and approve each application before it goes out.&lt;/p&gt;

&lt;h3&gt;
  
  
  How long does a tech job search take on average?
&lt;/h3&gt;

&lt;p&gt;The median time-to-hire in 2025 reached about 68 days, over two months. A focused strategy like this 30-day plan aims to compress the early stages so interviews begin sooner, even if the full hiring cycle extends beyond the month.&lt;/p&gt;

</description>
      <category>howtogettechinterviewsin30days</category>
      <category>30daystechinterviewplan</category>
      <category>2026linkedinstrategy</category>
      <category>atsresume</category>
    </item>
    <item>
      <title>What is FAANG? How to Get Hired by Big Tech Companies</title>
      <dc:creator>Ekekenta Odionyenfe Clinton </dc:creator>
      <pubDate>Wed, 27 Aug 2025 12:51:28 +0000</pubDate>
      <link>https://forem.com/fastapplyai/what-is-faang-how-to-get-hired-by-big-tech-companies-4ilh</link>
      <guid>https://forem.com/fastapplyai/what-is-faang-how-to-get-hired-by-big-tech-companies-4ilh</guid>
      <description>&lt;p&gt;When people talk about the best-paying, most competitive jobs in technology, they often mention FAANG. The term describes a group of companies that dominate the industry. They attract top talent worldwide. They are known for high salaries, benefits, and career opportunities.&lt;/p&gt;

&lt;p&gt;Getting hired by them is tough. The process is selective. The competition is global. But with the right preparation, you can increase your chances.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is FAANG
&lt;/h2&gt;

&lt;p&gt;FAANG is an acronym. It refers to:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Facebook (Meta)&lt;/li&gt;
&lt;li&gt;Amazon&lt;/li&gt;
&lt;li&gt;Apple&lt;/li&gt;
&lt;li&gt;Netflix&lt;/li&gt;
&lt;li&gt;Google (Alphabet)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;These companies set the standard in software engineering, product design, cloud services, e-commerce, and digital media. They are leaders in scale and innovation. Jobs at FAANG are highly sought after because they bring experience, prestige, and strong pay.&lt;/p&gt;

&lt;p&gt;For a broader explanation of the term and its history, see &lt;strong&gt;&lt;a href="https://www.investopedia.com/terms/f/faang-stocks.asp?utm_source=blog.fastapply.co" rel="noopener noreferrer"&gt;Investopedia’s overview of FAANG stocks&lt;/a&gt;&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fxz6n6i94w5u38pvw0imq.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fxz6n6i94w5u38pvw0imq.png" alt="FAANG company logos arranged in a sleek grid" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Why people aim for FAANG
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;High compensation:&lt;/strong&gt; Salaries and stock options are among the best in the world (&lt;a href="https://www.levels.fyi/?utm_source=blog.fastapply.co" rel="noopener noreferrer"&gt;see Levels.fyi salary benchmarks&lt;/a&gt;).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Learning environment:&lt;/strong&gt; You work with experts solving difficult problems.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Career growth:&lt;/strong&gt; FAANG experience on a resume opens doors across industries.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Global reach:&lt;/strong&gt; Products impact billions of users.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The rewards are significant. That’s why competition is intense.&lt;/p&gt;

&lt;h2&gt;
  
  
  Roles FAANG hires for
&lt;/h2&gt;

&lt;p&gt;FAANG companies recruit across many functions, but technical roles dominate:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Software engineering&lt;/li&gt;
&lt;li&gt;Data science&lt;/li&gt;
&lt;li&gt;Machine learning engineering&lt;/li&gt;
&lt;li&gt;Product management&lt;/li&gt;
&lt;li&gt;UX/UI design&lt;/li&gt;
&lt;li&gt;Cybersecurity&lt;/li&gt;
&lt;li&gt;Cloud infrastructure&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;They also hire in operations, finance, sales, HR, and legal. But technical expertise is the fastest path in.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Follrywk7jzfxla2x8y0x.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Follrywk7jzfxla2x8y0x.png" alt="FAANG job roles with icons (engineering, data, design, product)" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  The hiring process
&lt;/h2&gt;

&lt;p&gt;Each FAANG company has its own process, but common steps include:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Online application:&lt;/strong&gt; Resume submission through job boards or company portals.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Recruiter screening:&lt;/strong&gt; A phone or video call to assess fit.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Technical interviews:&lt;/strong&gt; Coding challenges, system design, or case studies.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Behavioral interviews:&lt;/strong&gt; Questions on teamwork, leadership, and problem solving.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Final loop:&lt;/strong&gt; Multiple rounds with senior staff.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Recruiters expect candidates to pass both technical and behavioral tests. Preparation matters. A good resource is &lt;strong&gt;&lt;a href="https://interviewkickstart.com/blogs/articles/how-do-i-know-if-im-ready-to-interview-at-faang?utm_source=blog.fastapply.co" rel="noopener noreferrer"&gt;Interview Kickstart’s breakdown of FAANG interview prep&lt;/a&gt;&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Skills you need
&lt;/h2&gt;

&lt;p&gt;To get into FAANG, focus on hard skills and supporting soft skills.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Hard skills&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Strong coding ability (Python, Java, C++, JavaScript)&lt;/li&gt;
&lt;li&gt;Data structures and algorithms&lt;/li&gt;
&lt;li&gt;System design principles&lt;/li&gt;
&lt;li&gt;Cloud computing (AWS, GCP, Azure)&lt;/li&gt;
&lt;li&gt;Data analysis and machine learning tools&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Soft skills&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Communication&lt;/li&gt;
&lt;li&gt;Collaboration&lt;/li&gt;
&lt;li&gt;Leadership potential&lt;/li&gt;
&lt;li&gt;Adaptability under pressure&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Both skill sets appear in interviews.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to prepare
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Study computer science fundamentals:&lt;/strong&gt; Algorithms, complexity, and data structures.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Practice coding challenges:&lt;/strong&gt; Use platforms such as &lt;strong&gt;&lt;a href="https://leetcode.com/?utm_source=blog.fastapply.co" rel="noopener noreferrer"&gt;LeetCode&lt;/a&gt;&lt;/strong&gt;, HackerRank, or Codeforces.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Learn system design:&lt;/strong&gt; Read case studies, practice designing scalable systems.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Research behavioral frameworks:&lt;/strong&gt; The STAR method is particularly effective for situational questions.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Network strategically:&lt;/strong&gt; Connect with FAANG employees, recruiters, and alumni—referrals often boost chances.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Preparation is a months-long process. Consistency counts more than cramming.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8nkq5nomckn4uwcbq65s.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F8nkq5nomckn4uwcbq65s.png" alt="Candidate practicing coding + interview prep flow" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Challenges in applying
&lt;/h2&gt;

&lt;p&gt;The biggest hurdle is getting noticed. Thousands apply for each role. ATS filters reject resumes that don’t match keywords. Recruiters scan applications in seconds. Applying to dozens of positions manually is slow and draining.&lt;/p&gt;

&lt;h2&gt;
  
  
  FastApply and FAANG applications
&lt;/h2&gt;

&lt;p&gt;This is where &lt;a href="https://fastapply.co/?utm_source=blog.fastapply.co" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt; changes the game. FAANG jobs go live and receive hundreds of applicants in hours. To compete, you need speed and precision.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;FastApply:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Scans job descriptions and tailors your resume automatically.&lt;/li&gt;
&lt;li&gt;Adjusts hard skills to match ATS filters.&lt;/li&gt;
&lt;li&gt;Generates custom cover letters.&lt;/li&gt;
&lt;li&gt;Submits applications across multiple platforms at once.&lt;/li&gt;
&lt;li&gt;Tracks every application so you know where you stand.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Instead of applying to five roles in a week, you apply to fifty. Each application looks unique and targeted. That means more recruiter calls and more interview invites.&lt;/p&gt;

&lt;p&gt;If you want to learn more about passing recruiter filters, check out our guide on &lt;strong&gt;&lt;a href="https://blog.fastapply.co/how-ai-is-reshaping-tech-hiring-and-why-your-resume-must-adapt?utm_source=blog.fastapply.co" rel="noopener noreferrer"&gt;how AI is reshaping hiring and why your resume must adapt&lt;/a&gt;&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Standing out after you apply
&lt;/h2&gt;

&lt;p&gt;FastApply gets you noticed. The rest is on you. Once interviews begin:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Communicate clearly.&lt;/li&gt;
&lt;li&gt;Break problems into steps.&lt;/li&gt;
&lt;li&gt;Explain your thinking process.&lt;/li&gt;
&lt;li&gt;Ask thoughtful questions about the company and role.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;FAANG companies value candidates who show both technical depth and collaborative spirit.&lt;/p&gt;

&lt;p&gt;For advice on managing the grind of job search while improving your skills, see our post: &lt;strong&gt;&lt;a href="https://blog.fastapply.co/how-to-find-jobs-and-upskill-without-burning-out-20250?utm_source=blog.fastapply.co" rel="noopener noreferrer"&gt;avoiding burnout while upskilling and applying&lt;/a&gt;&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;FAANG stands for Facebook, Amazon, Apple, Netflix, and Google. These companies are the top tier of technology employers. Jobs there bring high pay, growth, and prestige.&lt;/p&gt;

&lt;p&gt;The path in is not easy. You need strong skills, careful preparation, and a way to get noticed among thousands of applicants.&lt;/p&gt;

&lt;p&gt;FastApply helps you cross that first barrier. It tailors, submits, and tracks your applications at scale, giving you the speed and personalization you need.&lt;/p&gt;

&lt;p&gt;If your goal is to join FAANG, start now. Build your skills, prepare for interviews, and let FastApply handle the applications that get you in the door.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>What Are Hard Skills? Meaning, Examples, and Resume Tips</title>
      <dc:creator>Ekekenta Odionyenfe Clinton </dc:creator>
      <pubDate>Wed, 27 Aug 2025 12:48:15 +0000</pubDate>
      <link>https://forem.com/fastapplyai/what-are-hard-skills-meaning-examples-and-resume-tips-51n7</link>
      <guid>https://forem.com/fastapplyai/what-are-hard-skills-meaning-examples-and-resume-tips-51n7</guid>
      <description>&lt;p&gt;When employers scan resumes, they look for proof of ability. They want to see skills that can be measured, tested, and applied right away. These are called hard skills.&lt;/p&gt;

&lt;p&gt;Hard skills differ from soft skills. Soft skills are traits like communication, teamwork, or adaptability. Hard skills are concrete. You learn them through training, education, or experience. They are often tied to tools, technologies, or processes.&lt;/p&gt;

&lt;p&gt;If you want to stand out, you need to show the right hard skills on your resume. Let’s break down what they are, examples from different fields, and how to present them for maximum impact.&lt;/p&gt;

&lt;h2&gt;
  
  
  What are hard skills
&lt;/h2&gt;

&lt;p&gt;Hard skills are specific, teachable abilities that you can quantify. They often require certifications, courses, or practice to master. As &lt;strong&gt;&lt;a href="https://www.techtarget.com/searchcio/definition/hard-skills?utm_source=http://blog.fastapply.co" rel="noopener noreferrer"&gt;TechTarget explains&lt;/a&gt;&lt;/strong&gt;, they’re measurable and job-specific, unlike soft skills which are harder to test.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Examples:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Programming in Python&lt;/li&gt;
&lt;li&gt;Data analysis with Excel or SQL&lt;/li&gt;
&lt;li&gt;Graphic design with Adobe Illustrator&lt;/li&gt;
&lt;li&gt;Foreign language fluency&lt;/li&gt;
&lt;li&gt;Project management with Jira&lt;/li&gt;
&lt;li&gt;Accounting and financial modeling&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Employers value hard skills because they predict immediate contribution. They know what you can do, not just how you work.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fvrz12n2hltvy5336hdlp.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fvrz12n2hltvy5336hdlp.png" alt="Hard skills vs soft skills" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Examples of hard skills by industry
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Technology&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Programming languages (Python, Java, JavaScript, C++)&lt;/li&gt;
&lt;li&gt;Database management (SQL, MongoDB)&lt;/li&gt;
&lt;li&gt;Cloud computing (AWS, Azure, Google Cloud)&lt;/li&gt;
&lt;li&gt;Cybersecurity tools (Firewalls, SIEM)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Business and finance&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Financial forecasting&lt;/li&gt;
&lt;li&gt;Accounting software (QuickBooks, SAP)&lt;/li&gt;
&lt;li&gt;Data analysis (Excel, Power BI, Tableau)&lt;/li&gt;
&lt;li&gt;Business intelligence reporting&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Marketing and design&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;SEO and SEM&lt;/li&gt;
&lt;li&gt;Social media management&lt;/li&gt;
&lt;li&gt;Graphic design (Adobe Photoshop, Illustrator)&lt;/li&gt;
&lt;li&gt;Video editing (Final Cut Pro, Premiere Pro)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Healthcare&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Patient care procedures&lt;/li&gt;
&lt;li&gt;Electronic health record systems (Epic, Cerner)&lt;/li&gt;
&lt;li&gt;Medical coding (ICD-10, CPT)&lt;/li&gt;
&lt;li&gt;Lab testing protocols&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Education&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Curriculum planning&lt;/li&gt;
&lt;li&gt;Learning management systems (Canvas, Blackboard)&lt;/li&gt;
&lt;li&gt;Classroom technology (Google Classroom, Zoom)&lt;/li&gt;
&lt;li&gt;Language instruction&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Skilled trades&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Welding&lt;/li&gt;
&lt;li&gt;Electrical systems&lt;/li&gt;
&lt;li&gt;Plumbing installation&lt;/li&gt;
&lt;li&gt;CNC machine operation&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Hard skills are everywhere. The key is identifying which matter for the jobs you want.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmsppf9dpc767bx053azh.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fmsppf9dpc767bx053azh.png" alt="Hard skills examples by industry" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Why hard skills matter in hiring
&lt;/h2&gt;

&lt;p&gt;Recruiters use Applicant Tracking Systems (ATS) to filter resumes. These systems scan for keywords. If your resume lacks the right hard skills, you may get filtered out.&lt;/p&gt;

&lt;p&gt;Even after the ATS stage, hiring managers look for specific abilities. They want proof you meet the technical requirements of the role. That is why hard skills often appear first in job descriptions.&lt;/p&gt;

&lt;p&gt;As &lt;strong&gt;&lt;a href="https://www.walkme.com/blog/hard-skills/?utm_source=http://blog.fastapply.co" rel="noopener noreferrer"&gt;WalkMe notes&lt;/a&gt;&lt;/strong&gt;, hard skills directly impact productivity, accuracy, and efficiency—key reasons employers emphasize them.&lt;/p&gt;

&lt;p&gt;Hard skills get you in the door. Soft skills help you keep the job. You need both, but you cannot skip hard skills when applying.&lt;/p&gt;

&lt;h2&gt;
  
  
  Resume tips for hard skills
&lt;/h2&gt;

&lt;p&gt;How you present hard skills makes a difference. Here are practical tips:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Match job descriptions:&lt;/strong&gt; Read postings carefully. If a job requires “SQL,” list SQL specifically. Avoid vague language.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Create a skills section:&lt;/strong&gt; Place key hard skills in a dedicated section near the top of your resume.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Show application in experience:&lt;/strong&gt; Don’t just list “Excel.” Show how you used Excel to analyze data or improve reporting.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Include certifications:&lt;/strong&gt; List official credentials that prove your expertise.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Keep it updated:&lt;/strong&gt; Remove outdated skills. Focus on current, in-demand tools and processes.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;&lt;a href="https://resumegenius.com/blog/resume-help/hard-skills?utm_source=http://blog.fastapply.co" rel="noopener noreferrer"&gt;ResumeGenius suggests&lt;/a&gt;&lt;/strong&gt; weaving skills into achievement-driven bullet points and tailoring them to each job application. For more strategies, check out our post on &lt;strong&gt;&lt;a href="https://blog.fastapply.co/how-ai-is-reshaping-tech-hiring-and-why-your-resume-must-adapt?utm_source=http://blog.fastapply.co" rel="noopener noreferrer"&gt;How AI Is Reshaping Tech Hiring and Why Your Resume Must Adapt&lt;/a&gt;&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fdx5c6zryx0gdg61nquc9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fdx5c6zryx0gdg61nquc9.png" alt="Resume snapshot – skills section mockup" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  FastApply and hard skills
&lt;/h2&gt;

&lt;p&gt;Listing hard skills is not enough. You also need to tailor them for every role. Employers and ATS systems look for exact keyword matches. That means editing your resume again and again.&lt;/p&gt;

&lt;p&gt;&lt;a href="//htts://fastapply.co"&gt;FastApply&lt;/a&gt; automates this process. It scans job descriptions, matches required hard skills, and adjusts your resume to fit. It highlights the right skills for each application.&lt;/p&gt;

&lt;p&gt;Instead of wasting time rewriting, you apply to more roles with resumes that look specific, not generic. That increases your chances of passing ATS filters and catching recruiter attention.&lt;/p&gt;

&lt;p&gt;Curious about automation and career growth? Read our guide: &lt;strong&gt;&lt;a href="https://blog.fastapply.co/building-a-successful-career-in-2025-how-auto-apply-ai-can-help?utm_source=http://blog.fastapply.co" rel="noopener noreferrer"&gt;Building a Successful Career in 2025: How Auto-Apply AI Can Help&lt;/a&gt;&lt;/strong&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;Hard skills are measurable abilities that prove you can do the work. They differ from soft skills by being concrete, teachable, and easy to test. Employers value them because they show immediate impact.&lt;/p&gt;

&lt;p&gt;To land interviews, you need to identify the right hard skills for your industry and show them clearly on your resume. Pair them with real examples and certifications.&lt;/p&gt;

&lt;p&gt;With FastApply, you don’t waste hours editing. It tailors your resume automatically, matches hard skills to job descriptions, and helps you stand out faster.&lt;/p&gt;

&lt;p&gt;Hard skills open the door. FastApply helps you walk through it.&lt;/p&gt;

&lt;p&gt;P.S. If you’re balancing job applications with upskilling, here’s a must-read: &lt;strong&gt;&lt;a href="https://blog.fastapply.co/how-to-find-jobs-and-upskill-without-burning-out-20250?utm_source=http://blog.fastapply.co" rel="noopener noreferrer"&gt;How To Find Jobs And Upskill Without Burning Out&lt;/a&gt;&lt;/strong&gt;.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>How to Get a Job at Tesla in 2025: Insider Tips</title>
      <dc:creator>Ekekenta Odionyenfe Clinton </dc:creator>
      <pubDate>Wed, 27 Aug 2025 12:40:43 +0000</pubDate>
      <link>https://forem.com/fastapplyai/how-do-i-find-a-new-job-immediately-1imf</link>
      <guid>https://forem.com/fastapplyai/how-do-i-find-a-new-job-immediately-1imf</guid>
      <description>&lt;p&gt;Tesla leads global innovation in electric vehicles, energy solutions, and AI manufacturing. The company attracts professionals who want to work with advanced technology, but thousands apply each year while only a few get hired.&lt;/p&gt;

&lt;p&gt;Here's what most people miss: Tesla's hiring process isn't random. Recruiters look for specific things, and when you know what those are, you improve your odds dramatically.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why People Want Tesla Jobs
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Clear mission:&lt;/strong&gt; Accelerating the world's transition to sustainable energy&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Innovation at scale:&lt;/strong&gt; Projects in EVs, solar, batteries, and AI&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Career growth:&lt;/strong&gt; Opportunities across engineering, manufacturing, and business&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;High visibility:&lt;/strong&gt; Work that influences entire industries&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;For many professionals, Tesla represents both purpose and prestige.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyv6eniyeor7uico361an.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyv6eniyeor7uico361an.png" alt="Tesla logo" width="800" height="440"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Resume Tips for Tesla in 2025
&lt;/h2&gt;

&lt;p&gt;Tesla recruiters use &lt;a href="https://topresume.com/career-advice/5-key-tips-for-a-stellar-key-skills-section" rel="noopener noreferrer"&gt;ATS systems&lt;/a&gt; and hiring managers who want proof of impact. A generic resume won't work.&lt;/p&gt;

&lt;p&gt;Key rules:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Tailor for each role:&lt;/strong&gt; Match Tesla's job descriptions directly&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Show measurable results:&lt;/strong&gt; Write "Reduced production cycle time by 15%" instead of "Worked on assembly"&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Highlight technical expertise:&lt;/strong&gt; Software (C++, Python, MATLAB), hardware, or manufacturing skills&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Include leadership and collaboration:&lt;/strong&gt; Tesla values initiative and the ability to thrive in fast teams&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Keep it lean:&lt;/strong&gt; 1 page for most applicants, 2 max for senior-level&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://fastapply.co/?utm_source=blog.fastapply.co" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt; helps by scanning Tesla postings and tailoring resumes automatically. Instead of rewriting every time, you submit optimized resumes in minutes.&lt;/p&gt;

&lt;h2&gt;
  
  
  Tesla Interview Process in 2025
&lt;/h2&gt;

&lt;p&gt;Tesla's process moves fast and varies by role but usually includes:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Online application via &lt;a href="https://www.tesla.com/careers" rel="noopener noreferrer"&gt;Tesla Careers&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Recruiter screening call&lt;/li&gt;
&lt;li&gt;Technical assessment (coding, engineering problems, or case studies depending on role)&lt;/li&gt;
&lt;li&gt;Hiring manager interview&lt;/li&gt;
&lt;li&gt;On-site or virtual interviews (multiple rounds, often with problem-solving tasks)&lt;/li&gt;
&lt;li&gt;Final offer review&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Preparation is essential. People who walk in without role-specific technical depth rarely advance.&lt;/p&gt;

&lt;h2&gt;
  
  
  What Tesla Looks For
&lt;/h2&gt;

&lt;p&gt;Tesla hires for both hard skills and cultural fit. Key traits include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Problem-solving ability&lt;/strong&gt; - Strong engineering or technical thinking&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Hands-on skills&lt;/strong&gt; - Ability to apply knowledge in real-world contexts&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Ownership&lt;/strong&gt; - Taking initiative without waiting for instructions&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Passion for sustainability&lt;/strong&gt; - Belief in Tesla's mission&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  How to Prepare for Tesla Interviews
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Master technical foundations:&lt;/strong&gt; Whether it's electrical engineering, coding, or mechanical systems&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Practice coding and engineering problems:&lt;/strong&gt; Use &lt;a href="https://leetcode.com/" rel="noopener noreferrer"&gt;LeetCode&lt;/a&gt; (software) or &lt;a href="https://www.glassdoor.com/Interview/Tesla-Interview-Questions-E43129.htm" rel="noopener noreferrer"&gt;Glassdoor Tesla interview questions&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Understand Tesla's products:&lt;/strong&gt; Be ready to discuss Tesla vehicles, energy products, or AI initiatives&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Prepare STAR stories:&lt;/strong&gt; Especially for teamwork, leadership, and problem-solving scenarios&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Communicate clearly under pressure:&lt;/strong&gt; Tesla values fast, clear decision-making&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Insider Tips for 2025
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Referrals matter:&lt;/strong&gt; Referrals move your application ahead. Network with Tesla employees on &lt;a href="https://www.linkedin.com/" rel="noopener noreferrer"&gt;LinkedIn&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Apply early:&lt;/strong&gt; Tesla roles fill quickly. Applications within 48 hours have higher chances&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Be mission-driven:&lt;/strong&gt; Highlight your alignment with Tesla's sustainability goals&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Show resilience:&lt;/strong&gt; Tesla is known for a demanding environment. Persistence is key&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  The Challenge of Applying
&lt;/h2&gt;

&lt;p&gt;Tesla jobs attract thousands of applicants. Resumes that aren't ATS-optimized get rejected fast. Editing and uploading applications one by one takes time. By the time you apply, the role might already have hundreds of submissions.&lt;/p&gt;

&lt;p&gt;See &lt;a href="https://topresume.com/career-advice/what-is-an-ats-resume" rel="noopener noreferrer"&gt;how ATS systems filter resumes&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  FastApply and Tesla Jobs
&lt;/h2&gt;

&lt;p&gt;FastApply helps you stay ahead by:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Tailoring resumes to Tesla postings&lt;/li&gt;
&lt;li&gt;Matching keywords to beat ATS filters&lt;/li&gt;
&lt;li&gt;Generating custom cover letters&lt;/li&gt;
&lt;li&gt;Submitting across multiple platforms instantly&lt;/li&gt;
&lt;li&gt;Tracking applications so you never lose progress&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;With FastApply, you apply faster, smarter, and earlier. This gives you an edge over slower applicants.&lt;/p&gt;

&lt;h2&gt;
  
  
  After You Land the Interview
&lt;/h2&gt;

&lt;p&gt;Once FastApply gets you noticed, success depends on how you perform:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Practice technical problems daily&lt;/li&gt;
&lt;li&gt;Time yourself during problem-solving sessions&lt;/li&gt;
&lt;li&gt;Prepare stories that show leadership and resilience&lt;/li&gt;
&lt;li&gt;Stay calm and confident. Tesla values problem-solving style as much as solutions&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Getting Your Tesla Job
&lt;/h2&gt;

&lt;p&gt;Getting a job at Tesla in 2025 requires preparation, technical expertise, and persistence. A generic resume or unstructured interview approach won't get you far.&lt;/p&gt;

&lt;p&gt;FastApply makes the application process easier by tailoring, submitting, and tracking your resumes so you focus on what matters: preparing for interviews and showcasing your skills.&lt;/p&gt;

&lt;p&gt;Tesla is selective. With the right tools and preparation, you put yourself in a position for success.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>How do I find a new job immediately?</title>
      <dc:creator>Ekekenta Odionyenfe Clinton </dc:creator>
      <pubDate>Sun, 24 Aug 2025 08:32:01 +0000</pubDate>
      <link>https://forem.com/fastapplyai/how-do-i-find-a-new-job-immediately-24ha</link>
      <guid>https://forem.com/fastapplyai/how-do-i-find-a-new-job-immediately-24ha</guid>
      <description>&lt;p&gt;When you need a new job, every day counts. Bills don’t wait. Stress builds fast. You search, apply, and refresh your inbox, but responses take weeks. The question is urgent: how do you find a new job immediately?&lt;/p&gt;

&lt;p&gt;There’s no magic button that guarantees instant employment, but you can speed up the process. The key is reaching more opportunities faster, tailoring your applications without losing time, and getting noticed early. Let’s walk through what works and why FastApply is the best way to move quickly.&lt;/p&gt;

&lt;h2&gt;
  
  
  Start with the basics
&lt;/h2&gt;

&lt;p&gt;Most people start with job boards. LinkedIn, Indeed, Glassdoor, ZipRecruiter, and Wellfound list millions of roles. They let you filter by title, location, pay, or company. They give you alerts so you can act fast.&lt;/p&gt;

&lt;p&gt;The issue is time. You see hundreds of openings, but applying takes hours. If you only send five applications a day, your search drags on. To find work quickly, you need scale.&lt;/p&gt;

&lt;h2&gt;
  
  
  Understand how hiring systems work
&lt;/h2&gt;

&lt;p&gt;Behind almost every posting is an Applicant Tracking System, or ATS. Companies use them to manage applicants. ATS platforms scan your resume for keywords. They filter out candidates who don’t match.&lt;/p&gt;

&lt;p&gt;That means your resume has to be tailored for each job. If it isn’t, you risk rejection before a human ever looks at it. Tailoring takes time. Too much time if you need a job right away.&lt;/p&gt;

&lt;h2&gt;
  
  
  Easy Apply vs Manual Apply
&lt;/h2&gt;

&lt;p&gt;Job boards often offer Easy Apply. You click once, and your resume goes straight to the recruiter. It saves time and helps you apply to more roles in less effort.&lt;/p&gt;

&lt;p&gt;Manual apply routes you to a company’s site. You fill out forms, upload documents, and answer questions. It allows for more detail, but it’s slow.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Comparison&lt;/strong&gt;&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Method&lt;/th&gt;
&lt;th&gt;Benefits&lt;/th&gt;
&lt;th&gt;Downsides&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Easy Apply&lt;/td&gt;
&lt;td&gt;Fast, one click, quick visibility&lt;/td&gt;
&lt;td&gt;Generic resume, less customization&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Manual Apply&lt;/td&gt;
&lt;td&gt;Tailored, full application&lt;/td&gt;
&lt;td&gt;Time consuming, repetitive&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;If speed is your goal, Easy Apply helps. But if quality matters, Manual Apply does. To get a job quickly, you need both at the same time.&lt;/p&gt;

&lt;h2&gt;
  
  
  Increase your reach
&lt;/h2&gt;

&lt;p&gt;The fastest way to land interviews is to apply to more jobs. Recruiters often notice early applicants first. Sending out 10 applications a week won’t move the needle. Sending 100 tailored applications at the same time changes the outcome.&lt;/p&gt;

&lt;p&gt;Volume increases odds. Tailoring improves results. Together, they shorten your search.&lt;/p&gt;

&lt;h2&gt;
  
  
  Use networking alongside applications
&lt;/h2&gt;

&lt;p&gt;Networking still matters. Reach out to past colleagues. Let your network know you’re available. Connect with recruiters on LinkedIn. Attend local or virtual events in your industry.&lt;/p&gt;

&lt;p&gt;But networking takes time to produce results. Applications keep you in the running now. The smartest move is combining both.&lt;/p&gt;

&lt;h2&gt;
  
  
  FastApply makes it immediate
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://fastapply.co" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt; exists for people who want results quickly. It automates the repetitive work of applications. It integrates with LinkedIn, Indeed, Glassdoor, Wellfound, ZipRecruiter, and ATS platforms like Greenhouse, Lever, Workable, and Ashby.&lt;/p&gt;

&lt;p&gt;Here’s how it works:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Upload your resume once.&lt;/li&gt;
&lt;li&gt;FastApply tailors it automatically for each job.&lt;/li&gt;
&lt;li&gt;It writes a matching cover letter.&lt;/li&gt;
&lt;li&gt;It fills out repeated form fields for you.&lt;/li&gt;
&lt;li&gt;It tracks where and when you applied.&lt;/li&gt;
&lt;li&gt;It applies in bulk across multiple sites.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Instead of applying to five jobs in an evening, you apply to fifty. Each application looks unique, tailored, and ATS-friendly. Recruiters see your application early, and it passes keyword filters. That’s how you speed up the job hunt.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0ebp9idum4stiwlrp43w.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0ebp9idum4stiwlrp43w.png" alt="Setting your job preferences on FastApply" width="800" height="368"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Why FastApply is the fastest way forward
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Job boards&lt;/strong&gt; give you listings, but you still spend hours filling forms. FastApply takes care of that.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;ATS&lt;/strong&gt; rejects generic resumes. FastApply adapts itself to match requirements.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Easy Apply&lt;/strong&gt; is quick but generic. FastApply is quick and tailored.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Manual Apply&lt;/strong&gt; is tailored but slow. FastApply is tailored and fast.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;When you need a job immediately, volume plus quality is what matters. FastApply gives you both.&lt;/p&gt;

&lt;h2&gt;
  
  
  Reduce stress while moving faster
&lt;/h2&gt;

&lt;p&gt;Looking for work is exhausting. The more time you spend on repetitive applications, the more drained you feel. That exhaustion leads to missed opportunities.&lt;/p&gt;

&lt;p&gt;FastApply removes that burden. It keeps you applying consistently every day without burning out. It gives you visibility with a dashboard that shows progress. It replaces frustration with action.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Feays7vgb8xbrq7p9j351.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Feays7vgb8xbrq7p9j351.png" alt="FastApply bot applying to jobs on LinkedIn" width="800" height="422"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;If you’re asking how to find a new job immediately, the answer is clear. Apply faster. Apply more. Apply better. Use the tools that combine speed with personalization.&lt;/p&gt;

&lt;p&gt;FastApply is built for this moment. It helps you reach opportunities quickly, pass ATS filters, and get noticed earlier. It is the fastest way to land interviews and move into your next role.&lt;/p&gt;

&lt;p&gt;Don’t wait weeks for results. Start applying at scale today. Use FastApply, and make the process immediate.&lt;/p&gt;

</description>
    </item>
    <item>
      <title>How to Run DeepSeek Locally Using LM Studio(For Free)</title>
      <dc:creator>Clinton Ekekenta</dc:creator>
      <pubDate>Tue, 11 Feb 2025 11:07:01 +0000</pubDate>
      <link>https://forem.com/fastapplyai/how-to-run-deepseek-locally-using-lm-studiofor-free-3cc7</link>
      <guid>https://forem.com/fastapplyai/how-to-run-deepseek-locally-using-lm-studiofor-free-3cc7</guid>
      <description>&lt;p&gt;Running AI models locally ensures your data stays private and secure. With growing concerns about data being sent to China, running AI models locally ensures your data never leaves your computer. In this tutorial, I'll show you how to run DeepSeek on your computer using LM Studio, a straightforward tool that makes local AI accessible to everyone.&lt;/p&gt;

&lt;h2&gt;
  
  
  Understanding LM Studio
&lt;/h2&gt;

&lt;p&gt;LM Studio is a user-friendly application that lets you run various AI models locally on your computer. What makes it particularly appealing is its simple interface and the ability to run models like DeepSeek, Llama, and Mistral without any complex setup.&lt;/p&gt;

&lt;h2&gt;
  
  
  Installation Process
&lt;/h2&gt;

&lt;p&gt;Getting started with LM Studio is remarkably simple:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Visit &lt;a href="https://lmstudio.ai/" rel="noopener noreferrer"&gt;lmstudio.ai&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Download the application for your operating system&lt;/li&gt;
&lt;li&gt;Run the installer and follow the standard installation prompts&lt;/li&gt;
&lt;li&gt;Launch LM Studio&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Choosing Your DeepSeek Model
&lt;/h2&gt;

&lt;p&gt;Once LM Studio is running, you'll be presented with a chat interface. To get DeepSeek up and running:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Click on the search function in LM Studio&lt;/li&gt;
&lt;li&gt;Search for "DeepSeek" to see all available models&lt;/li&gt;
&lt;li&gt;Choose from several variants:

&lt;ul&gt;
&lt;li&gt;DeepSeek R1: The latest version, optimized for efficiency&lt;/li&gt;
&lt;li&gt;Mathematics-focused variants&lt;/li&gt;
&lt;li&gt;Coding-specialized versions&lt;/li&gt;
&lt;li&gt;Different parameter sizes (7B, 8B, etc.)&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Understanding Model Sizes
&lt;/h2&gt;

&lt;p&gt;The model size you choose matters for both performance and practicality:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;7B models: 7 billion parameters, good balance of performance and resource usage&lt;/li&gt;
&lt;li&gt;Larger models (like 70B): 

&lt;ul&gt;
&lt;li&gt;Offer enhanced performance&lt;/li&gt;
&lt;li&gt;Require significant storage (around 43GB)&lt;/li&gt;
&lt;li&gt;Need more computational power&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;/ul&gt;

&lt;h2&gt;
  
  
  Selecting the Right Model for Your System
&lt;/h2&gt;

&lt;p&gt;For most users, I recommend starting with smaller models:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Choose the 7B version if you're unsure about your system's capabilities&lt;/li&gt;
&lt;li&gt;Consider your available storage space and computing power&lt;/li&gt;
&lt;li&gt;Test the model's performance on your system before moving to larger versions&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Using Your Local DeepSeek
&lt;/h2&gt;

&lt;p&gt;After downloading your chosen model:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Return to the chat interface&lt;/li&gt;
&lt;li&gt;Select your downloaded DeepSeek model from the model selection menu&lt;/li&gt;
&lt;li&gt;Begin interacting with the model locally&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Privacy Benefits
&lt;/h2&gt;

&lt;p&gt;By running DeepSeek locally through LM Studio:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Your data never leaves your computer&lt;/li&gt;
&lt;li&gt;No information is sent to external servers&lt;/li&gt;
&lt;li&gt;Complete control over your interactions with the AI&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Remember, the key to successful local AI usage is finding the right balance between model capability and your system's resources. Start with smaller models and upgrade as needed based on your requirements and system capabilities.&lt;/p&gt;

&lt;p&gt;Do you feel lazy about filling out job forms and uploading resumes? Apply to 100+ LinkedIn &amp;amp; Indeed jobs in minutes with &lt;a href="https://chromewebstore.google.com/detail/fastapply-free-ai-automat/aokdahpjojkcjlnlbjlecolfcnhjndnd" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>deepseek</category>
      <category>deepseekr1</category>
      <category>opensource</category>
      <category>llm</category>
    </item>
    <item>
      <title>How to Install and Run DeepSeek-1 Locally on Windows (For Free)</title>
      <dc:creator>Clinton Ekekenta</dc:creator>
      <pubDate>Tue, 11 Feb 2025 10:53:07 +0000</pubDate>
      <link>https://forem.com/fastapplyai/how-to-install-and-run-deepseek-1-locally-on-windows-for-free-2bng</link>
      <guid>https://forem.com/fastapplyai/how-to-install-and-run-deepseek-1-locally-on-windows-for-free-2bng</guid>
      <description>&lt;p&gt;Running powerful AI models locally on your PC might sound daunting, but it's actually quite straightforward. In this tutorial, I'll walk you through installing DeepSeek-1 on your Windows machine in about ten minutes. The best part? You won't need expensive hardware or a high-end GPU that costs more than your mortgage.&lt;/p&gt;

&lt;h2&gt;
  
  
  Hardware Requirements
&lt;/h2&gt;

&lt;p&gt;Before we dive in, let's talk about what you'll need. I'm using a Mini Forum MS-A1 with an AMD Ryzen 7 CPU and 32GB of RAM for this tutorial. While these specs are comfortable, you can run DeepSeek-1 on more modest hardware. The key is finding the right balance between model size and your system's capabilities, which we'll discuss later.&lt;/p&gt;

&lt;h2&gt;
  
  
  Setting Up Your Windows Environment
&lt;/h2&gt;

&lt;p&gt;The first step is preparing your Windows system for running AI models locally. Let's start by enabling the necessary Windows features:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Press the Windows key and search for &lt;strong&gt;Windows features&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;In the Windows Features dialog, locate and check the box next to &lt;strong&gt;Virtual Machine Platform&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Click OK and restart your computer when prompted&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Installing Required Software
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Ollama Installation
&lt;/h3&gt;

&lt;p&gt;Ollama serves as our model manager and is essential for running DeepSeek-1. Here's how to set it up:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Visit &lt;a href="http://ollama.com/" rel="noopener noreferrer"&gt;ollama.com&lt;/a&gt; and click the download button&lt;/li&gt;
&lt;li&gt;Select the Windows version (Mac and Linux versions are also available)&lt;/li&gt;
&lt;li&gt;Run the installer once downloaded&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Note: Don't be concerned when you don't see a graphical interface after installation - this is normal as Ollama runs in the background.&lt;/p&gt;

&lt;h3&gt;
  
  
  Docker Desktop Setup
&lt;/h3&gt;

&lt;p&gt;Docker Desktop is crucial for running our web interface. Follow these steps:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Go to &lt;a href="https://docs.docker.com/get-started/" rel="noopener noreferrer"&gt;docs.docker.com/get-started&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Click &lt;strong&gt;Get Docker **and select D&lt;/strong&gt;ocker Desktop for Windows**&lt;/li&gt;
&lt;li&gt;Download the x86_64 version&lt;/li&gt;
&lt;li&gt;Run the installer and restart your computer&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;When you log back in, you might see two important prompts:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A command prompt asking you to update WSL (Windows Subsystem for Linux)&lt;/li&gt;
&lt;li&gt;The Docker Desktop setup wizard&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Complete both processes to ensure proper configuration.&lt;/p&gt;

&lt;h2&gt;
  
  
  Installing Open Web UI
&lt;/h2&gt;

&lt;p&gt;Open Web UI provides our graphical interface for interacting with DeepSeek-1. Here's how to set it up:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Visit &lt;a href="http://docs.openwebui.com/" rel="noopener noreferrer"&gt;docs.openwebui.com&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Navigate to &lt;strong&gt;Getting Started&lt;/strong&gt; → &lt;strong&gt;Quick Start&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Open Command Prompt (Windows key + R, type &lt;strong&gt;cmd&lt;/strong&gt;, press Enter)&lt;/li&gt;
&lt;li&gt;Copy and paste the provided container command

&lt;ul&gt;
&lt;li&gt;For systems with NVIDIA GPUs, use the GPU-enabled command&lt;/li&gt;
&lt;li&gt;For other systems, use the standard command&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Wait for the container to download and start&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Once running, you can access the interface through Docker Desktop by clicking on the ports tab, which will open the UI in your browser. You'll notice it has a familiar chat interface, similar to ChatGPT.&lt;/p&gt;

&lt;h2&gt;
  
  
  Adding DeepSeek-r1 Model
&lt;/h2&gt;

&lt;p&gt;Now for the exciting part - installing the actual AI model:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Go back to ollama.com and click on &lt;strong&gt;Models&lt;/strong&gt;
&lt;/li&gt;
&lt;li&gt;Find DeepSeek in the list&lt;/li&gt;
&lt;li&gt;Choose your model size:

&lt;ul&gt;
&lt;li&gt;Model names include parameter counts (e.g., deepseek-r1:7b for 7 billion parameters)&lt;/li&gt;
&lt;li&gt;Larger models offer better performance but require more resources&lt;/li&gt;
&lt;li&gt;Start with deepseek-r1:7b for a good balance&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Copy the model name (e.g., deepseek-r1:7b)&lt;/li&gt;
&lt;li&gt;In the Open Web UI interface, click the model selection dropdown&lt;/li&gt;
&lt;li&gt;Paste the model name and initiate the download&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Using Your Local DeepSeek-r1
&lt;/h2&gt;

&lt;p&gt;After the model downloads and verifies, you can start using it completely offline. All processing happens on your local machine, ensuring your data stays private. You can even download multiple models and run them simultaneously to compare their outputs.&lt;/p&gt;

&lt;p&gt;Remember, this is just the beginning. You can experiment with different model sizes and configurations to find what works best for your specific hardware and needs.&lt;/p&gt;

&lt;p&gt;Do you feel lazy about filling out job forms and uploading resumes? Apply to 100+ LinkedIn &amp;amp; Indeed jobs in minutes with &lt;a href="https://chromewebstore.google.com/detail/fastapply-free-ai-automat/aokdahpjojkcjlnlbjlecolfcnhjndnd" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>deepseek</category>
      <category>deepseekr1</category>
      <category>opensource</category>
      <category>webdev</category>
    </item>
    <item>
      <title>How to Add and Use Deepseek-r1 in Your Visual Studio Code (For Free!)</title>
      <dc:creator>Clinton Ekekenta</dc:creator>
      <pubDate>Thu, 30 Jan 2025 17:19:22 +0000</pubDate>
      <link>https://forem.com/fastapplyai/how-to-add-and-use-deepseek-r1-in-your-visual-studio-code-for-free-6n3</link>
      <guid>https://forem.com/fastapplyai/how-to-add-and-use-deepseek-r1-in-your-visual-studio-code-for-free-6n3</guid>
      <description>&lt;p&gt;The AI revolution is happening, and Deepseek-r1 is at the forefront. This powerful Large Language Model (LLM) goes head-to-head with top AI models like GPT, excelling in reasoning, coding, and problem-solving, all while running right on your own machine. No more relying on expensive, cloud-based tools. With Deepseek-r1, you get a fast, private, and cost-effective coding assistant that’s always available when you need it.&lt;br&gt;
After countless hours with tools like Cursor and other paid AI helpers, I decided to give Deepseek-r1 a shot. I discovered a game-changer: a seamless, free integration with Visual Studio Code that supercharged my workflow. Ready to dive in? Let me show you how to set it up step by step.&lt;/p&gt;
&lt;h2&gt;
  
  
  Why Deepseek-r1?
&lt;/h2&gt;

&lt;p&gt;Before we jump into the setup, let's look at why you should consider using Deepseek-r1 as a developer:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You can run everything locally on your computer without a cloud provider.&lt;/li&gt;
&lt;li&gt;It helps you solve complex coding tasks faster and smarter.&lt;/li&gt;
&lt;li&gt;It performs well in code generation and debugging.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;
  
  
  Installing Deepseek-r1 in VS Code?
&lt;/h2&gt;

&lt;p&gt;Let's proceed to install Deepseek-r1 in your Virtual Studio Code coding environment. To do that, follow the steps below:&lt;/p&gt;
&lt;h3&gt;
  
  
  Step 1: Install Ollama
&lt;/h3&gt;

&lt;p&gt;To get started, you’ll need Ollama, a lightweight platform that lets you run LLMs locally. Ollama is the backbone of your Deepseek-r1 setup because it will enable you to manage and run Deepseek-r1 effortlessly on your computer.&lt;/p&gt;

&lt;p&gt;To install Ollama, head over to &lt;a href="https://ollama.com/" rel="noopener noreferrer"&gt;Ollama’s official website&lt;/a&gt; and download the version for your OS. Then their installation instructions to get it up and running.&lt;br&gt;
&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fm7uwvc1hi54fgriqvm64.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fm7uwvc1hi54fgriqvm64.png" alt="Downloading Ollama online" width="800" height="414"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h3&gt;
  
  
  Step 2: Download Deepseek-r1
&lt;/h3&gt;

&lt;p&gt;With Ollama installed, it’s time to bring Deepseek-r1 into your coding environment. Open your terminal and run below:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ollama pull deepseek-r1
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;blockquote&gt;
&lt;p&gt;This may take some time to install, but you must exercise some patience.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;The above command will download the Deepseek-r1 model to your local computer.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fbley3tcc9v1an7z3yahu.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fbley3tcc9v1an7z3yahu.png" alt="Installing Deepseek-r1 locally on your computer" width="800" height="223"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Once the download is complete, test it with a simple query to ensure everything’s working. Run the deepseek-r1 with the command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ollama run deepseek-r1
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And add your test prompt:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6yl8ll5ib58nl9obgsnl.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6yl8ll5ib58nl9obgsnl.png" alt="Installing Continue.dev on VS extension" width="800" height="395"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you see a response, you’re all set! Deepseek-r1 is ready to roll.&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 3: Install the Continue.dev Extension
&lt;/h3&gt;

&lt;p&gt;Now, let’s bring Deepseek-r1 into Visual Studio Code. For this, we’ll use &lt;a href="http://continue.dev/" rel="noopener noreferrer"&gt;Continue.dev&lt;/a&gt;, a fantastic extension that connects VS Code to LLMs like Deepseek-r1. This extension will act as a bridge between your VS Code and Ollama, allowing you to interact with Deepseek-r1 directly within your coding environment. To install Continue.dev Extension, follow the steps:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Open VS Code and go to the Extensions Marketplace.&lt;/li&gt;
&lt;li&gt;Search for Continue.dev and hit install.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fshplvr9guhqd2b3sjp1s.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fshplvr9guhqd2b3sjp1s.png" alt="Installing Continue.dev on VS extension" width="800" height="362"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Step 4: Configure Deepseek-r1 in Continue.dev
&lt;/h3&gt;

&lt;p&gt;With Continue.dev installed, it’s time to connect it to Deepseek-r1. Follow the steps to configure it:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Open the Continue.dev interface by clicking its icon in the VS Code Activity Bar.&lt;/li&gt;
&lt;li&gt;Look for the model selection button at the bottom-left corner of the chat window.&lt;/li&gt;
&lt;li&gt;Click the button, select Ollama as the platform, and then choose Deepseek-r1 from the list of available models.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ftm105obzebk2br2g8bzw.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ftm105obzebk2br2g8bzw.png" alt="Configuring Deepseek on VS Code" width="800" height="912"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;That’s it! You’re now ready to harness the power of Deepseek-r1 in your coding workflow.&lt;/p&gt;

&lt;h2&gt;
  
  
  What Can You Do with Deepseek-r1?
&lt;/h2&gt;

&lt;p&gt;Once everything is set up, the possibilities of Deepseek-r1 are endless in your coding environment:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;It gives you intelligent, context-aware suggestions as you type.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;You can highlight a code block and ask Deepseek-r1 to optimize or rewrite it.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;if you are stuck on an error, Deepseek-r1 will help you troubleshoot it.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;You can select any snippet and get a detailed breakdown of how it works.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Here’s a quick demo of how Deepseek-r1 works in your Virtual Studio Code.&lt;/p&gt;

&lt;p&gt;The most interesting part is that you:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You don't need subscriptions or hidden fees, just free and powerful AI assistance.&lt;/li&gt;
&lt;li&gt;Everything runs locally, so your code stays on your machine.&lt;/li&gt;
&lt;li&gt;You can tailor Deepseek-r1’s behavior to fit your specific needs.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Final Thoughts
&lt;/h2&gt;

&lt;p&gt;Integrating Deepseek-r1 into Visual Studio Code has been a game-changer for my productivity. It’s fast, reliable, and incredibly versatile all without me having to spend a dive. Whether you’re a seasoned developer or just starting, this setup is worth exploring.&lt;/p&gt;

&lt;p&gt;So, what are you waiting for? Give Deepseek-r1 a try and experience the future of coding today.&lt;/p&gt;

&lt;p&gt;Apply to 100+ LinkedIn &amp;amp; Indeed Jobs in Minutes using &lt;a href="https://chromewebstore.google.com/detail/fastapply-free-ai-automat/aokdahpjojkcjlnlbjlecolfcnhjndnd" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Happy coding! 🚀&lt;/p&gt;

</description>
      <category>deepseek</category>
      <category>deepseekr1</category>
      <category>ai</category>
      <category>vscode</category>
    </item>
    <item>
      <title>Confronting Bias in Artificial Intelligence (AI)</title>
      <dc:creator>Clinton Ekekenta</dc:creator>
      <pubDate>Tue, 28 Jan 2025 12:35:33 +0000</pubDate>
      <link>https://forem.com/fastapplyai/confronting-bias-in-artificial-intelligence-ai-daf</link>
      <guid>https://forem.com/fastapplyai/confronting-bias-in-artificial-intelligence-ai-daf</guid>
      <description>&lt;p&gt;Artificial Intelligence (AI) has crept into every area of our daily lives. These AI systems were created by humans, for humans, while using data that's highly correlated with humans. Thus, it's inevitable that AI systems can inherit the biases that humans have already absorbed.&lt;/p&gt;

&lt;p&gt;Now, if we must continue dealing with AI systems on such a significant scale, we must confront any possibility of exclusion, unfairness, or discrimination. In this article, we discuss one of the scary aspects of AI usage in human affairs: &lt;strong&gt;AI bias&lt;/strong&gt;. This article will explain everything you need to know about bias in AI, including its types, consequences, detection, and mitigation.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is AI Bias?
&lt;/h2&gt;

&lt;p&gt;AI bias is a systematic distortion of machine learning (ML) models and algorithms that lead to prejudice for or against a person or group. It's a terrible situation where the results from an AI system discriminate against a particular group or person, leading to unfair outcomes.&lt;/p&gt;

&lt;p&gt;AI bias is sometimes called algorithm bias or machine learning bias. This phenomenon often originates from incorrect assumptions in the ML pipeline, whether in the data pre-processing, algorithm design, or model outcomes.&lt;/p&gt;

&lt;p&gt;As humans, we carry biases, both consciously and subconsciously, with us. For instance, we might give favorable treatment to people we consider “good-looking.” Or, we might assume that people who dress a certain way don't hold a 9-5 job before we even find out if they do. Stereotypes like these are part of the data and prompts that are fed into AI systems.&lt;/p&gt;

&lt;p&gt;When AI systems reinforce stereotypes and produce skewed judgments, they become untrustworthy. But with AI shaping our future and automating critical decision-making processes, we can not afford a mistrust. That's why AI researchers are focused on producing better-performing systems that produce fair, equal, and inclusive results.&lt;/p&gt;

&lt;h2&gt;
  
  
  Types of Bias in AI
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzdt2yrv68iho4x9ja9ys.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fzdt2yrv68iho4x9ja9ys.jpg" alt="Types of AI bias" width="800" height="1131"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Photo by Author&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Below are the most common types of AI biases:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Algorithmic Bias&lt;/strong&gt;
Algorithmic bias occurs when ML algorithms produce unfair or incorrect outcomes that worsen with time because of flaws in their design or training data. This bias isn’t always intentional, but its impact can be significant.&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Flaws in the algorithm design&lt;/strong&gt;: An AI practitioner may intentionally or unintentionally give more importance to certain features or attributes of the dataset while designing and implementing the algorithm. This can lead to discrimination or underrepresentation of certain groups. For example, if a loan approval algorithm heavily relies on only income levels without considering other factors, it might unfairly reject applications from people in lower-income groups.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Flaws in the training data&lt;/strong&gt;: If the data a model learned from is biased, the model will likely replicate this bias in its decisions. For example, if a hiring algorithm was trained on past data that favored one gender over another, it might continue to favor that gender even if it’s not explicitly told to do so.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Cognitive Bias&lt;/strong&gt;
As mentioned earlier, we inherently carry biases with us as humans. These biases can slip into a training dataset without the data scientists or AI engineers realizing it. When this happens, whether through the data selection process or how the data is weighted, it results in a type of AI bias known as cognitive bias. Cognitive bias in AI occurs when the training data reflects the beliefs of its creators or curators.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;For example, a data scientist might be working on a model for recommending personalized learning paths for students. If the person assumes all students can access advanced technology and resources in their schools, they might slip this belief into the training data. This can result in a model that may recommend online simulations or advanced software to students in underfunded schools.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Recency Bias&lt;/strong&gt;
Sometimes, a dataset influenced by recent events can lead to a cognitive bias known as recency bias. This occurs when the training data favors the latest trends and events without considering the broader historical context.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;For example, if the training dataset of a stock prediction model only contains information on the current hottest stocks in the market, the model might place disproportionate weight on the recent performance of the stocks. This means the model might be unable to accurately identify patterns and predict future stock prices because it can not access historical information on the stocks.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Confirmation Bias&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Confirmation bias is the opposite of recency bias. In this case, the model is trained using a dataset that favors pre-existing beliefs. Thus, the model might be unable to identify new or future patterns. For example, if a fashion trend prediction model is trained using data from previous seasons, it might overlook new styles gaining popularity because it is biased toward the historical trends it has already learned.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Outgroup Homogeneity Bias&lt;/strong&gt;
Outgroup homogeneity bias in AI occurs when the model is trained on homogenous data that doesn't capture the diversity of both the majority and minority groups. This means the dataset focuses more on the characteristics of the majority group without considering the subtle differences present in minority groups.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Homogeneity bias is often a result of the AI engineer's lack of exposure to diverse groups (outgroups) outside their own (ingroup), leading to racial bias or unfair outcomes. For example, a model that assesses students’ writing might be trained primarily on essays by native English speakers. Thus, the model may consider unique phrasing or structures from non-native speakers as errors and unfairly score them.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Prejudice Bias&lt;/strong&gt;
This type of bias in AI stems from wrong societal biases or stereotypes that are unintentionally introduced into the training data. When AI systems are trained on datasets that contain historical biases, they can replicate and amplify these biases.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;For example, if a recruitment algorithm is trained on data where women have historically been underrepresented in engineering roles, the AI might favor male candidates, supporting the stereotype that men are superior for such jobs.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Exclusion Bias&lt;/strong&gt;
This type of bias occurs when the training data does not include important information crucial to the reality that the AI system is supposed to model. Exclusion bias often happens during the data preprocessing stage when a researcher decides to remove or keep certain data points.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;For example, a researcher might exclude attendance data while working on a student success prediction model. However, attendance might actually be a key predictor of student performance.&lt;/p&gt;

&lt;p&gt;Ultimately, just because AI systems are fed millions of data doesn't automatically make them neutral or trustworthy. The humans behind these datasets can still highly influence them.&lt;/p&gt;

&lt;h2&gt;
  
  
  Consequences of Biased AI systems
&lt;/h2&gt;

&lt;p&gt;AI biases are often unintentional and can be difficult to notice because they are ingrained into our society and may seem “normal.” It's only when we start seeing the consequences of these biases that we truly understand the implications of their existence. Below are some of such consequences:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Unfair treatment&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Biased AI systems can limit the access of marginalized groups to essential services. For instance, a model trained on a medical dataset that under-represents women in the healthcare sector can make it harder for female patients to get appointments. This can lead to unequal access to healthcare and potential harm to women.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Discrimination&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Bias in AI can amplify existing inequalities in our society. For example, in the criminal justice system, a biased algorithm can lead to the discrimination of people of color. They could be more likely to be arrested or receive harsher sentences.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Technology mistrust&lt;/strong&gt;
When users can't trust an AI system to serve everyone's needs regardless of race, gender, age, socioeconomic background, or other characteristics, they won't want to be associated with the technology.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Being aware of the different biases in AI and their consequences for individuals and society at large is the first step to building more equitable models. The second step is to detect these biases early in the development stage of the AI system and reduce their negative effects.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to Detect Bias in AI
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fblog.fastapply.co%2Fimages%2Fconfronting-bias-in-artificial-intelligence%2Fpexels-katierainbow-9714250.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fblog.fastapply.co%2Fimages%2Fconfronting-bias-in-artificial-intelligence%2Fpexels-katierainbow-9714250.jpg" alt="Detecting Bias in AI" width="800" height="533"&gt;&lt;/a&gt;&lt;br&gt;
&lt;em&gt;Photo by Author&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;To detect bias in AI systems, researchers and practitioners always ask these three critical questions:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Was the model trained with diverse datasets?&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;A model with a homogenous training dataset will likely produce biased results. So, it's essential to check if the model was trained with diverse and representative data to ensure fair treatment across various demographic groups. When every group is represented in a dataset, the model is likely not to favor one over the other.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;strong&gt;Is the model’s judgement fair?&lt;/strong&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;If the outcomes from a model are unjustly favoring or discriminating against certain groups, then it's an unfair model that's promoting human biases. A fair model produces fair results and makes equitable decisions that represent different demographic groups.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Is the model transparent?&lt;/strong&gt;
A transparent model clearly explains every decision it makes and the reasoning behind every outcome, making it easier to detect hidden biases. Transparent models also help both technical and non-technical users understand AI systems.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  How To Reduce Bias in AI
&lt;/h2&gt;

&lt;p&gt;Mitigating AI bias is a complicated challenge because it's sometimes difficult to identify and isolate the different sources of bias in AI since they can arise from the data, the algorithm, and the user. However, below are some of the approaches AI researchers have proposed for preventing AI systems from promoting negative human bias:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Using diverse data collection&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;As stated earlier, a diverse dataset is vital for creating equitable AI systems. Therefore, data should be pre-processed to identify and address biases before training the model. This can be achieved by using evenly distributed datasets that represent every group being considered. Meanwhile, it's also vital to regularly retrain the algorithm with updated datasets that reflect current societal changes to avoid confirmation or prejudice biases.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;Building transparent AI systems&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Transparent AI systems provide clear explanations of a model's input, training data, and the logic behind its decisions. This information reveals whether the system's decision is biased and when a model deviates from the intended outcomes. When users know how a system arrived at its conclusion, it builds their trust in the system. However, building transparent models can be challenging for black-box systems such as Large Language Models (LLMs), where the training data is private and the behavior of the algorithms cannot be well documented.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Using human reviewers&lt;/strong&gt;&lt;br&gt;
Also known as a “human-in-the-loop” system, human reviewers can find biases that AI systems may easily overlook. Organizations should assemble a team during the AI development and evaluation that assess every decision an AI system makes before approving. For this process to yield meaningful results, the review team should include people with different backgrounds, such as race, gender, and educational level. This diversity ensures the model is reviewed from different perspectives, and its potential for bias is considered from all angles.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;Continuous Model Monitoring&lt;/strong&gt;&lt;br&gt;
AI models are not static. They evolve and interact with real-world data and biased users, which can introduce them to new biases over time. Monitoring and testing these models is crucial to identify and address potential issues before they cause harm. This approach involves periodically evaluating the model’s performance with real-world data and making necessary adjustments to maintain fairness and accuracy.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Finally, mitigation approaches for AI bias are still a work in progress that's continuously undergoing constant research and development. In the meantime, these strategies shared above can help organizations take meaningful steps toward ensuring fairness, transparency, and inclusivity in AI development.&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;This article has explained the various sources of AI biases, their profound societal impact, and some strategies for combating them. It's clear that if AI systems are not delicately designed, they could become a sociotechnical disaster. Thus, as we look to the future, we all need to be part of the conversation because AI is becoming the cornerstone of technology in every sector, and it should work for everyone. We must remain vigilant in safeguarding this technology against subtle yet harmful biases.&lt;/p&gt;

&lt;p&gt;Apply to 100+ LinkedIn &amp;amp; Indeed Jobs in Minutes using &lt;a href="https://chromewebstore.google.com/detail/fastapply-free-ai-automat/aokdahpjojkcjlnlbjlecolfcnhjndnd" rel="noopener noreferrer"&gt;FastApply&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>ai</category>
      <category>automation</category>
    </item>
    <item>
      <title>Integrating Large Language Models in Production Applications</title>
      <dc:creator>Clinton Ekekenta</dc:creator>
      <pubDate>Mon, 06 Jan 2025 14:14:31 +0000</pubDate>
      <link>https://forem.com/fastapplyai/integrating-large-language-models-in-production-applications-57on</link>
      <guid>https://forem.com/fastapplyai/integrating-large-language-models-in-production-applications-57on</guid>
      <description>&lt;p&gt;In this practical guide, you will learn how to create a highly scalable model deployment solution with built-in LLMs for your applications. &lt;br&gt;
In your examples, we will use Hugging Face’s ChatGPT2 model, but you can easily plug in any other model including ChatGPT4, Claude, etc. &lt;br&gt;
Whether you are designing a new application with AI capabilities or improving the existing AI systems, this guide will help you step by step to create a strong LLM integration.&lt;/p&gt;
&lt;h2&gt;
  
  
  Understanding LLM Integration Fundamentals
&lt;/h2&gt;

&lt;p&gt;Before we start writing code, let’s figure out what it takes to build a production LLM integration. API calls are not the only thing you need to consider when building production-ready LLM integration, you also need to consider things like reliability, cost, and stability. Your production applications must address issues such as service outages, rate limits, and variability in response time while keeping costs under control.&lt;br&gt;
Here's what we'll build together:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A robust API client that gracefully handles failures&lt;/li&gt;
&lt;li&gt;A smart caching system to optimize costs and speed&lt;/li&gt;
&lt;li&gt;A proper prompt management system&lt;/li&gt;
&lt;li&gt;Comprehensive error handling and monitoring&lt;/li&gt;
&lt;li&gt;A complete content moderation system as your example project&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;
  
  
  Prerequisites
&lt;/h2&gt;

&lt;p&gt;Before we start coding, make sure you have:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Python 3.8 or newer installed on your machine&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://redis.io/" rel="noopener noreferrer"&gt;Redis&lt;/a&gt; cloud account or locally installed&lt;/li&gt;
&lt;li&gt;Basic &lt;a href="https://www.python.org/" rel="noopener noreferrer"&gt;Python programming&lt;/a&gt; knowledge&lt;/li&gt;
&lt;li&gt;Basic understanding of REST APIs&lt;/li&gt;
&lt;li&gt;A &lt;a href="https://huggingface.co/" rel="noopener noreferrer"&gt;Hugging Face API key&lt;/a&gt; (or any other LLM provider key)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Want to follow along? The complete code is available in your &lt;a href="https://github.com/icode247/llm_integration" rel="noopener noreferrer"&gt;GitHub repository&lt;/a&gt;.&lt;/p&gt;
&lt;h2&gt;
  
  
  Setting Up your Development Environment
&lt;/h2&gt;

&lt;p&gt;Let's start by getting your development environment ready. We'll create a clean project structure and install all the necessary packages.&lt;/p&gt;

&lt;p&gt;First, let's create your project directory and set up a Python virtual environment. Open your terminal and run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nb"&gt;mkdir &lt;/span&gt;llm_integration &lt;span class="o"&gt;&amp;amp;&amp;amp;&lt;/span&gt; &lt;span class="nb"&gt;cd &lt;/span&gt;llm_integration
python3 &lt;span class="nt"&gt;-m&lt;/span&gt; venv &lt;span class="nb"&gt;env
&lt;/span&gt;syource &lt;span class="nb"&gt;env&lt;/span&gt;/bin/activate
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now let's set up your project dependencies. Create a new &lt;code&gt;requirements.txt&lt;/code&gt; file with these essential packages:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="nv"&gt;transformers&lt;/span&gt;&lt;span class="o"&gt;==&lt;/span&gt;4.36.0
huggingface-hub&lt;span class="o"&gt;==&lt;/span&gt;0.19.4
&lt;span class="nv"&gt;redis&lt;/span&gt;&lt;span class="o"&gt;==&lt;/span&gt;4.6.0
&lt;span class="nv"&gt;pydantic&lt;/span&gt;&lt;span class="o"&gt;==&lt;/span&gt;2.5.0
pydantic-settings&lt;span class="o"&gt;==&lt;/span&gt;2.1.0
&lt;span class="nv"&gt;tenacity&lt;/span&gt;&lt;span class="o"&gt;==&lt;/span&gt;8.2.3
python-dotenv&lt;span class="o"&gt;==&lt;/span&gt;1.0.0
&lt;span class="nv"&gt;fastapi&lt;/span&gt;&lt;span class="o"&gt;==&lt;/span&gt;0.104.1
&lt;span class="nv"&gt;uvicorn&lt;/span&gt;&lt;span class="o"&gt;==&lt;/span&gt;0.24.0
&lt;span class="nv"&gt;torch&lt;/span&gt;&lt;span class="o"&gt;==&lt;/span&gt;2.1.0
&lt;span class="nv"&gt;numpy&lt;/span&gt;&lt;span class="o"&gt;==&lt;/span&gt;1.24.3
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Let's break down why we need each of these packages: &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;transformers&lt;/code&gt;: This is Hugging Face’s powerful library that we will be using to interface with the Qwen2.5-Coder model. &lt;/li&gt;
&lt;li&gt;
&lt;code&gt;huggingface-hub&lt;/code&gt;: Enables us to handle model loading and versioning redis: For implementing request caching &lt;/li&gt;
&lt;li&gt;
&lt;code&gt;pydantic&lt;/code&gt;: Used for data validation and settings. &lt;/li&gt;
&lt;li&gt;
&lt;code&gt;tenacity&lt;/code&gt;: Responsible for your retrying functionality for increased reliability &lt;/li&gt;
&lt;li&gt;
&lt;code&gt;python-dotenv&lt;/code&gt;: For loading environment variables&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;fastapi&lt;/code&gt;: Builds your API endpoints with a small amount of code &lt;/li&gt;
&lt;li&gt;
&lt;code&gt;uvicorn&lt;/code&gt;: Used for running your FastAPI application with great efficiency&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;torch&lt;/code&gt;: For running transformer models and handling machine learning operations&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;numpy&lt;/code&gt;: Used for numerical computing.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Install all the packages with the command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;pip &lt;span class="nb"&gt;install&lt;/span&gt; &lt;span class="nt"&gt;-r&lt;/span&gt; requirements.txt
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Let's organize your project with a clean structure. Create these directories and files in your project directory:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;llm_integration/
├── core/
│   ├── llm_client.py      &lt;span class="c"&gt;# your main LLM interaction code&lt;/span&gt;
│   ├── prompt_manager.py  &lt;span class="c"&gt;# Handles prompt templates&lt;/span&gt;
│   └── response_handler.py &lt;span class="c"&gt;# Processes LLM responses&lt;/span&gt;
├── cache/
│   └── redis_manager.py   &lt;span class="c"&gt;# Manages your caching system&lt;/span&gt;
├── config/
│   └── settings.py        &lt;span class="c"&gt;# Configuration management&lt;/span&gt;
├── api/
│   └── routes.py          &lt;span class="c"&gt;# API endpoints&lt;/span&gt;
├── utils/
│   ├── monitoring.py      &lt;span class="c"&gt;# Usage tracking&lt;/span&gt;
│   └── rate_limiter.py    &lt;span class="c"&gt;# Rate limiting logic&lt;/span&gt;
├── requirements.txt
└── main.py
└── usage_logs.json       
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Building the LLM Client
&lt;/h2&gt;

&lt;p&gt;Let's start with your LLM client which is the most important component of your application. This is where we'll interact with the ChatGPT model (or any other LLM you prefer). Add the following code snippets to your &lt;code&gt;core/llm_client.py&lt;/code&gt; file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;torch&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;transformers&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;AutoModelForCausalLM&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;AutoTokenizer&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;tenacity&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;retry&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;stop_after_attempt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;wait_exponential&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;typing&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;Optional&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;logging&lt;/span&gt;

&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;LLMClient&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;__init__&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;model_name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;gpt2&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;timeout&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;30&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
        &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;tokenizer&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;AutoTokenizer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;from_pretrained&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;model_name&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;model&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;AutoModelForCausalLM&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;from_pretrained&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
                &lt;span class="n"&gt;model_name&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                &lt;span class="n"&gt;device_map&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;auto&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                &lt;span class="n"&gt;torch_dtype&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;torch&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;float16&lt;/span&gt;
            &lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="k"&gt;except&lt;/span&gt; &lt;span class="nb"&gt;Exception&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;logging&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;error&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Error loading model: &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nf"&gt;str&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="c1"&gt;# Fallback to a simpler model if the specified one fails
&lt;/span&gt;            &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;tokenizer&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;AutoTokenizer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;from_pretrained&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;gpt2&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;model&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;AutoModelForCausalLM&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;from_pretrained&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;gpt2&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;timeout&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;timeout&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;logger&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;logging&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getLogger&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;__name__&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In this first part of your&lt;code&gt;LLMClient&lt;/code&gt; class, we're setting up the foundation:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;We are using &lt;code&gt;AutoModelForCausalLM&lt;/code&gt; and &lt;code&gt;AutoTokenizer&lt;/code&gt; from the transformers library to load your model&lt;/li&gt;
&lt;li&gt;The &lt;code&gt;device_map="auto"&lt;/code&gt; parameter automatically handles GPU/CPU allocation&lt;/li&gt;
&lt;li&gt;We're using &lt;code&gt;torch.float16&lt;/code&gt; to optimize memory usage while maintaining good performance&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Now let's add the method that talks to your model:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt; &lt;span class="nd"&gt;@retry&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
        &lt;span class="n"&gt;stop&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nf"&gt;stop_after_attempt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="mi"&gt;3&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
        &lt;span class="n"&gt;wait&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="nf"&gt;wait_exponential&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;multiplier&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;1&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;min&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;4&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;max&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;10&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
        &lt;span class="n"&gt;reraise&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="bp"&gt;True&lt;/span&gt;
    &lt;span class="p"&gt;)&lt;/span&gt;
    &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;complete&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
                      &lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
                      &lt;span class="n"&gt;temperature&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;float&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mf"&gt;0.7&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                      &lt;span class="n"&gt;max_tokens&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;Optional&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="bp"&gt;None&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Get completion from the model with automatic retries&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
        &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;inputs&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;tokenizer&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;return_tensors&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;pt&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;to&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
                &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;model&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;device&lt;/span&gt;
            &lt;span class="p"&gt;)&lt;/span&gt;

            &lt;span class="k"&gt;with&lt;/span&gt; &lt;span class="n"&gt;torch&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;no_grad&lt;/span&gt;&lt;span class="p"&gt;():&lt;/span&gt;
                &lt;span class="n"&gt;outputs&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;model&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;generate&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
                    &lt;span class="o"&gt;**&lt;/span&gt;&lt;span class="n"&gt;inputs&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                    &lt;span class="n"&gt;max_new_tokens&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;max_tokens&lt;/span&gt; &lt;span class="ow"&gt;or&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                    &lt;span class="n"&gt;temperature&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;temperature&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                    &lt;span class="n"&gt;do_sample&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="bp"&gt;True&lt;/span&gt;
                &lt;span class="p"&gt;)&lt;/span&gt;

            &lt;span class="n"&gt;response_text&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;tokenizer&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;decode&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
                &lt;span class="n"&gt;outputs&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt; 
                &lt;span class="n"&gt;skip_special_tokens&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="bp"&gt;True&lt;/span&gt;
            &lt;span class="p"&gt;)&lt;/span&gt;

            &lt;span class="c1"&gt;# Calculate token usage for monitoring
&lt;/span&gt;            &lt;span class="n"&gt;input_tokens&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;len&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;inputs&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;input_ids&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt;
            &lt;span class="n"&gt;output_tokens&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;len&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;outputs&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;])&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="n"&gt;input_tokens&lt;/span&gt;

            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                &lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;content&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;response_text&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                &lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;usage&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                    &lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;prompt_tokens&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;input_tokens&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                    &lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;completion_tokens&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;output_tokens&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                    &lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;total_tokens&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;input_tokens&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="n"&gt;output_tokens&lt;/span&gt;
                &lt;span class="p"&gt;},&lt;/span&gt;
                &lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;model&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;gpt2&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;

        &lt;span class="k"&gt;except&lt;/span&gt; &lt;span class="nb"&gt;Exception&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;logger&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;error&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Error in LLM completion: &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nf"&gt;str&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="k"&gt;raise&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Let's break down what's happening in this completion method:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Added &lt;code&gt;@retry&lt;/code&gt; decorator method to deal with temporary failures.&lt;/li&gt;
&lt;li&gt;Used &lt;code&gt;torch.no_grad()&lt;/code&gt; context manager to save memory by disabling gradient calculations.&lt;/li&gt;
&lt;li&gt;Tracking the token usage in both input and output which is very important for costing.&lt;/li&gt;
&lt;li&gt;Returns a structured dictionary with the response and usage statistics.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Creating your LLM Response Handler
&lt;/h2&gt;

&lt;p&gt;Next, we need to add the response handler to parse and structure the LLM's raw output. Do that in your &lt;code&gt;core/response_handler.py&lt;/code&gt; file with the following code snippets:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;typing&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;logging&lt;/span&gt;

&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;ResponseHandler&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;__init__&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;logger&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;logging&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getLogger&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;__name__&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;parse_moderation_response&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;raw_response&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Parse and structure the raw LLM response for moderation&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
        &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="c1"&gt;# Default response structure
&lt;/span&gt;            &lt;span class="n"&gt;structured_response&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;is_appropriate&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="bp"&gt;True&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;confidence_score&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mf"&gt;0.0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;reason&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="bp"&gt;None&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;

            &lt;span class="c1"&gt;# Simple keyword-based analysis
&lt;/span&gt;            &lt;span class="n"&gt;lower_response&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;raw_response&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;lower&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

            &lt;span class="c1"&gt;# Check for inappropriate content signals
&lt;/span&gt;            &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="nf"&gt;any&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;word&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;lower_response&lt;/span&gt; &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="n"&gt;word&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;inappropriate&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;unsafe&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;offensive&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;harmful&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;]):&lt;/span&gt;
                &lt;span class="n"&gt;structured_response&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;is_appropriate&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="bp"&gt;False&lt;/span&gt;
                &lt;span class="n"&gt;structured_response&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;confidence_score&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mf"&gt;0.9&lt;/span&gt;
                &lt;span class="c1"&gt;# Extract reason if present
&lt;/span&gt;                &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;because&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;lower_response&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
                    &lt;span class="n"&gt;reason_start&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;lower_response&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;find&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;because&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
                    &lt;span class="n"&gt;structured_response&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;reason&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;raw_response&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;reason_start&lt;/span&gt;&lt;span class="p"&gt;:].&lt;/span&gt;&lt;span class="nf"&gt;split&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;.&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;)[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;].&lt;/span&gt;&lt;span class="nf"&gt;strip&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
            &lt;span class="k"&gt;else&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
                &lt;span class="n"&gt;structured_response&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;confidence_score&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mf"&gt;0.95&lt;/span&gt;

            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;structured_response&lt;/span&gt;

        &lt;span class="k"&gt;except&lt;/span&gt; &lt;span class="nb"&gt;Exception&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;logger&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;error&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Error parsing response: &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nf"&gt;str&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;is_appropriate&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="bp"&gt;True&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;confidence_score&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mf"&gt;0.5&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;reason&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Failed to parse response&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;

    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;format_response&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;raw_response&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Format the final response with parsed content and usage stats&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
        &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;content&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;parse_moderation_response&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;raw_response&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;content&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]),&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;usage&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;raw_response&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;usage&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;model&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;raw_response&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;model&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="k"&gt;except&lt;/span&gt; &lt;span class="nb"&gt;Exception&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;logger&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;error&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Error formatting response: &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nf"&gt;str&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="k"&gt;raise&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Adding a Robust Caching System
&lt;/h2&gt;

&lt;p&gt;Now let's create your caching system to improve the application performance and reduce costs. Add the following code snippets to your &lt;code&gt;cache/redis_manager.py&lt;/code&gt; file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;redis&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;typing&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;Optional&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;Any&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;hashlib&lt;/span&gt;

&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;CacheManager&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;__init__&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;redis_url&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;ttl&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;3600&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;redis&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;redis&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;from_url&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;redis_url&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;ttl&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;ttl&lt;/span&gt;

    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;_generate_key&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;params&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;dict&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Generate a unique cache key&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
        &lt;span class="n"&gt;cache_data&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
            &lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;prompt&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;params&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;params&lt;/span&gt;
        &lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="n"&gt;serialized&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;dumps&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;cache_data&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;sort_keys&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="bp"&gt;True&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;hashlib&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;sha256&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;serialized&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;encode&lt;/span&gt;&lt;span class="p"&gt;()).&lt;/span&gt;&lt;span class="nf"&gt;hexdigest&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

    &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;get_cached_response&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
                                &lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
                                &lt;span class="n"&gt;params&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;dict&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;Optional&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;dict&lt;/span&gt;&lt;span class="p"&gt;]:&lt;/span&gt;
        &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Retrieve cached LLM response&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
        &lt;span class="n"&gt;key&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;_generate_key&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;params&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="n"&gt;cached&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;redis&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;key&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;loads&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;cached&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;cached&lt;/span&gt; &lt;span class="k"&gt;else&lt;/span&gt; &lt;span class="bp"&gt;None&lt;/span&gt;

    &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;cache_response&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
                           &lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
                           &lt;span class="n"&gt;params&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;dict&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
                           &lt;span class="n"&gt;response&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;dict&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="bp"&gt;None&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Cache LLM response&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
        &lt;span class="n"&gt;key&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;_generate_key&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;params&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;redis&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;setex&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;key&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;ttl&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;dumps&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;response&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In the above code snippets, we created a &lt;code&gt;CacheManager&lt;/code&gt; class that handles all caching operations with the following:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;The &lt;code&gt;_generate_key&lt;/code&gt; method, which creates unique cache keys based on prompts and parameters&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;get_cached_response&lt;/code&gt; which checks if we have a cached response for a given prompt&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;cache_response&lt;/code&gt; that stores successful responses for future use&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Creating a Smart Prompt Manager
&lt;/h2&gt;

&lt;p&gt;Let's create your prompt manager that will manage the prompts for your LLM model. Add the following code to your &lt;code&gt;core/prompt_manager.py&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;typing&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;Optional&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;pydantic&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;BaseModel&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;os&lt;/span&gt;

&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;Prompt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;BaseModel&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
    &lt;span class="n"&gt;template&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;
    &lt;span class="n"&gt;version&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;
    &lt;span class="n"&gt;description&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;Optional&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;

&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;PromptManager&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;__init__&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;prompts_dir&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;prompts&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;prompts_dir&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;prompts_dir&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;prompts&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;Prompt&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{}&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;_load_prompts&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;_load_prompts&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
        &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Load prompt templates from JSON files&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="ow"&gt;not&lt;/span&gt; &lt;span class="n"&gt;os&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;path&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;exists&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;prompts_dir&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
            &lt;span class="n"&gt;os&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;makedirs&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;prompts_dir&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

        &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="n"&gt;filename&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;os&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;listdir&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;prompts_dir&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
            &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;filename&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;endswith&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;.json&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
                &lt;span class="k"&gt;with&lt;/span&gt; &lt;span class="nf"&gt;open&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;os&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;path&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;join&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;prompts_dir&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;filename&lt;/span&gt;&lt;span class="p"&gt;))&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
                    &lt;span class="n"&gt;prompt_data&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;load&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
                    &lt;span class="n"&gt;prompt_name&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;filename&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;replace&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;.json&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;''&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
                    &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;prompts&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;prompt_name&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Prompt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;**&lt;/span&gt;&lt;span class="n"&gt;prompt_data&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;get_prompt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="o"&gt;**&lt;/span&gt;&lt;span class="n"&gt;kwargs&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Get a formatted prompt template&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;name&lt;/span&gt; &lt;span class="ow"&gt;not&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;prompts&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="k"&gt;raise&lt;/span&gt; &lt;span class="nc"&gt;KeyError&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Prompt template &lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="n"&gt;name&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt; not found&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

        &lt;span class="n"&gt;prompt&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;prompts&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="n"&gt;name&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;template&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;format&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="o"&gt;**&lt;/span&gt;&lt;span class="n"&gt;kwargs&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then create a sample prompt template for content moderation in your &lt;code&gt;prompts/content_moderation.json&lt;/code&gt; file with code snippets:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight json"&gt;&lt;code&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"template"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Analyze if this message is appropriate or not. Respond with whether it is appropriate or inappropriate, and explain why:&lt;/span&gt;&lt;span class="se"&gt;\n\n&lt;/span&gt;&lt;span class="s2"&gt;Message: {content}&lt;/span&gt;&lt;span class="se"&gt;\n\n&lt;/span&gt;&lt;span class="s2"&gt;Analysis:"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"version"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"1.0"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;&lt;span class="w"&gt;
    &lt;/span&gt;&lt;span class="nl"&gt;"description"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;&lt;span class="w"&gt; &lt;/span&gt;&lt;span class="s2"&gt;"Template for content moderation tasks"&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;&lt;span class="w"&gt;
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now your prompt manager will be able to load prompt templates from your JSON file and get also get a formatted prompt template.&lt;/p&gt;

&lt;h2&gt;
  
  
  Setting Up a Configuration Manager
&lt;/h2&gt;

&lt;p&gt;To keep all your LLM configurations in one place and easily reuse them across your application, let's create configuration settings. Add the code below to your &lt;code&gt;config/settings.py&lt;/code&gt; file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;pydantic_settings&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;BaseSettings&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;SettingsConfigDict&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;typing&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;Optional&lt;/span&gt;

&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;Settings&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;BaseSettings&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
    &lt;span class="n"&gt;huggingface_api_key&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;
    &lt;span class="n"&gt;redis_url&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;redis://localhost:6379&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
    &lt;span class="n"&gt;cache_ttl&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;3600&lt;/span&gt;
    &lt;span class="n"&gt;llm_model_name&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;gpt2&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
    &lt;span class="n"&gt;request_timeout&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;30&lt;/span&gt;
    &lt;span class="n"&gt;max_retries&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;3&lt;/span&gt;
    &lt;span class="n"&gt;rate_limit_requests&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;100&lt;/span&gt;
    &lt;span class="n"&gt;rate_limit_period&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;60&lt;/span&gt;

    &lt;span class="n"&gt;model_config&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;SettingsConfigDict&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
        &lt;span class="n"&gt;env_file&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;.env&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="n"&gt;protected_namespaces&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
    &lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="n"&gt;settings&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Settings&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Implementing Rate Limiting
&lt;/h2&gt;

&lt;p&gt;Next, let's implement rate limiting to control how users access your application’s resources. To do that, add the following code to your &lt;code&gt;utils/rate_limiter.py&lt;/code&gt; file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;time&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;collections&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;deque&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;typing&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;Deque&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;Tuple&lt;/span&gt;

&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;RateLimiter&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;__init__&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;requests&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;period&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;int&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;requests&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;requests&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;period&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;period&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;timestamps&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;Deque&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;float&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nf"&gt;deque&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

    &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;check_rate_limit&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="nb"&gt;bool&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Check if request is within rate limits&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
        &lt;span class="n"&gt;now&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;time&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;time&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

        &lt;span class="k"&gt;while&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;timestamps&lt;/span&gt; &lt;span class="ow"&gt;and&lt;/span&gt; &lt;span class="n"&gt;now&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;timestamps&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;period&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;timestamps&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;popleft&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="nf"&gt;len&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;timestamps&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;=&lt;/span&gt; &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;requests&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="bp"&gt;False&lt;/span&gt;

        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;timestamps&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;append&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;now&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="bp"&gt;True&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In the &lt;code&gt;RateLimiter&lt;/code&gt; we implemented a resuable &lt;code&gt;check_rate_limit&lt;/code&gt; method that can be used in any route to handle rate limiting by simply passing the period and number of requests allowed for each user for period of time.&lt;/p&gt;

&lt;h2&gt;
  
  
  Creating your API Endpoints
&lt;/h2&gt;

&lt;p&gt;Now let's create your API endpoints in the &lt;code&gt;api/routes.py&lt;/code&gt; file to integrate your LLM in your application:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;functools&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;lru_cache&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;fastapi&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;APIRouter&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;HTTPException&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;Depends&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;typing&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;core.llm_client&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;LLMClient&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;core.prompt_manager&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;PromptManager&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;cache.redis_manager&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;CacheManager&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;config.settings&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;settings&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;utils.monitoring&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;UsageMonitor&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;utils.rate_limiter&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;RateLimiter&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;core.response_handler&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;ResponseHandler&lt;/span&gt;

&lt;span class="n"&gt;router&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;APIRouter&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="n"&gt;rate_limiter&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;RateLimiter&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="n"&gt;requests&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;rate_limit_requests&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;period&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;rate_limit_period&lt;/span&gt;
&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="n"&gt;usage_monitor&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;UsageMonitor&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="c1"&gt;# Dependency injection functions
&lt;/span&gt;&lt;span class="nd"&gt;@lru_cache&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;get_llm_client&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;LLMClient&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Provide LLM client instance&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nc"&gt;LLMClient&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
        &lt;span class="n"&gt;model_name&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;llm_model_name&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="n"&gt;timeout&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;request_timeout&lt;/span&gt;
    &lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="nd"&gt;@lru_cache&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;get_response_handler&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;ResponseHandler&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Provide response handler instance&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nc"&gt;ResponseHandler&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="nd"&gt;@lru_cache&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;get_cache_manager&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;CacheManager&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Provide cache manager instance&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nc"&gt;CacheManager&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
        &lt;span class="n"&gt;redis_url&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;redis_url&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="n"&gt;ttl&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;settings&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;cache_ttl&lt;/span&gt;
    &lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="nd"&gt;@lru_cache&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
&lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;get_prompt_manager&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;PromptManager&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Provide prompt manager instance&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="nc"&gt;PromptManager&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="nd"&gt;@router.post&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;/moderate&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;moderate_content&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="n"&gt;content&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;
    &lt;span class="n"&gt;llm_client&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;LLMClient&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Depends&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;get_llm_client&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
    &lt;span class="n"&gt;cache_manager&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;CacheManager&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Depends&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;get_cache_manager&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
    &lt;span class="n"&gt;prompt_manager&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;PromptManager&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Depends&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;get_prompt_manager&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
    &lt;span class="n"&gt;response_handler&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;ResponseHandler&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Depends&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;get_response_handler&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="p"&gt;):&lt;/span&gt;
    &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Moderate content using LLM&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="ow"&gt;not&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;rate_limiter&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;check_rate_limit&lt;/span&gt;&lt;span class="p"&gt;():&lt;/span&gt;
        &lt;span class="k"&gt;raise&lt;/span&gt; &lt;span class="nc"&gt;HTTPException&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;status_code&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;429&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
            &lt;span class="n"&gt;detail&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Rate limit exceeded&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt;

    &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="n"&gt;prompt&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;prompt_manager&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get_prompt&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;content_moderation&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;content&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;content&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;text&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt;

        &lt;span class="c1"&gt;# Check cache first
&lt;/span&gt;        &lt;span class="n"&gt;cached_response&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;cache_manager&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get_cached_response&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;temperature&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mf"&gt;0.3&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;cached_response&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;cached_response&lt;/span&gt;

        &lt;span class="c1"&gt;# Get LLM response
&lt;/span&gt;        &lt;span class="n"&gt;raw_response&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;llm_client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;complete&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;temperature&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mf"&gt;0.3&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt;

        &lt;span class="c1"&gt;# Process the response
&lt;/span&gt;        &lt;span class="n"&gt;formatted_response&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;response_handler&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;format_response&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;raw_response&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

        &lt;span class="c1"&gt;# Cache the processed response
&lt;/span&gt;        &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;cache_manager&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;cache_response&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;prompt&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;temperature&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="mf"&gt;0.3&lt;/span&gt;&lt;span class="p"&gt;},&lt;/span&gt;
            &lt;span class="n"&gt;formatted_response&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt;

        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;formatted_response&lt;/span&gt;

    &lt;span class="k"&gt;except&lt;/span&gt; &lt;span class="nb"&gt;Exception&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="k"&gt;raise&lt;/span&gt; &lt;span class="nc"&gt;HTTPException&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;status_code&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;500&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;detail&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Error processing request: &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nf"&gt;str&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Here we defined a &lt;code&gt;/moderate&lt;/code&gt; endpoint in the &lt;code&gt;APIRouter&lt;/code&gt; class, which is responsible for organizing API routes. The &lt;code&gt;@lru_cache&lt;/code&gt; decorator is applied to dependency injection functions (&lt;code&gt;get_llm_client&lt;/code&gt;, &lt;code&gt;get_response_handler&lt;/code&gt;, &lt;code&gt;get_cache_manager&lt;/code&gt;, and &lt;code&gt;get_prompt_manager&lt;/code&gt;) to ensure that instances of &lt;code&gt;LLMClient&lt;/code&gt;, &lt;code&gt;CacheManager&lt;/code&gt;, and &lt;code&gt;PromptManager&lt;/code&gt; are cached for better performance. The &lt;code&gt;moderate_content&lt;/code&gt; function, decorated with &lt;code&gt;@router.post&lt;/code&gt;, defines a &lt;strong&gt;POST&lt;/strong&gt; route for content moderation and utilizes FastAPI's &lt;code&gt;Depends&lt;/code&gt; mechanism to inject these dependencies. Inside the function, the &lt;code&gt;RateLimiter&lt;/code&gt; class, configured with rate limit settings from settings, enforces request limits.&lt;/p&gt;

&lt;p&gt;Finally, let's update your &lt;code&gt;main.py&lt;/code&gt; to bring everything together:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;fastapi&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;FastAPI&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;api.routes&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;router&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;uvicorn&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;logging&lt;/span&gt;

&lt;span class="n"&gt;logging&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;basicConfig&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="n"&gt;level&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;logging&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;INFO&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="nb"&gt;format&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;&lt;span class="s"&gt;%(asctime)s - %(name)s - %(levelname)s - %(message)s&lt;/span&gt;&lt;span class="sh"&gt;'&lt;/span&gt;
&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="n"&gt;app&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;FastAPI&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;title&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;LLM Integration API&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="n"&gt;app&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;include_router&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;router&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;prefix&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;/api/v1&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;__name__&lt;/span&gt; &lt;span class="o"&gt;==&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;__main__&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="n"&gt;uvicorn&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;run&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
        &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;main:app&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="n"&gt;host&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;0.0.0.0&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="n"&gt;port&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;8000&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
        &lt;span class="nb"&gt;reload&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="bp"&gt;True&lt;/span&gt;
    &lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In the above code, we've created a FastAPI app and the router using &lt;code&gt;api.routes&lt;/code&gt; under the &lt;code&gt;/api/v1&lt;/code&gt; prefix. Enabled logging to display informational messages with timestamps. The app will run &lt;code&gt;localhost:8000&lt;/code&gt; using Uvicorn, with hot-reloading enabled.&lt;/p&gt;

&lt;h2&gt;
  
  
  Running your Application
&lt;/h2&gt;

&lt;p&gt;We now have all the components in place, let’s start getting your application up and running. First, create a &lt;code&gt;.env&lt;/code&gt; file in your project root directory and add your &lt;code&gt;HUGGINGFACE_API_KEY&lt;/code&gt; and &lt;code&gt;REDIS_URL&lt;/code&gt;:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;HUGGINGFACE_API_KEY=your_api_key_here
REDIS_URL=redis://localhost:6379
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then ensure Redis is running on your machine. On most Unix-based systems, you can start it with the command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;redis-server
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now you can start your application:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;python main.py
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;your FastAPI server will start running on &lt;a href="http://localhost:8000" rel="noopener noreferrer"&gt;http://localhost:8000&lt;/a&gt;. The automatic API documentation will be available at &lt;a href="http://localhost:8000/docs" rel="noopener noreferrer"&gt;http://localhost:8000/docs&lt;/a&gt; - this is super helpful for testing your endpoints!&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjdsmm6ofk3bfhatq4oai.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjdsmm6ofk3bfhatq4oai.png" alt="llm integration fastapi automatic api docs" width="800" height="320"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Testing your Content Moderation API
&lt;/h2&gt;

&lt;p&gt;Let's test your newly created API with a real request. Open a new terminal and run this curl command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-X&lt;/span&gt; POST http://localhost:8000/api/v1/moderate &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"Content-Type: application/json"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-d&lt;/span&gt; &lt;span class="s1"&gt;'{"text": "This is a test message that needs moderation."}'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You should see a response like this on your terminal:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7f86wj9skpnp232qdc76.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7f86wj9skpnp232qdc76.png" alt="running the llm content moderator" width="800" height="333"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Adding Monitoring and Analytics
&lt;/h2&gt;

&lt;p&gt;Now let's add some monitoring features to track how your application is performing and how much resyources is being used. Add the following code to your &lt;code&gt;utils/monitoring.py&lt;/code&gt; file:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;datetime&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;datetime&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;logging&lt;/span&gt;
&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;typing&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;

&lt;span class="k"&gt;class&lt;/span&gt; &lt;span class="nc"&gt;UsageMonitor&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;__init__&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;log_file&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;usage_logs.json&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;log_file&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;log_file&lt;/span&gt;
        &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;logger&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;logging&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;getLogger&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;__name__&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

    &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;log_request&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
                         &lt;span class="n"&gt;endpoint&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
                         &lt;span class="n"&gt;response&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
                         &lt;span class="n"&gt;duration_ms&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="nb"&gt;float&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
        &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Log API request details&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
        &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;log_entry&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;timestamp&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;datetime&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="nf"&gt;isoformat&lt;/span&gt;&lt;span class="p"&gt;(),&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;endpoint&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;endpoint&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;tokens_used&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;response&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;usage&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;][&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;total_tokens&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;duration_ms&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;duration_ms&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;model&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;response&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;model&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;

            &lt;span class="k"&gt;with&lt;/span&gt; &lt;span class="nf"&gt;open&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;log_file&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;a&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
                &lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;write&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;dumps&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;log_entry&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;+&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="se"&gt;\n&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

        &lt;span class="k"&gt;except&lt;/span&gt; &lt;span class="nb"&gt;Exception&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;logger&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;error&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Error logging usage: &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nf"&gt;str&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The &lt;code&gt;UsageMonitor&lt;/code&gt; class will be performing the following operations:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Tracking every API request with timestamps&lt;/li&gt;
&lt;li&gt;Recording token usage for cost monitoring&lt;/li&gt;
&lt;li&gt;Measuring response times&lt;/li&gt;
&lt;li&gt;Storing everything in a structured log file (replace this with a database before you deploy your application to production)&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Next, add a new method to calculate usage statistics:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;  &lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;get_usage_statistics&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;-&amp;gt;&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Calculate usage statistics&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
        &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;total_tokens&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;
            &lt;span class="n"&gt;total_requests&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;
            &lt;span class="n"&gt;total_duration&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;

            &lt;span class="k"&gt;with&lt;/span&gt; &lt;span class="nf"&gt;open&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;log_file&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;r&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
                &lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="n"&gt;line&lt;/span&gt; &lt;span class="ow"&gt;in&lt;/span&gt; &lt;span class="n"&gt;f&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
                    &lt;span class="n"&gt;entry&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;json&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;loads&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;line&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
                    &lt;span class="n"&gt;total_tokens&lt;/span&gt; &lt;span class="o"&gt;+=&lt;/span&gt; &lt;span class="n"&gt;entry&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;tokens_used&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;
                    &lt;span class="n"&gt;total_requests&lt;/span&gt; &lt;span class="o"&gt;+=&lt;/span&gt; &lt;span class="mi"&gt;1&lt;/span&gt;
                    &lt;span class="n"&gt;total_duration&lt;/span&gt; &lt;span class="o"&gt;+=&lt;/span&gt; &lt;span class="n"&gt;entry&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;duration_ms&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;

            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;total_tokens&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;total_tokens&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;total_requests&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;total_requests&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;average_latency&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;total_duration&lt;/span&gt; &lt;span class="o"&gt;/&lt;/span&gt; &lt;span class="n"&gt;total_requests&lt;/span&gt; &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="n"&gt;total_requests&lt;/span&gt; &lt;span class="o"&gt;&amp;gt;&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt; &lt;span class="k"&gt;else&lt;/span&gt; &lt;span class="mi"&gt;0&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
                &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;timestamp&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;datetime&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;now&lt;/span&gt;&lt;span class="p"&gt;().&lt;/span&gt;&lt;span class="nf"&gt;isoformat&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;
            &lt;span class="p"&gt;}&lt;/span&gt;

        &lt;span class="k"&gt;except&lt;/span&gt; &lt;span class="nb"&gt;Exception&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
            &lt;span class="n"&gt;self&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="n"&gt;logger&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;error&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Error calculating statistics: &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nf"&gt;str&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
            &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="p"&gt;{}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Update your API to add the monitoring features from the &lt;code&gt;UsageMonitor&lt;/code&gt; class:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="c1"&gt;#...
&lt;/span&gt;&lt;span class="kn"&gt;from&lt;/span&gt; &lt;span class="n"&gt;utils.monitoring&lt;/span&gt; &lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;UsageMonitor&lt;/span&gt;
&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;time&lt;/span&gt;

&lt;span class="c1"&gt;#...
&lt;/span&gt;&lt;span class="n"&gt;usage_monitor&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;UsageMonitor&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="nd"&gt;@router.get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;/stats&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;get_statistics&lt;/span&gt;&lt;span class="p"&gt;():&lt;/span&gt;
    &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Get usage statistics&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
    &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;usage_monitor&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get_usage_statistics&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;


&lt;span class="nd"&gt;@router.post&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;/moderate&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="k"&gt;async&lt;/span&gt; &lt;span class="k"&gt;def&lt;/span&gt; &lt;span class="nf"&gt;moderate_content&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="n"&gt;content&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;Dict&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="nb"&gt;str&lt;/span&gt;&lt;span class="p"&gt;],&lt;/span&gt;
    &lt;span class="n"&gt;llm_client&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;LLMClient&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Depends&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;get_llm_client&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
    &lt;span class="n"&gt;cache_manager&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;CacheManager&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Depends&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;get_cache_manager&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
    &lt;span class="n"&gt;prompt_manager&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;PromptManager&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Depends&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;get_prompt_manager&lt;/span&gt;&lt;span class="p"&gt;),&lt;/span&gt;
    &lt;span class="n"&gt;response_handler&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;ResponseHandler&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Depends&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;get_response_handler&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;  &lt;span class="c1"&gt;# Add this
&lt;/span&gt;&lt;span class="p"&gt;):&lt;/span&gt;
    &lt;span class="n"&gt;start_time&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;time&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;time&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

    &lt;span class="sh"&gt;"""&lt;/span&gt;&lt;span class="s"&gt;Moderate content using LLM&lt;/span&gt;&lt;span class="sh"&gt;"""&lt;/span&gt;
    &lt;span class="k"&gt;if&lt;/span&gt; &lt;span class="ow"&gt;not&lt;/span&gt; &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;rate_limiter&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;check_rate_limit&lt;/span&gt;&lt;span class="p"&gt;():&lt;/span&gt;
        &lt;span class="k"&gt;raise&lt;/span&gt; &lt;span class="nc"&gt;HTTPException&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;status_code&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;429&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
            &lt;span class="n"&gt;detail&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Rate limit exceeded&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt;

    &lt;span class="k"&gt;try&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="c1"&gt;#...
&lt;/span&gt;
        &lt;span class="c1"&gt;# Add monitoring
&lt;/span&gt;        &lt;span class="n"&gt;duration_ms&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;time&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;time&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt; &lt;span class="o"&gt;-&lt;/span&gt; &lt;span class="n"&gt;start_time&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt; &lt;span class="o"&gt;*&lt;/span&gt; &lt;span class="mi"&gt;1000&lt;/span&gt;
        &lt;span class="nf"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;duration_ms&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
        &lt;span class="k"&gt;await&lt;/span&gt; &lt;span class="n"&gt;usage_monitor&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;log_request&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;/moderate&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
            &lt;span class="n"&gt;formatted_response&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; 
            &lt;span class="n"&gt;duration_ms&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt;

        &lt;span class="k"&gt;return&lt;/span&gt; &lt;span class="n"&gt;formatted_response&lt;/span&gt;

    &lt;span class="k"&gt;except&lt;/span&gt; &lt;span class="nb"&gt;Exception&lt;/span&gt; &lt;span class="k"&gt;as&lt;/span&gt; &lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
        &lt;span class="k"&gt;raise&lt;/span&gt; &lt;span class="nc"&gt;HTTPException&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
            &lt;span class="n"&gt;status_code&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;500&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
            &lt;span class="n"&gt;detail&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="sa"&gt;f&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;Error processing request: &lt;/span&gt;&lt;span class="si"&gt;{&lt;/span&gt;&lt;span class="nf"&gt;str&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;e&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="si"&gt;}&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;
        &lt;span class="p"&gt;)&lt;/span&gt;  
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Now, test your &lt;code&gt;/stats&lt;/code&gt; endpoint by running this curl command:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-X&lt;/span&gt; GET http://localhost:8000/api/v1/stats
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The above command will show you the stats of your requests on the /moderate endpoint as shown in the screenshot below:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fui8zknuvu7ytiso3p7rj.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fui8zknuvu7ytiso3p7rj.png" alt="testing llm moderator monitoring" width="800" height="278"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Conclusion
&lt;/h2&gt;

&lt;p&gt;Throughout this tutorial, have learned how to use a large language model in production applications. You implemented features like API clients, caching, prompt management, and error handling. As an example of these concepts, you developed a content moderation system.&lt;/p&gt;

&lt;p&gt;Now that you have a solid foundation, you could enhance your system with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Streaming responses for real-time applications&lt;/li&gt;
&lt;li&gt;A/B testing for an immediate improvement&lt;/li&gt;
&lt;li&gt;A web-based interface to manage prompts&lt;/li&gt;
&lt;li&gt;Custom model fine-tuning&lt;/li&gt;
&lt;li&gt;Integration with third-party monitoring services&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Please recall that in the examples you used the ChatGPT2 model, but you can adapt this system to work with any LLM provider. So choose the model that meets your requirements and is within your budget.&lt;/p&gt;

&lt;p&gt;Please don’t hesitate to contact me if you have questions or if you want to tell me what you are building with this system.&lt;/p&gt;

&lt;p&gt;Happy coding! 🚀&lt;/p&gt;

</description>
      <category>webdev</category>
      <category>ai</category>
      <category>llm</category>
      <category>python</category>
    </item>
  </channel>
</rss>
