Skip to content

Instantly share code, notes, and snippets.

View yoeven's full-sized avatar
🍁

Yoeven D Khemlani yoeven

🍁
View GitHub Profile
@yoeven
yoeven / transcription.json
Created March 21, 2025 08:28
JigsawStack Transcription Large Audio Result
{
"success": true,
"text": "We don't teach leaders how to have uncomfortable conversations. We don't teach students how to have uncomfortable conversations. You tell me which is going to be more valuable for the rest of your life. How to have a difficult conversation or trigonometry? Described as a visionary thinker with a rare intellect. Multiple time best-selling author. Scientific. Every single one of us knows what we do. Some of us know how we do it. But very, very few of us can clearly articulate why we do what we do. And I think one of the reasons most of us don't know who we are is because we're making decisions that are inconsistent with that true cause, with that why. There's a great irony in all of this. I had what a lot of people would be considered a good life and yet didn't want to wake up and go to work anymore. Why? We cannot do this thing called career or life alone. We're just not that smart. We're not that strong. We're just not that good. For anyone who wants to be a better version of t
@yoeven
yoeven / vocr_result.json
Created March 7, 2025 11:54
vocr_result.json
{
"success": true,
"context": {
"code_url": [
"https://github.com/mistralai/mistral-src"
],
"markdown": [
"https://mistral.ai/news/announcing-mistral-7b/"
]
},
@yoeven
yoeven / getYoutubeThumbnail.ts
Created January 1, 2025 21:21
Get Youtube Video Thumbnail JS/TS Script
// Based on info from here https://stackoverflow.com/questions/2068344/how-do-i-get-a-youtube-video-thumbnail-from-the-youtube-api
const formatsToTry = ["maxresdefault", "hqdefault", "0", "default"];
const getYTThumbnail = async (video_id: string) => {
const baseURL = `https://img.youtube.com/vi/${video_id}/`;
for (let index = 0; index < formatsToTry.length; index++) {
const endText = formatsToTry[index];
@yoeven
yoeven / supported_models.json
Last active December 12, 2024 02:55
Prompt Engine Supported Models
[
"chat-bison",
"chat-bison-001",
"chat-bison-32k",
"chat-bison-32k@002",
"chat-bison@001",
"chat-bison@002",
"chatgpt-4o-latest",
"claude-2",
"claude-2.1",
@yoeven
yoeven / exa_ai_search_results.json
Created November 29, 2024 10:24
JigsawStack AI Web Search vs Exa
{
"requestId": "730e36306316f1c5e5b823eb5e180db1",
"autopromptString": "Heres how to get started with Rust:",
"resolvedSearchType": "neural",
"results": [
{
"score": 0.19925512373447418,
"title": "Getting started",
"id": "https://www.rust-lang.org/learn/get-started",
"url": "https://www.rust-lang.org/learn/get-started",
[
{
"accent": "af-ZA-female-1",
"locale_name": "Afrikaans (South Africa)",
"gender": "female"
},
{
"accent": "af-ZA-male-1",
"locale_name": "Afrikaans (South Africa)",
"gender": "male"
const endPoint = "https://api.jigsawstack.com/v1/ai/scrape";
const run = async (url: string, prompts: string[]) => {
const resp = await fetch(endPoint, {
method: "POST",
headers: {
"Content-Type": "application/json",
"x-api-key": "KEY",
},
body: JSON.stringify({
@yoeven
yoeven / fly.toml
Last active September 4, 2023 10:55
Hasura fly.io toml file
#https://fly.io/docs/reference/configuration/
app = "hasura"
primary_region = "sjc" #https://fly.io/docs/reference/regions/
[build]
image = "hasura/graphql-engine:v2.15.2" #update version accordingly
#https://hasura.io/docs/latest/deployment/updating-graphql-engine/
#https://hasura.io/docs/latest/policies/versioning
@yoeven
yoeven / JSON_to_URLEncoded.ts
Last active July 5, 2023 07:19 — forked from lastguest/JSON_to_URLEncoded.js
Convert JavaScript object to x-www-form-urlencoded format
const JSONtoURLEncoded = (element: any, key?: string, _list?: any[]) => {
let list = _list || [];
if (typeof element == "object") {
for (let idx in element) JSONtoURLEncoded(element[idx], key ? key + "[" + idx + "]" : idx, list);
} else {
list.push(key + "=" + encodeURIComponent(element));
}
return list.join("&");
};
@yoeven
yoeven / requestWithoutResp.ts
Last active April 24, 2023 14:22
Fetch without a response (JS)
//https://www.sensedeep.com/blog/posts/stories/lambda-fast-http.html
export const fetchWithoutResp = async (
url: string,
body?: string | Buffer,
headers: {
[key: string]: string;
} = {},
method: "POST" | "GET" = "POST"
) => {
const router = url.includes("http://") ? http : https;