Skip to content

Instantly share code, notes, and snippets.

View Konard's full-sized avatar
🖥️
Watch how I code at https://www.youtube.com/c/КонстантинДьяченко

Konstantin Dyachenko Konard

🖥️
Watch how I code at https://www.youtube.com/c/КонстантинДьяченко
View GitHub Profile
@Konard
Konard / main.py
Created September 26, 2023 16:02 — forked from kalinochkind/main.py
Discord gpt bot
#!/usr/bin/env python3
import discord
import sqlite3
import datetime
import openai
import os
import tiktoken
openai.api_type = "azure"
@shinshin86
shinshin86 / chatgpt-with-qa-format.js
Created December 9, 2022 12:54
Script for displaying the conversing with ChatGPT in the console log in QA format.
// USAGE: After conversing with ChatGPT, run this code on the Chrome developer console.
const textList = []
document.querySelectorAll('.text-base').forEach((t, i) => {
textList.push(`${i % 2 === 0 ? "Q:" : "A:"} ${t.textContent}`)
})
console.log(textList.join('\n'));
@Vovanda
Vovanda / RandomTextInWidget
Last active January 17, 2021 07:49
Отображение случайного сообщения в виджете VK приложения (VKScript)
// VKScript rand implementation
// VK API random in widget
//Получение случайных числел
//Используем id проверенного человека с большим колличеством друзей
var friends_ids = API.friends.get({ user_id: 3972090, count: 10000 });
var count_of_randoms = 2;
var rnd_ids = API.friends.get({ user_id: 3972090, order:"random", count: count_of_randoms }).items;
var rnd_values = [];
var i = 0;
@ythosa
ythosa / clone-all.bat
Last active December 18, 2020 12:56 — forked from Konard/clone-all.bat
Clone all LinksPlatform's repositories using SSH.
git clone git@github.com:linksplatform/ccc
git clone git@github.com:linksplatform/Collections
git clone git@github.com:linksplatform/Collections.Methods
git clone git@github.com:linksplatform/Communication
git clone git@github.com:linksplatform/Communication.Protocol.Lino
git clone git@github.com:linksplatform/Comparers
git clone git@github.com:linksplatform/Comparisons.SQLiteVSDoublets
git clone git@github.com:linksplatform/Converters
git clone git@github.com:linksplatform/Crawler
git clone git@github.com:linksplatform/CSharpToCppTranslator
@Neilos
Neilos / README.md
Last active October 6, 2023 00:26
Bi-directional hierarchical sankey diagram

This is a demonstration of a bi-directional hierarchical sankey diagram produced in javascript, html and css using d3. (Refresh page to generate new random data)

Sankey diagrams represent flows between nodes by varying the thickness of the connecting links.

This diagram was based off of Mike Bostock's sankey diagram, but additionally incorporates bi-directionality into the flow and caters for hierarchical relationships between nodes to allow drill down into the data.

All javascript code to generate the diagram markup is contained in the app.js file, but the underlying calculations are performed using a custom plugin: bihisankey.js.