Skip to content

Instantly share code, notes, and snippets.

View AaradhyaSaxena's full-sized avatar

Aaradhya Saxena AaradhyaSaxena

View GitHub Profile
@AaradhyaSaxena
AaradhyaSaxena / 01-intro.md
Last active November 27, 2023 18:09
qdrant-vector-db

# Qdrant

Vector databases are a relatively new way for interacting with abstract data representations derived from opaque machine learning models such as deep learning architectures. These representations are often called vectors or embeddings and they are a compressed version of the data used to train a machine learning model to accomplish a task like sentiment analysis, speech recognition, object detection, and many others.

These new databases shine in many applications like semantic search and recommendation systems, and here, we’ll learn about one of the most popular and fastest growing vector databases in the market, Qdrant.

Screenshot 2023-11-04 at 5 34 18 PM

Concepts

  1. Collection
@AaradhyaSaxena
AaradhyaSaxena / 00-Introduction.md
Last active November 27, 2023 18:11
Introduction to Information Retrieval

These are my notes from the book "Introduction to information retrieval"

  1. Intro to IR
  2. Term Vocabulary
  3. Tolerant Retrieval
  4. Index Construction
  5. Index Compression
  6. Scoring
  7. Compute Scoring
  8. Evaluation of Information Retrieval

System Design

System design is about — Architecture + Data + Applications

Architecture means how are you going to put the different functioning blocks of a system together and make them seamlessly work with each other after taking into account all the nodal points where a sub-system can fail/stop working.

Screenshot 2023-08-02 at 12 10 10 PM

Data means what is the input, what are the data processing blocks, how to store petabytes of data and most importantly how to process it and give the desired/required output.

@AaradhyaSaxena
AaradhyaSaxena / 01-Design-patterns.md
Last active March 26, 2024 14:46
Design Patterns

Design Patterns

Design patterns can be classified into three main categories:

Creational Patterns:

Creational design patterns relate to how objects are constructed from classes. Examples of creational patterns include Factory Method, Abstract Factory, Builder, Prototype, and Singleton.

Structural Patterns:

Spring Basics

The highlight of Spring Boot is its auto-configuration feature whereby it automatically includes all the dependencies of a project based on property files and JAR classpaths. Spring Boot is basically the Spring framework along with embedded servers. Spring boot removes the need for XML configuration.

Decoupling Components

public interface Filter {
    public String[] 
    getRecommendations(String movie);
}
@AaradhyaSaxena
AaradhyaSaxena / 01-Computer Networking.md
Last active November 27, 2023 18:11
Computer Networking

Computer Networking

What Is a Protocol?

Think of your routine conversations. They usually follow a general pattern dictated by predefined rules. For example, most conversations start with greetings and end with goodbyes.

Formally, according to the Oxford Dictionary, a protocol is “a set of rules governing the exchange or transmission of data between devices.”

TCP

The Transmission Control Protocol (TCP) is one such protocol. It was created to allow end systems to communicate effectively. The distinguishing feature of TCP is that it ensures that data reaches the intended destination and is not corrupted along the way.

@AaradhyaSaxena
AaradhyaSaxena / 01-CreditRisk-and-Financing.md
Last active November 27, 2023 18:12
WorldQuant-Financial Markets

Credit Risk and Financing

Bond Pricing

Consider a two-year bond. You receive a coupon, say, in six months. You receive another six months later, another six months later, and the last one in two years, along with the principal amount. So, if we think about the total amount, what we must consider is that the separate times will result in those amounts having different value today. In other words, we simply cannot add cash flows at all different time points in the future and expect to have a straightforward way to sum them today.

Suppose we have $1,000 invested for one year at 4%. What we're doing is something called future valuing. This helps us to calculate what that $1,000 will be 1 year from now. The answer is $1,040. What if we did that problem in reverse? What if we discounted $1,040 that we receive one year from now to today’s dollars? This is known as present-valuing. What is that worth today?

Discounting

When you take an amount in the present and imagine how much it's worth in the future,

@AaradhyaSaxena
AaradhyaSaxena / 01-Chapter-1.md
Last active November 27, 2023 18:12
Book Summary: Intelligent Investor

Chapter1: Investment vs Speculation

He defines investing as the process of analyzing stocks and investing in companies with solid fundamentals and a margin of safety. On the other hand, he defines speculation as the process of buying and selling stocks based on market trends or other speculative factors.

Graham emphasizes that investing is a rational and analytical process, while speculation is an emotional and impulsive process. He warns that speculators often get caught up in the excitement of the market and make irrational decisions that can lead to significant losses.

The chapter goes on to explain the concept of intrinsic value, which is the true value of a company based on its earnings, assets, and other fundamentals. Graham argues that investors should focus on investing in companies that are undervalued in the market relative to their intrinsic value, rather than trying to time the market or make short-term gains.

Graham also introduces the concept of a margin of safety, which is the difference

@AaradhyaSaxena
AaradhyaSaxena / 1. models.md
Last active February 27, 2023 12:04
Recommendation-Models-Google-Cloud

About recommendation models

(https://cloud.google.com/retail/docs/models)

The Retail API offers the following recommendation model types:

  • Others You May Like
  • Frequently Bought Together (shopping cart expansion)
  • Recommended for You
  • Similar Items
  • Buy it Again
  • On-sale
@AaradhyaSaxena
AaradhyaSaxena / 01- Locust.md
Last active March 30, 2023 05:01
Load/Performance Testing

Locust

Events

If you want to run some setup code as part of your test, it is often enough to put it at the module level of your locustfile, but sometimes you need to do things at particular times in the run. For this need, Locust provides event hooks.

test_start and test_stop

If you need to run some code at the start or stop of a load test, you should use the test_start and test_stop events. You can set up listeners for these events at the module level of your locustfile:

from locust import events