Fuzzy Fund Search logo

Fuzzy Fund Search

Organization
cxcscmu
fuzzy-fund-search

Fuzzy matching techniques for finding hedge funds by name when exact names are unknown

Overview

Publishercxcscmu
RepositorySkillLearnBench
Skill namefuzzy-fund-search
Stars
91
Forks
7
Bundled files
Instructions only
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by cxcscmu on GitHub. Read the source before you install it.

Installation

Install the Fuzzy Fund Search AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/cxcscmu/SkillLearnBench/tree/main/skills/b1-one-shot-claude-haiku-4-5/financial-analysis/fuzzy-fund-search
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/cxcscmu/SkillLearnBench.git /tmp/SkillLearnBench
mkdir -p .claude/skills
cp -r /tmp/SkillLearnBench/skills/b1-one-shot-claude-haiku-4-5/financial-analysis/fuzzy-fund-search .claude/skills/fuzzy-fund-search
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Fuzzy Fund Search in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Fuzzy Fund Search on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Fuzzy Fund Search is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Fuzzy Name Search for Hedge Funds

Overview

Fund names in the COVERPAGE.tsv may not match exactly what you're searching for. Fuzzy matching helps find the best match when you have approximate or partial names.

Libraries

Using fuzzywuzzy

bash
pip install fuzzywuzzy python-Levenshtein

Using difflib (built-in)

No installation needed - Python standard library

Search Methods

Method 1: Using fuzzywuzzy (Recommended)

python
from fuzzywuzzy import fuzz
from fuzzywuzzy import process
import pandas as pd

def fuzzy_search_fund(search_term, coverpage_df, threshold=70):
    """
    Find funds matching a search term using fuzzy matching

    Args:
        search_term: Partial or approximate fund name (e.g., "renaissance technologies")
        coverpage_df: DataFrame from COVERPAGE.tsv
        threshold: Minimum match score (0-100)

    Returns:
        DataFrame of matches sorted by score (highest first)
    """

    fund_names = coverpage_df['FILINGMANAGER_NAME'].tolist()

    # Use extractBests to get multiple matches
    matches = process.extractBests(
        search_term,
        fund_names,
        scorer=fuzz.token_sort_ratio,  # Good for finding partial matches
        score_cutoff=threshold
    )

    # Build result dataframe
    results = []
    for matched_name, score in matches:
        fund_row = coverpage_df[coverpage_df['FILINGMANAGER_NAME'] == matched_name].iloc[0]
        results.append({
            'FILINGMANAGER_NAME': matched_name,
            'ACCESSION_NUMBER': fund_row['ACCESSION_NUMBER'],
            'match_score': score,
            'REPORTCALENDARORQUARTER': fund_row['REPORTCALENDARORQUARTER']
        })

    return pd.DataFrame(results).sort_values('match_score', ascending=False)

# Usage Example
q3_coverpage = pd.read_csv('/root/2025-q3/COVERPAGE.tsv', sep='\t')
matches = fuzzy_search_fund("renaissance technologies", q3_coverpage, threshold=70)
print(matches.head())

# Get best match
best_match = matches.iloc[0]
accession_number = best_match['ACCESSION_NUMBER']
fund_name = best_match['FILINGMANAGER_NAME']

Method 2: Using difflib (Built-in)

python
from difflib import SequenceMatcher
import pandas as pd

def simple_fuzzy_search(search_term, coverpage_df, threshold=0.6):
    """
    Simple fuzzy search using difflib (no external dependencies)
    """
    search_term_lower = search_term.lower()
    fund_names = coverpage_df['FILINGMANAGER_NAME'].tolist()

    matches = []
    for name in fund_names:
        similarity = SequenceMatcher(None, search_term_lower, name.lower()).ratio()
        if similarity >= threshold:
            fund_row = coverpage_df[coverpage_df['FILINGMANAGER_NAME'] == name].iloc[0]
            matches.append({
                'FILINGMANAGER_NAME': name,
                'ACCESSION_NUMBER': fund_row['ACCESSION_NUMBER'],
                'similarity': similarity
            })

    return pd.DataFrame(matches).sort_values('similarity', ascending=False)

Method 3: Partial String Matching (Simple)

python
def substring_search(search_term, coverpage_df, case_sensitive=False):
    """
    Simple substring matching (works for known partial names)
    """
    if case_sensitive:
        matches = coverpage_df[coverpage_df['FILINGMANAGER_NAME'].str.contains(search_term, na=False)]
    else:
        matches = coverpage_df[coverpage_df['FILINGMANAGER_NAME'].str.contains(
            search_term, case=False, na=False
        )]

    return matches[['FILINGMANAGER_NAME', 'ACCESSION_NUMBER']]

