o9k-search

Search hmem when the user references something without an ID — past conversations ('letzte Woche', 'remember when'), unknown proper names, definite articles assuming shared context ('the bug we had', 'das Schema von gestern'), or asks whether a schema/rule/decision is documented. Search first, ask second. Skip for explicit ID lookups like 'read P0048'.

10 stars

Best use case

o9k-search is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Search hmem when the user references something without an ID — past conversations ('letzte Woche', 'remember when'), unknown proper names, definite articles assuming shared context ('the bug we had', 'das Schema von gestern'), or asks whether a schema/rule/decision is documented. Search first, ask second. Skip for explicit ID lookups like 'read P0048'.

Teams using o9k-search should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/o9k-search/SKILL.md --create-dirs "https://raw.githubusercontent.com/Bumblebiber/hmem/main/skills/o9k-search/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/o9k-search/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How o9k-search Compares

Feature / Agento9k-searchStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Search hmem when the user references something without an ID — past conversations ('letzte Woche', 'remember when'), unknown proper names, definite articles assuming shared context ('the bug we had', 'das Schema von gestern'), or asks whether a schema/rule/decision is documented. Search first, ask second. Skip for explicit ID lookups like 'read P0048'.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# hmem Search

When the user references past context without pinning it to an ID, or when looking up definitions, schemas, or decisions stored in hmem — convert the intent into a targeted `read_memory` query.

## Workflow

1. **Extract from the prompt:**
   - **Keywords** — distinctive nouns, project names, error fragments, schema names. Skip filler like "wir", "neulich", "besprochen", "Schema für".
   - **Time hint** — map to `after`/`before` range using the current date as anchor. "gestern" → narrow (−1 to 0d), "letzte Woche" → medium (−10 to −3d), "neulich"/"vor kurzem" → generous (−21d). No time hint → skip the range.

2. **First search:**
   ```
   read_memory({ search: "<keywords>", after: "<ISO>", before: "<ISO>" })
   ```
   Keywords as a single space-separated string. Use ISO dates (`2026-04-11`), not relative forms.

3. **If results are empty or off-topic — work through this sequence immediately, without waiting:**

   **a) Drop time filter, keep keywords**
   Time hints from humans are fuzzy; the memory may sit just outside the window.

   **b) Try term variations — systematically, not just once**
   The stored entry may use a different phrasing than what the user said. Try all that apply:
   - German ↔ English: "Schema" → "schema", "Entscheidung" → "decision", "Fehler" → "error"
   - Abbreviations or expansions: "H-Schema" → "H-Entry Schema", "O-Eintrag" → "O-entry"
   - Compound splits: "Standardschema" → "Standard Schema", "Checkpoint-Strategie" → "checkpoint strategy"
   - Synonyms: "Kollision" → "conflict", "Struktur" → "structure", "Vorlage" → "template"
   - Broader category: "H-Standardschema" → "H-entry", "entry schema", "Human schema"
   - Related prefix: if the topic is about a specific entry type (H, P, E, I…), search that prefix directly via `read_memory({ prefix: "R", search: "H" })`

   Don't try one variation and stop. Run 2–3 variations before concluding nothing was found.

   **c) Switch store**
   Default is `personal`. If the topic is work-related and personal turned up nothing, try `store: "company"`.

   **d) Broaden with `find_related`**
   If you found *something* related but not quite right, use `find_related({ id: "<hit-ID>" })` to surface linked entries.

   Only report "nothing found" after all of these have failed.

4. **Present the hits:**
   - Top 3–5 most relevant: `ID · date · one-line summary`.
   - If the question implies drilling into one entry, offer `read_memory({ id: "..." })` rather than dumping everything.

## Why term variation matters

hmem entries are titled by whoever created them, not by a controlled vocabulary. "H-Standardschema" might be stored as "H-Entry Schema: Standard-Struktur für Human-Context-Einträge" (R0025). The search engine does substring/FTS matching, but only within what's actually stored. If the first search misses, the entry almost certainly exists under a different phrasing — not in a different location.

The failure mode to avoid: searching once, getting no results, and concluding the information doesn't exist. **A null result is a signal to try harder, not a final answer.**

## The "assumed shared knowledge" trigger

The user often speaks as if you already know things you don't — because from *their* side, the conversation is continuous across sessions. Watch for:

- **Definite articles without prior mention:** "der Bug mit dem Sync", "das Problem von neulich", "die Entscheidung zum Schema" — the `der/das/die` implies you should know which one.
- **Proper names dropped cold:** a project, person, feature, or error name you haven't seen this session.
- **Casual callbacks:** "wie besprochen", "wie gesagt", "du weißt schon", "as we agreed".
- **Assumed status:** "wo stehen wir mit X?", "ist Y schon fertig?"
- **Schema/rule lookups:** "gibt es ein Standard für X?", "was ist das Schema für Y?", "was haben wir zu Z beschlossen?"

When this pattern shows up: search first, answer second.

## Don't

- Don't pre-parse time into a fixed dictionary (`"neulich" → 14d`). Context shifts the right window.
- Don't silently search only `personal` when the context is clearly work-related.
- Don't return raw `read_memory` output to the user. Summarize what was found.
- Don't trigger when the user cites a specific ID — they already know where to look.
- **Don't stop after a single null result.** Work through the variation sequence before giving up.

## Related tools

- `search_memory` — dedicated FTS5 endpoint; `read_memory({ search })` covers the same ground with structured output.
- `find_related(id)` — after locating a hit, surface linked entries.
- `read_memory({ time_around: "<ID>" })` — once you have an anchor, find entries created around the same time.
- `read_memory({ prefix: "R" })` — scan all Rules when looking for documented standards or constraints.

Related Skills

We are still matching the closest adjacent skills for this page. In the meantime, continue through the full directory.