agentsclimarketplace

Suffix structure builder

Skill a5c-ai/babysitter/library/specializations/algorithms-optimization/skills/suffix-structure-builder

Build and query suffix arrays and related structuresFrom its SKILL.md

Install
npx -y skills add a5c-ai/babysitter --skill suffix-structure-builder

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

SKILL.md

2.0 KB, 429 tokens by cl100k_base, as published. Nobody here has run it

Suffix Structure Builder Skill

Purpose

Build suffix arrays, suffix trees, and related structures with efficient construction algorithms and common query implementations.

Capabilities

  • Suffix array construction (SA-IS, DC3)
  • LCP array construction
  • Suffix tree construction
  • Suffix automaton construction
  • Query implementations for each structure
  • Sparse table for LCP queries

Target Processes

  • trie-suffix-structures
  • pattern-matching-algorithms
  • string-processing

Suffix Structures

Suffix Array

  • O(n log n) or O(n) construction
  • Combined with LCP for powerful queries
  • Pattern matching in O(m log n)

LCP Array

  • Kasai's algorithm O(n)
  • Range minimum queries for LCA
  • Distinct substring counting

Suffix Tree

  • Ukkonen's algorithm O(n)
  • More complex but powerful
  • Direct pattern matching O(m)

Suffix Automaton

  • O(n) construction
  • Smallest automaton for all substrings
  • Powerful for counting problems

Input Schema

{
  "type": "object",
  "properties": {
    "structure": {
      "type": "string",
      "enum": ["suffixArray", "lcpArray", "suffixTree", "suffixAutomaton"]
    },
    "algorithm": { "type": "string" },
    "queries": { "type": "array" },
    "language": {
      "type": "string",
      "enum": ["cpp", "python", "java"]
    }
  },
  "required": ["structure"]
}

Output Schema

{
  "type": "object",
  "properties": {
    "success": { "type": "boolean" },
    "code": { "type": "string" },
    "complexity": { "type": "object" },
    "queryImplementations": { "type": "array" }
  },
  "required": ["success", "code"]
}

What ships with it: 1 file

656 B alongside SKILL.md

Keep looking

Skills are one crate of 326,059. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.