Matching Algorithms Comparison

AlgorithmUse CaseProsCons
token_sort_ratioHandles reordered words"technologies renaissance" ≈ "renaissance technologies"Slower
token_set_ratioHandles subset words"Renaissance Tech" ≈ "Renaissance Technologies"Slower
fuzz.ratioExact character matchFast, simpleSensitive to word order
SequenceMatcherQuick approximate matchBuilt-in, no depsLess sophisticated
Substring matchKnown partial namesFastestOnly works with exact substrings

Best Practices

1. Start with a Reasonable Threshold

python
# For very fuzzy matches
matches = fuzzy_search_fund("berkshire", coverpage_df, threshold=50)

# For tighter matches
matches = fuzzy_search_fund("berkshire hathaway", coverpage_df, threshold=80)

2. Clean Search Terms

python
def clean_search_term(term):
    """Remove extra whitespace and punctuation"""
    return ' '.join(term.lower().strip().split())

search = clean_search_term("  RENAISSANCE TECHNOLOGIES  ")
# Result: "renaissance technologies"

3. Validate Top Match

python
matches = fuzzy_search_fund("warren buffett", coverpage_df)

if len(matches) > 0:
    best = matches.iloc[0]
    print(f"Found: {best['FILINGMANAGER_NAME']}")
    print(f"Match Score: {best['match_score']}")
    print(f"Accession: {best['ACCESSION_NUMBER']}")

    # Manual verification
    assert 'berkshire' in best['FILINGMANAGER_NAME'].lower(), "Match doesn't contain expected keyword"
else:
    print("No matches found")

Common Search Patterns

python
# Search for famous fund managers
q3_data = pd.read_csv('/root/2025-q3/COVERPAGE.tsv', sep='\t')

# Renaissance Technologies (Jim Simons)
renaissance = fuzzy_search_fund("renaissance technologies", q3_data)

# Berkshire Hathaway (Warren Buffett)
berkshire = fuzzy_search_fund("berkshire hathaway", q3_data)

# Citadel
citadel = fuzzy_search_fund("citadel", q3_data)

# Tiger Global
tiger = fuzzy_search_fund("tiger global", q3_data)

Example: Complete Fund Lookup Workflow

python
import pandas as pd
from fuzzywuzzy import process, fuzz

def find_and_verify_fund(search_term, coverpage_df, expected_keywords=None):
    """
    Find a fund and verify the match
    """
    # Fuzzy search
    fund_names = coverpage_df['FILINGMANAGER_NAME'].tolist()
    matches = process.extractBests(
        search_term,
        fund_names,
        scorer=fuzz.token_sort_ratio,
        score_cutoff=70,
        limit=3
    )

    # Verify with expected keywords
    for matched_name, score in matches:
        if expected_keywords is None or all(
            keyword.lower() in matched_name.lower()
            for keyword in expected_keywords
        ):
            fund_row = coverpage_df[
                coverpage_df['FILINGMANAGER_NAME'] == matched_name
            ].iloc[0]
            return {
                'fund_name': matched_name,
                'accession_number': fund_row['ACCESSION_NUMBER'],
                'quarter': fund_row['REPORTCALENDARORQUARTER'],
                'match_score': score
            }

    return None

# Usage
result = find_and_verify_fund(
    "renaissance",
    q3_data,
    expected_keywords=['renaissance', 'tech']
)

Troubleshooting

No Matches Found

  • Lower the threshold: threshold=50 instead of 80
  • Try simpler search terms: "Renaissance" instead of "Renaissance Technologies"
  • Check if fund exists in data: coverpage_df['FILINGMANAGER_NAME'].str.contains(partial_name, case=False).any()

Too Many Matches

  • Increase threshold: threshold=85 instead of 70
  • Add more specific keywords: "berkshire hathaway" instead of "berkshire"

Wrong Match Selected

  • Manually inspect top matches before using
  • Add validation keywords to filter results
  • Use limit=5 to get multiple options and review manually

Frequently asked questions

What does the Fuzzy Fund Search AI skill do?

Fuzzy matching techniques for finding hedge funds by name when exact names are unknown

Why use Fuzzy Fund Search on TypingMind?

Because you install it once and use it with any model. Fuzzy Fund Search is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Fuzzy Fund Search in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/cxcscmu/SkillLearnBench/tree/main/skills/b1-one-shot-claude-haiku-4-5/financial-analysis/fuzzy-fund-search. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Fuzzy Fund Search?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Fuzzy Fund Search?

As many as you like. As long as a model supports skills, you can use Fuzzy Fund Search with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Fuzzy Fund Search AI skill free?

Yes. It is published on GitHub by cxcscmu under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