Skip to content

Instantly share code, notes, and snippets.

View erhangundogan's full-sized avatar
👋

Erhan Gundogan erhangundogan

👋
View GitHub Profile
@erhangundogan
erhangundogan / prompting.md
Created June 10, 2025 09:23
Prompting Examples from Mistral
@erhangundogan
erhangundogan / fine-tuning-vs-prompting.md
Created June 10, 2025 09:09
Fine-Tuning vs Prompting

Fine-tuning vs prompting

When deciding whether to use prompt engineering or fine-tuning for an AI model, it can be difficult to determine which method is best. It's generally recommended to start with prompt engineering, as it's faster and less resource-intensive. To help you choose the right approach, here are the key benefits of prompting and fine-tuning:

Benefits of Prompting

  • A generic model can work out of the box (the task can be described in a zero shot fashion)
  • Does not require any fine-tuning data or training to work
  • Can easily be updated for new workflows and prototyping

Popular Open-Source Edge Projects

Tool Description
EdgeX Foundry A vendor-neutral, open-source framework for building edge computing solutions.
KubeEdge Kubernetes-native edge computing framework for managing workloads and devices at the edge.
Open Horizon IBM’s open-source project for managing edge devices and apps at scale.
Baetyl An edge computing platform from Baidu, designed for AI at the edge.
LF Edge Projects A Linux Foundation umbrella hosting multiple edge computing projects like Fledge, EVE, etc.
FogLAMP Open-source fog computing platform for industrial IoT.
@erhangundogan
erhangundogan / ValuationRatios.md
Created May 23, 2025 20:00
Top 12 Valuation Ratios (Investment)

The Top 12 Valuation Ratios

  • EV / Revenue: It measures the dollars in Enterprise Value for each dollar of revenue. High-profit margins are highly correlated with higher revenue multiples.

    Formula: EV / Revenue = Enterprise Value / Revenue

  • EV / EBITDA: Firms with high growth rates typically trade at higher EBITDA Multiples.

    Formula: EV / EBITDA = Enterprise Value / EBITDA

@erhangundogan
erhangundogan / troubleshoot-kubernetes.md
Created May 14, 2025 10:22
Troubleshoot Kubernetes

Troubleshooting Kubernetes issues beyond logs requires a systematic approach to inspect cluster components, resources, and configurations. Below, I outline key open-source tools and techniques (excluding log analysis, as you specified) to diagnose problems in Kubernetes related to running processes, open ports, network connections, hardware usage (CPU, memory, disk, network), and cluster-specific issues like pod failures, networking, or misconfigurations. These methods focus on on-demand troubleshooting and leverage tools that provide insights into the cluster's state.

1. Inspect Cluster Resources and Status

  • Tool/Method: kubectl
    • Purpose: Native Kubernetes CLI to check the state of pods, nodes, services, deployments, and other resources.
    • Techniques:
      • Check Pod Status: kubectl get pods -n <namespace> -o wide to see pod status (e.g., CrashLoopBackOff, Pending), node assignment, and IP addresses.
      • Describe Resources: `kubectl describe pod <po

There are numerous open-source tools available for troubleshooting operating systems across various aspects like running processes, open ports, network connections, hardware usage (CPU, memory, disk, network), and logs. Below is a categorized list of popular open-source tools that can help with these tasks, primarily focusing on Linux/Unix systems, but some are cross-platform and work on Windows or macOS as well.

1. Running Processes

  • top: Real-time system-monitoring tool for Unix systems, displays CPU and memory usage by processes.
    • Alternative: htop (enhanced, user-friendly version with a colorful interface and process management features).
  • ps: Displays a snapshot of current processes, highly customizable for filtering and formatting output.
  • pidstat (part of sysstat): Monitors individual process statistics like CPU, memory, and I/O usage over time.
  • Glances: Cross-platform system-monitoring tool that provides a comprehensive view of processes, CPU, memory

Content classification

Streamers need to apply Content Classification Labels to indicate to viewers if the stream they’re about to watch contains themes related to: Mature-Rated Games; Sexual Themes; Drugs, Intoxication, or Excessive Tobacco Use; Violent and Graphic Depictions; Significant Profanity or Vulgarity; Politics and Sensitive Social Issues; or Gambling.

Do you know the benefits of content classification?

  • Improves customer experience
  • Reduces service and operational costs
  • Eases integration with core business applications
  • Automates bulk documents classification
  • Facilitates adherence to regulatory compliance

Chatbot

  • Perception: Gather information as much as possible:
    • From prompt via user
    • From predefined information regarding to user
    • From logs
    • From APIs
    • From other agents (MCP, A2A etc)
  • Processing & Decision Making:
  • Choose LLM to use
@erhangundogan
erhangundogan / fine-tuning.md
Created April 15, 2025 12:10
LLM Fine Tuning

Fine-Tuning

Customize the model for a specific task, domain, or tone Narrow/specific tasks.

Adapts the model to specific needs, such as:

  • Your company’s support knowledge
  • Medical or financial language
  • Legal documents
  • Specific brand tone

nvidia-smi

+-----------------------------------------------------------------------------------------+
| NVIDIA-SMI 570.124.06             Driver Version: 570.124.06     CUDA Version: 12.8     |
|-----------------------------------------+------------------------+----------------------+
| GPU  Name                 Persistence-M | Bus-Id          Disp.A | Volatile Uncorr. ECC |
| Fan  Temp   Perf          Pwr:Usage/Cap |           Memory-Usage | GPU-Util  Compute M. |
|                                         |                        |               MIG M. |
|=========================================+========================+======================|