<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Shashank Agarwal on Medium]]></title>
        <description><![CDATA[Stories by Shashank Agarwal on Medium]]></description>
        <link>https://medium.com/@imshashank?source=rss-9dc6fbec4bfd------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*YQe7RhZephSu-jmB.</url>
            <title>Stories by Shashank Agarwal on Medium</title>
            <link>https://medium.com/@imshashank?source=rss-9dc6fbec4bfd------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 24 Nov 2026 02:28:22 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@imshashank/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[The Silent Failures of AI Agents: Why Your Evaluation Strategy is Broken]]></title>
            <link>https://medium.com/@imshashank/the-silent-failures-of-ai-agents-why-your-evaluation-strategy-is-broken-8a0caf6c0757?source=rss-9dc6fbec4bfd------2</link>
            <guid isPermaLink="false">https://medium.com/p/8a0caf6c0757</guid>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[llm]]></category>
            <category><![CDATA[agent-evaluation]]></category>
            <category><![CDATA[agents]]></category>
            <category><![CDATA[noveum]]></category>
            <dc:creator><![CDATA[Shashank Agarwal]]></dc:creator>
            <pubDate>Wed, 10 Dec 2025 08:44:58 GMT</pubDate>
            <atom:updated>2025-12-10T08:44:58.861Z</atom:updated>
            <content:encoded><![CDATA[<p>How I discovered that accuracy metrics are useless for evaluating AI agents — and what to do instead</p><p>I was debugging an AI agent at 2 AM when I realized something was fundamentally wrong with how we evaluate agents.</p><p>The agent had a 95% accuracy score. It was getting the right answer 95% of the time. By all traditional metrics, it was performing great. But in production, it was a disaster.</p><p>It was hallucinating facts that didn’t exist. It was violating compliance constraints. It was taking inefficient paths that cost 10x more than necessary. And none of my evaluation metrics caught any of this.</p><p>That’s when I realized: <strong>we’re evaluating AI agents like ML models, and it’s completely wrong.</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mjc5_BdZ7yDd11UzD6AuZA.png" /><figcaption>Example Agent Trajectory visalized by Noveum.ai platform</figcaption></figure><h3><strong>The Problem with Traditional Evaluation</strong></h3><p>Traditional ML evaluation metrics (accuracy, precision, recall, F1 score) are designed for models that produce a single output. They ask: “Is the output correct?”</p><p>But agents don’t produce a single output. They take multiple steps, make multiple decisions, and follow complex reasoning paths. Evaluating only the final output is like grading a math test by only looking at the final answer, not the work.</p><p>An agent can get the right answer through the wrong path. It can hallucinate in intermediate steps but still reach the correct conclusion. It can violate constraints while technically achieving the goal.</p><p>Traditional metrics miss all of this.</p><h3><strong>The Five Silent Failures of AI Agents</strong></h3><p>Here are the five types of failures that traditional evaluation misses:</p><p><strong>1. Hallucinations</strong></p><p>The agent invents facts that don’t exist. A customer service agent might make up a return policy. A financial advisor might invent a tax rule. A medical chatbot might describe a symptom that doesn’t exist.</p><p>These hallucinations might not affect the final output (the agent might correct itself), but they’re a serious problem in production. Users might see them. They might act on them.</p><p><strong>2. Constraint Violations</strong></p><p>The agent violates its constraints. A customer service agent starts giving investment advice when it should only handle billing. A content moderation agent lets through hate speech. A compliance bot approves a transaction that violates regulations.</p><p>These violations might not affect the final output, but they’re critical failures in production.</p><p><strong>3. Inefficient Paths</strong></p><p>The agent takes a 10-step path to solve a problem that could be solved in 2 steps. This doesn’t affect the correctness of the answer, but it affects cost and latency significantly.</p><p>An agent that takes 10 steps costs 5x more than one that takes 2 steps. In production, this adds up fast.</p><p><strong>4. Context Violations</strong></p><p>The agent ignores or contradicts the provided context. It’s supposed to answer questions based on a provided knowledge base, but instead, it relies on its training data. It makes claims that contradict the provided context.</p><p><strong>5. Consistency Violations</strong></p><p>The agent contradicts itself. It says “We don’t have that product” then later says “That product costs $50.” It’s logically inconsistent.</p><p>These five failures are invisible to traditional accuracy metrics. An agent can have 95% accuracy and still fail in all five ways.</p><h3><strong>Why This Matters</strong></h3><p>In production, these silent failures are catastrophic:</p><ul><li><strong>Hallucinations</strong> destroy user trust. Users see false information and stop trusting the agent.</li><li><strong>Constraint Violations</strong> create legal liability. Your compliance bot approves a fraudulent transaction. Your content moderation agent lets through hate speech.</li><li><strong>Inefficient Paths</strong> destroy your unit economics. Your agent costs 10x more than it should.</li><li><strong>Context Violations</strong> make your agent unreliable. It gives different answers than your knowledge base.</li><li><strong>Consistency Violations</strong> confuse users. They don’t know what to believe.</li></ul><h3><strong>The Right Way to Evaluate Agents</strong></h3><p>Here’s what I’ve learned about evaluating agents properly:</p><p><strong>1. Use the System Prompt as Ground Truth</strong></p><p>Your system prompt defines what the agent should do, how it should behave, and what constraints it should follow. This is your ground truth. Everything else is a deviation.</p><p>Instead of manually labeling evaluation data (which is expensive and slow), use the system prompt to automatically evaluate the agent’s behavior. Does the agent follow its system prompt? Does it violate any constraints? Does it stay within its defined role?</p><p><strong>2. Evaluate the Entire Trajectory</strong></p><p>Don’t just look at the final output. Analyze every step the agent took. Every LLM call. Every tool call. Every decision.</p><p>This is where you’ll find the real problems. An agent might hallucinate in step 3, correct itself in step 5, and reach the right conclusion in step 7. If you only look at step 7, you’ll miss the hallucination.</p><p><strong>3. Use Multi-Dimensional Scoring</strong></p><p>Evaluate across multiple dimensions simultaneously:</p><ul><li><strong>Task Completion:</strong> Did the agent achieve its goal?</li><li><strong>Efficiency:</strong> Did it take the optimal path?</li><li><strong>Hallucination:**</strong> Did it invent facts?</li><li><strong>Compliance:</strong> Did it follow constraints?</li><li><strong>Coherence:</strong> Was it logically consistent?</li><li><strong>Cost:</strong> How many tokens did it use?</li><li><strong>Tool Validity:</strong> Were tool calls valid?</li></ul><p>A single metric isn’t enough. You need to evaluate across all dimensions to get a complete picture.</p><p><strong>4. Implement Continuous Evaluation</strong></p><p>Don’t evaluate only before deployment. Evaluate continuously in production. This allows you to catch regressions early, identify patterns in failures, and improve your agent based on real-world performance.</p><p><strong>5. Use Prescriptive Recommendations</strong></p><p>It’s not enough to know that your agent is hallucinating. You need to know why and how to fix it. The best evaluation frameworks provide specific recommendations: “Add this constraint to your system prompt,” or “Use this model instead,” or “Adjust these tool parameters.”</p><p><strong>The Bottom Line</strong></p><p>We need to stop evaluating AI agents like ML models. Agents are fundamentally different. They take multiple steps. The path matters. Constraints matter. Efficiency matters.</p><p>By using the system prompt as ground truth, evaluating the entire trajectory, and using multi-dimensional scoring, you can build agents that you can actually trust in production.</p><p>The silent failures will disappear. Your users will be happy. Your costs will go down. Your compliance will improve. Or try a <a href="https://noveum.ai/en/solutions/agent-evaluation">purpose-built Platform for AI Agent Evaluation</a> like Noveum.ai.</p><p>It’s time to evaluate agents the right way.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8a0caf6c0757" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Generate Embeddable HTML code for any URL using Pipfeed’s Extract API]]></title>
            <link>https://medium.com/pipfeed/generate-embeddable-html-code-for-any-url-using-pipfeeds-extract-api-a032a9d5cc78?source=rss-9dc6fbec4bfd------2</link>
            <guid isPermaLink="false">https://medium.com/p/a032a9d5cc78</guid>
            <category><![CDATA[news]]></category>
            <category><![CDATA[api]]></category>
            <category><![CDATA[extract]]></category>
            <category><![CDATA[news-articles]]></category>
            <dc:creator><![CDATA[Shashank Agarwal]]></dc:creator>
            <pubDate>Tue, 10 Nov 2020 09:36:35 GMT</pubDate>
            <atom:updated>2020-11-11T05:17:23.204Z</atom:updated>
            <content:encoded><![CDATA[<p>Embeddable Cards provide a clean, responsive, and shareable card for any content on the web. Cards are the easiest way to leverage Pipfeed’s extract API for any media, Cards provide a responsive embed. 40% of Users will click, hover, or view Cards with videos, images, and rich media. Cards are responsive and adapt to automatically fit any site they are placed in.</p><p>But a lot of these embed APIs aren’t very customizable and usually results in a longer load time. Using Pipfeed’s extract API, you can generate a pure HTML code in the framework and style of your choice. For this example, we will be using bootstrap cards to style the generated cards.</p><h3>Extracting metadata from the article URL:</h3><p>We want to get all the various fields such as the main image, title, description, etc. from the article itself. For this, we will use Pipfeed’s News Article Extract API. The API allows you 100 calls per day and 3000 calls per month for free. You can upgrade to one of our plans for a higher API call volume.</p><p>You can get the API key from promptAPI here: <a href="https://promptapi.com/marketplace/description/pipfeed-api">https://promptapi.com/marketplace/description/pipfeed-api</a></p><pre>$curl = curl_init();<br><br>curl_setopt_array($curl, array(<br>  CURLOPT_URL =&gt; &quot;https://api.promptapi.com/pipfeed&quot;,<br>  CURLOPT_HTTPHEADER =&gt; array(<br>    &quot;Content-Type: text/plain&quot;,<br>    &quot;apikey: YOUR_API_KEY&quot;<br>  ),<br>  CURLOPT_RETURNTRANSFER =&gt; true,<br>  CURLOPT_ENCODING =&gt; &quot;&quot;,<br>  CURLOPT_MAXREDIRS =&gt; 10,<br>  CURLOPT_TIMEOUT =&gt; 0,<br>  CURLOPT_FOLLOWLOCATION =&gt; true,<br>  CURLOPT_HTTP_VERSION =&gt; CURL_HTTP_VERSION_1_1,<br>  CURLOPT_CUSTOMREQUEST =&gt; &quot;POST&quot;,<br>  CURLOPT_POSTFIELDS =&gt;&quot;https%3A%2F%2Fsystem.camp%2Fstartups%2Funderstanding-kpis-for-mobile-apps-and-how-to-measure-kpis%2F&quot;<br>));<br><br>$response = curl_exec($curl);<br><br>curl_close($curl);<br>echo $response;</pre><p>For this example we are using <strong>PHP</strong> to generate the HTML code, you can use the language of your choice to generate the code.</p><p>The above will return a response like this:</p><pre>{<br>  &quot;authors&quot;: null,<br>  &quot;blogLogoUrl&quot;: null,<br>  &quot;blogName&quot;: null,<br>  &quot;categories&quot;: null,<br>  &quot;category&quot;: &quot;machine-learning&quot;,<br>  &quot;description&quot;: &quot;How to create a financial model for a mobile app? How to measure KPIs? What are KPIs? Learn all this and more...&quot;,<br>  &quot;html&quot;: &quot;&lt;div class=\&quot;page\&quot; id=\&quot;readability-page-1\&quot;&gt;&lt;div&gt;\n\t\n\n&lt;p&gt;KPIs are the ultimate indicator for how well you Mobile app is doing. KPI stands for Key Performance Indicator. The first rule of KPIs is that they need to be the \u201ckey indicators\u201d of your business model and should always relate to the financial model directly.&lt;/p&gt;\n\n\n\n&lt;p&gt;Why? Because you want to quantify and improve these KPIs to help your company earn more money or get more users.&lt;/p&gt;\n\n\n\n&lt;p&gt;The main goal of any app is either to make the sure users are using the app frequently or they are paying frequently. Hence it is hard to make a lot of profits from Utility apps like Calculators. These apps are really good but the overall usage is quite low and hence the Business Model will not make sense to build a company around these use-cases.&lt;/p&gt;\n\n\n\n&lt;p&gt;Based on these metrics we can then define how much money the apps can make.&lt;/p&gt;\n\n\n\n&lt;h2 id=\&quot;let-s-define-the-kpis-first-\&quot;&gt;Let\u2019s define the KPIs first:&lt;/h2&gt;\n\n\n\n&lt;h3 id=\&quot;retention-rate\&quot;&gt;Retention Rate&lt;/h3&gt;\n\n\n\n&lt;p&gt;Retention Rate is the most important metric for a mobile app. This defines the \u201cpercentage\u201d of users that are still using the app after a certain time has passed.&lt;/p&gt;\n\n\n\n&lt;p&gt;For example: If your app has 1000 user signed up. After one month you check how many users have opened the app in the second month. So in second month if 300 users have opened the app then you retention rate is defined as :&lt;/p&gt;\n\n\n\n&lt;blockquote&gt;&lt;p&gt;300/1000 = 30%&lt;/p&gt;&lt;/blockquote&gt;\n\n\n\n&lt;p&gt;So the retention rate is 30%. Industry average is around 15% to 60%. Mobile apps like Facebook, Instagram &amp; watsapp have a retention rate of over 70% hence they have these insane valuations.&lt;/p&gt;\n\n\n\n&lt;h3 id=\&quot;conversion-rate-\&quot;&gt;Conversion Rate:&lt;/h3&gt;\n\n\n\n&lt;p&gt;This metric is useful for mobile apps that offer a Subscription Model. Conversion rate in this scenario means how many users are converting to paid subscribers.&lt;/p&gt;\n\n\n\n&lt;p&gt;For example: From the 300 Monthly Active Users(MAU) if 60 pay and become your subscribers then your conversion rate can be calculated as:&lt;/p&gt;\n\n\n\n&lt;blockquote&gt;&lt;p&gt;300/60 = 20%&lt;/p&gt;&lt;/blockquote&gt;\n\n\n\n&lt;p&gt;Hence you have a 20% conversion rate.  Industry average is around 10%. The Harvard Business Review found that even a 5% increase in retention could increase revenues by &lt;a rel=\&quot;noopener\&quot; href=\&quot;https://amplitude.com/blog/2016/01/27/understanding-user-retention\&quot;&gt;25% to 95%&lt;/a&gt;.&lt;/p&gt;\n\n\n\n&lt;h2 id=\&quot;cost-per-acquisition-cpa-\&quot;&gt;Cost Per Acquisition(CPA)&lt;/h2&gt;\n\n\n\n&lt;p&gt;Cost Per Acquisition is defined as the average cost to acquire a user. This cost must be averaged out over long periods spanning multiple months to get the big picture.&lt;/p&gt;\n\n\n\n&lt;p&gt;The other KPI metrics will help you understand how valuable is your app. But CPA defines if your app makes sense in terms of a viable business.&lt;/p&gt;\n\n\n\n&lt;p&gt;There are various channels for acquiring users:&lt;/p&gt;\n\n\n\n&lt;ul&gt;&lt;li&gt;Ads (Google, Facebook, LinkedIn, Twitter, SnapChat, TikTok, Apple etc.)&lt;/li&gt;&lt;li&gt;Influencer Marketing&lt;/li&gt;&lt;li&gt;SEO/Blog Content&lt;/li&gt;&lt;li&gt;Directory Listings (ProductHunt, BetaFy etc.)&lt;/li&gt;&lt;li&gt;Community Forums&lt;/li&gt;&lt;li&gt;Direct Advertising (Podcasts, Rent Websites etc.)&lt;/li&gt;&lt;li&gt;And hundreds more&lt;/li&gt;&lt;/ul&gt;\n\n\n\n&lt;h2 id=\&quot;lets-see-how-all-these-numbers-fit-in-a-financial-model-\&quot;&gt;Lets see how all these numbers fit in a Financial Model:&lt;/h2&gt;\n\n\n\n&lt;p&gt;The model is quite straightforward once you have the KPIs.&lt;/p&gt;\n\n\n\n&lt;p&gt;In the below example we are looking at apps that earn from Subscription or Monthly Recurring Revenue.&lt;/p&gt;\n\n\n\n&lt;h2 id=\&quot;now-let-s-look-at-apps-that-earn-from-subscription-only-\&quot;&gt;Now let\u2019s look at apps that earn from Subscription only.&lt;/h2&gt;\n\n\n\n&lt;p&gt;In this model we are also making an assumption that people are willing to pay for the service and a significant number of users exist that are willing to pay for the service you are providing. This is what truly a startup does, finds a service people are willing to pay for and make sure that there is a large number of users willing to pay for this service. If you have this then you have a great business that investors will be happy to invest in.&lt;/p&gt;\n\n\n\n&lt;p&gt;We will look at an app like Pocket.&lt;/p&gt;\n\n\n\n&lt;h3 id=\&quot;assumptions-\&quot;&gt;Assumptions:&lt;/h3&gt;\n\n\n\n&lt;p&gt;&lt;strong&gt;Retention Rate:&lt;/strong&gt; 30%&lt;br&gt;&lt;strong&gt;Conversion Rate:&lt;/strong&gt; 10%&lt;br&gt;&lt;strong&gt;Monthly Subscription Cost:&lt;/strong&gt; $4.99&lt;br&gt;&lt;strong&gt;CPA:&lt;/strong&gt; $1/-&lt;/p&gt;\n\n\n\n&lt;p&gt;To get 1000 users we spend&lt;br&gt;Number of Users * CPA = 1000 USD&lt;/p&gt;\n\n\n\n&lt;p&gt;Monthly Active Users&lt;br&gt;Total Users * Retention Rate&lt;br&gt;1000 * 30% = 300 MAU&lt;/p&gt;\n\n\n\n&lt;p&gt;Subscription earning from MAU&lt;br&gt;MAU * Conversion Rate * Average Subscription Cost&lt;br&gt;300 * 10% * 4.99 = 149.7&lt;/p&gt;\n\n\n\n&lt;p&gt;Yearly Subscription earning&lt;br&gt;149.7 * 12 = 1796.4&lt;/p&gt;\n\n\n\n&lt;p&gt;Profits&lt;br&gt;$1796.4 \u2013 $1000 = $794.4&lt;/p&gt;\n\n\n\n&lt;p&gt;So, if we spend 1000 dollars we earn a profit of 794.4. If you can scale this system to 100,000 users then your yearly profits become: $794,00.4. This is a pretty good &amp; viable business model that investors will be ready to invest in to help you scale.&lt;/p&gt;\n\n\n\n&lt;p&gt;Pocket had around 20 million users in 2015. So if we plug the numbers in the above model we get a yearly revenue from 20 million users at $15,888,000 (over 15 million dollars). Pocket app got acquired for around 30 million by Mozilla Foundation.&lt;/p&gt;\n\n\n\n&lt;p&gt;SaaS usually have a retention rate of over 80%. Retention like this is required as the Cost Per Acquisition is pretty high. That\u2019s why you will see SaaS companies offering $10 to $1000 referral commission.&lt;/p&gt;\n\n\n\n&lt;h2 id=\&quot;now-let-s-look-at-apps-that-earn-from-ads-only-\&quot;&gt;Now let\u2019s look at apps that earn from Ads only.&lt;/h2&gt;\n\n\n\n&lt;p&gt;For advertising based apps the most important number is Total Users &amp; Retention.&lt;/p&gt;\n\n\n\n&lt;p&gt;In mass consumer apps finding the total retained users is a bit tricky. These apps only make sense if the Retention Curve is a \u201cSmile\u201d curve like this:&lt;/p&gt;\n\n\n\n&lt;figure&gt;&lt;span data-svq-align=\&quot;\&quot;&gt;&lt;img data-src=\&quot;https://system.camp/wp-content/uploads/2020/10/retention_smile_curve.png\&quot; data-height=\&quot;802\&quot; data-width=\&quot;1133\&quot; alt=\&quot;\&quot; src=\&quot;https://system.camp/wp-content/uploads/2020/10/retention_smile_curve.png\&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;figcaption&gt;Evernote Retention Curve. Source: https://www.sequoiacap.com/article/retention&lt;/figcaption&gt;&lt;/figure&gt;\n\n\n\n&lt;p&gt;This below retention graph is an example of long tail retention. Where some percentage of your users choose to stick around for a longer time and hence make the financial model viable.&lt;/p&gt;\n\n\n\n&lt;figure&gt;&lt;span data-svq-align=\&quot;\&quot;&gt;&lt;img data-src=\&quot;https://system.camp/wp-content/uploads/2020/10/retention-smile-flat.png\&quot; data-height=\&quot;600\&quot; data-width=\&quot;1014\&quot; alt=\&quot;\&quot; src=\&quot;https://system.camp/wp-content/uploads/2020/10/retention-smile-flat.png\&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;figcaption&gt;Retention Graph. Source: https://www.sequoiacap.com/article/retention&lt;/figcaption&gt;&lt;/figure&gt;\n\n\n\n&lt;p&gt;You can use Retention curve graph to find if you Product Market Fit. I should probably write an article on understanding retention rates.&lt;/p&gt;\n\n\n\n&lt;p&gt;In any case we assume the overall retention assuming you has a smile graph and your long tail users are sticking around and using the app. For this use case this is what the financial model will look like.&lt;/p&gt;\n\n\n\n&lt;p&gt;Let\u2019s look an app like FlipBoard:&lt;/p&gt;\n\n\n\n&lt;h3 id=\&quot;assumptions--1\&quot;&gt;Assumptions:&lt;/h3&gt;\n\n\n\n&lt;p&gt;&lt;strong&gt;Retention Rate:&lt;/strong&gt; 15%&lt;br&gt;&lt;strong&gt;Average Earning from Ads/user/month:&lt;/strong&gt; $0.5&lt;br&gt;&lt;strong&gt;CPA:&lt;/strong&gt; $0.5/-&lt;/p&gt;\n\n\n\n&lt;p&gt;To get 1000 users we spend&lt;br&gt;Number of Users * CPA = $500&lt;/p&gt;\n\n\n\n&lt;p&gt;Monthly Active Users&lt;br&gt;Total Users * Retention Rate&lt;br&gt;1000 * 15% = 150 MAU&lt;/p&gt;\n\n\n\n&lt;p&gt;Ads earning from MAU&lt;br&gt;MAU * Average Earning From Ads Per User&lt;br&gt;150 * $0.5 = $75&lt;/p&gt;\n\n\n\n&lt;p&gt;Yearly Ads earning&lt;br&gt;75 * 12 = 900&lt;/p&gt;\n\n\n\n&lt;p&gt;Profits&lt;br&gt;$900 \u2013 $500 = $400&lt;/p&gt;\n\n\n\n&lt;p&gt;&lt;strong&gt;Earning per user overall: &lt;/strong&gt;$0.4 per year&lt;/p&gt;\n\n\n\n&lt;p&gt;Here we reduced the cost of customer acquisition to make sense of the model to $0.5. Unless you are able to achievea much lower CPA, advertising model will not work. Also ads based models only work for large number of user.&lt;/p&gt;\n\n\n\n&lt;p&gt;FlipBoard has around 145 million Monthly Active Users. So putting these numbers into the above financial model we get their yearly revenue to be around:&lt;/p&gt;\n\n\n\n&lt;p&gt;MAU * Average Earning from Ads/User * Months In Year&lt;/p&gt;\n\n\n\n&lt;p&gt;145 million MAU * $0.5 * 12 = $870 Million&lt;/p&gt;\n\n\n\n&lt;p&gt;The above model should be taken with a grain of Salt. This is a good model for \u201cpredicting\u201d the possible outcome and usually at really large scale it depends on the business on how they chose to monetize.&lt;/p&gt;\n\n\n\n&lt;p&gt;Usually mobile apps with such large number do direct deals with advertisers and are able to increase their annual earning. Flipboard doesn\u2019t have an advertising platform like Facebook and deals with large advertisers/big companies directly.&lt;/p&gt;\n\n\n\n&lt;p&gt;In some cases the goal is not just to increase the annual ads expenditure but maintain a consistent influx of ads revenue. This is a model followed by FlipBoard. They usually do month long or year long deals with Big Brands to have a consistent cash flow.&lt;/p&gt;\n\n\n\n&lt;p&gt;The other big factor that defines how much you can charge for ads is the type of users you have. For apps like tiktok, most users fall in younger category and hence ads targeted at younger audience. These users have a lower monthly earning and are not that attractive to advertisers unless they can reach a really large number of users.&lt;/p&gt;\n\n\n\n&lt;p&gt;LinkedIn can charge more for its ads as the users using the platform are mostly professionals. It is very hard to find professionals to advertise to on the Internet. This is what Microsoft saw when they acquired LinkedIn for $26.2 Billion.&lt;/p&gt;\n\n\n\n&lt;h2 id=\&quot;how-to-use-this-model\&quot;&gt;How to use this Model&lt;/h2&gt;\n\n\n\n&lt;p&gt;So this was a guide on creating a Financial model for mobile apps. To use the above strategy to provide a more realistic model try to make your assumptions based on real world data.&lt;/p&gt;\n\n\n\n&lt;p&gt;Before starting you should ask these questions:&lt;/p&gt;\n\n\n\n&lt;ul&gt;&lt;li&gt;Are user willing to pay for your service?&lt;/li&gt;&lt;li&gt;How much are they willing to pay?&lt;/li&gt;&lt;li&gt;How many users are there that you can realistically reach?&lt;/li&gt;&lt;/ul&gt;\n\n\n\n&lt;p&gt;If you have answers to these problems that you can create a much more realistic model. It is very easy to validate your idea even before starting. Find your potential paying customers and ask them if they would want a service like this and they are willing to pay for this.&lt;/p&gt;\n\n\n\n&lt;p&gt;Hope you like this guide and I hope it provides a framework for your startup. Wish you all the best.&lt;/p&gt;\n\n\n\n&lt;p&gt;Let me know in the comments what you think.&lt;/p&gt;\n\n\t\n\n&lt;div&gt;\n    &lt;div&gt;\n        &lt;div&gt;\n            &lt;p&gt;&lt;a rel=\&quot;author\&quot; href=\&quot;https://system.camp/profile/shashank/\&quot;&gt;\n\t\t\t\t\t&lt;img loading=\&quot;lazy\&quot; width=\&quot;80\&quot; height=\&quot;80\&quot; srcset=\&quot;https://secure.gravatar.com/avatar/33563973b6f338002e574f30a3f94788?s=160&amp;d=mm&amp;r=g 2x\&quot; src=\&quot;https://secure.gravatar.com/avatar/33563973b6f338002e574f30a3f94788?s=80&amp;d=mm&amp;r=g\&quot; alt=\&quot;\&quot;&gt;                &lt;/a&gt;\n            &lt;/p&gt;\n            &lt;p&gt;&lt;span&gt;\n                    \n                &lt;/span&gt;\n                &lt;span&gt;\n                    &lt;span&gt;Member since&lt;/span&gt;\n                     &lt;time datetime=\&quot;2020-10-05 07:14\&quot;&gt;\n                        October 6, 2020                     &lt;/time&gt;\n                &lt;/span&gt;\n            &lt;/p&gt;\n\n\t\t\t\n\t    \n\n\t\t\t\n        &lt;/div&gt;\n\t\t    &lt;/div&gt;\n\n\t\n\t&lt;/div&gt;\n&lt;/div&gt;&lt;/div&gt;&quot;,<br>  &quot;images&quot;: [<br>    &quot;https://system.camp/wp-content/uploads/2020/10/Calling-WordPress-REST-APIs-to-create-users-articles-posts-etc.-with-examples-using-JAVA.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/Batch-load-objects-using-dynamoDBMapper.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2019/09/onboard_image_06.min_.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/Calling-WordPress-REST-APIs-to-create-users-articles-posts-etc.-with-examples-using-JAVA-150x150.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/Teal-Autumn-Leaves-Facebook-Cover-150x150.png&quot;,<br>    &quot;https://system.camp/wp-content/plugins/front-user-profile/assets/img/cat-placeholder.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/Batch-load-objects-using-dynamoDBMapper-150x150.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/Understanding-Financial-Model-using-KPIs-for-mobile-apps-A-definitive-Guide-1-1024x390.jpg&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/Ocean-Beach-Wedding-Facebook-Cover.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/How-to-parse-Google-Search-result-in-Java-150x150.jpg&quot;,<br>    &quot;https://system.camp/wp-content/themes/typer/assets/img/placeholder.png&quot;,<br>    &quot;https://secure.gravatar.com/avatar/33563973b6f338002e574f30a3f94788?s=60&amp;d=mm&amp;r=g&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/The-simplest-way-to-sort-HapMap_String-Object_-in-JAVA.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/cropped-logo-1.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/Ocean-Beach-Wedding-Facebook-Cover-150x150.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/retention-smile-flat.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2019/09/onboard_image_07.min_.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/How-to-parse-Google-Search-result-in-Java.jpg&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/retention_smile_curve.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/Teal-Autumn-Leaves-Facebook-Cover.png&quot;,<br>    &quot;https://secure.gravatar.com/avatar/33563973b6f338002e574f30a3f94788?s=80&amp;d=mm&amp;r=g&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2019/09/onboard_image_05.min_.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/The-simplest-way-to-sort-HapMap_String-Object_-in-JAVA-150x150.png&quot;,<br>    &quot;https://system.camp/wp-content/uploads/2020/10/Understanding-Financial-Model-using-KPIs-for-mobile-apps-A-definitive-Guide-1.jpg&quot;<br>  ],<br>  &quot;keywords&quot;: [<br>    &quot;ads&quot;,<br>    &quot;app&quot;,<br>    &quot;apps&quot;,<br>    &quot;earning&quot;,<br>    &quot;financial&quot;,<br>    &quot;kpis&quot;,<br>    &quot;mobile&quot;,<br>    &quot;model&quot;,<br>    &quot;pay&quot;,<br>    &quot;rate&quot;,<br>    &quot;retention&quot;,<br>    &quot;understanding&quot;,<br>    &quot;users&quot;,<br>    &quot;willing&quot;<br>  ],<br>  &quot;language&quot;: &quot;en&quot;,<br>  &quot;mainImage&quot;: &quot;https://system.camp/wp-content/uploads/2020/10/Understanding-Financial-Model-using-KPIs-for-mobile-apps-A-definitive-Guide-1-1024x390.jpg&quot;,<br>  &quot;predictedCategories&quot;: [<br>    &quot;machine-learning&quot;,<br>    &quot;money&quot;,<br>    &quot;data-science&quot;<br>  ],<br>  &quot;publishedAt&quot;: null,<br>  &quot;summary&quot;: &quot;The first rule of KPIs is that they need to be the \u201ckey indicators\u201d of your business model and should always relate to the financial model directly.\nSo in second month if 300 users have opened the app then you retention rate is defined as :300/1000 = 30%So the retention rate is 30%.\nMobile apps like Facebook, Instagram &amp; watsapp have a retention rate of over 70% hence they have these insane valuations.\nConversion Rate:This metric is useful for mobile apps that offer a Subscription Model.\nHow to use this ModelSo this was a guide on creating a Financial model for mobile apps.&quot;,<br>  &quot;tags&quot;: [<br>    &quot;Apps&quot;<br>  ],<br>  &quot;text&quot;: &quot;KPIs are the ultimate indicator for how well you Mobile app is doing. KPI stands for Key Performance Indicator. The first rule of KPIs is that they need to be the \u201ckey indicators\u201d of your business model and should always relate to the financial model directly. Why? Because you want to quantify and improve these KPIs to help your company earn more money or get more users. The main goal of any app is either to make the sure users are using the app frequently or they are paying frequently. Hence it is hard to make a lot of profits from Utility apps like Calculators. These apps are really good but the overall usage is quite low and hence the Business Model will not make sense to build a company around these use-cases. Based on these metrics we can then define how much money the apps can make. Let\u2019s define the KPIs first: Retention Rate Retention Rate is the most important metric for a mobile app. This defines the \u201cpercentage\u201d of users that are still using the app after a certain time has passed. For example: If your app has 1000 user signed up. After one month you check how many users have opened the app in the second month. So in second month if 300 users have opened the app then you retention rate is defined as : 300/1000 = 30% So the retention rate is 30%. Industry average is around 15% to 60%. Mobile apps like Facebook, Instagram &amp; watsapp have a retention rate of over 70% hence they have these insane valuations. Conversion Rate: This metric is useful for mobile apps that offer a Subscription Model. Conversion rate in this scenario means how many users are converting to paid subscribers. For example: From the 300 Monthly Active Users(MAU) if 60 pay and become your subscribers then your conversion rate can be calculated as: 300/60 = 20% Hence you have a 20% conversion rate. Industry average is around 10%. The Harvard Business Review found that even a 5% increase in retention could increase revenues by 25% to 95%. Cost Per Acquisition(CPA) Cost Per Acquisition is defined as the average cost to acquire a user. This cost must be averaged out over long periods spanning multiple months to get the big picture. The other KPI metrics will help you understand how valuable is your app. But CPA defines if your app makes sense in terms of a viable business. There are various channels for acquiring users: Ads (Google, Facebook, LinkedIn, Twitter, SnapChat, TikTok, Apple etc.) Influencer Marketing SEO/Blog Content Directory Listings (ProductHunt, BetaFy etc.) Community Forums Direct Advertising (Podcasts, Rent Websites etc.) And hundreds more Lets see how all these numbers fit in a Financial Model: The model is quite straightforward once you have the KPIs. In the below example we are looking at apps that earn from Subscription or Monthly Recurring Revenue. Now let\u2019s look at apps that earn from Subscription only. In this model we are also making an assumption that people are willing to pay for the service and a significant number of users exist that are willing to pay for the service you are providing. This is what truly a startup does, finds a service people are willing to pay for and make sure that there is a large number of users willing to pay for this service. If you have this then you have a great business that investors will be happy to invest in. We will look at an app like Pocket. Assumptions: Retention Rate: 30% Conversion Rate: 10% Monthly Subscription Cost: $4.99 CPA: $1/- To get 1000 users we spend Number of Users * CPA = 1000 USD Monthly Active Users Total Users * Retention Rate 1000 * 30% = 300 MAU Subscription earning from MAU MAU * Conversion Rate * Average Subscription Cost 300 * 10% * 4.99 = 149.7 Yearly Subscription earning 149.7 * 12 = 1796.4 Profits $1796.4 \u2013 $1000 = $794.4 So, if we spend 1000 dollars we earn a profit of 794.4. If you can scale this system to 100,000 users then your yearly profits become: $794,00.4. This is a pretty good &amp; viable business model that investors will be ready to invest in to help you scale. Pocket had around 20 million users in 2015. So if we plug the numbers in the above model we get a yearly revenue from 20 million users at $15,888,000 (over 15 million dollars). Pocket app got acquired for around 30 million by Mozilla Foundation. SaaS usually have a retention rate of over 80%. Retention like this is required as the Cost Per Acquisition is pretty high. That\u2019s why you will see SaaS companies offering $10 to $1000 referral commission. Now let\u2019s look at apps that earn from Ads only. For advertising based apps the most important number is Total Users &amp; Retention. In mass consumer apps finding the total retained users is a bit tricky. These apps only make sense if the Retention Curve is a \u201cSmile\u201d curve like this: Evernote Retention Curve. Source: https://www.sequoiacap.com/article/retention This below retention graph is an example of long tail retention. Where some percentage of your users choose to stick around for a longer time and hence make the financial model viable. Retention Graph. Source: https://www.sequoiacap.com/article/retention You can use Retention curve graph to find if you Product Market Fit. I should probably write an article on understanding retention rates. In any case we assume the overall retention assuming you has a smile graph and your long tail users are sticking around and using the app. For this use case this is what the financial model will look like. Let\u2019s look an app like FlipBoard: Assumptions: Retention Rate: 15% Average Earning from Ads/user/month: $0.5 CPA: $0.5/- To get 1000 users we spend Number of Users * CPA = $500 Monthly Active Users Total Users * Retention Rate 1000 * 15% = 150 MAU Ads earning from MAU MAU * Average Earning From Ads Per User 150 * $0.5 = $75 Yearly Ads earning 75 * 12 = 900 Profits $900 \u2013 $500 = $400 Earning per user overall: $0.4 per year Here we reduced the cost of customer acquisition to make sense of the model to $0.5. Unless you are able to achievea much lower CPA, advertising model will not work. Also ads based models only work for large number of user. FlipBoard has around 145 million Monthly Active Users. So putting these numbers into the above financial model we get their yearly revenue to be around: MAU * Average Earning from Ads/User * Months In Year 145 million MAU * $0.5 * 12 = $870 Million The above model should be taken with a grain of Salt. This is a good model for \u201cpredicting\u201d the possible outcome and usually at really large scale it depends on the business on how they chose to monetize. Usually mobile apps with such large number do direct deals with advertisers and are able to increase their annual earning. Flipboard doesn\u2019t have an advertising platform like Facebook and deals with large advertisers/big companies directly. In some cases the goal is not just to increase the annual ads expenditure but maintain a consistent influx of ads revenue. This is a model followed by FlipBoard. They usually do month long or year long deals with Big Brands to have a consistent cash flow. The other big factor that defines how much you can charge for ads is the type of users you have. For apps like tiktok, most users fall in younger category and hence ads targeted at younger audience. These users have a lower monthly earning and are not that attractive to advertisers unless they can reach a really large number of users. LinkedIn can charge more for its ads as the users using the platform are mostly professionals. It is very hard to find professionals to advertise to on the Internet. This is what Microsoft saw when they acquired LinkedIn for $26.2 Billion. How to use this Model So this was a guide on creating a Financial model for mobile apps. To use the above strategy to provide a more realistic model try to make your assumptions based on real world data. Before starting you should ask these questions: Are user willing to pay for your service? How much are they willing to pay? How many users are there that you can realistically reach? If you have answers to these problems that you can create a much more realistic model. It is very easy to validate your idea even before starting. Find your potential paying customers and ask them if they would want a service like this and they are willing to pay for this. Hope you like this guide and I hope it provides a framework for your startup. Wish you all the best. Let me know in the comments what you think. Member since October 6, 2020&quot;,<br>  &quot;title&quot;: &quot;Understanding Financial Model and KPIs for mobile apps&quot;,<br>  &quot;url&quot;: &quot;https://system.camp/startups/understanding-kpis-for-mobile-apps-and-how-to-measure-kpis/&quot;<br>}</pre><h3>Embed.ly like generated code</h3><p>Our goal is to create a card that looks like the one generated by embed.ly. Below is the embed code generated by embedly’s code generator: <a href="https://embed.ly/code?url=https%3A%2F%2Fsystem.camp%2Fstartups%2Funderstanding-kpis-for-mobile-apps-and-how-to-measure-kpis%2F">https://embed.ly/code?url=https%3A%2F%2Fsystem.camp%2Fstartups%2Funderstanding-kpis-for-mobile-apps-and-how-to-measure-kpis%2F</a> . You can generate the code for any URL.</p><h4>Generated code:</h4><pre>&lt;blockquote class=&quot;embedly-card&quot;&gt;&lt;h4&gt;&lt;a href=&quot;https://system.camp/startups/understanding-kpis-for-mobile-apps-and-how-to-measure-kpis/&quot;&gt;Understanding Financial Model and KPIs for mobile apps - A definitive Guide - System.Camp&lt;/a&gt;&lt;/h4&gt;&lt;p&gt;KPIs are the ultimate indicator for how well you Mobile app is doing. KPI stands for Key Performance Indicator. The first rule of KPIs is that they need to be the &quot;key indicators&quot; of your business model and should always relate to the financial model directly. Why?&lt;/p&gt;&lt;/blockquote&gt;<br>&lt;script async src=&quot;//cdn.embedly.com/widgets/platform.js&quot; charset=&quot;UTF-8&quot;&gt;&lt;/script&gt;</pre><h4>This is how the rendered HTML from embed.ly looks like</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1_h3QQe1nbNT42wNouiYVw.png" /></figure><h3>Using Bootstrap Cards Component</h3><p>Bootstrap is an amazing library that provides various kinds of cards that are responsive and looks very pretty. You can see the various types of Bootstrap cards here: <a href="https://getbootstrap.com/docs/4.0/components/card/">https://getbootstrap.com/docs/4.0/components/card/</a></p><p>This is the code we want to generate using PHP</p><pre>&lt;div class=&quot;card&quot; style=&quot;max-width: 600px; padding: 0px; position: relative; min-width: 200px; margin: 5px auto;&quot;&gt;<br>        &lt;img class=&quot;h-auto d-inline-block&quot; src=&quot;https://system.camp/wp-content/uploads/2020/10/Understanding-Financial-Model-using-KPIs-for-mobile-apps-A-definitive-Guide-1-1024x390.jpg&quot; alt=&quot;Understanding Financial Model and KPIs for mobile apps&quot;&gt;<br>        &lt;div class=&quot;card-body&quot;&gt;<br>            &lt;h5 class=&quot;card-title&quot;&gt;Understanding Financial Model and KPIs for mobile apps&lt;/h5&gt;<br>            &lt;p class=&quot;card-text&quot;&gt;How to create a financial model for a mobile app? How to measure KPIs? What are KPIs? Learn all this and more...&lt;/p&gt;<br>            &lt;a href=&quot;https://system.camp/startups/understanding-kpis-for-mobile-apps-and-how-to-measure-kpis/&quot; target=&quot;_blank&quot; class=&quot;btn btn-primary&quot;&gt;Read more...&lt;/a&gt;<br>        &lt;/div&gt;<br>    &lt;/div&gt;</pre><h3>Putting it all together</h3><p>From the returned article extract response we will be using these fields</p><p>For Bootstrap to work you will need to import Bootstrap’s css, js and also jquery in your headers. Most websites will have this already imported in their header so please check. If not then please add these imports to your headers.</p><pre>&lt;script src=&quot;https://code.jquery.com/jquery-3.5.1.min.js&quot; integrity=&quot;sha256-9/aliU8dGd2tb6OSsuzixeV4y/faTqgFtohetphbbj0=&quot;crossorigin=&quot;anonymous&quot;&gt;&lt;/script&gt;<br>&lt;!-- Latest compiled and minified CSS --&gt;&lt;link rel=&quot;stylesheet&quot; href=&quot;https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/css/bootstrap.min.css&quot; integrity=&quot;sha384-JcKb8q3iqJ61gNV9KGb8thSsNjpSL0n8PARn9HuZOnIxN0hoP+VmmDGMN5t9UJ0Z&quot; crossorigin=&quot;anonymous&quot;&gt;&lt;!-- Latest compiled and minified JavaScript --&gt;&lt;script src=&quot;https://stackpath.bootstrapcdn.com/bootstrap/4.5.2/js/bootstrap.min.js&quot; integrity=&quot;sha384-B4gt1jrGC7Jh4AgTPSdUtOBvfO8shuf57BaghqFfPlYxofvL8/KUEfYiJOMMV+rV&quot; crossorigin=&quot;anonymous&quot;&gt;&lt;/script&gt;</pre><p>Let’s put this all together in our PHP script:</p><pre>&lt;!doctype html&gt;<br>&lt;html lang=&quot;en&quot;&gt;<br>&lt;head&gt;<br>    &lt;script<br>            src=&quot;https://code.jquery.com/jquery-3.5.1.min.js&quot;<br>            integrity=&quot;sha256-9/aliU8dGd2tb6OSsuzixeV4y/faTqgFtohetphbbj0=&quot;<br>            crossorigin=&quot;anonymous&quot;&gt;&lt;/script&gt; &lt;!-- Latest compiled and minified CSS --&gt; &lt;link rel=&quot;stylesheet&quot; href=&quot;https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css&quot; integrity=&quot;sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u&quot; crossorigin=&quot;anonymous&quot;&gt; &lt;!-- Latest compiled and minified JavaScript --&gt; &lt;script src=&quot;https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js&quot; integrity=&quot;sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa&quot; crossorigin=&quot;anonymous&quot;&gt;&lt;/script&gt;<br>&lt;/head&gt;&lt;body&gt;<strong>&lt;?php</strong><br>$curl = curl_init();<br>curl_setopt_array($curl, array( CURLOPT_URL =&gt; &quot;https://api.promptapi.com/pipfeed&quot;, CURLOPT_HTTPHEADER =&gt; array( &quot;Content-Type: text/plain&quot;, &quot;apikey: jQHpezlBNvwdjW41WcExce6mcn5yz8sW&quot; ), CURLOPT_RETURNTRANSFER =&gt; true, CURLOPT_ENCODING =&gt; &quot;&quot;, CURLOPT_MAXREDIRS =&gt; 10, CURLOPT_TIMEOUT =&gt; 0, CURLOPT_FOLLOWLOCATION =&gt; true, CURLOPT_HTTP_VERSION =&gt; CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST =&gt; &quot;POST&quot;, CURLOPT_POSTFIELDS =&gt; &quot;https://system.camp/startups/understanding-kpis-for-mobile-apps-and-how-to-measure-kpis/&quot;<br>));<br>$response = curl_exec($curl);<br>curl_close($curl);<br>$extractedArticle = json_decode($response);<br>//var_dump($extractedArticle);<br>//var_dump($extractedArticle-&gt;title);<br><strong>?&gt;</strong>&lt;div class=&quot;container&quot;&gt; &lt;div class=&quot;card&quot; style=&quot;max-width: 600px; padding: 0px; position: relative; min-width: 200px; margin: 5px auto;&quot;&gt; &lt;img class=&quot;h-auto d-inline-block&quot; src=&quot;<strong>&lt;?php</strong> echo $extractedArticle-&gt;mainImage <strong>?&gt;</strong>&quot; alt=&quot;<strong>&lt;?php</strong> echo $extractedArticle-&gt;title <strong>?&gt;</strong>&quot;&gt; &lt;div class=&quot;card-body&quot;&gt; &lt;h5 class=&quot;card-title&quot;&gt;<strong>&lt;?php</strong> echo $extractedArticle-&gt;title <strong>?&gt;</strong>&lt;/h5&gt; &lt;p class=&quot;card-text&quot;&gt;<strong>&lt;?php</strong> echo $extractedArticle-&gt;description <strong>?&gt;</strong>&lt;/p&gt; &lt;a href=&quot;<strong>&lt;?php</strong> echo $extractedArticle-&gt;url <strong>?&gt;</strong>&quot; target=&quot;_blank&quot; class=&quot;btn btn-primary&quot;&gt;Read more...&lt;/a&gt; &lt;/div&gt; &lt;/div&gt;&lt;/div&gt;&lt;/body&gt;</pre><h4>This is how the rendered HTML looks like</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wa-xKewiOTWy41L9su8jww.png" /></figure><p>You can customize the generated embedding code based on your preferences. For example, you can use the “Summary” or show the first 4 lines from the article content or use all images and show them as a carousel. You can customize the embeddings the way you prefer.</p><p>Let me know what you think of the tutorial in the comments below.</p><p><em>Originally published at </em><a href="https://pipfeed.com/2020/11/10/generate-embeddable-html-code-for-any-url-using-pipfeeds-extract-api/"><em>https://pipfeed.com</em></a><em> on November 10, 2020.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a032a9d5cc78" width="1" height="1" alt=""><hr><p><a href="https://medium.com/pipfeed/generate-embeddable-html-code-for-any-url-using-pipfeeds-extract-api-a032a9d5cc78">Generate Embeddable HTML code for any URL using Pipfeed’s Extract API</a> was originally published in <a href="https://medium.com/pipfeed">PipFeed</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[[Tutorial] Extract full news article content from any RSS feed using Extract API — PipFeed.com]]></title>
            <link>https://medium.com/pipfeed/tutorial-extract-full-news-article-content-from-any-rss-feed-using-extract-api-pipfeed-com-96da1c87fe61?source=rss-9dc6fbec4bfd------2</link>
            <guid isPermaLink="false">https://medium.com/p/96da1c87fe61</guid>
            <category><![CDATA[parse]]></category>
            <category><![CDATA[api]]></category>
            <category><![CDATA[extract]]></category>
            <category><![CDATA[news-articles]]></category>
            <category><![CDATA[news]]></category>
            <dc:creator><![CDATA[Shashank Agarwal]]></dc:creator>
            <pubDate>Mon, 09 Nov 2020 11:19:20 GMT</pubDate>
            <atom:updated>2020-11-11T05:20:32.471Z</atom:updated>
            <content:encoded><![CDATA[<h3>[Tutorial] Extract full news article content from any RSS feed using Extract API — PipFeed.com</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*amnKu5c4-9wcxlKD.jpg" /></figure><p>Learn how to extract all fields from any RSS feed or given a list of URLs. For this example, we will be using Medium’s RSS feed. The code will be in python but can easily be adapted for other languages.</p><p>Lets start by importing the packages. We will be using “feedparser” to extract Medium Rss feed.</p><pre>pip install feedparser <br>pip install requests</pre><p>Let’s begin by first extracting links from the RSS feed. For this example, we will be extracting the articles from “Towards Data Science”. “Towards Data Science” is one of the leading blogs when it comes to Data Science, Machine Learning &amp; Artificial Intelligence.</p><pre>import feedparser NewsFeed = feedparser.parse(&quot;https://towardsdatascience.com/feed&quot;) print(&quot;Total entries found in feed: &quot;+ str(len(NewsFeed.entries)) +&quot;\n&quot;) i =0 for entry in NewsFeed.entries: print(str(i) + &quot;: Got url: &quot; + entry.link) i = i +1</pre><p>We are able to extract the links, now we want to extract the entire content, summary, metadata and other details for each news article in the feed.</p><p>To extract we will be using Pipfeed’s extract API: <a href="https://promptapi.com/marketplace/description/pipfeed-api">https://promptapi.com/marketplace/description/pipfeed-api</a> You can get a free API key from prompt API.</p><pre>import requests url = &quot;https://api.promptapi.com/pipfeed&quot; payload = &quot;https://towardsdatascience.com/topic-model-evaluation-3c43e2308526&quot; headers= { &quot;apikey&quot;: &quot;YOUR_API_KEY&quot; } response = requests.request(&quot;POST&quot;, url, headers=headers, data = payload) status_code = response.status_code result = response.text print(result)</pre><p>The above code will extract the given URL and return all the fields. Below is the response we get for the above code. DO NOT forget to replace the API key with your own API keys generated from prompt API.</p><p>“Summary” &amp; “predictedCategories” are generated using Pipfeed’s AI models. The rest of the fields are extracted from the article HTML itself.</p><pre>{ &quot;publishedAt&quot;: &quot;2020-11-09T05:15:23.001Z&quot;, &quot;title&quot;: &quot;Topic Model Evaluation&quot;, &quot;authors&quot;: [ &quot;Giri Rabindranath&quot; ], &quot;description&quot;: &quot;Evaluation is the key to understanding topic models - This article explains what topic model evaluation is, why it&#39;s important and how to do it&quot;, &quot;language&quot;: &quot;en&quot;, &quot;url&quot;: &quot;https://towardsdatascience.com/topic-model-evaluation-3c43e2308526&quot;, &quot;mainImage&quot;: &quot;https://miro.medium.com/max/1200/1*wvlqQPpOHFK7xQ1XOhe6xg.jpeg&quot;, &quot;category&quot;: &quot;machine-learning&quot;, &quot;categories&quot;: null, &quot;predictedCategories&quot;: [ &quot;machine-learning&quot;, &quot;data-science&quot;, &quot;programming&quot; ], &quot;tags&quot;: [], &quot;keywords&quot;: [ &quot;coherence&quot;, &quot;evaluation&quot;, &quot;human&quot;, &quot;model&quot;, &quot;models&quot;, &quot;topic&quot;, &quot;topics&quot;, &quot;way&quot;, &quot;word&quot;, &quot;words&quot; ], &quot;summary&quot;: &quot;In this article, we\u2019ll look at topic model evaluation, what it is and how to do it.\nWhat is topic model evaluation?\nTopic model evaluation is the process of assessing how well a topic model does what it is designed for.\nThis is why topic model evaluation matters.\nHow to evaluate topic models \u2014 RecapThis article has hopefully made one thing clear \u2014 topic model evaluation isn\u2019t easy!&quot;, &quot;images&quot;: [ &quot;https://miro.medium.com/fit/c/140/140/1*74Yrxu8s4sOtTECtixv9Fg.jpeg&quot;, &quot;https://miro.medium.com/max/60/1*<a href="https://pipfeed.com/cdn-cgi/l/email-protection">[email protected]</a>?q=20&quot;, &quot;https://miro.medium.com/fit/c/140/140/0*l_zfjU9IKMa47tfy&quot;, &quot;https://miro.medium.com/fit/c/56/56/2*b2y5uCYazQ9FgiUQEUHT6Q.jpeg&quot;, &quot;https://miro.medium.com/max/60/1*mpyrgqwMjfclV2oN1U2VIA.jpeg?q=20&quot;, &quot;https://miro.medium.com/max/698/1*E4oPMmq5jTKuStZJuyDGpw.jpeg&quot;, &quot;https://miro.medium.com/max/12032/1*wvlqQPpOHFK7xQ1XOhe6xg.jpeg&quot;, &quot;https://miro.medium.com/max/60/1*_MXaw5BKgIsm8J3dOUNHMg.jpeg?q=20&quot;, &quot;https://miro.medium.com/max/224/1*AGyTPCaRzVqL77kFwUwHKg.png&quot;, &quot;https://miro.medium.com/max/270/1*W_RAPQ62h0em559zluJLdQ.png&quot;, &quot;https://miro.medium.com/max/60/1*E4oPMmq5jTKuStZJuyDGpw.jpeg?q=20&quot;, &quot;https://miro.medium.com/max/1200/1*wvlqQPpOHFK7xQ1XOhe6xg.jpeg&quot;, &quot;https://miro.medium.com/max/60/0*aP8H1qpRN_OR1x5r?q=20&quot;, &quot;https://miro.medium.com/max/60/0*NIpOoYo9iHt4lMbg?q=20&quot;, &quot;https://miro.medium.com/max/60/0*l_zfjU9IKMa47tfy?q=20&quot;, &quot;https://miro.medium.com/max/270/1*Crl55Tm6yDNMoucPo1tvDg.png&quot;, &quot;https://miro.medium.com/max/784/1*_MXaw5BKgIsm8J3dOUNHMg.jpeg&quot;, &quot;https://miro.medium.com/fit/c/140/140/1*FTG-junI6KJzojC_xRVNXg.png&quot;, &quot;https://miro.medium.com/max/60/0*fG5RLd48iOZezB_y.jpeg?q=20&quot;, &quot;https://miro.medium.com/fit/c/140/140/0*NIpOoYo9iHt4lMbg&quot;, &quot;https://miro.medium.com/fit/c/140/140/1*<a href="https://pipfeed.com/cdn-cgi/l/email-protection">[email protected]</a>&quot;, &quot;https://miro.medium.com/max/60/1*wvlqQPpOHFK7xQ1XOhe6xg.jpeg?q=20&quot;, &quot;https://miro.medium.com/fit/c/140/140/1*mpyrgqwMjfclV2oN1U2VIA.jpeg&quot;, &quot;https://miro.medium.com/fit/c/140/140/0*fG5RLd48iOZezB_y.jpeg&quot;, &quot;https://miro.medium.com/fit/c/140/140/0*aP8H1qpRN_OR1x5r&quot;, &quot;https://miro.medium.com/max/60/1*74Yrxu8s4sOtTECtixv9Fg.jpeg?q=20&quot;, &quot;https://miro.medium.com/max/60/1*FTG-junI6KJzojC_xRVNXg.png?q=20&quot; ], &quot;blogName&quot;: null, &quot;blogLogoUrl&quot;: null, &quot;html&quot;: &quot;&lt;div class=\&quot;page\&quot; id=\&quot;readability-page-1\&quot;&gt;&lt;section&gt;&lt;div&gt;&lt;div&gt;&lt;h2 id=\&quot;ef6b\&quot;&gt;DATA SCIENCE EXPLAINED&lt;/h2&gt;&lt;h2 id=\&quot;e375\&quot;&gt;Here\u2019s what you need to know about evaluating topic models&lt;/h2&gt;&lt;div&gt;&lt;div&gt;&lt;div&gt;&lt;div&gt;&lt;a rel=\&quot;noopener\&quot; href=\&quot;https://medium.com/@g_rabi?source=post_page-----3c43e2308526--------------------------------\&quot;&gt;&lt;div&gt;&lt;p&gt;&lt;img height=\&quot;28\&quot; width=\&quot;28\&quot; src=\&quot;https://miro.medium.com/fit/c/56/56/2*b2y5uCYazQ9FgiUQEUHT6Q.jpeg\&quot; alt=\&quot;Giri Rabindranath\&quot;&gt;&lt;/p&gt;&lt;/div&gt;&lt;/a&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;div&gt;&lt;p id=\&quot;8bff\&quot;&gt;&lt;em&gt;Topic models are widely used for analyzing unstructured text data, but they provide no guidance on the quality of topics produced. Evaluation is the key to understanding topic models. In this article, we\u2019ll look at what topic model evaluation is, why it\u2019s important and how to do it.&lt;/em&gt;&lt;/p&gt;&lt;/div&gt;&lt;/section&gt;&lt;section&gt;&lt;div&gt;&lt;div&gt;&lt;h2 id=\&quot;324c\&quot;&gt;Contents&lt;/h2&gt;&lt;ul&gt;&lt;li id=\&quot;dd12\&quot;&gt;&lt;a rel=\&quot;noopener\&quot; href=\&quot;#f0ce\&quot;&gt;&lt;em&gt;What is topic model evaluation&lt;/em&gt;&lt;/a&gt;?&lt;/li&gt;&lt;li id=\&quot;ceba\&quot;&gt;&lt;a rel=\&quot;noopener\&quot; href=\&quot;#d1ae\&quot;&gt;&lt;em&gt;How to evaluate topic models&lt;/em&gt;&lt;/a&gt;&lt;/li&gt;&lt;li id=\&quot;ea5d\&quot;&gt;&lt;a rel=\&quot;noopener\&quot; href=\&quot;#2932\&quot;&gt;&lt;em&gt;Evaluating topic models \u2014 Human judgment&lt;/em&gt;&lt;/a&gt;&lt;/li&gt;&lt;li id=\&quot;6275\&quot;&gt;&lt;a rel=\&quot;noopener\&quot; href=\&quot;#9b50\&quot;&gt;&lt;em&gt;Evaluating topic models \u2014 Quantitative metrics&lt;/em&gt;&lt;/a&gt;&lt;/li&gt;&lt;li id=\&quot;ea38\&quot;&gt;&lt;a rel=\&quot;noopener\&quot; href=\&quot;#19ff\&quot;&gt;&lt;em&gt;Calculating coherence using Gensim in Python&lt;/em&gt;&lt;/a&gt;&lt;/li&gt;&lt;li id=\&quot;95a3\&quot;&gt;&lt;a rel=\&quot;noopener\&quot; href=\&quot;#1756\&quot;&gt;&lt;em&gt;Limitations of coherence&lt;/em&gt;&lt;/a&gt;&lt;/li&gt;&lt;li id=\&quot;251a\&quot;&gt;&lt;a rel=\&quot;noopener\&quot; href=\&quot;#63c4\&quot;&gt;&lt;em&gt;How to evaluate topic models \u2014 Recap&lt;/em&gt;&lt;/a&gt;&lt;/li&gt;&lt;li id=\&quot;e448\&quot;&gt;&lt;a rel=\&quot;noopener\&quot; href=\&quot;#31aa\&quot;&gt;&lt;em&gt;Conclusion&lt;/em&gt;&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p id=\&quot;6f84\&quot;&gt;Topic modeling is a branch of &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;https://highdemandskills.com/natural-language-processing-explained-simply/\&quot;&gt;natural language processing&lt;/a&gt; that\u2019s used for exploring text data. It works by identifying key themes \u2014 or topics \u2014 based on the words or phrases in the data that have a similar meaning. Its versatility and ease-of-use have led to a variety of applications.&lt;/p&gt;&lt;p id=\&quot;3772\&quot;&gt;Be&lt;span id=\&quot;rmm\&quot;&gt;i&lt;/span&gt;ng a form of unsupervised learning, topic modeling is useful when annotated or labeled data isn\u2019t available. This is helpful, as the majority of emerging text data isn\u2019t labeled, and labeling is time-consuming and expensive to do.&lt;/p&gt;&lt;p id=\&quot;030c\&quot;&gt;For an easy-to-follow, intuitive explanation of topic modeling and its applications, see &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;https://highdemandskills.com/topic-modeling-intuitive/\&quot;&gt;this article&lt;/a&gt;.&lt;/p&gt;&lt;p id=\&quot;fb4a\&quot;&gt;One of the shortcomings of topic modeling is that there\u2019s no guidance about the quality of topics produced. If you want to learn about how meaningful the topics are, you\u2019ll need to evaluate the topic model.&lt;/p&gt;&lt;p id=\&quot;b937\&quot;&gt;In this article, we\u2019ll look at topic model evaluation, what it is and how to do it. It\u2019s an important part of the topic modeling process that sometimes gets overlooked. For a topic model to be truly useful, some sort of evaluation is needed to understand how relevant the topics are for the purpose of the model.&lt;/p&gt;&lt;p id=\&quot;b85d\&quot;&gt;Topic model evaluation is the process of assessing how well a topic model does what it is designed for.&lt;/p&gt;&lt;p id=\&quot;44ee\&quot;&gt;When you run a topic model, you usually do it with a specific purpose in mind. It may be for document classification, to explore a set of unstructured texts, or some other analysis. As with any model, if you wish to know how effective it is at doing what it\u2019s designed for, you\u2019ll need to evaluate it. This is why topic model evaluation matters.&lt;/p&gt;&lt;p id=\&quot;e9c9\&quot;&gt;Evaluating a topic model can help you decide if the model has captured the internal structure of a corpus (a collection of text documents). This can be particularly useful in tasks like e-discovery, where the effectiveness of a topic model can have implications for legal proceedings or other important matters.&lt;/p&gt;&lt;p id=\&quot;a51a\&quot;&gt;More generally, topic model evaluation can help you answer questions like:&lt;/p&gt;&lt;ul&gt;&lt;li id=\&quot;b7ef\&quot;&gt;Are the identified topics understandable?&lt;/li&gt;&lt;li id=\&quot;1d2d\&quot;&gt;Are the topics coherent?&lt;/li&gt;&lt;li id=\&quot;325e\&quot;&gt;Does the topic model serve the purpose it is being used for?&lt;/li&gt;&lt;/ul&gt;&lt;p id=\&quot;da03\&quot;&gt;Without some form of evaluation, you won\u2019t know how well your topic model is performing or if it\u2019s being used properly.&lt;/p&gt;&lt;p id=\&quot;c559\&quot;&gt;Evaluating a topic model isn\u2019t always easy, however.&lt;/p&gt;&lt;p id=\&quot;3adc\&quot;&gt;If a topic model is used for a measurable task, such as classification, then its effectiveness is relatively straightforward to calculate (eg. measure the proportion of successful classifications). But if the model is used for a more qualitative task, such as exploring the semantic themes in an unstructured corpus, then evaluation is more difficult.&lt;/p&gt;&lt;p id=\&quot;ff58\&quot;&gt;In this article, we\u2019ll focus on evaluating topic models that do not have clearly measurable outcomes. These include topic models used for document exploration, content recommendation and e-discovery, amongst other use cases.&lt;/p&gt;&lt;p id=\&quot;dc38\&quot;&gt;Evaluating these types of topic models seeks to understand how easy it is for humans to interpret the topics produced by the model. Put another way, topic model evaluation is about the \u2018human interpretability\u2019 or \u2018semantic interpretability\u2019 of topics.&lt;/p&gt;&lt;p id=\&quot;48f0\&quot;&gt;There are a number of ways to evaluate topic models. These include:&lt;/p&gt;&lt;p id=\&quot;fb66\&quot;&gt;&lt;em&gt;Human judgment&lt;/em&gt;&lt;/p&gt;&lt;ul&gt;&lt;li id=\&quot;422a\&quot;&gt;Observation-based, eg. observing the top \u2019N\u2019 words in a topic&lt;/li&gt;&lt;li id=\&quot;cee6\&quot;&gt;Interpretation-based, eg. \u2018word intrusion\u2019 and \u2018topic intrusion\u2019 to identify the words or topics that \u201cdon\u2019t belong\u201d in a topic or document&lt;/li&gt;&lt;/ul&gt;&lt;p id=\&quot;ce7c\&quot;&gt;&lt;em&gt;Quantitative metrics&lt;/em&gt; \u2014 Perplexity (held out likelihood) and coherence calculations&lt;/p&gt;&lt;p id=\&quot;8c62\&quot;&gt;&lt;em&gt;Mixed approaches&lt;/em&gt; \u2014 Combinations of judgment-based and quantitative approaches&lt;/p&gt;&lt;p id=\&quot;6bd7\&quot;&gt;Let\u2019s look at a few of these more closely.&lt;/p&gt;&lt;h2 id=\&quot;f1c4\&quot;&gt;Observation-based approaches&lt;/h2&gt;&lt;p id=\&quot;4ea9\&quot;&gt;The easiest way to evaluate a topic is to look at the most probable words in the topic. This can be done in a tabular form, for instance by listing the top 10 words in each topic, or in other formats.&lt;/p&gt;&lt;p id=\&quot;939a\&quot;&gt;One visually appealing way to observe the probable words in a topic is through Word Clouds.&lt;/p&gt;&lt;p id=\&quot;9585\&quot;&gt;To illustrate, the following example is a Word Cloud based on topics modeled from the minutes of US Federal Open Market Committee (FOMC) meetings. The FOMC is an important part of the US financial system and meets 8 times per year. The following Word Cloud is based on a topic that emerged from an analysis of topic trends in FOMC meetings over 2007 to 2020.&lt;/p&gt;&lt;figure&gt;&lt;a href=\&quot;https://highdemandskills.com/topic-trends-fomc/\&quot;&gt;&lt;div&gt;&lt;div&gt;&lt;p&gt;&lt;img data-old-src=\&quot;https://miro.medium.com/max/60/1*E4oPMmq5jTKuStZJuyDGpw.jpeg?q=20\&quot; sizes=\&quot;349px\&quot; srcset=\&quot;https://miro.medium.com/max/552/1*E4oPMmq5jTKuStZJuyDGpw.jpeg 276w, https://miro.medium.com/max/698/1*E4oPMmq5jTKuStZJuyDGpw.jpeg 349w\&quot; height=\&quot;181\&quot; width=\&quot;349\&quot; src=\&quot;https://miro.medium.com/max/698/1*E4oPMmq5jTKuStZJuyDGpw.jpeg\&quot; alt=\&quot;Image for post\&quot;&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/a&gt;&lt;figcaption&gt;Word Cloud of \u201cinflation\u201d topic. Image by Author.&lt;/figcaption&gt;&lt;/figure&gt;&lt;p id=\&quot;b025\&quot;&gt;Topic modeling doesn\u2019t provide guidance on the meaning of any topic, so labeling a topic requires human interpretation. In this case, based on the most probable words displayed in the Word Cloud, the topic appears to be about \u201cinflation\u201d.&lt;/p&gt;&lt;p id=\&quot;ead0\&quot;&gt;You can see more Word Clouds from the FOMC topic modeling example &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;https://highdemandskills.com/topic-trends-fomc/#h4-interpret-topics\&quot;&gt;here&lt;/a&gt;.&lt;/p&gt;&lt;p id=\&quot;d586\&quot;&gt;Beyond observing the most probable words in a topic, a more comprehensive observation-based approach called \u2018Termite\u2019 has been &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;http://vis.stanford.edu/files/2012-Termite-AVI.pdf\&quot;&gt;developed by Stanford University researchers&lt;/a&gt;.&lt;/p&gt;&lt;p id=\&quot;a78d\&quot;&gt;Termite is described as \u201c&lt;em&gt;a visualization of the term-topic distributions produced by topic models\u201d &lt;/em&gt;[1]. In this description, \u2018term\u2019 refers to a \u2018word\u2019, so \u2018term-topic distributions\u2019 are \u2018word-topic distributions\u2019.&lt;/p&gt;&lt;p id=\&quot;a348\&quot;&gt;Termite produces meaningful visualizations by introducing two calculations:&lt;/p&gt;&lt;ol&gt;&lt;li id=\&quot;ddbe\&quot;&gt;A \u2018saliency\u2019 measure, which identifies words that are more relevant for the topics in which they appear (beyond mere frequencies of their counts)&lt;/li&gt;&lt;li id=\&quot;246c\&quot;&gt;A \u2018seriation\u2019 method, for sorting words into more coherent groupings based on the degree of semantic similarity between them&lt;/li&gt;&lt;/ol&gt;&lt;p id=\&quot;d552\&quot;&gt;Termite produces graphs which summarize words and topics based on saliency and seriation. This helps to identify more interpretable topics and leads to better topic model evaluation.&lt;/p&gt;&lt;p id=\&quot;5bce\&quot;&gt;You can see example Termite visualizations &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;http://vis.stanford.edu/topic-diagnostics/\&quot;&gt;here&lt;/a&gt;.&lt;/p&gt;&lt;h2 id=\&quot;1281\&quot;&gt;Interpretation-based approaches&lt;/h2&gt;&lt;p id=\&quot;ccc6\&quot;&gt;Interpretation-based approaches take more effort than observation-based approaches but produce better results. These approaches are considered a \u2018gold standard\u2019 for evaluating topic models since they use human judgment to maximum effect.&lt;/p&gt;&lt;p id=\&quot;eff2\&quot;&gt;A good illustration of these is described in a &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;http://users.umiacs.umd.edu/~jbg/docs/nips2009-rtl.pdf\&quot;&gt;research paper&lt;/a&gt; by Jonathan Chang and others (2009) [2] which developed \u2018word intrusion\u2019 and \u2018topic intrusion\u2019 to help evaluate semantic coherence.&lt;/p&gt;&lt;p id=\&quot;e268\&quot;&gt;&lt;strong&gt;Word intrusion&lt;/strong&gt;&lt;/p&gt;&lt;p id=\&quot;cd41\&quot;&gt;In word intrusion, subjects are presented with groups of 6 words, 5 of which belong to a given topic and one which does not \u2014 the \u2018intruder\u2019 word. Subjects are asked to identify the intruder word.&lt;/p&gt;&lt;p id=\&quot;3489\&quot;&gt;To understand how this works, consider the group of words:&lt;/p&gt;&lt;p id=\&quot;7c02\&quot;&gt;[ &lt;em&gt;dog, cat, horse, apple, pig, cow &lt;/em&gt;]&lt;/p&gt;&lt;p id=\&quot;e26b\&quot;&gt;Can you spot the intruder?&lt;/p&gt;&lt;p id=\&quot;0e95\&quot;&gt;Most subjects pick \u2018apple\u2019 because it looks different to the others (all of which are animals, suggesting an animal-related topic for the others).&lt;/p&gt;&lt;p id=\&quot;294d\&quot;&gt;Now, consider:&lt;/p&gt;&lt;p id=\&quot;3370\&quot;&gt;[ &lt;em&gt;car, teacher, platypus, agile, blue, Zaire &lt;/em&gt;]&lt;/p&gt;&lt;p id=\&quot;2ebb\&quot;&gt;Which is the intruder in this group of words?&lt;/p&gt;&lt;p id=\&quot;fed9\&quot;&gt;It\u2019s much harder to identify, so most subjects choose the intruder at random. This implies poor topic coherence.&lt;/p&gt;&lt;p id=\&quot;3b59\&quot;&gt;&lt;strong&gt;Topic intrusion&lt;/strong&gt;&lt;/p&gt;&lt;p id=\&quot;1ee8\&quot;&gt;Similar to word intrusion, in topic intrusion subjects are asked to identify the \u2018intruder\u2019 topic from groups of topics that make up documents.&lt;/p&gt;&lt;p id=\&quot;2b99\&quot;&gt;In this task, subjects are shown a title and a snippet from a document along with 4 topics. Three of the topics have a high probability of belonging to the document while the remaining topic has a low probability \u2014 the \u2018intruder\u2019 topic.&lt;/p&gt;&lt;p id=\&quot;41ed\&quot;&gt;As for word intrusion, the intruder topic is sometimes easy to identify and at other times not. The success with which subjects can correctly choose the intruder helps to determine the level of coherence.&lt;/p&gt;&lt;p id=\&quot;7489\&quot;&gt;While evaluation methods based on human judgment can produce good results, they are costly and time-consuming to do.&lt;/p&gt;&lt;p id=\&quot;e193\&quot;&gt;Moreover, human judgment isn\u2019t clearly defined and humans don\u2019t always agree on what makes a good topic. In contrast, the appeal of quantitative metrics is the ability to standardize, automate and scale the evaluation of topic models.&lt;/p&gt;&lt;h2 id=\&quot;2047\&quot;&gt;Held out likelihood or perplexity&lt;/h2&gt;&lt;p id=\&quot;415d\&quot;&gt;A traditional metric for evaluating topic models is the \u2018held out likelihood\u2019, also referred to as \u2018perplexity\u2019.&lt;/p&gt;&lt;p id=\&quot;4c08\&quot;&gt;This is calculated by splitting a dataset into two parts \u2014 a training set and a test set. The idea is to train a topic model using the training set and then test the model on a test set which contains previously unseen documents (ie. held out documents). Likelihood is usually calculated as a logarithm, so this metric is sometimes referred to as the \u2018held out log-likelihood\u2019.&lt;/p&gt;&lt;p id=\&quot;c176\&quot;&gt;The perplexity metric is a predictive one. It assesses a topic model\u2019s ability to predict a test set after having been trained on a training set. In practice, around 80% of a corpus may be set aside as a training set with the remaining 20% being a test set.&lt;/p&gt;&lt;p id=\&quot;4ffe\&quot;&gt;Although the perplexity metric is a natural choice for topic models from a technical standpoint, it does not provide good results for human interpretation. This was demonstrated by research, again by Jonathan Chang and others (2009), which found that perplexity did not do a good job of conveying whether topics are coherent or not.&lt;/p&gt;&lt;p id=\&quot;bf74\&quot;&gt;When comparing perplexity against human judgment approaches like word intrusion and topic intrusion, the research showed a negative correlation. This means that as the perplexity score improves (ie. the held out log-likelihood is higher), the human interpretability of topics and topic mixes get worse (rather than better). The perplexity metric therefore appears to be misleading when it comes to the human understanding of topics and topic mixes.&lt;/p&gt;&lt;p id=\&quot;ad6d\&quot;&gt;Are there better quantitative metrics than perplexity for evaluating topic models?&lt;/p&gt;&lt;h2 id=\&quot;6e3f\&quot;&gt;Coherence&lt;/h2&gt;&lt;p id=\&quot;a14e\&quot;&gt;One of the shortcomings of perplexity is that it does not capture context, ie. perplexity does not capture the relationship between words in a topic or topics in a document. The idea of semantic context is important for human understanding.&lt;/p&gt;&lt;p id=\&quot;3175\&quot;&gt;To overcome this, approaches have been developed that attempt to capture context between words in a topic. They use measures such as the conditional likelihood (rather than the log-likelihood) of the co-occurrence of words in a topic. These approaches are collectively referred to as \u2018coherence\u2019.&lt;/p&gt;&lt;p id=\&quot;6ad7\&quot;&gt;There\u2019s been a lot of research on coherence over recent years and as a result there are a variety of methods available. A useful way to deal with this is to set up a framework that allows you to choose the methods that you prefer.&lt;/p&gt;&lt;p id=\&quot;ebf8\&quot;&gt;Such a framework has been proposed by researchers at &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;http://aksw.org/About.html\&quot;&gt;AKSW&lt;/a&gt;. Using this &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;http://svn.aksw.org/papers/2015/WSDM_Topic_Evaluation/public.pdf\&quot;&gt;framework&lt;/a&gt;, which we\u2019ll call the \u201ccoherence pipeline\u201d, you can calculate coherence in a way that works best for your circumstances (eg. based on availability of a corpus, speed of computation etc).&lt;/p&gt;&lt;p id=\&quot;06ae\&quot;&gt;The coherence pipeline offers a versatile way to calculate coherence. It is also what Gensim, a popular package for topic modeling in Python, uses for implementing coherence (more on this later).&lt;/p&gt;&lt;p id=\&quot;94ae\&quot;&gt;The coherence pipeline is made up of four stages:&lt;/p&gt;&lt;ol&gt;&lt;li id=\&quot;acc4\&quot;&gt;Segmentation&lt;/li&gt;&lt;li id=\&quot;1668\&quot;&gt;Probability estimation&lt;/li&gt;&lt;li id=\&quot;75ce\&quot;&gt;Confirmation&lt;/li&gt;&lt;li id=\&quot;0982\&quot;&gt;Aggregation&lt;/li&gt;&lt;/ol&gt;&lt;p id=\&quot;4e6c\&quot;&gt;These four stages form the basis of coherence calculations and work as follows:&lt;/p&gt;&lt;p id=\&quot;91d7\&quot;&gt;&lt;strong&gt;Segmentation&lt;/strong&gt; sets up the word groupings that are used for pair-wise comparisons.&lt;/p&gt;&lt;p id=\&quot;b612\&quot;&gt;Let\u2019s say that we wish to calculate the coherence of a set of topics. Coherence calculations start by choosing words within each topic (usually the most frequently occurring words) and comparing them with each other, one pair at a time. Segmentation is the process of choosing how words are grouped together for these pair-wise comparisons.&lt;/p&gt;&lt;p id=\&quot;7439\&quot;&gt;Word groupings can be made up of single words or larger groupings. For single words, each word in a topic is compared with each other word in the topic. For 2-word or 3-word groupings, each 2-word group is compared with each other 2-word group, or each 3-word group is compared with each other 3-word group, and so on.&lt;/p&gt;&lt;p id=\&quot;0de4\&quot;&gt;Comparisons can also be made between groupings of different size, for instance single words can be compared with 2-word or 3-word groups.&lt;/p&gt;&lt;p id=\&quot;4a41\&quot;&gt;&lt;strong&gt;Probability &lt;/strong&gt;estimation refers to the type of probability measure that underpins the calculation of coherence. To illustrate, consider the two widely used coherence approaches of &lt;em&gt;UCI&lt;/em&gt; and &lt;em&gt;UMass&lt;/em&gt;:&lt;/p&gt;&lt;ul&gt;&lt;li id=\&quot;6032\&quot;&gt;UCI is based on point-wise mutual information (PMI) calculations. This is given by: &lt;code&gt;&lt;strong&gt;PMI&lt;/strong&gt;(wi,wj) = log[(&lt;strong&gt;P&lt;/strong&gt;(wi,wj) + e) / &lt;strong&gt;P&lt;/strong&gt;(wi).&lt;strong&gt;P&lt;/strong&gt;(wj)]&lt;/code&gt;, for words &lt;code&gt;wi&lt;/code&gt; and &lt;code&gt;wj&lt;/code&gt; and some small number &lt;code&gt;e&lt;/code&gt;, and where &lt;code&gt;&lt;strong&gt;P&lt;/strong&gt;(wi)&lt;/code&gt; is the probability of word &lt;code&gt;i&lt;/code&gt; occurring in a topic and &lt;code&gt;&lt;strong&gt;P&lt;/strong&gt;(wi,wj)&lt;/code&gt; is the probability of both words &lt;code&gt;i&lt;/code&gt; and &lt;code&gt;j&lt;/code&gt; appearing in a topic. Here, the probabilities are based on word co-occurrence counts.&lt;/li&gt;&lt;li id=\&quot;0083\&quot;&gt;UMass caters for the order in which words appear and is based on the calculation of: &lt;code&gt;log[(&lt;strong&gt;P&lt;/strong&gt;(wi,wj) + e) / &lt;strong&gt;P&lt;/strong&gt;(wj)]&lt;/code&gt;, with &lt;code&gt;wi&lt;/code&gt;, &lt;code&gt;wj&lt;/code&gt;, &lt;code&gt;&lt;strong&gt;P&lt;/strong&gt;(wi)&lt;/code&gt; and &lt;code&gt;&lt;strong&gt;P&lt;/strong&gt;(wi,wj)&lt;/code&gt; as for UCI. Here, the probabilities are conditional, since &lt;code&gt;&lt;strong&gt;P&lt;/strong&gt;(wi|wj) = [(&lt;strong&gt;P&lt;/strong&gt;(wi,wj) / &lt;strong&gt;P&lt;/strong&gt;(wj)]&lt;/code&gt;, which we know from &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;https://highdemandskills.com/bayes-theorem/\&quot;&gt;Bayes\u2019 theorem&lt;/a&gt;. So, this approach measures how much a common word appearing within a topic is a good predictor for a less common word in the topic.&lt;/li&gt;&lt;/ul&gt;&lt;p id=\&quot;f8a3\&quot;&gt;&lt;strong&gt;Confirmation&lt;/strong&gt; measures how strongly each word grouping in a topic relates to other word groupings (ie. how similar they are). There are direct and indirect ways of doing this, depending on the frequency and distribution of words in a topic.&lt;/p&gt;&lt;p id=\&quot;1c55\&quot;&gt;&lt;strong&gt;Aggregation&lt;/strong&gt; is the final step of the coherence pipeline. It\u2019s a summary calculation of the confirmation measures of all the word groupings, resulting in a single coherence score. This is usually done by averaging the confirmation measures using the mean or median. Other calculations may also be used, such as the harmonic mean, quadratic mean, minimum or maximum.&lt;/p&gt;&lt;p id=\&quot;93e5\&quot;&gt;Coherence is a popular way to quantitatively evaluate topic models and has good coding implementations in languages such as Python (eg. Gensim).&lt;/p&gt;&lt;p id=\&quot;ddfb\&quot;&gt;To see how coherence works in practice, let\u2019s look at an example.&lt;/p&gt;&lt;p id=\&quot;8445\&quot;&gt;Gensim is a widely used package for topic modeling in Python. It uses &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;https://highdemandskills.com/topic-modeling-intuitive/\&quot;&gt;Latent Dirichlet Allocation&lt;/a&gt; (LDA) for topic modeling and includes functionality for calculating the coherence of topic models.&lt;/p&gt;&lt;p id=\&quot;d3e9\&quot;&gt;As mentioned, Gensim calculates coherence using the coherence pipeline, offering a range of options for users.&lt;/p&gt;&lt;p id=\&quot;1da5\&quot;&gt;The following example uses Gensim to model topics for US company earnings calls. These are quarterly conference calls in which company management discusses financial performance and other updates with analysts, investors and the media. They are an important fixture in the US financial calendar.&lt;/p&gt;&lt;p id=\&quot;ad5b\&quot;&gt;The following code calculates coherence for the trained topic model in the example:&lt;/p&gt;&lt;figure&gt;&lt;div&gt;&lt;/div&gt;&lt;figcaption&gt;&lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;https://highdemandskills.com/topic-modeling-lda/\&quot;&gt;Calculating the coherence score using Gensim&lt;/a&gt;&lt;/figcaption&gt;&lt;/figure&gt;&lt;p id=\&quot;c9d2\&quot;&gt;The coherence method that was chosen in this example is \u201cc_v\u201d. This is one of several choices offered by Gensim. Other choices include UCI (\u201cc_uci\u201d) and UMass (\u201cu_mass\u201d).&lt;/p&gt;&lt;p id=\&quot;594d\&quot;&gt;For more information about the Gensim package and the various choices that go with it, please refer to the &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;https://radimrehurek.com/gensim/models/coherencemodel.html\&quot;&gt;Gensim documentation&lt;/a&gt;.&lt;/p&gt;&lt;p id=\&quot;3292\&quot;&gt;Gensim can also be used to explore the effect of varying LDA parameters on a topic model\u2019s coherence score. This helps to select the best choice of parameters for the model. The following code shows how to calculate coherence for varying values of the alpha parameter in the LDA model:&lt;/p&gt;&lt;figure&gt;&lt;div&gt;&lt;/div&gt;&lt;figcaption&gt;&lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;https://highdemandskills.com/topic-modeling-lda/\&quot;&gt;Investigating coherence by varying the alpha parameter&lt;/a&gt;&lt;/figcaption&gt;&lt;/figure&gt;&lt;p id=\&quot;fe44\&quot;&gt;The above code also produces a chart of the model\u2019s coherence score for different values of the alpha parameter:&lt;/p&gt;&lt;figure&gt;&lt;a href=\&quot;https://highdemandskills.com/topic-modeling-lda/\&quot;&gt;&lt;div&gt;&lt;div&gt;&lt;p&gt;&lt;img data-old-src=\&quot;https://miro.medium.com/max/60/1*_MXaw5BKgIsm8J3dOUNHMg.jpeg?q=20\&quot; sizes=\&quot;392px\&quot; srcset=\&quot;https://miro.medium.com/max/552/1*_MXaw5BKgIsm8J3dOUNHMg.jpeg 276w, https://miro.medium.com/max/784/1*_MXaw5BKgIsm8J3dOUNHMg.jpeg 392w\&quot; height=\&quot;262\&quot; width=\&quot;392\&quot; src=\&quot;https://miro.medium.com/max/784/1*_MXaw5BKgIsm8J3dOUNHMg.jpeg\&quot; alt=\&quot;Image for post\&quot;&gt;&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/a&gt;&lt;figcaption&gt;Topic model coherence for different values of the alpha parameter. Image by Author.&lt;/figcaption&gt;&lt;/figure&gt;&lt;p id=\&quot;ae19\&quot;&gt;This helps in choosing the best value of alpha based on coherence scores.&lt;/p&gt;&lt;p id=\&quot;e6dc\&quot;&gt;In practice, you would also want to check the effect of varying other model parameters on the coherence score. You can see how this was done in the US company earning call example &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;https://highdemandskills.com/topic-modeling-lda/#h3-3\&quot;&gt;here&lt;/a&gt;.&lt;/p&gt;&lt;p id=\&quot;ecfa\&quot;&gt;The overall choice of parameters would depend on balancing the varying effects on coherence, and also on judgment about the nature of the topics and the purpose of the model.&lt;/p&gt;&lt;p id=\&quot;098d\&quot;&gt;Despite its usefulness, coherence has some important limitations.&lt;/p&gt;&lt;p id=\&quot;5a89\&quot;&gt;According to &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;https://www.linkedin.com/in/mattilyra/?originalSubdomain=de\&quot;&gt;Matti Lyra&lt;/a&gt;, a leading data scientist and researcher, the key limitations are:&lt;/p&gt;&lt;ul&gt;&lt;li id=\&quot;83d2\&quot;&gt;&lt;strong&gt;Variability&lt;/strong&gt; \u2014 The aggregation step of the coherence pipeline is typically calculated over a large number of word-group pairs. While this produces a metric (eg. mean of the coherence scores), there\u2019s no way of estimating the variability of the metric. This means that there\u2019s no way of knowing the degree of confidence in the metric. Hence, although we can calculate aggregate coherence scores for a topic model, we don\u2019t really know how well that score reflects the actual coherence of the model (relative to statistical noise).&lt;/li&gt;&lt;li id=\&quot;72c8\&quot;&gt;&lt;strong&gt;Comparability&lt;/strong&gt; \u2014 The coherence pipeline allows the user to select different methods for each part of the pipeline. This, combined with the unknown variability of coherence scores, makes it difficult to meaningfully compare different coherence scores, or coherence scores between different models.&lt;/li&gt;&lt;li id=\&quot;4722\&quot;&gt;&lt;strong&gt;Reference corpus&lt;/strong&gt; \u2014 The choice of reference corpus is important. In cases where the probability estimates are based on the reference corpus, then a smaller or domain-specific corpus can produce misleading results when applied to set of documents that are quite different to the reference corpus.&lt;/li&gt;&lt;li id=\&quot;5a31\&quot;&gt;&lt;strong&gt;\u201cJunk\u201d topics&lt;/strong&gt; \u2014 Topic modeling provides no guarantees about the topics that are identified (hence the need for evaluation) and sometimes produces meaningless, or \u201cjunk\u201d, topics. These can distort the results of coherence calculations. The difficulty lies in identifying these junk topics for removal \u2014 it usually requires human inspection to do so. But involving humans in the process defeats the very purpose of using coherence, ie. to automate and scale topic model evaluation.&lt;/li&gt;&lt;/ul&gt;&lt;p id=\&quot;5cab\&quot;&gt;With these limitations in mind, what\u2019s the best approach for evaluating topic models?&lt;/p&gt;&lt;p id=\&quot;1a08\&quot;&gt;This article has hopefully made one thing clear \u2014 topic model evaluation isn\u2019t easy!&lt;/p&gt;&lt;p id=\&quot;6705\&quot;&gt;Unfortunately, there\u2019s no straight forward or reliable way to evaluate topic models to a high standard of human interpretability. Also, the very idea of human interpretability differs between people, domains and use cases.&lt;/p&gt;&lt;p id=\&quot;ae25\&quot;&gt;Nevertheless, the most reliable way to evaluate topic models is by using human judgment. But this takes time and is expensive.&lt;/p&gt;&lt;p id=\&quot;e576\&quot;&gt;In terms of quantitative approaches, coherence is a versatile and scalable way to evaluate topic models, notwithstanding its limitations.&lt;/p&gt;&lt;p id=\&quot;659b\&quot;&gt;In practice, you\u2019ll need to decide how to evaluate a topic model on a case-by-case basis, including which methods and process to use. A degree of domain knowledge and a clear understanding of the purpose of the model will help.&lt;/p&gt;&lt;p id=\&quot;7e42\&quot;&gt;The thing to remember is that some sort of evaluation can be important in helping you assess the merits of your topic model and how to apply it.&lt;/p&gt;&lt;p id=\&quot;d9cf\&quot;&gt;Topic model evaluation is an important part of the topic modeling process. This is because topic modeling offers no guidance on the quality of topics produced. Evaluation helps you assess how relevant the produced topics are, and how effective the topic model is.&lt;/p&gt;&lt;p id=\&quot;1dcb\&quot;&gt;Evaluating topic models is unfortunately difficult to do. There are various approaches available, but the best results come from human interpretation. This is a time-consuming and costly exercise.&lt;/p&gt;&lt;p id=\&quot;a922\&quot;&gt;Quantitative evaluation methods offer the benefits of automation and scaling. Coherence is the most popular of these and is easy to implement in widely used coding languages, such as with Gensim in Python.&lt;/p&gt;&lt;p id=\&quot;c34b\&quot;&gt;In practice, the best approach for evaluating topic models will depend on the circumstances. Domain knowledge, an understanding of the model\u2019s purpose, and judgment will help in deciding the best evaluation approach.&lt;/p&gt;&lt;p id=\&quot;db90\&quot;&gt;Topic modeling is an area of ongoing research \u2014 newer, better ways of evaluating topic models are likely to emerge.&lt;/p&gt;&lt;p id=\&quot;cd6c\&quot;&gt;In the meantime, topic modeling continues to be a versatile and effective way to analyze and make sense of unstructured text data. And with the continued use of topic models, evaluation will remain an important part of the process.&lt;/p&gt;&lt;p id=\&quot;6e32\&quot;&gt;[1] J. Chuang, C. D. Manning and J. Heer, &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;http://vis.stanford.edu/files/2012-Termite-AVI.pdf\&quot;&gt;Termite: Visualization Techniques for Assessing Textual Topic Models&lt;/a&gt; (2012), Stanford University Computer Science Department&lt;/p&gt;&lt;p id=\&quot;7dfa\&quot;&gt;[2] J. Chang et al, &lt;a rel=\&quot;noopener nofollow\&quot; href=\&quot;http://users.umiacs.umd.edu/~jbg/docs/nips2009-rtl.pdf\&quot;&gt;Reading Tea Leaves: How Humans Interpret Topic Models&lt;/a&gt; (2009), Neural Information Processing Systems&lt;/p&gt;&lt;/div&gt;&lt;/div&gt;&lt;/section&gt;&lt;/div&gt;&quot;, &quot;text&quot;: &quot;DATA SCIENCE EXPLAINED Here\u2019s what you need to know about evaluating topic models Topic models are widely used for analyzing unstructured text data, but they provide no guidance on the quality of topics produced. Evaluation is the key to understanding topic models. In this article, we\u2019ll look at what topic model evaluation is, why it\u2019s important and how to do it. Contents What is topic model evaluation? How to evaluate topic models Evaluating topic models \u2014 Human judgment Evaluating topic models \u2014 Quantitative metrics Calculating coherence using Gensim in Python Limitations of coherence How to evaluate topic models \u2014 Recap Conclusion Topic modeling is a branch of natural language processing that\u2019s used for exploring text data. It works by identifying key themes \u2014 or topics \u2014 based on the words or phrases in the data that have a similar meaning. Its versatility and ease-of-use have led to a variety of applications. Being a form of unsupervised learning, topic modeling is useful when annotated or labeled data isn\u2019t available. This is helpful, as the majority of emerging text data isn\u2019t labeled, and labeling is time-consuming and expensive to do. For an easy-to-follow, intuitive explanation of topic modeling and its applications, see this article. One of the shortcomings of topic modeling is that there\u2019s no guidance about the quality of topics produced. If you want to learn about how meaningful the topics are, you\u2019ll need to evaluate the topic model. In this article, we\u2019ll look at topic model evaluation, what it is and how to do it. It\u2019s an important part of the topic modeling process that sometimes gets overlooked. For a topic model to be truly useful, some sort of evaluation is needed to understand how relevant the topics are for the purpose of the model. Topic model evaluation is the process of assessing how well a topic model does what it is designed for. When you run a topic model, you usually do it with a specific purpose in mind. It may be for document classification, to explore a set of unstructured texts, or some other analysis. As with any model, if you wish to know how effective it is at doing what it\u2019s designed for, you\u2019ll need to evaluate it. This is why topic model evaluation matters. Evaluating a topic model can help you decide if the model has captured the internal structure of a corpus (a collection of text documents). This can be particularly useful in tasks like e-discovery, where the effectiveness of a topic model can have implications for legal proceedings or other important matters. More generally, topic model evaluation can help you answer questions like: Are the identified topics understandable? Are the topics coherent? Does the topic model serve the purpose it is being used for? Without some form of evaluation, you won\u2019t know how well your topic model is performing or if it\u2019s being used properly. Evaluating a topic model isn\u2019t always easy, however. If a topic model is used for a measurable task, such as classification, then its effectiveness is relatively straightforward to calculate (eg. measure the proportion of successful classifications). But if the model is used for a more qualitative task, such as exploring the semantic themes in an unstructured corpus, then evaluation is more difficult. In this article, we\u2019ll focus on evaluating topic models that do not have clearly measurable outcomes. These include topic models used for document exploration, content recommendation and e-discovery, amongst other use cases. Evaluating these types of topic models seeks to understand how easy it is for humans to interpret the topics produced by the model. Put another way, topic model evaluation is about the \u2018human interpretability\u2019 or \u2018semantic interpretability\u2019 of topics. There are a number of ways to evaluate topic models. These include: Human judgment Observation-based, eg. observing the top \u2019N\u2019 words in a topic Interpretation-based, eg. \u2018word intrusion\u2019 and \u2018topic intrusion\u2019 to identify the words or topics that \u201cdon\u2019t belong\u201d in a topic or document Quantitative metrics \u2014 Perplexity (held out likelihood) and coherence calculations Mixed approaches \u2014 Combinations of judgment-based and quantitative approaches Let\u2019s look at a few of these more closely. Observation-based approaches The easiest way to evaluate a topic is to look at the most probable words in the topic. This can be done in a tabular form, for instance by listing the top 10 words in each topic, or in other formats. One visually appealing way to observe the probable words in a topic is through Word Clouds. To illustrate, the following example is a Word Cloud based on topics modeled from the minutes of US Federal Open Market Committee (FOMC) meetings. The FOMC is an important part of the US financial system and meets 8 times per year. The following Word Cloud is based on a topic that emerged from an analysis of topic trends in FOMC meetings over 2007 to 2020. Word Cloud of \u201cinflation\u201d topic. Image by Author. Topic modeling doesn\u2019t provide guidance on the meaning of any topic, so labeling a topic requires human interpretation. In this case, based on the most probable words displayed in the Word Cloud, the topic appears to be about \u201cinflation\u201d. You can see more Word Clouds from the FOMC topic modeling example here. Beyond observing the most probable words in a topic, a more comprehensive observation-based approach called \u2018Termite\u2019 has been developed by Stanford University researchers. Termite is described as \u201ca visualization of the term-topic distributions produced by topic models\u201d [1]. In this description, \u2018term\u2019 refers to a \u2018word\u2019, so \u2018term-topic distributions\u2019 are \u2018word-topic distributions\u2019. Termite produces meaningful visualizations by introducing two calculations: A \u2018saliency\u2019 measure, which identifies words that are more relevant for the topics in which they appear (beyond mere frequencies of their counts) A \u2018seriation\u2019 method, for sorting words into more coherent groupings based on the degree of semantic similarity between them Termite produces graphs which summarize words and topics based on saliency and seriation. This helps to identify more interpretable topics and leads to better topic model evaluation. You can see example Termite visualizations here. Interpretation-based approaches Interpretation-based approaches take more effort than observation-based approaches but produce better results. These approaches are considered a \u2018gold standard\u2019 for evaluating topic models since they use human judgment to maximum effect. A good illustration of these is described in a research paper by Jonathan Chang and others (2009) [2] which developed \u2018word intrusion\u2019 and \u2018topic intrusion\u2019 to help evaluate semantic coherence. Word intrusion In word intrusion, subjects are presented with groups of 6 words, 5 of which belong to a given topic and one which does not \u2014 the \u2018intruder\u2019 word. Subjects are asked to identify the intruder word. To understand how this works, consider the group of words: [ dog, cat, horse, apple, pig, cow ] Can you spot the intruder? Most subjects pick \u2018apple\u2019 because it looks different to the others (all of which are animals, suggesting an animal-related topic for the others). Now, consider: [ car, teacher, platypus, agile, blue, Zaire ] Which is the intruder in this group of words? It\u2019s much harder to identify, so most subjects choose the intruder at random. This implies poor topic coherence. Topic intrusion Similar to word intrusion, in topic intrusion subjects are asked to identify the \u2018intruder\u2019 topic from groups of topics that make up documents. In this task, subjects are shown a title and a snippet from a document along with 4 topics. Three of the topics have a high probability of belonging to the document while the remaining topic has a low probability \u2014 the \u2018intruder\u2019 topic. As for word intrusion, the intruder topic is sometimes easy to identify and at other times not. The success with which subjects can correctly choose the intruder helps to determine the level of coherence. While evaluation methods based on human judgment can produce good results, they are costly and time-consuming to do. Moreover, human judgment isn\u2019t clearly defined and humans don\u2019t always agree on what makes a good topic. In contrast, the appeal of quantitative metrics is the ability to standardize, automate and scale the evaluation of topic models. Held out likelihood or perplexity A traditional metric for evaluating topic models is the \u2018held out likelihood\u2019, also referred to as \u2018perplexity\u2019. This is calculated by splitting a dataset into two parts \u2014 a training set and a test set. The idea is to train a topic model using the training set and then test the model on a test set which contains previously unseen documents (ie. held out documents). Likelihood is usually calculated as a logarithm, so this metric is sometimes referred to as the \u2018held out log-likelihood\u2019. The perplexity metric is a predictive one. It assesses a topic model\u2019s ability to predict a test set after having been trained on a training set. In practice, around 80% of a corpus may be set aside as a training set with the remaining 20% being a test set. Although the perplexity metric is a natural choice for topic models from a technical standpoint, it does not provide good results for human interpretation. This was demonstrated by research, again by Jonathan Chang and others (2009), which found that perplexity did not do a good job of conveying whether topics are coherent or not. When comparing perplexity against human judgment approaches like word intrusion and topic intrusion, the research showed a negative correlation. This means that as the perplexity score improves (ie. the held out log-likelihood is higher), the human interpretability of topics and topic mixes get worse (rather than better). The perplexity metric therefore appears to be misleading when it comes to the human understanding of topics and topic mixes. Are there better quantitative metrics than perplexity for evaluating topic models? Coherence One of the shortcomings of perplexity is that it does not capture context, ie. perplexity does not capture the relationship between words in a topic or topics in a document. The idea of semantic context is important for human understanding. To overcome this, approaches have been developed that attempt to capture context between words in a topic. They use measures such as the conditional likelihood (rather than the log-likelihood) of the co-occurrence of words in a topic. These approaches are collectively referred to as \u2018coherence\u2019. There\u2019s been a lot of research on coherence over recent years and as a result there are a variety of methods available. A useful way to deal with this is to set up a framework that allows you to choose the methods that you prefer. Such a framework has been proposed by researchers at AKSW. Using this framework, which we\u2019ll call the \u201ccoherence pipeline\u201d, you can calculate coherence in a way that works best for your circumstances (eg. based on availability of a corpus, speed of computation etc). The coherence pipeline offers a versatile way to calculate coherence. It is also what Gensim, a popular package for topic modeling in Python, uses for implementing coherence (more on this later). The coherence pipeline is made up of four stages: Segmentation Probability estimation Confirmation Aggregation These four stages form the basis of coherence calculations and work as follows: Segmentation sets up the word groupings that are used for pair-wise comparisons. Let\u2019s say that we wish to calculate the coherence of a set of topics. Coherence calculations start by choosing words within each topic (usually the most frequently occurring words) and comparing them with each other, one pair at a time. Segmentation is the process of choosing how words are grouped together for these pair-wise comparisons. Word groupings can be made up of single words or larger groupings. For single words, each word in a topic is compared with each other word in the topic. For 2-word or 3-word groupings, each 2-word group is compared with each other 2-word group, or each 3-word group is compared with each other 3-word group, and so on. Comparisons can also be made between groupings of different size, for instance single words can be compared with 2-word or 3-word groups. Probability estimation refers to the type of probability measure that underpins the calculation of coherence. To illustrate, consider the two widely used coherence approaches of UCI and UMass: UCI is based on point-wise mutual information (PMI) calculations. This is given by: PMI(wi,wj) = log[(P(wi,wj) + e) / P(wi).P(wj)], for words wi and wj and some small number e, and where P(wi) is the probability of word i occurring in a topic and P(wi,wj) is the probability of both words i and j appearing in a topic. Here, the probabilities are based on word co-occurrence counts. UMass caters for the order in which words appear and is based on the calculation of: log[(P(wi,wj) + e) / P(wj)], with wi, wj, P(wi) and P(wi,wj) as for UCI. Here, the probabilities are conditional, since P(wi|wj) = [(P(wi,wj) / P(wj)], which we know from Bayes\u2019 theorem. So, this approach measures how much a common word appearing within a topic is a good predictor for a less common word in the topic. Confirmation measures how strongly each word grouping in a topic relates to other word groupings (ie. how similar they are). There are direct and indirect ways of doing this, depending on the frequency and distribution of words in a topic. Aggregation is the final step of the coherence pipeline. It\u2019s a summary calculation of the confirmation measures of all the word groupings, resulting in a single coherence score. This is usually done by averaging the confirmation measures using the mean or median. Other calculations may also be used, such as the harmonic mean, quadratic mean, minimum or maximum. Coherence is a popular way to quantitatively evaluate topic models and has good coding implementations in languages such as Python (eg. Gensim). To see how coherence works in practice, let\u2019s look at an example. Gensim is a widely used package for topic modeling in Python. It uses Latent Dirichlet Allocation (LDA) for topic modeling and includes functionality for calculating the coherence of topic models. As mentioned, Gensim calculates coherence using the coherence pipeline, offering a range of options for users. The following example uses Gensim to model topics for US company earnings calls. These are quarterly conference calls in which company management discusses financial performance and other updates with analysts, investors and the media. They are an important fixture in the US financial calendar. The following code calculates coherence for the trained topic model in the example: Calculating the coherence score using Gensim The coherence method that was chosen in this example is \u201cc_v\u201d. This is one of several choices offered by Gensim. Other choices include UCI (\u201cc_uci\u201d) and UMass (\u201cu_mass\u201d). For more information about the Gensim package and the various choices that go with it, please refer to the Gensim documentation. Gensim can also be used to explore the effect of varying LDA parameters on a topic model\u2019s coherence score. This helps to select the best choice of parameters for the model. The following code shows how to calculate coherence for varying values of the alpha parameter in the LDA model: Investigating coherence by varying the alpha parameter The above code also produces a chart of the model\u2019s coherence score for different values of the alpha parameter: Topic model coherence for different values of the alpha parameter. Image by Author. This helps in choosing the best value of alpha based on coherence scores. In practice, you would also want to check the effect of varying other model parameters on the coherence score. You can see how this was done in the US company earning call example here. The overall choice of parameters would depend on balancing the varying effects on coherence, and also on judgment about the nature of the topics and the purpose of the model. Despite its usefulness, coherence has some important limitations. According to Matti Lyra, a leading data scientist and researcher, the key limitations are: Variability \u2014 The aggregation step of the coherence pipeline is typically calculated over a large number of word-group pairs. While this produces a metric (eg. mean of the coherence scores), there\u2019s no way of estimating the variability of the metric. This means that there\u2019s no way of knowing the degree of confidence in the metric. Hence, although we can calculate aggregate coherence scores for a topic model, we don\u2019t really know how well that score reflects the actual coherence of the model (relative to statistical noise). Comparability \u2014 The coherence pipeline allows the user to select different methods for each part of the pipeline. This, combined with the unknown variability of coherence scores, makes it difficult to meaningfully compare different coherence scores, or coherence scores between different models. Reference corpus \u2014 The choice of reference corpus is important. In cases where the probability estimates are based on the reference corpus, then a smaller or domain-specific corpus can produce misleading results when applied to set of documents that are quite different to the reference corpus. \u201cJunk\u201d topics \u2014 Topic modeling provides no guarantees about the topics that are identified (hence the need for evaluation) and sometimes produces meaningless, or \u201cjunk\u201d, topics. These can distort the results of coherence calculations. The difficulty lies in identifying these junk topics for removal \u2014 it usually requires human inspection to do so. But involving humans in the process defeats the very purpose of using coherence, ie. to automate and scale topic model evaluation. With these limitations in mind, what\u2019s the best approach for evaluating topic models? This article has hopefully made one thing clear \u2014 topic model evaluation isn\u2019t easy! Unfortunately, there\u2019s no straight forward or reliable way to evaluate topic models to a high standard of human interpretability. Also, the very idea of human interpretability differs between people, domains and use cases. Nevertheless, the most reliable way to evaluate topic models is by using human judgment. But this takes time and is expensive. In terms of quantitative approaches, coherence is a versatile and scalable way to evaluate topic models, notwithstanding its limitations. In practice, you\u2019ll need to decide how to evaluate a topic model on a case-by-case basis, including which methods and process to use. A degree of domain knowledge and a clear understanding of the purpose of the model will help. The thing to remember is that some sort of evaluation can be important in helping you assess the merits of your topic model and how to apply it. Topic model evaluation is an important part of the topic modeling process. This is because topic modeling offers no guidance on the quality of topics produced. Evaluation helps you assess how relevant the produced topics are, and how effective the topic model is. Evaluating topic models is unfortunately difficult to do. There are various approaches available, but the best results come from human interpretation. This is a time-consuming and costly exercise. Quantitative evaluation methods offer the benefits of automation and scaling. Coherence is the most popular of these and is easy to implement in widely used coding languages, such as with Gensim in Python. In practice, the best approach for evaluating topic models will depend on the circumstances. Domain knowledge, an understanding of the model\u2019s purpose, and judgment will help in deciding the best evaluation approach. Topic modeling is an area of ongoing research \u2014 newer, better ways of evaluating topic models are likely to emerge. In the meantime, topic modeling continues to be a versatile and effective way to analyze and make sense of unstructured text data. And with the continued use of topic models, evaluation will remain an important part of the process. [1] J. Chuang, C. D. Manning and J. Heer, Termite: Visualization Techniques for Assessing Textual Topic Models (2012), Stanford University Computer Science Department [2] J. Chang et al, Reading Tea Leaves: How Humans Interpret Topic Models (2009), Neural Information Processing Systems&quot; }</pre><p>Now let&#39;s combine the code and save the results to a CSV file.</p><pre>import requests<br>import feedparser<br>import csv<br>import json<br><br>url = &quot;https://api.promptapi.com/pipfeed&quot;<br><br>headers= {<br>  &quot;apikey&quot;: &quot;YOUR_API_KEY&quot;<br>}<br><br>#File we want to save the articles to<br>csv_file = &quot;articles.csv&quot;<br><br>def extract_article(article_url):<br>payload = article_url<br>response = requests.request(&quot;POST&quot;, url, headers=headers, data = payload)<br>status_code = response.status_code<br>result = response.text<br>return json.loads(result)<br><br><br>def save_to_css(extracted_articles):<br>keys = extracted_articles[0].keys()<br>with open(csv_file, &#39;w&#39;, newline=&#39;&#39;)  as output_file:<br>    dict_writer = csv.DictWriter(output_file, keys)<br>    dict_writer.writeheader()<br>    dict_writer.writerows(extracted_articles)<br><br><br>NewsFeed = feedparser.parse(&quot;https://towardsdatascience.com/feed&quot;)<br>extracted_articles = list()<br><br>print(&quot;Total entries found in feed: &quot;+ str(len(NewsFeed.entries)) +&quot;\n&quot;)<br>i =0<br>for entry in NewsFeed.entries:<br>print(str(i) + &quot;: Extracting url: &quot; + article_url)<br>extracted_article = extract_article(entry.link)<br>extracted_articles.append(extracted_article)<br><br>print(extracted_articles)<br>print(&quot;Saving articles to csv&quot;)<br>save_to_css(extracted_articles)</pre><p>The above code will extract all the articles that appear in the RSS feed for <a href="https://towardsdatascience.com/feed">https://towardsdatascience.com/feed</a> and save them to a CSV file called “articles.csv”.</p><p>You can now use this data for training models, analytics, and whatever you may feel like. Let us know what you think about the APIs and tutorial in the comments.</p><p><em>Originally published at </em><a href="https://pipfeed.com/2020/11/09/tutorial-extract-full-news-article-content-from-any-rss-feed-using-extract-api/"><em>https://pipfeed.com</em></a><em> on November 9, 2020.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=96da1c87fe61" width="1" height="1" alt=""><hr><p><a href="https://medium.com/pipfeed/tutorial-extract-full-news-article-content-from-any-rss-feed-using-extract-api-pipfeed-com-96da1c87fe61">[Tutorial] Extract full news article content from any RSS feed using Extract API — PipFeed.com</a> was originally published in <a href="https://medium.com/pipfeed">PipFeed</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How does Pipfeed’s recommendation Engine work? — PipFeed.com]]></title>
            <link>https://medium.com/pipfeed/how-does-pipfeeds-recommendation-engine-work-pipfeed-com-2f3c12546fb?source=rss-9dc6fbec4bfd------2</link>
            <guid isPermaLink="false">https://medium.com/p/2f3c12546fb</guid>
            <category><![CDATA[recommender-systems]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[artificial-intelligence]]></category>
            <category><![CDATA[news]]></category>
            <category><![CDATA[recommendation-system]]></category>
            <dc:creator><![CDATA[Shashank Agarwal]]></dc:creator>
            <pubDate>Tue, 13 Oct 2020 09:51:15 GMT</pubDate>
            <atom:updated>2020-11-11T05:22:00.807Z</atom:updated>
            <content:encoded><![CDATA[<h3>How does Pipfeed’s recommendation Engine work? — PipFeed.com</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*ySiYrjZSIUZC_fyT.jpg" /></figure><p>At Pipfeed we take price in creating a world-class recommendation engine and have spent a lot of time perfecting it. It is hard to create a recommendation engine and even hard to measure how well the algorithm is working. Here is how Pipfeed’s recommendation engine works.</p><p>The main feed is comprised of “Plugins”. Each of these plugins “competes” to add articles to the user’s feed.</p><h3>Pipfeed’s plugins</h3><p>Pipfeed has a plugin system internally and each of the plugins have different approach to add articles to the user’s main feed.</p><ul><li><strong>Subscriptions:</strong> Add articles from the blogs user has subscribed to</li><li><strong>Interests:</strong> Adds articles from user’s Interests on their profile</li><li><strong>Trending:</strong> Adds articles that are trending on PipFeed</li><li><strong>Past Liked Blogs</strong>: Adds articles from user’s previous most liked blogs</li><li><strong>Past Liked Interests:</strong> Adds articles from user’s past liked Interests</li><li><strong>Collaborative filtering:</strong> Adds articles similar to previously read articles</li><li><strong>Content-based filtering:</strong> Find users with similar reading behavior and then adds from that user’s past history</li><li>And more…</li></ul><h3>The Feedback Loop</h3><p>Pipfeed’s recommendation engine re-balances the importance given to each plugin based on user interactions. So we measure articles from which plugin is the user most interacting with and that plugin gets to put more articles in the user’s feed.</p><p>So the system keeps “rebalancing” itself over time and as the user uses the app more, the more personalized the feed becomes.</p><p><em>Originally published at </em><a href="https://pipfeed.com/2020/10/13/how-does-pipfeeds-recommendation-engine-work/"><em>https://pipfeed.com</em></a><em> on October 13, 2020.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2f3c12546fb" width="1" height="1" alt=""><hr><p><a href="https://medium.com/pipfeed/how-does-pipfeeds-recommendation-engine-work-pipfeed-com-2f3c12546fb">How does Pipfeed’s recommendation Engine work? — PipFeed.com</a> was originally published in <a href="https://medium.com/pipfeed">PipFeed</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Uploading docs in ElasticSearch using Java with async for super-fast processing with examples]]></title>
            <link>https://medium.com/system-camp/uploading-docs-in-elasticsearch-using-java-with-async-for-super-fast-processing-with-examples-1fd250067c84?source=rss-9dc6fbec4bfd------2</link>
            <guid isPermaLink="false">https://medium.com/p/1fd250067c84</guid>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[java]]></category>
            <category><![CDATA[elasticsearch]]></category>
            <dc:creator><![CDATA[Shashank Agarwal]]></dc:creator>
            <pubDate>Sat, 18 Jul 2020 06:56:26 GMT</pubDate>
            <atom:updated>2020-07-18T07:01:26.469Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/828/0*0XEkIWoLxyfx9dM2.png" /></figure><p>I wanted a quick and easy method to dump a lot of objects to my ElasticSearch endpoint and I did the rookie mistake of adding the “official” maven repository for ElasticSearch for JAVA.</p><p>That jar is so “huge”. It has pretty much all of server and client code. I tweeted about this but looks like there isn’t going to a fix soon.</p><p>Worry not, I was able to find a light-weight ElasticSearch client for JAVA called “Jest”. This is how you install the dependency</p><pre>&lt;dependency&gt;<br>    &lt;groupId&gt;io.searchbox&lt;/groupId&gt;<br>    &lt;artifactId&gt;jest&lt;/artifactId&gt;<br>    &lt;version&gt;6.3.1&lt;/version&gt;<br>&lt;/dependency&gt;</pre><h3>Initializing the client:</h3><p>I signed up for an account on “elastic.co”. The parent company that owns ElasticSearch. Using AWS ElasticSearch was really hard and had a lot of requirements &amp; steps. elastic.co was one click and they also had a free trial, so I went with it.</p><pre>JestClient getJestClient() {<br>    JestClientFactory factory = new JestClientFactory();<br>    factory.setHttpClientConfig(<br>        new HttpClientConfig.Builder(<br>            &quot;https://&lt;your-endpoint&gt;-central1.gcp.cloud.es.io:9243&quot;)<br>            .defaultCredentials(&quot;elastic&quot;, &quot;password&quot;)<br>            .build()<br>    );<br>    return factory.getObject();<br>  }</pre><p>The JestClient offers a lot of APIs but since I want to just dump a lot of documents to my endpoint, I used their bulk async methods. This is how I use it.</p><h3>First, create a list of items of “Index” items.</h3><pre>List&lt;Index&gt; indexList = new ArrayList&lt;&gt;();<br><br>String jsonString = objectMapper.writeValueAsString(feedDao);<br>Index index = new Index.Builder(jsonString).index(&quot;feeds&quot;).type(&quot;doc&quot;)<br>              .id(feedDao.getFeedId()).build();<br>indexList.add(index);</pre><p>My obejct is called “FeedDao” and I convert that to json using objectmapper and just saving it to an indexlist.</p><p>Then you need to create a Bulk request object like this. Make sure you have created your “index” already on ES. You can create index this simple API: <a href="https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-create-index.html">https://www.elastic.co/guide/en/elasticsearch/reference/current/indices-create-index.html</a></p><p>This is the Bulk Object using builder pattern:</p><pre>Bulk bulk = new Bulk.Builder()<br>     .defaultIndex(&quot;feeds&quot;)<br>     .defaultType(&quot;doc&quot;)<br>     .addAction(indexList)<br>     .build();</pre><p>The way to call an executeAsync is a bit different. You need to be able to handle the failure and successes. You can do whatever you want with the results.</p><pre>jestClient.executeAsync(bulk, new JestResultHandler&lt;JestResult&gt;() {<br>      @Override<br>      public void completed(JestResult result) {<br>        log.info(result);<br>      }<br><br>      @Override<br>      public void failed(Exception ex) {<br>        log.error(ex);<br>      }<br>    });</pre><p>That’s it. I hope this was useful to you. Feel free to bookmark this for later use of you can use the Search of this portal to find this later.</p><p>If there is an error somewhere, please let me know in the comments.</p><p><em>Originally published at </em><a href="https://system.camp/elasticsearch-dump-using-java-with-multi-threading-for-faster-processing/"><em>https://system.camp</em></a><em> on July 18, 2020.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1fd250067c84" width="1" height="1" alt=""><hr><p><a href="https://medium.com/system-camp/uploading-docs-in-elasticsearch-using-java-with-async-for-super-fast-processing-with-examples-1fd250067c84">Uploading docs in ElasticSearch using Java with async for super-fast processing with examples</a> was originally published in <a href="https://medium.com/system-camp">System.Camp</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Multi-threading in JAVA using “Executors”]]></title>
            <link>https://medium.com/system-camp/multi-threading-in-java-using-executors-de697e84e007?source=rss-9dc6fbec4bfd------2</link>
            <guid isPermaLink="false">https://medium.com/p/de697e84e007</guid>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[jvm]]></category>
            <category><![CDATA[threading-in-java]]></category>
            <category><![CDATA[java]]></category>
            <dc:creator><![CDATA[Shashank Agarwal]]></dc:creator>
            <pubDate>Fri, 17 Jul 2020 16:00:00 GMT</pubDate>
            <atom:updated>2020-07-18T07:03:07.278Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/828/0*fpfWAr_i_7So0hIX.png" /></figure><p>Multi-threading is not always super easy to implement. There is Runnable, Thread, and all sorts of frameworks/packages but we love the executors class to run our code in threads.</p><p>Here is the code:</p><p>A time-consuming function such as an API call, download files, etc.</p><pre>public Double someTimeConsumingFunction() throws InterruptedException {<br>  log.info(&quot;Thread started&quot;);<br>  Thread.sleep(1000);<br>  log.info(&quot;Thread finished&quot;);<br>  return Math.random();<br>}</pre><p>Our multi-threaded function</p><pre>public void threadsExample() {<br>  ExecutorService taskExecutor = Executors.newFixedThreadPool(25);<br>  List&lt;Future&lt;Double&gt;&gt; resultList = new ArrayList&lt;&gt;();<br><br>  for (int i = 0; i &lt; 10; i++) {<br>    Future&lt;Double&gt; result = taskExecutor<br>        .submit(new Callable&lt;Double&gt;() {<br>          public Double call() {<br>            try {<br>              return someTimeConsumingFunction();<br>            } catch (Exception e) {<br>              log.error(e);<br>            }<br>            return null;<br>          }<br>        });<br>    resultList.add(result);<br>  }<br>  taskExecutor.shutdown();<br>  try {<br>    log.info(&quot;Waiting for all threads to finish and terminate&quot;);<br>    taskExecutor.awaitTermination(Long.MAX_VALUE, TimeUnit.NANOSECONDS);<br>  } catch (InterruptedException e) {<br>    Sentry.capture(e);<br>  }<br>  log.info(&quot;Finished execution&quot;);<br>}</pre><p>As simple as that. I have actually bookmarked this page as I keep using this code again and again. Let me know in the comments if anything is unclear.</p><p><em>Originally published at </em><a href="https://system.camp/multi-threading-in-java-using-executors/"><em>https://system.camp</em></a><em> on July 17, 2020.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=de697e84e007" width="1" height="1" alt=""><hr><p><a href="https://medium.com/system-camp/multi-threading-in-java-using-executors-de697e84e007">Multi-threading in JAVA using “Executors”</a> was originally published in <a href="https://medium.com/system-camp">System.Camp</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Calling WordPress REST APIs to create users, articles, posts, etc. with examples using JAVA]]></title>
            <link>https://medium.com/system-camp/calling-wordpress-rest-apis-to-create-users-articles-posts-etc-with-examples-using-java-c44f508df07d?source=rss-9dc6fbec4bfd------2</link>
            <guid isPermaLink="false">https://medium.com/p/c44f508df07d</guid>
            <category><![CDATA[wordpress]]></category>
            <category><![CDATA[api]]></category>
            <category><![CDATA[java]]></category>
            <category><![CDATA[jvm]]></category>
            <category><![CDATA[system]]></category>
            <dc:creator><![CDATA[Shashank Agarwal]]></dc:creator>
            <pubDate>Thu, 16 Jul 2020 14:48:39 GMT</pubDate>
            <atom:updated>2020-07-18T07:06:32.133Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/820/0*l-75fcbVxJvywTkI.png" /></figure><p>Wordpress has an amazing REST API that lets you do pretty much anything that you would need. You can add users, add articles, create tags, create categories etc.</p><p>My backend system is in JAVA and here is how you can do various things in WordPress using JAVA:</p><p>For this we are going to use this really good package: <a href="https://github.com/Afrozaar/wp-api-v2-client-java">https://github.com/Afrozaar/wp-api-v2-client-java</a></p><pre>&lt;dependency&gt;<br>  &lt;groupId&gt;com.afrozaar.wordpress&lt;/groupId&gt;<br>  &lt;artifactId&gt;wp-api-v2-client-java&lt;/artifactId&gt;<br>  &lt;version&gt;4.8.3&lt;/version&gt;<br>  &lt;exclusions&gt;<br>    &lt;exclusion&gt;<br>      &lt;groupId&gt;ch.qos.logback&lt;/groupId&gt;<br>      &lt;artifactId&gt;logback-classic&lt;/artifactId&gt;<br>    &lt;/exclusion&gt;<br>    &lt;exclusion&gt;<br>      &lt;groupId&gt;commons-beanutils&lt;/groupId&gt;<br>      &lt;artifactId&gt;commons-beanutils-core&lt;/artifactId&gt;<br>    &lt;/exclusion&gt;<br>    &lt;exclusion&gt;<br>      &lt;groupId&gt;com.fasterxml.jackson.jaxrs&lt;/groupId&gt;<br>      &lt;artifactId&gt;jackson-jaxrs-json-provider&lt;/artifactId&gt;<br>    &lt;/exclusion&gt;<br>  &lt;/exclusions&gt;<br>&lt;/dependency&gt;</pre><p>P.S. I have removed some logging dependencies as they made the jar too big and it was also adding a lot of debug logs that we really don’t need.</p><h3>Creating the Wordpress Client</h3><pre>Wordpress getWordpressClient() {<br>    String baseUrl = &quot;wp-url/wp-json/&quot;;<br>    String username = &quot;admin-email&quot;;<br>    String password = &quot;admin-password&quot;;<br><br>    return ClientFactory<br>      .fromConfig(ClientConfig.of(baseUrl, username, password,<br>          false,<br>          true));<br>}</pre><h3>Creating a Tag</h3><pre>Term term = new Term();<br>term.setName(&quot;tag1);<br>term = wordpress.createTag(term);</pre><h3>Creating a Category</h3><pre>Term term = new Term();<br>term.setName(category);<br>term.setSlug(category);<br>Term cat = wordpress.createCategory(term);</pre><p>The response object will fail if the slug already exists, so its a good idea to wrap this in a try-catch statement.</p><h3>Creating a Post/Article</h3><pre>Post post = PostBuilder.aPost().build();<br>post.setTitle(TitleBuilder.aTitle().withRendered(&quot;title).build());<br>post.setExcerpt(ExcerptBuilder.anExcerpt().withRendered(&quot;description&quot;).build());<br>post.setContent(ContentBuilder.aContent().withRendered(&quot;summary&quot;).build());<br>post.setDate(Instant.now().toString());<br>post.setSlug(&quot;test-article&quot;);<br>post.setAuthor(authorId);<br><br>//Add IDs of tags that you want to add<br>post.setTagIds(tags);<br><br>//Add IDs of categories that you want to add<br>post.setCategoryIds(categoryIds);<br><br>createdPost = wordpress.createPost(post, PostStatus.publish);</pre><h3>Creating a User</h3><pre>User user = new User();<br>user.setEmail(&quot;test@testuser.com&quot;);<br>user.setName(&quot;Name&quot;);<br>user.setSlug(&quot;test&quot;);<br>user.setNickname(name);<br>AvatarUrls avatarUrls = new AvatarUrls();<br>avatarUrls.set96(&quot;user-image-url&quot;);<br>avatarUrls.set48(&quot;user-image-url&quot;);<br>avatarUrls.set24(&quot;user-image-url&quot;);<br>user.setAvatarUrls(avatarUrls);<br>try {<br>  user = wordpress.createUser(user, name, Utils.getAlphaNumericString(20));<br>} catch (UsernameAlreadyExistsException e) {<br>  log.error(e);<br>} catch (UserEmailAlreadyExistsException e) {<br>  log.error(e);<br>}</pre><pre>Media media = new Media();<br>media.setCaption(&quot;caption&quot;);<br>media.setDescription(&quot;description&quot;);<br>media.setAltText(&quot;alt-text&quot;);<br>Resource resource;<br><br>//Load images from a URL, save them local(/tmp) and then upload to<br>// wordpress<br><br>BufferedImage image;<br>try {<br>  String imagePath = Utils.read(&quot;urlToImage&quot;);<br>  File targetFile = new File(imagePath);<br>  <br>  //Only upload image if size is less than 4MB<br>  if ((double) targetFile.length() / (1024 * 1024) &lt; 4.0))) {<br>    resource = new FileSystemResource(targetFile);<br>    media1 = wordpress.createMedia(media, resource);<br>  }<br>} catch (Exception e) {<br>  log.error(e);<br>}</pre><h3>Uploading a Media/Image</h3><pre>Media media = new Media();<br>media.setCaption(&quot;caption&quot;);<br>media.setDescription(&quot;description&quot;);<br>media.setAltText(&quot;alt-text&quot;);<br>Resource resource;</pre><pre>//Load images from a URL, save them local(/tmp) and then upload to<br>// wordpress</pre><pre>BufferedImage image;<br>try {<br>  String imagePath = Utils.read(&quot;urlToImage&quot;);<br>  File targetFile = new File(imagePath);<br>  <br>  //Only upload image if size is less than 4MB<br>  if ((double) targetFile.length() / (1024 * 1024) &lt; 4.0))) {<br>    resource = new FileSystemResource(targetFile);<br>    media1 = wordpress.createMedia(media, resource);<br>  }<br>} catch (Exception e) {<br>  log.error(e);<br>}</pre><p>After creating a “featured image”, WordPress will not make the image available for few seconds to a few minutes. Hence you can’t just add that features image to a post. We overcame this by directly adding an entry into the mysql database.</p><p>This is the code to add a featured Image</p><pre>public void setFeaturedImage(Post post, Media media) {<br>    String sqlQuery = &quot;INSERT INTO `wp_postmeta` (`meta_id`, `post_id`, `meta_key`, `meta_value`) &quot;<br>        + &quot;VALUES (NULL, &quot;<br>        + &quot;&#39;&quot; + post.getId() + &quot;&#39;, &quot;<br>        + &quot;&#39;_thumbnail_id&#39;, &quot;<br>        + &quot;&#39;&quot; + media.getId() + &quot;&#39;)&quot;;<br>    log.info(sqlQuery);<br>    runSqlQuery(sqlQuery);<br>  }</pre><p>Hope you guys find this helpful. Let me know if you find any errors in the code.</p><p><em>Originally published at </em><a href="https://system.camp/adding-users-articles-to-wordpress-using-java/"><em>https://system.camp</em></a><em> on July 16, 2020.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c44f508df07d" width="1" height="1" alt=""><hr><p><a href="https://medium.com/system-camp/calling-wordpress-rest-apis-to-create-users-articles-posts-etc-with-examples-using-java-c44f508df07d">Calling WordPress REST APIs to create users, articles, posts, etc. with examples using JAVA</a> was originally published in <a href="https://medium.com/system-camp">System.Camp</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[SEO is killing good content and it needs to stop!]]></title>
            <link>https://medium.com/pipfeed/seo-is-killing-good-content-and-it-needs-to-stop-24290894dc53?source=rss-9dc6fbec4bfd------2</link>
            <guid isPermaLink="false">https://medium.com/p/24290894dc53</guid>
            <category><![CDATA[content-marketing]]></category>
            <category><![CDATA[google]]></category>
            <category><![CDATA[reading]]></category>
            <category><![CDATA[seo]]></category>
            <category><![CDATA[writing]]></category>
            <dc:creator><![CDATA[Shashank Agarwal]]></dc:creator>
            <pubDate>Mon, 13 Apr 2020 13:12:52 GMT</pubDate>
            <atom:updated>2020-04-13T13:12:52.778Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Yo1pNNdzxJU16W6Ci60cUg.png" /><figcaption>SEO is killing good content</figcaption></figure><p>We have access to an infinite amount of information in this modern age, practically you can search for anything you want. And with this comes a need to filter out the noise to ensure that the appropriate user gets to the appropriate content and vice versa. Search Engine Optimization (SEO) seeks to make the quest as user-friendly as possible. However, if you want to create content then you must know the significance of knowledge about how certain algorithms and requirements work to move the content to the top. Top blogs use the technique of SEO to get them highly ranked. But as we focus on the SEO more than the quality of content, it seems that we are trying to please the robots instead of humans.</p><h3>Evolution of SEO:</h3><p>In the year 1945 search engines were the first thing as a way to store information and make it available to the masses. Big names, like Yahoo and Google, came on the table in the early 90s and more and more companies have been accused of tricking the easy search system to get their content to the top. Examples of these crimes include; broken links; keyword filling; and content farms (too frequent low-quality posts). That is why SEO was born.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/639/0*sobZVc6wx3laOmLs.jpg" /></figure><p>In the past, content creators used to focus on the theme and how to engage their readers. This meant delivering original content that wasn’t already everywhere and, where needed, presenting it in a style that was original to them. But all of this changed after Google took charge of the creation and delivery of content around the world. Now, they have learned to think SERP first instead of thinking subject. How will their content be found amongst people? What words do they need to cover? How do they use the word hyperlink anchor text to train Google about the terms of the search it will link with those websites? Now the top blogs are only those which are SEO optimized.</p><p>Google is not to be entirely blamed for it. Processing the knowledge of the world and then presenting it to several items at a time is not a trivial job, particularly if you have hundreds of marketing pros learning to play the game to place their material above all others. But it leaves content creators struggling to second guess how their content will be viewed by Big G. This ensures that what might be good content is tainted with hidden agendas, and this leaves us with an Internet that is more filled with trash than it is valuable content.</p><p>Through time, SEO laws have become more complex and more than 200 standards are now to be met. But are those general scales going to allow the top quality content?</p><h3>How SEO causes dilution of web integrity?</h3><p>Most of the <a href="https://pipfeed.com/top-articles/">top blogs</a> contain SEO focused content and it dilutes web integrity but how?</p><p>First of all, it is much easier to create SEO optimized content because most of the content creators steal the content from the other top blogs related to the topic and give it the name of inspiration. Since the same content is written repeatedly with a slight difference nobody comes to know who wrote it first. Secondly, the primary aim for an SEO-focused blog post is to connect a site with a common search subject, which means it’s a subject that has already discussed elsewhere ad infinitum. Moreover, SEO does not promote detailed blog posts and suggests limiting blogs to minimum words that’s why most of the top blogs are not more than five hundred words. The content covered in ten blogs on google can be found collectively in a single book.</p><h3>Can good quality content reach people without SEO?</h3><p>So from the above discussion, it is clear that SEO compromises the quality of the content but what is the solution to this? Since ranking your blog on top in the Google search results ranking is necessary for making your blog reach maximum people and consequently for making it a top blog. You don’t need to worry about it anymore since Pipfeed.com is here to help you.</p><h3>What is Pipfeed and how it works?</h3><p><a href="https://pipfeed.com/">Pipfeed</a> is an article reading application based on algorithms of artificial intelligence. We learn from user experiences and can decide which articles the user would like to read and in particular which articles the user wouldn’t like to see.</p><p>We scans hundreds of articles each day and uses Artificial Intelligence to find relevant articles for each user. It is like having a magazine that is curated, edited and published just for you. We not only makes various readers around the world to access your content but also enables them to interact with you and reach out to you.</p><p>Most apps only focus on news and not articles. So Pipfeed is the best app to get your blogs published and make it reach out to maximum people. Use Pipfeed for your blogs and they will become top blogs.</p><h3>Conclusion:</h3><p>Writing is moving away from delivering a message, making a point or telling a story but now it’s all about traffic and clickbait. The good thing about this is that as the epidemic rises, so does the understanding of it among cultures. People are more informed about ‘what they read on the internet’ and companies are innovating new user interaction strategies. Overall, writers seem to be becoming more educated but less imaginative. Less first, but no doubt more roped-up. However, you can get your blogs featured as top blogs with the help of Pipfeed which will help you get rid of the tension about SEO and focus on the quality of the content.</p><p>So what are you waiting for? <a href="https://shashank915073.typeform.com/to/qFCVy1">Submit your</a> <a href="https://shashank915073.typeform.com/to/qFCVy1">blog</a> today on Pipfeed.com and within a few days, your blog will become one of the top blogs among readers on Pipfeed. Many content writers are using it and now they don’t have to worry about SEO while creating content, they just focus on the quality of content. Now you don’t have to think about common search terms or keywords, anchor text or word count while you are writing. We will let you concentrate on the content. We hope so, Google will upgrade its algorithm too since SEO is killing good content and it needs to stop!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=24290894dc53" width="1" height="1" alt=""><hr><p><a href="https://medium.com/pipfeed/seo-is-killing-good-content-and-it-needs-to-stop-24290894dc53">SEO is killing good content and it needs to stop!</a> was originally published in <a href="https://medium.com/pipfeed">PipFeed</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[3 Big Problems with Social Media as a News Source (and the Solution)]]></title>
            <link>https://medium.com/pipfeed/3-big-problems-with-social-media-as-a-news-source-and-the-solution-29a28506bf35?source=rss-9dc6fbec4bfd------2</link>
            <guid isPermaLink="false">https://medium.com/p/29a28506bf35</guid>
            <category><![CDATA[blog]]></category>
            <category><![CDATA[social-media]]></category>
            <category><![CDATA[social]]></category>
            <category><![CDATA[fake-news]]></category>
            <category><![CDATA[news]]></category>
            <dc:creator><![CDATA[Shashank Agarwal]]></dc:creator>
            <pubDate>Sat, 11 Apr 2020 11:06:42 GMT</pubDate>
            <atom:updated>2020-04-11T11:06:42.203Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jc5jF8ozfKFd45TiHfEm4g.png" /></figure><p>It’s no surprise that social media platforms are serving as virtual newsstands. If news is meant to travel fast than there’s no faster informational highway than social media. However, there are three fundamental concerns about consuming news from social feeds. The articles are often limited to your friends’ circle, not relevant to your interests, and come from untrusted sources.</p><p>Thankfully, there is a new way to retake control of your news feed without reviving newspaper subscriptions.</p><h3>3 Main Reasons You Should Rethink Social Media as a News Source</h3><p>There are plenty of reasons you should turn away from social media for news and information, but here are the top three that should be enough to convince you to look elsewhere.</p><h3>News Limited to Your Friends’ Circle</h3><p>Regardless of how many friends, follows, or followers you have online, social media platforms rely heavily on shared information. What appears in your social media feed, therefore, is greatly controlled by your friends and follows. Instead of controlling your news feed, you are at the mercy of your friends clicking ‘Share’.</p><p>Social media is great for connecting you with like-minded people, but it does fall short in broadening your horizons. It also falls short in challenging your intellect further with the same old basic information circulating your social feeds. You need to be able to easily target new ideas and dive deeper into your interests.</p><h3>Articles Not Relevant to Your Interests</h3><p>You probably have a lot in common with your social media friends, but articles of special interest to you are probably far and few between. Sure, there’s plenty of posts on parenting, exercise, and food, but is that all there is to read about? What if you want to go beyond the basics of those topics? For instance, you want to learn more about healthy food but only want <a href="https://pipfeed.com/2020/03/18/top-10-health-blogs-to-follow/">articles for picky eaters</a>. There is a blog for that! But you’re likely not going to come across it on social media.</p><p>And what if you have less-mainstream interests you want to learn more about? Let’s say you are more interested in <a href="https://pipfeed.com/2020/04/03/if-you-code-then-you-need-to-read-these-articles/">articles about coding</a> and <a href="https://pipfeed.com/2020/03/04/top-10-artificial-intelligence-blogs-to-follow/">artificial intelligence</a> than what exercises will tighten your buns. Unless the majority of your friends share your interest, your social media feed will rarely offer relevant content.</p><h3>Untrusted Sources</h3><p>There’s a reason #FakeNews is always trending. Social media is chock full of articles that are chock full of false information. And the inaccuracies are not limited to traditional news and politics. There are countless “experts” on social media that promote their opinions as truth. Not to mention the trolls and pranksters who purposely spread fake news. And unfortunately, everybody is guilty of sharing articles before validating their authenticity.</p><h3>A Better Information and News Source than Social Media</h3><p>The obvious solution to consuming higher quality information is to go directly to sources you trust and are interested in. But unfortunately, that takes quite a lot of digging and jumping between apps, websites, and blogs. Thankfully, there’s a more user-friendly solution.</p><p>Like you, we were concerned and wanted a better way to connect with blogs, news, and our hobbies. So, we developed Pipfeed. In the same way your favorite music app customizes your music based on your interests, Pipfeed customizes your reading material.</p><p><a href="https://pipfeed.com/">Pipfeed</a> is a personal reading app that connects you with articles and blog posts based on your interests. Our AI technology recommends the top blogs and delivers the best articles straight to your personalized Pipfeed. Visit our website to <a href="https://pipfeed.com/">download the free app</a> today.</p><p>Check out the <a href="https://pipfeed.com/top-articles/">Top Articles</a> on PipFeed today.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=29a28506bf35" width="1" height="1" alt=""><hr><p><a href="https://medium.com/pipfeed/3-big-problems-with-social-media-as-a-news-source-and-the-solution-29a28506bf35">3 Big Problems with Social Media as a News Source (and the Solution)</a> was originally published in <a href="https://medium.com/pipfeed">PipFeed</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Top 10 Food Blogs that will Tickle your Taste Buds]]></title>
            <link>https://medium.com/pipfeed/top-10-food-blogs-that-will-tickle-your-taste-buds-82ba747a0e9a?source=rss-9dc6fbec4bfd------2</link>
            <guid isPermaLink="false">https://medium.com/p/82ba747a0e9a</guid>
            <category><![CDATA[food]]></category>
            <category><![CDATA[pipfeed]]></category>
            <category><![CDATA[eating]]></category>
            <category><![CDATA[top-10]]></category>
            <category><![CDATA[blog]]></category>
            <dc:creator><![CDATA[Shashank Agarwal]]></dc:creator>
            <pubDate>Fri, 10 Apr 2020 11:27:43 GMT</pubDate>
            <atom:updated>2020-04-10T11:27:43.611Z</atom:updated>
            <content:encoded><![CDATA[<p>Are you a hardcore food-lover? Do you love to experiment with new dishes in your kitchen? If yes, then we have brought a list of the top food blogs that you ought to follow.</p><h3><a href="http://dishingupthedirt.com/">Dishing up the dirt</a></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/828/0*9TR1KwkKPPdoAb9W.jpeg" /></figure><p>Whether you have friends coming over or simply want to enjoy a meal with your family, this blog has it all.</p><p>Andrea Bemis is a veggie lover and her love for food stems led her to starting this blog. Whatever your favorite vegetable is, you will find a lip smacking recipe on this blog. Her Moroccan carrot soup with spiced chickpea croutons is a big hit among her followers.</p><h3><a href="https://pinchofyum.com/">Pinch of yum</a></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*FxTl0pcZFOvhjRg4.jpg" /></figure><p>Are you looking for some yummy recipes? Then head straight to this blog started by a teacher turned blogger. Follow the Pinch of yum blog for some finger licking recipes and you will not be disappointed.</p><p>Whether its breakfast, lunch, dinner, or snacks, this page has hundreds of recipes to satiate your taste buds.</p><h3><a href="https://www.budgetbytes.com/">Budget Bytes</a></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/612/0*lL-xdgWG7dOj40W9.jpg" /></figure><p>Budget-friendly and well-written are the two adjectives that beautifully describe this blog. If you want to enjoy tasty food without burning a hole in your pocket, then Budget bytes is your savior.</p><p>With simple and easily available ingredients, you can make tasty food the inexpensive way.</p><h3><a href="https://damndelicious.net/">Damn Delicious</a></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Br5vMivN6is003_4.jpg" /></figure><p>Chungah started this blog as a hobby and it has now turned into a full-time job for her. With the help of simple and fresh ingredients, she creates several mouth-watering dishes that are loved by her readers all over the world.</p><h3><a href="https://minimalistbaker.com/">Minimalist baker</a></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/819/0*fg5_aPzxHFmacOkG.jpg" /></figure><p>If you are looking for healthy and gluten-free recipes then this blog has got you covered. The blog has some of the most flavorful and simple to make recipes that make it a hit with the followers.</p><h3><a href="https://www.gimmesomeoven.com/">Gimme some oven</a></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/370/0*bZh8AbVLzmKODxr2.jpeg" /></figure><p>Gimme some oven is a wonderful blog that will provide you with some easy to prepare and tasty food recipes. You will also find a lifestyle and DIY section on this blog. Ali Ebright started this blog to collect all her recipes in one place and today it is one of the well-known food blogs.</p><h3><a href="https://cookieandkate.com/">Cookie and Kate</a></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/620/0*PvfFJm7wgo_6hWLi.jpg" /></figure><p>If you are not following this blog, then you are missing out on some really delicious vegetarian recipes. You will find some interesting recipes that can be made with real food yet turn out absolutely scrumptious.</p><h3><a href="https://www.loveandlemons.com/">Love n Lemons</a></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/815/0*_LPSuVhPei_zbiU0.jpg" /></figure><p>You will find all colorful food with a touch of lemon on this page. There are several vegetarian recipes that will attract your attention and tickle your taste buds. Head on to the blog for some wonderful and flavorsome recipes.</p><h3><a href="https://sallysbakingaddiction.com/">Sally’s baking addiction</a></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/364/0*yUaVzMf_L2h33cIn.jpeg" /></figure><p>The Sally’s baking addiction is dedicated to all baking fans. From cookies to cakes you will find the most alluring baking recipes on this page that you cannot resist.</p><p>This food blogger has 3 best-selling cook books in her kitty too.</p><h3><a href="https://www.sproutedkitchen.com/">Sprouted Kitchen</a></h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/819/0*lbwlXprwQPN7dt1A.jpeg" /></figure><p>This food blog is perfect for all those who need family recipe ideas. There is a vast variety of recipes for your family. From appetizers to bread, and dessert to baby food recipes, this is the ultimate food blog to follow.</p><p>These blogs will provide you with some delicious and healthy recipes. If food is your bae you must visit these blogs for fun and new food recipes.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=82ba747a0e9a" width="1" height="1" alt=""><hr><p><a href="https://medium.com/pipfeed/top-10-food-blogs-that-will-tickle-your-taste-buds-82ba747a0e9a">Top 10 Food Blogs that will Tickle your Taste Buds</a> was originally published in <a href="https://medium.com/pipfeed">PipFeed</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>