Skip to content

Instantly share code, notes, and snippets.

View AndreyBespamyatnov's full-sized avatar
🏠
Working from home

Andrei Bespamiatnov AndreyBespamyatnov

🏠
Working from home
View GitHub Profile

LLM Wiki

A pattern for building personal knowledge bases using LLMs.

This is an idea file, it is designed to be copy pasted to your own LLM Agent (e.g. OpenAI Codex, Claude Code, OpenCode / Pi, or etc.). Its goal is to communicate the high level idea, but your agent will build out the specifics in collaboration with you.

The core idea

Most people's experience with LLMs and documents looks like RAG: you upload a collection of files, the LLM retrieves relevant chunks at query time, and generates an answer. This works, but the LLM is rediscovering knowledge from scratch on every question. There's no accumulation. Ask a subtle question that requires synthesizing five documents, and the LLM has to find and piece together the relevant fragments every time. Nothing is built up. NotebookLM, ChatGPT file uploads, and most RAG systems work this way.

@AndreyBespamyatnov
AndreyBespamyatnov / Windows Defender Exclusions for Developer.ps1
Created March 11, 2026 12:57
Adds Windows Defender exclusions for developers (Visual Studio, JetBrains Rider, IntellIJ Idea, Git, MsBuild, dotnet, mono etc.)
$userPath = $env:USERPROFILE
$pathExclusions = New-Object System.Collections.ArrayList
$processExclusions = New-Object System.Collections.ArrayList
$pathExclusions.Add('C:\Windows\Microsoft.NET') > $null
$pathExclusions.Add('C:\Windows\assembly') > $null
$pathExclusions.Add($userPath + '\AppData\Local\Microsoft\VisualStudio') > $null
$pathExclusions.Add('C:\ProgramData\Microsoft\VisualStudio\Packages') > $null
$pathExclusions.Add('C:\Program Files (x86)\MSBuild') > $null
$pathExclusions.Add('C:\Program Files (x86)\Microsoft Visual Studio 14.0') > $null
@AndreyBespamyatnov
AndreyBespamyatnov / .gitlab-ci.yml
Created October 25, 2018 07:44 — forked from zerda/.gitlab-ci.yml
Gitlab CI for ASP.Net Core project
stages:
- build
- publish
.build: &build_template
stage: build
image: microsoft/dotnet:2.1-sdk-alpine
cache:
key: "$CI_PROJECT_NAMESPACE-$CI_PROJECT_NAME"
paths:
@AndreyBespamyatnov
AndreyBespamyatnov / readme.txt
Created April 9, 2018 12:47
Editing Setup ELK Stack on Ubuntu
Elasticsearch is an enterprise level open source search server based on Apache Lucene, offers a real-time distributed search and analytics with a RESTful web interface and schema-free JSON documents. Elasticsearch is developed in java and is released under Apache License. Currently, it is ranked second in most popular enterprise search engine, behind Apache Solr.
This guide will help you to install the Elasticsearch on Ubuntu
== Prerequisites ==
Make sure you have the latest JDK installed on your system. If you don't have setup it:
<syntaxhighlight lang="bash">
sudo apt-get remove --purge openjdk*
sudo add-apt-repository -y ppa:webupd8team/java
sudo apt-get update
@AndreyBespamyatnov
AndreyBespamyatnov / app.config
Created April 9, 2018 10:57 — forked from grenade/app.config
Emit log4net entries to logstash over UDP in near-realtime
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net" />
</configSections>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
</startup>
<log4net>
<appender name="UdpAppender" type="log4net.Appender.UdpAppender">
@AndreyBespamyatnov
AndreyBespamyatnov / app.config
Created April 9, 2018 10:57 — forked from grenade/app.config
Emit log4net entries to logstash over UDP in near-realtime
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<configSections>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net" />
</configSections>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
</startup>
<log4net>
<appender name="UdpAppender" type="log4net.Appender.UdpAppender">
-- a- list of clients, which have an order with order_sum > 50
select c.client_id, c.client_name from Clients as c
inner join Orders as o on o.client_id = c.client_id
where o.order_sum > 50
-- b- clients, whose total sum of orders exceeds 100
Select * from
(select c.client_id, c.client_name, SUM(o.order_sum) as total from Clients as c
inner join Orders as o on o.client_id = c.client_id
GROUP BY c.client_id) as t
private static bool CompareIterative(BTN n1, BTN n2)
{
// check for nulls
if (n1 == null || n2 == null)
{
return n1 == n2;
}
var q1 = new Queue<BTN>();
var q2 = new Queue<BTN>();
1) we will be create new array, lenght = max floor
2) we will add to index (if exist by number of floow) value of person time
3) read array from right to left
4) in cicle (current index of cicle as "floow")
4.1) if current vlue == 0, then incriminate result and continue
4.2) if it is firs floow, maybe we need to wite, add current value and continue
4.3) if curent value GREAT that result, then add value by formula (result = curent value - result)
4.4) otherwise/else, just incriminate result
that it)
public interface IQueue<T>
{
void Enqueue(T value);
T Dequeue();
}
public class StackQueue<T> : IQueue<T>
{
private readonly Stack<T> _stack1 = new Stack<T>();