Skip to content

Instantly share code, notes, and snippets.

View DiTo97's full-sized avatar

Federico Minutoli DiTo97

View GitHub Profile
@DiTo97
DiTo97 / SEO-reviewer.md
Created January 27, 2026 08:12
The spec file for the AI reviewer of SEO and GEO best practices
name description tools
SEO-reviewer
Analyzes and optimizes SEO and GEO best practices for Lovable applications
read
search
edit

You are the Lovable SEO & GEO Reviewer Agent. Your purpose is to analyze Lovable applications (which are React/Vite Client-Side Rendered Single Page Applications) and ensure they are optimized for Search Engines (SEO) and Generative AI Engines (GEO).

Your mindset is that Lovable apps are CSR (Client-Side Rendered). This means the browser builds the view. While Google renders JS well, social bots and some AI crawlers do not. You must treat SEO/GEO like code: it requires intentional review, testing, and refinement.

# /// script
# dependencies = [
# "openai-agents",
# ]
# ///
import asyncio
import json
from dataclasses import dataclass
from typing import Sequence, AsyncGenerator
@DiTo97
DiTo97 / AGENTS.md-reviewer.md
Last active January 27, 2026 08:10
The spec file for the AI reviewer of AGENTS.md file definitions.
name description tools
AGENTS.md-reviewer
Analyzes and optimizes AGENTS.md files and AGENTS docs following best practices for AI coding agents
read
search
edit

You are an expert AGENTS.md reviewer and optimizer. Your role is to analyze repository AGENTS.md files and their supporting documentation (AGENTS-docs folder), then optimize them according to proven best practices for AI coding agent configuration.

Core Principles

@DiTo97
DiTo97 / e2e_embeddings_pipeline.py
Last active January 8, 2026 01:36
end-to-end pipeline for hard-negative mining, Sentence-Transformers training, and evaluation
# /// script
# dependencies = [
# "sentence-transformers>=2.6.0",
# "datasets",
# "rank-bm25",
# "faiss-cpu",
# "tqdm",
# "torch",
# ]
# ///
@DiTo97
DiTo97 / mappamia.py
Last active December 30, 2025 15:03
CLI tool generating SVG maps of any country with Google Maps-style pin markers.
# /// script
# requires-python = ">=3.12"
# dependencies = [
# "aiohttp",
# "geopandas",
# "geopy",
# "matplotlib",
# "rich",
# "scipy",
# "svgpath2mpl",
@DiTo97
DiTo97 / safeasyncio.py
Last active January 7, 2026 18:10
A collection of utilities for safely executing asynchronous coroutines
import asyncio
import atexit
import functools
import threading
from typing import Any, Callable, Coroutine, ParamSpec
P = ParamSpec("P")
@DiTo97
DiTo97 / sampling_methods_for_evaluation.py
Last active December 14, 2025 04:09
efficient and reliable sampling methodologies for pass@k and pass^k evaluation
# /// script
# requires-python = ">=3.12"
# dependencies = [
# "scipy>1,<2",
# ]
# ///
import math
import random
from dataclasses import dataclass, field
@DiTo97
DiTo97 / a2a_distributed_queue.py
Last active October 18, 2025 15:18
A2A event queue and queue manager using Redis
import asyncio
import json
import logging
import uuid
import redis.asyncio as redis
from a2a.server.events.event_queue import EventQueue
from a2a.server.events.queue_manager import (
NoTaskQueue,
@DiTo97
DiTo97 / !telemetry.py
Last active October 18, 2025 15:26
OpenTelemetry tracing utilities for any library.
"""OpenTelemetry tracing utilities for any library.
This module provides decorators to simplify the integration of OpenTelemetry
tracing into Python applications. It offers `trace_function` for instrumenting
individual functions (both synchronous and asynchronous) and `trace_class`
for instrumenting multiple methods within a class.
The tracer is initialized with the module name and version defined by
`INSTRUMENTING_MODULE` ('<module>') and
`INSTRUMENTING_MODULE_VERSION` ('<version>').
import asyncio
import json
import os
import re
import typing
import uuid
from contextlib import contextmanager
from typing import Any
import numpy as np