Skip to content

Instantly share code, notes, and snippets.

View usametov's full-sized avatar

Ulan Sametov usametov

  • Asta Nova Enterprise Solutions
View GitHub Profile
@usametov
usametov / Client-Discovery-Prompt-Draft.md
Last active May 31, 2025 01:17
growth marketing bot

You are growth consultant. Your goal is to uncover clear objectives and points of interest for [Company Name], a [Type of Business]. Use open-ended, curious questions to explore goals, challenges, and perceptions, focus on the 'why' behind motivations and needs, align with strategic aims, and engage diverse stakeholders (e.g., leadership, employees, customers). Actively listen and probe for deeper insights, using the critical incident technique to recall specific moments of success or challenge.

Step 1: Ask questions to describe Company's Line of Business and Strategic Context. This is needed to output summary.

Example questions:

How does [Company Name]’s mission or vision as a [Type of Business] guide your current priorities and strategies? Why is this alignment critical to your long-term success? Probe: Can you think of a time when this mission drove a key decision or strategy? What was the outcome?

@usametov
usametov / Rosebud-game-templates.md
Last active May 19, 2025 20:29
market research with dynamic canvas generation and gamified survey delivery

Rosebud AI Game Templates for Market Research Surveys

Rosebud AI is a generative AI platform that enables users to create 2D and 3D games and interactive experiences through natural language prompts, requiring little to no coding expertise. Its game templates provide pre-built frameworks that can be customized, making it an innovative tool for crafting dynamic canvas generation and gamified survey delivery in market research. Below, I explore how Rosebud AI’s game templates can be leveraged for market research, focusing on their features, customization options, integration with conversational AI, and practical applications, while incorporating insights from web sources.

Overview of Rosebud AI Game Templates

Rosebud AI offers a variety of templates designed to streamline game creation, which can be adapted for market research surveys. These templates serve as starting points, a

