Evaluations of LLM applications is a big buzzword right now... but when do you really need new tools? Our latest blog post from Wenzhe Xue cuts through the noise to show with examples how built-in libraries such as pytest are often enough to get started. As complexity grows along the following dimensions, we're here to help! Metric based ➡ Human review Off the shelf eval or LLM as a judge ➡ Custom eval models trained on your data Offline ➡ Online, realtime https://lnkd.in/gGb3Sjah
Arjun Bansal’s Post
More Relevant Posts
-
Not sure how to start evaluating your LLM apps? 🤔 Check out our blog to learn the best practices! 💡 https://lnkd.in/gGb3Sjah
Evaluations of LLM applications is a big buzzword right now... but when do you really need new tools? Our latest blog post from Wenzhe Xue cuts through the noise to show with examples how built-in libraries such as pytest are often enough to get started. As complexity grows along the following dimensions, we're here to help! Metric based ➡ Human review Off the shelf eval or LLM as a judge ➡ Custom eval models trained on your data Offline ➡ Online, realtime https://lnkd.in/gGb3Sjah
Pytest is All You Need
arjunbansal.substack.com
To view or add a comment, sign in
-
𝐂𝐨𝐦𝐩𝐥𝐞𝐭𝐞𝐝 𝐝𝐚𝐲 𝟑𝟓, 𝟑𝟔:- 𝐓𝐢𝐭𝐥𝐞:- "𝐃𝐒𝐀 𝐋𝐞𝐜𝐭𝐮𝐫𝐞 𝟑𝟓,𝟑𝟔 𝐁𝐢𝐧𝐚𝐫𝐲 𝐒𝐞𝐚𝐫𝐜𝐡 𝐏𝐫𝐨𝐛𝐥𝐞𝐦 𝐒𝐨𝐥𝐯𝐢𝐧𝐠 𝟐 𝐚𝐧𝐝 𝟑" Greetings everyone, We delved deeper into the intricacies of binary search problem-solving techniques. Led by Mohammad F., the class was an enriching experience where we gained insights into identifying scenarios where binary search is the optimal approach. Furthermore, we explored various problems along with their time complexities, enhancing our understanding of this fundamental algorithm. 𝐊𝐞𝐲 𝐋𝐞𝐚𝐫𝐧𝐢𝐧𝐠𝐬:- Comprehensive review of concepts covered in the previous session. 𝐏𝐫𝐨𝐛𝐥𝐞𝐦𝐬 𝐃𝐢𝐬𝐜𝐮𝐬𝐬𝐞𝐝:- 1) Determining which element in an unsorted array of unique elements can be efficiently searched using binary search. 2) Employing a modified binary search technique, leveraging random functions, to locate an element within a sorted array. 3) Solving the "Koko Eating Bananas" problem from Leetcode Challenge, demonstrating the practical application of binary search in solving real-world problems efficiently. 4) "Capacity to Ship Packages within D Days" from Leetcode Challenge, which challenged us to optimize the shipping process by utilizing binary search techniques. 5) "Appy and Balloons" from CodeChef, a captivating problem that showcased the versatility of binary search in solving algorithmic challenges. Through these problem-solving exercises, we honed our skills in applying binary search algorithms effectively, thereby reinforcing our grasp of this essential concept in data structures and algorithms. Looking forward to our continued exploration and mastery of advanced topics in the upcoming sessions. #dsa #algorithms #devloper LearnYard Technologies FZ-LLC #consistencyiskey
To view or add a comment, sign in
-
Aspiring Software Developer II Problem Solver II DSA II Full Stack Developer II 300+ Leetcode GFG Problem II Student at Kamla Nehru Institute Of Technology II Ex Web Developer intern at CodSoft
🌟 Day 46 of the 75-day LeetCoding Challenge! 🎉 🚀 Problem: 35. Search Insert Position 🔍 Level Description : Easy ⚡Link to Problem : https://lnkd.in/gcK9Y6HJ 💡Approach || 🕒 O(logn) || 💾O(1) --Algorithm: 1. Repeat until i is less than or equal to j: 2. Calculate mid as the middle index between i and j: mid = (i + j) / 2 3. Compare nums[mid] with target: [i]. If nums[mid] is equal to target, return mid. [ii]. If nums[mid] is greater than target, adjust the search range to the left half by setting j to mid - 1. [iii]. If nums[mid] is less than target, adjust the search range to the right half by setting i to mid + 1. 4. Return the Insert Position: [i]. If the target is not found during the binary search, return i as the insert position. _______________________________________________________________ #75daysCodeChalleng #leetcode #algorithm #datastructures #codingjourney #linkedincodingcommunity #coding #codingchallenge
To view or add a comment, sign in
-
NIT Jamshedpur'26 || LeetCode 1722(max) || Codeforces 1110(max) || 𝟓⭐ HackerRank (C++, Problem Solving) || 2⭐ Codechef 1472 (max)
🌟 Day 71 of the 75-day LeetCoding Challenge! 🎉 🚀 Problem: 3137. Minimum Number of Operations to Make Word K-Periodic 🔍 Level Description: Medium ⚡Link to Problem: https://lnkd.in/g2KBjn7q 💡Approach || 🕒 O(n) || 💾O(n/k) --Algorithm: 1. Substring Extraction and Frequency Counting: -Traverse through the word string using a sliding window approach with a window size k. -Extract substrings of length k from the word starting at positions i, where i ranges from 0 to n-k (inclusive), where n is the length of the word. -Use a map<string, int> (m) to count the frequency of each extracted substring. 2. Determine Total Possible Periods: -Calculate the total number of complete k-length substrings (total) that can be formed from the word string. 3. Find the Most Frequent Substring: -Traverse through the map m to identify the substring (it.first) that appears most frequently (it.second). -Update mx to store the maximum frequency found. 4. Calculate Minimum Operations: -The minimum operations required to transform the word into a periodic string with period k can be determined as: -Subtract the maximum frequency (mx) of any substring from the total number of possible k-length substrings (total). 5. Return Result: -Return the calculated minimum number of operations as the result. __________________________________________________________________ 🤝Connect with me: https://lnkd.in/gkydBqEu #75daysCodeChalleng #leetcode #algorithm #datastructures #codingjourney #linkedincodingcommunity #coding #codingchallenge
To view or add a comment, sign in
-
Very interesting feature from the llama-cpp library: using a context- free to constraint the token sampling of a large language model. This means we can now generate code without syntax errors using an open source model like Llama-2! I just briefly wrote about how to use this new feature: https://lnkd.in/eUeukYEB
Testing out Llama Cpp Grammar constraint based Sampling
medium.com
To view or add a comment, sign in
-
I recently tackled the "Two Sum II - Input array is sorted" problem on LeetCode, and I wanted to share my approach with you all! The problem: Given an array of integers that is already sorted in ascending order, find two numbers such that they add up to a specific target number. The catch? You need to return the indices of the two numbers as an array, where index1 must be less than index2. Here's a brief overview of how I solved it: 1.Two-Pointer Technique : Leveraging the fact that the array is sorted, I utilized the two-pointer technique. By initializing two pointers at the start and end of the array, I could efficiently narrow down the search space. 2. Iterative Approach: With one pointer starting from the beginning and another from the end, I checked the sum of the elements pointed to by these pointers. If the sum was equal to the target, I returned the indices. Otherwise, I adjusted the pointers accordingly based on whether the sum was too small or too large. 3. Optimized Solution: By iteratively adjusting the pointers, I could efficiently find the pair of numbers that summed up to the target while maintaining the sorted order of the array. Link for the problem : https://lnkd.in/gX3JZMJD Link for my submission : https://lnkd.in/g4X43BpK I encourage you to give it a try and share your thoughts. Let's keep learning and growing together! 💡 #LeetCode #ProblemSolving #Algorithm #TwoPointer #CodingChallenge #EgyptianDevelopers #AlgorithmSolving
To view or add a comment, sign in
-
🚀 Excited to share a solution to the "Evaluate Reverse Polish Notation" problem on LeetCode! 💡 This problem challenges us to evaluate a given arithmetic expression in Reverse Polish Notation (RPN). Instead of the traditional infix notation where operators come between operands, RPN places operators after their operands. Here's a concise breakdown of my approach: 1️⃣ Using a Stack: Employing a stack data structure proved instrumental in efficiently solving this problem. We traverse the expression, pushing operands onto the stack and performing operations whenever encountering an operator. 2️⃣ Efficient Evaluation: By leveraging stack operations, I effectively evaluate the RPN expression in linear time complexity. 3️⃣ Robustness: Ensuring the solution handles various edge cases, including invalid expressions and division by zero, enhances its reliability and versatility. 💡 Key Insights: - Utilize stack to track operands and perform operations. - Safeguard against potential errors like invalid expressions and division by zero. 👉🏼 Check out my solution here: https://lnkd.in/dNkRz8P8 Link of the problem : https://lnkd.in/dne2_fBq I'm thrilled to share my approach and keen to hear your feedback and insights! Let's keep challenging ourselves and growing together in the world of problem-solving. 💪🏼 #LeetCode #ProblemSolving #CodingChallenge #Algorithm
To view or add a comment, sign in
-
I just came across PyPi module 'outlines' which is a utility to make text generation from LLMs easier. Some cool utilities like typecasting, regex-guided generation, early stopping, multiple choice and Pydantic-guided JSON generation (wow!) https://lnkd.in/gyyRpZ8E
GitHub - normal-computing/outlines: Generative Model Programming
github.com
To view or add a comment, sign in
-
🚀 **Solved: Range Sum of BST (LeetCode 938)** 🚀 I'm excited to share that I have successfully solved the "Range Sum of BST" problem on LeetCode, which is categorized under the easy difficulty level. 🎉 **Problem Statement:** Given the root node of a binary search tree (BST) and two integers, `low` and `high`, the task is to return the sum of values of all nodes with a value within the inclusive range [low, high]. **Key Concepts and Learning Points:** - **Binary Search Tree (BST) Properties:** Leveraging the BST property where the left child is less than the node and the right child is greater. This property helps in efficiently traversing the tree and summing up the values within the specified range. - **Recursive Approach:** Implementing a recursive function to traverse the BST. This function checks each node and accumulates the sum of node values that fall within the given range. - **Range-based Logic:** Efficiently deciding whether to traverse the left subtree, right subtree, or both based on the current node's value in relation to `low` and `high`. **Why This Problem is Interesting:** - **Data Structures & Algorithms:** It reinforces the understanding of binary search trees and recursive algorithms. - **Efficiency:** It highlights the importance of conditional traversal to optimize the range sum calculation. - **Practical Application:** This problem is a great example of how theoretical knowledge of data structures can be applied to solve practical problems efficiently. Solving this problem not only helped me sharpen my skills in working with binary search trees but also enhanced my ability to write clean and efficient recursive solutions. I'm thrilled to continue exploring more problems and expanding my algorithmic knowledge. Feel free to connect with me to discuss this problem, share insights, or collaborate on interesting projects! 🤝 #LeetCode #BinarySearchTree #BST #Algorithm #DataStructures #CodingChallenge #ProblemSolving #SoftwareEngineering #ContinuousLearning
To view or add a comment, sign in
-
🌟 Day 3 of the 75-day LeetCoding Challenge! 🎉 🚀 Problem: reverse Integer 🔍 Level Description : Medium ⚡Link to Problem : https://lnkd.in/gn6FtkeM 💡Approach || 🕒 O(log10(x))|| 💾O(1) --Algorithm: 1.Initialize a variable r to 0. This will store the reversed integer. Iterate through each digit of the input x until it becomes 0: a. Calculate the last digit of x by taking the modulus (x % 10). b. Calculate the new result by multiplying the current r by 10 and adding the last digit obtained in step (a). c. Check for integer overflow: If dividing the new result by 10 doesn't give back the previous r, return 0. d. Update r to the new result. e. Reduce x by removing the last digit (x /= 10). Once x becomes 0, return the reversed integer r. Time Complexity: The time complexity of the algorithm is O(log10(x)), where x is the input integer. This complexity arises from the number of digits in the input integer x. Space Complexity: The space complexity of the algorithm is O(1) because it uses only a constant amount of extra space regardless of the input size. __________________________________________________________________ #75daysCodeChalleng #leetcode #algorithm #datastructures #codingjourney #linkedincodingcommunity #coding #codingchallenge
To view or add a comment, sign in