@usametov
usametov / run_storm_wiki_gpt_with_VectorRM.py
Created May 14, 2025 03:04
run storm against local qdrant instance
"""
This STORM Wiki pipeline powered by Groq (Llama3-70B) and local Qdrant vector store with Ollama embeddings.
You need to set up the following environment variables to run this script:
- GROQ_API_KEY: Groq Cloud API key
- QDRANT_API_KEY: Qdrant API key (optional, only needed if using authenticated Qdrant)
Requirements:
1. Local Qdrant instance running (default: http://localhost:6333)
2. Ollama serving the embedding model (default: all-minilm:l6-v2)
@usametov
usametov / rmt.md
Created April 17, 2025 02:16
resting motor threshold in TMS

The resting motor threshold (RMT) in transcranial magnetic stimulation (TMS) is defined as the minimum intensity of stimulation required to elicit a motor-evoked potential (MEP) of at least 50 µV peak-to-peak amplitude in a target muscle (typically the abductor pollicis brevis for upper limb studies) in at least 50% of trials (e.g., 5 out of 10 pulses) while the muscle is at rest. RMT is expressed as a percentage of the maximum stimulator output (% MSO) and varies across individuals due to factors like skull-to-cortex distance, coil type, and neural excitability.

Below, I address your questions regarding RMT, Tesla measurements, amperage, double-cone coil use for the left cerebellar hemisphere (lobule VII/Crus I), and portable TMS devices.


1. Understanding RMT and Converting 80-90% of RMT to Tesla

RMT is not directly measured in Tesla (the unit of magnetic field strength) but as a percentage of the stimulator’s maximum output. The magnetic field strength (in Tesla) depends on the TMS device

@usametov
usametov / contextual.md
Last active April 15, 2025 23:39
how to create a dataset similar to NQ from a bunch of links assigned to one or more topics.

Integrating Contextual Retrieval into your Q&A generation process for a dataset similar to the Natural Questions (NQ) dataset can enhance the quality and relevance of the generated question and answer (Q&A) pairs. Since you already have a Clojure-based pipeline for scraping websites and producing high-quality semantic chunks, and you’re interested in using a prompt to generate Q&A pairs, incorporating Contextual Retrieval can improve how you leverage your chunks by adding contextual metadata or summaries to ensure questions are more precise and answers are more grounded in the content. This approach complements your existing setup and aligns with your prior interest in advanced retrieval techniques (e.g., RAG systems, Qdrant integration, and Contextual Retrieval vs. Late Chunking, as discussed on April 9, 2025).

Below, I’ll elaborate on how to use the output of Contextual Retrieval prompts to enhance your Q&A generation, modify the existing prompt to incorporate Contextual Retrieval outputs, and provide

@usametov
usametov / etaoin-clj.md
Last active April 14, 2025 04:00
stealth scraping

This is an example of stealth scraping with Etaoin in Clojure, simulating browser behavior while incorporating insights from the provided scrape.do blog posts. The blog posts focus on rotating proxies, avoiding detection, we will implement those concepts into a Clojure/Etaoin context, emphasizing browser simulation and anti-detection techniques.

Key Insights from the Blog Posts

  1. Cheap Rotating Proxies:

    • Rotating proxies are essential to avoid IP bans by distributing requests across multiple IP addresses, mimicking different users.
    • Residential proxies are recommended for stealth as they appear more legitimate than datacenter proxies.
    • Affordable proxy services can integrate with scraping tools to rotate IPs automatically.
  2. Web Scraping Detection:

@usametov
usametov / hardware-specs.md
Last active April 12, 2025 03:21
tms parameters for ASD

This complements the TMS design review document you shared earlier, which detailed coil configurations, targeting capabilities, and trade-offs. Your request to find "similar open-source projects" in the context of the review, combined with the gist’s focus on TMS parameters, suggests you’re seeking open-source initiatives that align with both the review’s technical scope (coil design, simulation, optimization) and the gist’s emphasis on customizable TMS parameters.

Below, I revisit the task of identifying open-source projects, ensuring they align with both the review and the Gist. I’ll incorporate the Gist’s parameters (e.g., coil size, pulse width, field strength) to refine recommendations, focusing on projects that support experimentation with such variables. I’ll also address any potential overlap with my previous response, expanding on new or refined suggestions based on the Gist’s insights.

Understanding the Gist’s Context

The Gist outlines TMS parameters critical to device design:

@usametov
usametov / clustering-clj.md
Created April 11, 2025 03:23
Clustering embedding vectors, k-means smile

https://grok.com/share/bGVnYWN5_42d104d8-881b-46ad-874e-b3f85d45a8f7

Clustering embedding vectors is a great way to group similar items, and picking random samples from each cluster can help with tasks like data exploration or sampling for further analysis. Since you’re working in Clojure and mentioned KNN (likely referring to K-Nearest Neighbors, though it’s more a classification algorithm than a clustering one), I’ll assume you meant clustering algorithms in general, like K-Means, and I’ll focus on options available in Clojure or libraries accessible from it.

Clustering Algorithms

Here’s an overview of clustering algorithms you can use for your 1000 embedding vectors, along with their suitability:

  1. K-Means Clustering
    • How it works: Partitions data into k clusters by minimizing the variance within each cluster. It assigns each vector to the nearest centroid, then updates centroids iteratively.
  • Pros:
@usametov
usametov / multi-shot-router.md
Created April 11, 2025 03:07
Multi-shot prompting for routing function calls

Multi-shot prompting (also called few-shot prompting) is a powerful technique to improve an LLM's ability to extract information accurately by providing multiple examples within the prompt. This helps the model understand the task, context, and desired output format better than zero-shot or single-shot prompting. Below, I’ll explain multi-shot prompting for routing function calls and extracting information from text, with clear examples tailored to your use case.

Since you mentioned issues with LLMs not extracting information properly for routing function calls, I’ll focus on scenarios where the model needs to parse user input and map it to specific functions, including handling ambiguous or noisy text. I’ll also include varied examples to demonstrate robustness.


What is Multi-Shot Prompting?

Multi-shot prompting involves giving the LLM several examples of input-output pairs in the prompt before asking it to process the actual input. Each example shows the expected task (e.g., extracting parameters

@usametov
usametov / url-check.md
Created April 11, 2025 00:46
qdrant uniqueness check clj

Prerequisites

  • A running Qdrant instance (local or remote).
  • Clojure project with dependencies for HTTP requests and JSON handling.
  • URLs stored in a Qdrant collection’s payload under a field like url.

Setup

Add the following dependencies to your project.clj (if using Leiningen):

:dependencies [[org.clojure/clojure "1.11.1"]